Created
May 15, 2013 12:51
-
-
Save kizu/5583779 to your computer and use it in GitHub Desktop.
Switch, label don't work :(
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
/* Switch, label don't work :( */ | |
.board { | |
position: absolute; | |
top: 0; | |
z-index: 0; | |
} | |
.board:before { | |
content: ""; | |
position: absolute; | |
top: 0; | |
left: 0; | |
right: 0; | |
bottom: 0; | |
background: #FFF; | |
z-index: -1; | |
} | |
.board .board { | |
z-index: -2; | |
} | |
.board .board:not(:active) { | |
z-index: -2; | |
transition: z-index 0s 999999s; | |
} | |
.board label:active ~ .board { | |
z-index: 0; | |
transition: z-index 0s; | |
} |
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 class="board"> | |
<input type="checkbox" id="a1"><label for="a1">a1</label> | |
<div class="board"> | |
<input type="checkbox" id="a2"><label for="a2">a2</label> | |
</div> | |
</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
// alert('Hello world!'); |
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":"css"} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment