diff --git a/public/bundle.js b/public/bundle.js index 4fde866..78960b1 100644 --- a/public/bundle.js +++ b/public/bundle.js @@ -1,5 +1,5 @@ //// -// version: a4e5557 +// version: 71de13c // src/js/dom.ts var content2 = $("content"); @@ -244,11 +244,9 @@ function handleBrowserKeydown(e) { } } function handleClick(e) { - const target = e.target.closest("button, a"); + const target = e.target; if (!(target instanceof HTMLElement)) return; - if (target.id.endsWith("-button")) - e.preventDefault(); switch (target.id) { case "back-button": navigateBack(); @@ -266,11 +264,13 @@ function handleClick(e) { fullscreenBrowser(); break; case "close-button": + e.stopImmediatePropagation(); closeBrowser(); break; default: return; } + e.preventDefault(); } function handlePageLoad() {} function setAddress(url) {