-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Introduce animation helpers for loading icons
- Loading branch information
1 parent
4a943d4
commit 99be881
Showing
10 changed files
with
84 additions
and
32 deletions.
There are no files selected for viewing
This file contains 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
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains 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
Large diffs are not rendered by default.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
// General purpose helpers for common situations. Unlike utilities, helpers usually cover more CSS | ||
// properties than one. And unlike with utilities, using `!important` is not allowed here. | ||
|
||
$_spin-count: 4; | ||
$_spin-duration: 2.2s; | ||
$_spin-easing: cubic-bezier(0.31, 0.3, 0.34, -0.17); | ||
|
||
@keyframes spin { | ||
0% { | ||
transform: rotate(0 * 360deg); | ||
} | ||
|
||
100% { | ||
transform: rotate($_spin-count * 360deg); | ||
} | ||
} | ||
|
||
:global(.animation-spin-clockwise) { | ||
animation: spin $_spin-duration $_spin-easing infinite; | ||
} | ||
|
||
:global(.animation-spin-counterclockwise) { | ||
animation: spin $_spin-duration $_spin-easing infinite reverse; | ||
} |