mirror of https://github.com/moparisthebest/mail
76 lines
1.7 KiB
SCSS
Executable File
76 lines
1.7 KiB
SCSS
Executable File
// Navigation
|
|
// -------------------------
|
|
|
|
.nav-container {
|
|
position: relative;
|
|
overflow: hidden;
|
|
height: 100%;
|
|
}
|
|
|
|
.nav-pusher {
|
|
position: relative;
|
|
left: 0;
|
|
z-index: 99;
|
|
height: 100%;
|
|
background: $color-white;
|
|
will-change: transform;
|
|
@include respond-to(desktop) {
|
|
transition: transform $time-nav-animation ease-out;
|
|
}
|
|
|
|
&:after {
|
|
position: absolute;
|
|
top: 0;
|
|
right: 0;
|
|
width: 0;
|
|
height: 0;
|
|
background: rgba(0,0,0,0.2);
|
|
width: 100%;
|
|
height: 100%;
|
|
content: '';
|
|
opacity: 0;
|
|
transform: scale(0, 0);
|
|
@include respond-to(desktop) {
|
|
transition: opacity $time-nav-animation, transform 0.1s $time-nav-animation;
|
|
}
|
|
}
|
|
}
|
|
|
|
.nav-menu {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
width: $nav-width;
|
|
max-width: $nav-max-width;
|
|
height: 100%;
|
|
background: $color-blue;
|
|
background-image: linear-gradient(to right, $color-blue 98%, darken($color-blue, 1%) 100%);
|
|
border-right: 1px solid $color-grey-light;
|
|
transform: translate3d(-50%, 0, 0);
|
|
will-change: transform;
|
|
|
|
@include respond-to(desktop) {
|
|
transition: transform $time-nav-animation ease-out;
|
|
}
|
|
}
|
|
|
|
.nav-menu-open {
|
|
.nav-menu {
|
|
transform: translateX(0);
|
|
}
|
|
.nav-pusher {
|
|
transform: translateX($nav-max-width);
|
|
@media(max-width: 450px) {
|
|
transform: translateX($nav-width);
|
|
}
|
|
|
|
&:after {
|
|
transform: scale(1, 1);
|
|
opacity: 1;
|
|
@include respond-to(desktop) {
|
|
transition: opacity $time-nav-animation;
|
|
}
|
|
}
|
|
}
|
|
}
|