Le menu mobile s'affiche et s'enlève
This commit is contained in:
parent
1e196708fa
commit
842af85788
2 changed files with 30 additions and 6 deletions
|
@ -83,3 +83,21 @@ text-decoration: none;
|
|||
}
|
||||
}
|
||||
|
||||
.headerMenuMobile{
|
||||
font-family: "Poppins";
|
||||
font-weight: 400; /*regular*/
|
||||
font-size: 1.25rem; /*20px*/
|
||||
color: #000; /*Noir pur*/
|
||||
list-style: none;
|
||||
font-style: none;
|
||||
display: none;
|
||||
}
|
||||
.nav-is-active{
|
||||
background-color: #fff;
|
||||
display: flex;
|
||||
flex-flow: column;
|
||||
justify-content: space-between;
|
||||
position: fixed;
|
||||
top: 75px;
|
||||
}
|
||||
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
<link rel="stylesheet" href="/public/css/header.css">
|
||||
<script>
|
||||
function onToggleNav() {
|
||||
var menu = document.querySelector(".headerMenu");
|
||||
var menu = document.querySelector(".headerMenuMobile");
|
||||
console.log(menu);
|
||||
menu.classList.toggle('nav-is-active');
|
||||
}
|
||||
|
@ -18,6 +18,12 @@
|
|||
</ul>
|
||||
<img class="headerMenuHamburger" src="/public/icones/hamburger-menu.svg" onclick="onToggleNav()"></img>
|
||||
</div>
|
||||
<ul class="headerMenuMobile">
|
||||
<li class="headerMenuElement"><a href="/">AGECEM</a></li>
|
||||
<li class="headerMenuElement"><a href="/vie-etudiante">Vie étudiante</a></li>
|
||||
<li class="headerMenuElement"><a href="/documentation">Documentation</a></li>
|
||||
<li class="headerMenuElement"><a href="/admin">admin</a></li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue