Last active
January 30, 2016 18:59
-
-
Save oboenikui/f148f2699b91a63c531c to your computer and use it in GitHub Desktop.
やばいSnippet
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
var style = document.createElement("style"); | |
style.innerHTML = | |
[` | |
@keyframes blink { | |
75% { opacity: 0.0; } | |
} | |
@-webkit-keyframes blink { | |
75% { opacity: 0.0; } | |
} | |
body { | |
animation: blink 1s step-end infinite; | |
-webkit-animation: blink 1s step-end infinite; | |
} | |
`, | |
` | |
body { | |
width: 450px; | |
margin: 0 auto; | |
overflow: hidden; | |
white-space: nowrap; | |
box-sizing: border-box; | |
animation: marquee 50s linear infinite; | |
} | |
/* Make it move */ | |
@keyframes marquee { | |
0% { text-indent: 27.5em } | |
100% { text-indent: -105em } | |
} | |
`][~~Math.floor(Math.random()*2)] | |
document.head.appendChild(style); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment