Created
May 8, 2024 18:04
-
-
Save GradientAnimator/dc6d8e334a5f9b111d344d8fd37a153f to your computer and use it in GitHub Desktop.
CSS Gradient Animation
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
.css-selector { | |
background: linear-gradient(319deg, #0c4cd0, #e37318, #ff0000); | |
background-size: 600% 600%; | |
-webkit-animation: grad 23s ease infinite; | |
-moz-animation: grad 23s ease infinite; | |
-o-animation: grad 23s ease infinite; | |
animation: grad 23s ease infinite; | |
} | |
@-webkit-keyframes grad { | |
0%{background-position:5% 0%} | |
50%{background-position:96% 100%} | |
100%{background-position:5% 0%} | |
} | |
@-moz-keyframes grad { | |
0%{background-position:5% 0%} | |
50%{background-position:96% 100%} | |
100%{background-position:5% 0%} | |
} | |
@-o-keyframes grad { | |
0%{background-position:5% 0%} | |
50%{background-position:96% 100%} | |
100%{background-position:5% 0%} | |
} | |
@keyframes grad { | |
0%{background-position:5% 0%} | |
50%{background-position:96% 100%} | |
100%{background-position:5% 0%} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment