From 8bb5052dd5464c4904f1d5162503022c358f2e7b Mon Sep 17 00:00:00 2001 From: vince Date: Sat, 20 Jun 2026 02:21:16 +0200 Subject: [PATCH] fix(ui): keep console layout usable at mid widths --- src/App.test.tsx | 2 +- src/lib/ui/components/ThemeToggle.tsx | 3 +- src/lib/ui/components/render.test.tsx | 2 +- src/lib/ui/components/styles.css | 23 +++++++- tests/e2e/dashboard.spec.ts | 76 ++++++++++++++++++++++++--- tests/e2e/storybook.spec.ts | 6 ++- 6 files changed, 98 insertions(+), 14 deletions(-) diff --git a/src/App.test.tsx b/src/App.test.tsx index 31f5787..fbb133d 100644 --- a/src/App.test.tsx +++ b/src/App.test.tsx @@ -35,7 +35,7 @@ describe("React app dashboard state view", () => { expect(html).toContain('data-ui-theme-toggle="true"'); expect(html).toContain('data-ui-theme-current="dark"'); - expect(html).toContain('aria-label="Switch to light theme"'); + expect(html).toContain('aria-label="Light theme"'); expect(html).toContain('aria-pressed="false"'); expect(html).toContain("Theme"); expect(html).toContain("Dark"); diff --git a/src/lib/ui/components/ThemeToggle.tsx b/src/lib/ui/components/ThemeToggle.tsx index bdb8345..9e883af 100644 --- a/src/lib/ui/components/ThemeToggle.tsx +++ b/src/lib/ui/components/ThemeToggle.tsx @@ -9,11 +9,10 @@ export interface ThemeToggleProps { export function ThemeToggle({ theme, onThemeChange }: ThemeToggleProps) { const nextTheme = getNextUiTheme(theme); - const label = `Switch to ${nextTheme} theme`; return (