-
-
Save jonabaptistella/ef8e905a98bab056b8fcfabc1e28b36c to your computer and use it in GitHub Desktop.
Infinite rotation by CSS. Useful for loading spinners.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @keyframes rotating | |
| { | |
| from | |
| { | |
| transform: rotate(0deg); | |
| -o-transform: rotate(0deg); | |
| -ms-transform: rotate(0deg); | |
| -moz-transform: rotate(0deg); | |
| -webkit-transform: rotate(0deg); | |
| } | |
| to | |
| { | |
| transform: rotate(360deg); | |
| -o-transform: rotate(360deg); | |
| -ms-transform: rotate(360deg); | |
| -moz-transform: rotate(360deg); | |
| -webkit-transform: rotate(360deg); | |
| } | |
| } | |
| @-webkit-keyframes rotating | |
| { | |
| from | |
| { | |
| transform: rotate(0deg); | |
| -webkit-transform: rotate(0deg); | |
| } | |
| to | |
| { | |
| transform: rotate(360deg); | |
| -webkit-transform: rotate(360deg); | |
| } | |
| } | |
| .rotating | |
| { | |
| -webkit-animation: rotating 1s linear infinite; | |
| -moz-animation: rotating 1s linear infinite; | |
| -ms-animation: rotating 1s linear infinite; | |
| -o-animation: rotating 1s linear infinite; | |
| animation: rotating 1s linear infinite; | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment