A Pen by Elijah Manor on CodePen.
Forked from elijahmanor/CSS-Hamburger-Icon.markdown
Last active
August 29, 2015 14:24
-
-
Save jthigh/1c9f12ec8bed39df6283 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
<a id="nav-toggle" href="#"><span></span></a> |
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
#nav-toggle span, #nav-toggle span:before, #nav-toggle span:after { | |
cursor: pointer; | |
border-radius: 1px; | |
height: 5px; | |
width: 35px; | |
background: white; | |
position: absolute; | |
display: block; | |
content: ''; | |
} | |
#nav-toggle span:before { | |
top: -10px; | |
} | |
#nav-toggle span:after { | |
bottom: -10px; | |
} |
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
#nav-toggle span { | |
&, &:before, &:after { | |
cursor: pointer; | |
-webkit-border-radius: 1px; | |
border-radius: 1px; | |
height: 5px; | |
width: 35px; | |
background: white; | |
position: absolute; | |
display: block; | |
content: ''; | |
} | |
&:before { | |
top: -10px; | |
} | |
&:after { | |
bottom: -10px; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment