Created
August 21, 2012 00:21
-
-
Save charliepark/3409697 to your computer and use it in GitHub Desktop.
CSS animations to give a div a rainbow border, perpetually changing color
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
@-webkit-keyframes rainbow { | |
0% {border-color: hsl(0, 100%, 50%);} | |
100% {border-color: hsl(255, 100%, 50%);} | |
} | |
.rainbow_border{ | |
border: 4px solid hsl(0, 100%, 50%); | |
-webkit-animation: rainbow 5s infinite alternate; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I gave it more colors based on a seven-color rainbow. This makes it seem more so like a rainbow
Found: Here
then increased the time