Last active
May 5, 2016 08:36
-
-
Save xiaxianlin/bc82f10d29630889e348bd02c7ee8a21 to your computer and use it in GitHub Desktop.
Untitled
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
.btn{ | |
position: relative; | |
width: 100px; | |
text-align: center; | |
line-height: 30px; | |
color: #fff; | |
margin: 150px auto; | |
background: #58a; | |
} | |
.btn:before, | |
.btn:after{ | |
content: ' '; | |
position: absolute; | |
z-index: -1; | |
display: block; | |
width: 0; | |
height: 0; | |
} | |
.btn:before{ | |
border: 10px solid transparent; | |
border-right-color: red; | |
left: -10px; | |
bottom: -10px; | |
} | |
.btn:after{ | |
border: 15px solid transparent; | |
border-left-color: #58a; | |
border-bottom-color: #58a; | |
top: 0; | |
right: -30px; | |
} |
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="btn">button</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