Created
October 8, 2019 16:15
-
-
Save isaadansari/f73f738f103949c0a2f92330bcafa048 to your computer and use it in GitHub Desktop.
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
.checkboxes { | |
cursor: pointer; | |
-webkit-user-select: none; | |
-moz-user-select: none; | |
-ms-user-select: none; | |
user-select: none; | |
input { | |
position: absolute; | |
opacity: 0; | |
cursor: pointer; | |
height: 0; | |
width: 0; | |
} | |
&:hover { | |
input ~ .checkmark { | |
background-color: rgb(248, 248, 248); | |
} | |
} | |
input:focus ~ .checkmark { | |
border: 1px dashed #0067b9; | |
} | |
input:checked ~ .checkmark { | |
background-color: #fff; | |
} | |
input:checked ~ .checkmark:after { | |
display: block; | |
} | |
.checkmark:after { | |
left: 7px; | |
top: 2px; | |
width: 5px; | |
height: 12px; | |
border: solid #000; | |
border-width: 0 2px 2px 0; | |
-webkit-transform: rotate(45deg); | |
-ms-transform: rotate(45deg); | |
transform: rotate(45deg); | |
} | |
} | |
.checkmark { | |
position: absolute; | |
top: 0; | |
left: 0; | |
width: 20px; | |
height: 20px; | |
border-radius: 2px; | |
border: solid 1px #c5c5c5; | |
background-color: #ffffff; | |
&:after { | |
content: ''; | |
position: absolute; | |
display: none; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment