-
-
Save PatrickJS/5f327021632c87a846f1 to your computer and use it in GitHub Desktop.
Triangle with Shadow
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
/* | |
Triangle with Shadow | |
*/ | |
.triangle-with-shadow { | |
width: 50px; | |
height: 100px; | |
position: relative; | |
overflow: hidden; | |
box-shadow: none | |
} | |
.triangle-with-shadow:after { | |
content: ""; | |
position: absolute; | |
width: 150px; | |
height: 50px; | |
background: #999; | |
transform: rotate(45deg); | |
top: -20px; | |
left: -110px; | |
box-shadow: 1px 1px 10px 1px rgba(0,0,0,0.5); | |
} | |
.triangle-with-shadow:hover, .triangle-with-shadow:hover:after { | |
box-shadow: none; | |
} |
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="triangle-with-shadow"></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
{"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