From 611c9bb14d6d97e2975d8412d41271847f16fb74 Mon Sep 17 00:00:00 2001 From: Matthieu Bessat Date: Fri, 15 Mar 2024 20:28:30 +0100 Subject: [PATCH] fix(menu): don't disable overflow when menu open --- layouts/partials/header.html | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/layouts/partials/header.html b/layouts/partials/header.html index ee76de0..503b8b1 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -46,11 +46,13 @@ const nav_button = document.getElementById("navi-toggle") nav_button.addEventListener("change", event => { if (event.target.checked) { + /* document.documentElement.style.overflow = "hidden"; document.body.style.overflow = "hidden"; + */ } if (!event.target.checked) { - document.documentElement.overflow = "initial"; + document.documentElement.style.overflow = "initial"; document.body.style.overflow = "initial"; } })