From 9d1e4871e25038be3ce5a88962a445b235c8f2ff Mon Sep 17 00:00:00 2001 From: Alan Brooks Date: Sun, 5 Apr 2026 00:29:58 -0400 Subject: [PATCH] fix: buttons when in visualizer only mode --- js/ui.js | 25 ++++++++----------------- styles.css | 14 ++++++++++++++ 2 files changed, 22 insertions(+), 17 deletions(-) diff --git a/js/ui.js b/js/ui.js index 9350795..49df562 100644 --- a/js/ui.js +++ b/js/ui.js @@ -1582,29 +1582,20 @@ export class UIRenderer { updateToggleButtonIcon(); if (isUIHidden) { - hideButton(); + showButton(); } else { showButton(); } }; - // Mouse move handler const handleMouseMove = (e) => { - const rect = overlay.getBoundingClientRect(); - const isNearTopRight = e.clientY < 100 && e.clientX > rect.width - 150; - - if (isUIHidden) { - if (overlay.classList.contains('is-video-mode')) { - if (isNearTopRight) { - showButton(); - } else { - hideButton(); - } - } else if (isNearTopRight) { - showButton(); - } else { - hideButton(); - } + if (!isUIHidden) return; + const btnRect = toggleBtn.getBoundingClientRect(); + const nearBtn = e.clientY < 100 && Math.abs(e.clientX - (btnRect.left + btnRect.width / 2)) < 150; + if (nearBtn) { + showButton(); + } else { + hideButton(); } }; diff --git a/styles.css b/styles.css index 16d7d69..5e089ef 100644 --- a/styles.css +++ b/styles.css @@ -10465,6 +10465,20 @@ body:has(#side-panel.active) #close-fullscreen-cover-btn { order: 1; } +#fullscreen-cover-overlay.ui-hidden .fullscreen-top-actions { + opacity: 1; + pointer-events: auto; + transform: none; +} + +#fullscreen-cover-overlay.ui-hidden .fullscreen-top-actions button, +#fullscreen-cover-overlay.ui-hidden .fullscreen-top-actions #close-fullscreen-cover-btn, +#fullscreen-cover-overlay.ui-hidden .fullscreen-top-actions #fs-visualizer-btn { + opacity: 1; + pointer-events: auto; + transform: none; +} + #fullscreen-cover-overlay #toggle-ui-btn { top: 1.25rem; left: calc(80px + 2.3rem + env(safe-area-inset-left));