
A couple of years ago, when CSS trigonometry functions became baseline, I wrote an article about them. One of the examples I did, was a CSS-only an...
For further actions, you may consider blocking this person and/or reporting abuse
sick
Awesome, thank you ;-)
Thanks!
First off, great work! Love the cleverness of it all and the styling. Learned alot. Thanks for designing and posting this.
Second, I know this is an older post but figured I would point this out anyway. It looks like there is a small flaw in the minute/hourly animations. The animation for the minute hand (and hour) move NOT at the top of the minute (or hour), but they move dependent upon when you loaded/refreshed the page. Meaning? If you load/refresh the page at 10:05:17 then the minute hand will not move until 10:06:17 when it should have moved at 10:06:00. The same holds true for the hour hand.
Luckily the fix is simple. Just change the UpdateClock function to determine the proper offsets. There are two places below that need to be changed. First, calcuate the animation offsets. Second, make a tweak to the existing code that set the offsets, but use them directly (there was some fuzzy addition here previously)
Great finding, thank you!
Thank you! This is awesome! However, there's a small issue causing the script to work incorrectly with fractional time zones. For example, when the timezone is set to +9.5, the clock displays the time half an hour earlier than it should.
To fix this, simply replace parseInt with** parseFloat** when retrieving the timezone value from the element attribute. This will ensure that fractional offsets are handled correctly.
This error exists even in the CDN.
Ah, didn't think about that — thanks for letting me know!
I've added this method, so it rounds the timezone to nearest quarter of an hour:
And since you're called StanTheMan70 — here's Stan The Man and me, 25 years ago ;-)
Holy CSS!
Nice, but you can just name the variable
--d
without the underscore, neater.That's to indicate the variable should be considerend "private".
This is timeless CSS at it's best
Thank you!
next I want an overly complicated button made using only CSS. Now that's a keeper
🕖
This looks so good🌟Thanks for sharing!
Thanks!
Great work thanks.
Thanks!
So nice!
Thanks!
Wow! Very interesting! Clocks are hard! Thanks for sharing!
Thank you!
Noice, The clock is so smooth, thanks for sharing
Thank you!
COOL👍MARK❤
Thanks!
Good Job !
Thanks!
Absolutely amazing
Thanks!
Great, It seems awesome 🙌
Thanks!
This is so cool, thanks for sharing.
Thanks!
good quilt
Very good!
Thanks!
Great article, thanks.
Always knew that trigonometry is cool ))
Yeah, it is!
Awesome!!! Excellent!
Thank you!!