-
-
Save jinze/ccd3a4644d251cfcbae72ad56315c350 to your computer and use it in GitHub Desktop.
Marching ants border
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
/** | |
* Marching ants border | |
*/ | |
.wrapper{ | |
border: 1PX solid rgba(0,0,0,0); | |
background-image: linear-gradient(#fff, #fff), repeating-linear-gradient(-45deg, #000 0, #000 12.5%, transparent 0, transparent 25%, #000 0, #000 37.5%, transparent 0,transparent 50%); | |
background-clip:padding-box, border-box; | |
background-size:1em 1em; | |
width:700px; | |
height:300px; | |
box-sizing:border-box; | |
padding: 1em; | |
animation: ants 20s linear infinite; | |
} | |
@keyframes ants { | |
to { background-position: 100% 100%; } | |
} |
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
<div class="wrapper"></div> |
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
// alert('Hello world!'); |
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
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment