FIX: Menu panel position adjustment (#15358)

This commit is contained in:
Penar Musaraj 2021-12-20 10:25:37 -05:00 committed by GitHub
parent 40d1bbab5d
commit 973c9bdcd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -338,11 +338,7 @@ const SiteHeaderComponent = MountWidget.extend(
}
const windowWidth = document.body.offsetWidth;
const headerWidth =
document.querySelector("#main-outlet .container").offsetWidth || 1100;
const remaining = (windowWidth - headerWidth) / 2;
const viewMode =
this.site.mobileView || remaining < 50 ? "slide-in" : "drop-down";
const viewMode = this.site.mobileView ? "slide-in" : "drop-down";
menuPanels.forEach((panel) => {
const headerCloak = document.querySelector(".header-cloak");