Created
March 6, 2012 01:13
-
-
Save ootz0rz/1982665 to your computer and use it in GitHub Desktop.
CSS3 checkbox
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
li:before { | |
/* add space, create an "L" from borders, and rotate to make a checkmark */ | |
content:"\00a0"; | |
/* Make it a small rectangle so the border will create an L-shape */ | |
width: 6px; | |
height: 12px; | |
/* Add a white border on the bottom and left, creating that 'L' */ | |
border: solid #fff; | |
border-width: 0 3px 3px 0; | |
/* position relative to text */ | |
position: absolute; | |
left: 10px; | |
top: 40%; | |
margin-top: -6px; | |
/* Rotate the L 45 degrees to turn it into a checkmark */ | |
-webkit-transform: rotate(45deg); | |
-moz-transform: rotate(45deg); | |
-o-transform: rotate(45deg); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment