website/static/javascript/navbar.js
grey-cat-1908 8f0c07fe89 hihi-haha
2023-10-21 12:46:00 +03:00

15 lines
No EOL
352 B
JavaScript

let navOpen = false
function getNavbar() {
let navbar = document.getElementById("nav-toggle")
switch (navOpen) {
case false:
navbar.classList.add("active")
navOpen = true;
break;
case true:
navbar.classList.remove("active")
navOpen = false;
break;
}
}