Restore menu toggle when clicking on the logo
The caret icon is too small on smartphone to expand/collapse the menu
This commit is contained in:
parent
aa30c35e7e
commit
9336891e67
1 changed files with 7 additions and 1 deletions
8
internal/ui/static/js/bootstrap.js
vendored
8
internal/ui/static/js/bootstrap.js
vendored
|
@ -111,9 +111,15 @@ document.addEventListener("DOMContentLoaded", () => {
|
|||
}
|
||||
}, true);
|
||||
|
||||
onClick("button[aria-controls='header-menu']", () => toggleMainMenu());
|
||||
if (document.documentElement.clientWidth < 600) {
|
||||
let logoElement = document.querySelector(".logo");
|
||||
if (logoElement) {
|
||||
logoElement.setAttribute("role", "button");
|
||||
}
|
||||
onClick(".logo", () => toggleMainMenu());
|
||||
onClick(".header nav li", (event) => onClickMainMenuListItem(event));
|
||||
} else {
|
||||
onClick("button[aria-controls='header-menu']", () => toggleMainMenu());
|
||||
}
|
||||
|
||||
if ("serviceWorker" in navigator) {
|
||||
|
|
Loading…
Reference in a new issue