Passage en flex-column du menu latéral

This commit is contained in:
Darks 2019-12-02 22:54:01 +01:00
parent f7e9715572
commit 7f63577c4f
Signed by: Darks
GPG Key ID: F61F10FA138E797C
2 changed files with 10 additions and 9 deletions

View File

@ -1,5 +1,5 @@
.container {
margin-left: 140px;
margin-left: 110px;
}
section {

View File

@ -14,7 +14,7 @@ nav a:focus {
#light-menu {
position: fixed; z-index: 10;
list-style: none;
width: 140px;
width: 110px;
height: 100%; overflow-y: auto;
margin: 0; padding: 0;
text-indent: 0;
@ -32,8 +32,8 @@ nav a:focus {
transition: .15s ease;
}
#logo img {
width: 40%;
margin: 0 0 -4.5px 7px; padding: 0;
display: block; height: 50px;
margin: 0 auto; padding: 0;
filter: drop-shadow(0 0 2px rgba(0, 0, 0, .0));
transition: filter .15s ease;
}
@ -47,13 +47,14 @@ nav a:focus {
}
#light-menu li {
width: 100%; height: 45px;
width: 100%;
color: #ffffff;
}
#light-menu li > a {
display: flex; flex-direction: row; flex-grow: 0;
display: flex; flex-direction: column; flex-grow: 0;
align-items: center; justify-content: flex-start;
width: 100%; height: 100%;
margin-bottom: 15px;
transition: opacity .15s ease; /* because Chrome sucks */
}
@ -69,18 +70,18 @@ nav a:focus {
/* Overlay */
#menu {
position: fixed; z-index: 5;
left: -160px; width: 300px; /* default: left-to-right animation */
left: -190px; width: 300px; /* default: left-to-right animation */
height: 100%; overflow-x: hidden; overflow-y: auto;
background: #1c2124; box-shadow: 0 0 5px rgba(0, 0, 0, 0.3);
transition: .15s ease;
}
#menu.opened {
left: 140px;
left: 110px;
}
/* Just apply class="scroll-animation" to menu to change to scroll animation */
#menu.scroll-animation {
left: 140px; width: 0;
left: 110px; width: 0;
}
#menu.scroll-animation.opened {
width: 300px;