Created
November 7, 2012 15:29
-
-
Save minitech/4032249 to your computer and use it in GitHub Desktop.
Using a box-shadow to mimic a gradient
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
/** | |
* Using a box-shadow to mimic a gradient | |
*/ | |
#item { | |
background-color: #07f; | |
border-radius: 0.2em; | |
box-shadow: inset 0 -1em 1em -0.5em rgba(0, 0, 0, 0.7); | |
color: white; | |
display: inline-block; | |
font-family: sans-serif; | |
padding: 0.2em; | |
} |
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
<div id="item">Hello, world!</div> |
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
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"all"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment