From 4b011487f73c48257e29530d8c5d128b6434fad8 Mon Sep 17 00:00:00 2001 From: Miodec Date: Tue, 7 Jul 2026 18:50:18 +0200 Subject: [PATCH 1/4] chore: fix formatting --- frontend/src/ts/components/pages/test/Keymap.tsx | 2 +- frontend/storybook/stories/AccountXpBar.stories.tsx | 3 ++- frontend/storybook/stories/Anime.stories.tsx | 3 ++- frontend/storybook/stories/AnimeGroup.stories.tsx | 3 ++- frontend/storybook/stories/AnimePresence.stories.tsx | 3 ++- frontend/storybook/stories/AnimeSwitch.stories.tsx | 3 ++- frontend/storybook/stories/AsyncContent.stories.tsx | 3 ++- frontend/storybook/stories/Balloon.stories.tsx | 3 ++- frontend/storybook/stories/Checkbox.stories.tsx | 3 ++- frontend/storybook/stories/DataTable.stories.tsx | 3 ++- frontend/storybook/stories/Form.stories.tsx | 3 ++- frontend/storybook/stories/Header.stories.tsx | 3 ++- frontend/storybook/stories/Nav.stories.tsx | 3 ++- frontend/storybook/stories/SlimSelect.stories.tsx | 3 ++- 14 files changed, 27 insertions(+), 14 deletions(-) diff --git a/frontend/src/ts/components/pages/test/Keymap.tsx b/frontend/src/ts/components/pages/test/Keymap.tsx index 4194e840dd20..8250656d212b 100644 --- a/frontend/src/ts/components/pages/test/Keymap.tsx +++ b/frontend/src/ts/components/pages/test/Keymap.tsx @@ -99,7 +99,7 @@ function KeyboardDefinitionRenderer(props: { }) { return (
Date: Tue, 7 Jul 2026 19:33:48 +0200 Subject: [PATCH 2/4] fix: modal tab navigation when quick restart is set to tab not working correctly --- frontend/src/ts/components/common/AnimatedModal.tsx | 1 + frontend/src/ts/input/hotkeys/utils.ts | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/frontend/src/ts/components/common/AnimatedModal.tsx b/frontend/src/ts/components/common/AnimatedModal.tsx index 1c504cafc9e4..bad4d6c7c639 100644 --- a/frontend/src/ts/components/common/AnimatedModal.tsx +++ b/frontend/src/ts/components/common/AnimatedModal.tsx @@ -334,6 +334,7 @@ export function AnimatedModal(props: AnimatedModalProps): JSXElement { props.modalClass, )} ref={modalRef} + tabIndex={-1} onScroll={(e) => props.onScroll?.(e)} > diff --git a/frontend/src/ts/input/hotkeys/utils.ts b/frontend/src/ts/input/hotkeys/utils.ts index 5093d103f0da..add98cfc994a 100644 --- a/frontend/src/ts/input/hotkeys/utils.ts +++ b/frontend/src/ts/input/hotkeys/utils.ts @@ -51,7 +51,8 @@ function isInteractiveElementFocused(): boolean { document.activeElement?.tagName === "SELECT" || document.activeElement?.tagName === "BUTTON" || document.activeElement?.classList.contains("button") === true || - document.activeElement?.classList.contains("textButton") === true + document.activeElement?.classList.contains("textButton") === true || + document.activeElement?.classList.contains("modal") === true ); } From a224275a5dcfcc5af38aaa766c7fc1956d7fe537 Mon Sep 17 00:00:00 2001 From: Christian Fehmer Date: Tue, 7 Jul 2026 19:37:43 +0200 Subject: [PATCH 3/4] refactor: solid modals with recaptcha (@fehmer) (#8187) Co-authored-by: Miodec --- .../components/common/AnimatedModal.spec.tsx | 9 + frontend/src/html/popups.html | 46 ---- frontend/src/styles/popups.scss | 87 -------- .../ts/components/common/AnimatedModal.tsx | 38 ++-- .../components/modals/ForgotPasswordModal.tsx | 96 +++++++++ .../components/modals/GoogleSignUpModal.tsx | 166 +++++++++++++++ frontend/src/ts/components/modals/Modals.tsx | 6 + .../ts/components/modals/QuoteReportModal.tsx | 58 ++---- .../ts/components/modals/QuoteSearchModal.tsx | 7 - .../ts/components/modals/QuoteSubmitModal.tsx | 53 +++-- .../modals/RegisterCaptchaModal.tsx | 52 ++--- .../ts/components/modals/UserReportModal.tsx | 147 +++++++++++++ .../src/ts/components/pages/login/Login.tsx | 4 +- .../components/pages/profile/UserDetails.tsx | 19 +- .../src/ts/components/ui/form/Captcha.tsx | 53 +++++ .../ts/components/ui/form/TextareaField.tsx | 1 + .../src/ts/controllers/captcha-controller.ts | 54 ----- frontend/src/ts/index.ts | 1 - frontend/src/ts/modals/forgot-password.ts | 100 --------- frontend/src/ts/modals/google-sign-up.ts | 196 ------------------ frontend/src/ts/modals/user-report.ts | 157 -------------- frontend/src/ts/states/modals.ts | 5 +- frontend/src/ts/states/quote-report.ts | 8 - frontend/src/ts/states/user-report.ts | 5 + packages/contracts/src/quotes.ts | 3 +- packages/contracts/src/users.ts | 14 +- 26 files changed, 606 insertions(+), 779 deletions(-) create mode 100644 frontend/src/ts/components/modals/ForgotPasswordModal.tsx create mode 100644 frontend/src/ts/components/modals/GoogleSignUpModal.tsx create mode 100644 frontend/src/ts/components/modals/UserReportModal.tsx create mode 100644 frontend/src/ts/components/ui/form/Captcha.tsx delete mode 100644 frontend/src/ts/controllers/captcha-controller.ts delete mode 100644 frontend/src/ts/modals/forgot-password.ts delete mode 100644 frontend/src/ts/modals/google-sign-up.ts delete mode 100644 frontend/src/ts/modals/user-report.ts create mode 100644 frontend/src/ts/states/user-report.ts diff --git a/frontend/__tests__/components/common/AnimatedModal.spec.tsx b/frontend/__tests__/components/common/AnimatedModal.spec.tsx index 6b6d3540fbb1..3eb79f9a145e 100644 --- a/frontend/__tests__/components/common/AnimatedModal.spec.tsx +++ b/frontend/__tests__/components/common/AnimatedModal.spec.tsx @@ -2,9 +2,11 @@ import { render } from "@solidjs/testing-library"; import { describe, it, expect, vi, beforeEach } from "vitest"; import { AnimatedModal } from "../../../src/ts/components/common/AnimatedModal"; +import { hideModal, ModalId, showModal } from "../../../src/ts/states/modals"; describe("AnimatedModal", () => { beforeEach(() => { + showModal("Support" as ModalId); vi.clearAllMocks(); // Mock dialog methods that don't exist in jsdom @@ -57,6 +59,13 @@ describe("AnimatedModal", () => { ).toHaveTextContent("Test Content"); }); + it("doesnt render children if not open", () => { + hideModal("Support" as ModalId); + const { modalDiv } = renderModal({}); + + expect(modalDiv).not.toBeInTheDocument(); + }); + it("has escape handler attached", () => { const { dialog } = renderModal({}); diff --git a/frontend/src/html/popups.html b/frontend/src/html/popups.html index 2f920af7ec60..2a8f560ac554 100644 --- a/frontend/src/html/popups.html +++ b/frontend/src/html/popups.html @@ -1,12 +1,3 @@ - -