mirror of
https://github.com/miniflux/v2.git
synced 2025-06-27 16:36:00 +00:00
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);
|
}, true);
|
||||||
|
|
||||||
onClick("button[aria-controls='header-menu']", () => toggleMainMenu());
|
|
||||||
if (document.documentElement.clientWidth < 600) {
|
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));
|
onClick(".header nav li", (event) => onClickMainMenuListItem(event));
|
||||||
|
} else {
|
||||||
|
onClick("button[aria-controls='header-menu']", () => toggleMainMenu());
|
||||||
}
|
}
|
||||||
|
|
||||||
if ("serviceWorker" in navigator) {
|
if ("serviceWorker" in navigator) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue