fix(menu): don't disable overflow when menu open
All checks were successful
Deploy workflow / deploy (push) Successful in 29s

This commit is contained in:
Matthieu Bessat 2024-03-15 20:28:30 +01:00
parent 2860b6cbbf
commit 9946d619ff

View file

@ -46,12 +46,16 @@
const nav_button = document.getElementById("navi-toggle") const nav_button = document.getElementById("navi-toggle")
nav_button.addEventListener("change", event => { nav_button.addEventListener("change", event => {
if (event.target.checked) { if (event.target.checked) {
/*
document.documentElement.style.overflow = "hidden"; document.documentElement.style.overflow = "hidden";
document.body.style.overflow = "hidden"; document.body.style.overflow = "hidden";
*/
} }
if (!event.target.checked) { if (!event.target.checked) {
document.documentElement.overflow = "initial"; /*
document.documentElement.style.overflow = "initial";
document.body.style.overflow = "initial"; document.body.style.overflow = "initial";
*/
} }
}) })
</script> </script>