Last active
August 29, 2015 14:21
-
-
Save Korveld/454d97434f773aac999a to your computer and use it in GitHub Desktop.
Sandwich sass
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
.toggle-mnu | |
width: 60px | |
height: 50px | |
position: absolute | |
z-index: 100 | |
border: none | |
right: 20px | |
top: 9px | |
background-color: #1b1464 | |
display: none | |
span | |
display: block | |
$w: 34px | |
$h: 3px | |
.sandwich | |
width: $w | |
height: $w | |
position: absolute | |
top: 12px | |
bottom: 0 | |
left: 0 | |
right: 0 | |
margin: auto | |
z-index: 200 | |
display: block | |
.sw-topper | |
position: relative | |
top: 0 | |
width: $w | |
height: $h | |
background: rgb(255, 255, 255) | |
border: none | |
border-radius: 4px 4px 4px 4px | |
transition: transform 0.5s, top 0.2s | |
.sw-bottom | |
position: relative | |
width: $w | |
height: $h | |
top: $h * 2.2 | |
background: rgb(255, 255, 255) | |
border: none | |
border-radius: 4px 4px 4px 4px | |
transition: transform 0.5s, top 0.2s | |
transition-delay: 0.2s, 0s | |
.sw-footer | |
position: relative | |
width: $w | |
height: $h | |
top: $h * 4.5 | |
background: rgb(255, 255, 255) | |
border: none | |
border-radius: 4px 4px 4px 4px | |
transition: all 0.5s | |
transition-delay: 0.1s | |
.sandwich.active | |
.sw-topper | |
top: 9px | |
transform: rotate(-45deg) | |
.sw-bottom | |
top: 6px | |
transform: rotate(45deg) | |
.sw-footer | |
opacity: 0 | |
top: 0 | |
transform: rotate(180deg) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment