From 7918e0009e98e3c9a244c0d6f9bf7f5fc4370356 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mathis=20Dr=C3=B6ge?= Date: Sun, 1 Dec 2024 00:31:15 +0100 Subject: [PATCH] Controller navigation fixes, part 2 This makes dialogs closeable with the back button again --- src/frontend/helpers/gamepad.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/frontend/helpers/gamepad.ts b/src/frontend/helpers/gamepad.ts index 8e392662d1..48e12d8122 100644 --- a/src/frontend/helpers/gamepad.ts +++ b/src/frontend/helpers/gamepad.ts @@ -291,18 +291,18 @@ export const initGamepad = () => { const el = currentElement() if (!el) return false - return !!el.closest('.Dialog__element') + return !!el.closest('.MuiDialog-root') } function closeDialog() { const el = currentElement() if (!el) return false - const dialog = el.closest('.Dialog__element') + const dialog = el.closest('.MuiDialog-root') if (!dialog) return false const closeButton = dialog.querySelector( - '.Dialog__CloseButton' + '[aria-label="close"]' ) if (!closeButton) return false