Fixed a bug where clicking Services in the mobile navigation would

immediately close the window.
This commit is contained in:
blake committed 2026-02-18 16:09:48 -06:00
1 parent d16d8732c8
commit 287af0ecc2
7 files changed
+8 -6

No files matched your search

+2
View File
@@ -12,6 +12,8 @@ const navLinks = document.querySelectorAll(".main-nav-link");
navLinks.forEach((link) => {
link.addEventListener("click", () => {
const isMobile = window.matchMedia("(max-width: 63em)").matches;
if (isMobile && link.closest(".nav-item-dropdown")) return;
headerEl.classList.remove("nav-open");
});
});