Skip to content

Instantly share code, notes, and snippets.

@john555
Last active April 26, 2018 07:34
Show Gist options
  • Save john555/55f9a52bd6b58f00b40558d4c988cfe1 to your computer and use it in GitHub Desktop.
Save john555/55f9a52bd6b58f00b40558d4c988cfe1 to your computer and use it in GitHub Desktop.
.hour {
...
animation: rotateHourHand calc(12 * 60 * 60s) linear infinite;
animation-delay: calc(calc(var(--start-minutes) * -60 * 1s) + calc(var(--start-seconds) * -1 * 1s));
}
@keyframes rotateHourHand {
from {
transform: translate(20px, 20px) rotate(calc(var(--start-hours) * 30deg));
}
to {
transform: translate(20px, 20px) rotate(calc(var(--start-hours) * 30deg + 360deg));
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment