From b1995522ee2940b17da908c3c3b6ee4870002df1 Mon Sep 17 00:00:00 2001 From: Arnaud Date: Mon, 13 Jul 2026 06:57:52 +0200 Subject: [PATCH] fix: destructive confirm buttons had unreadable black-on-red text MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --destructive-foreground was never defined in globals.css (light or dark theme) — text-destructive-foreground resolved to nothing, so both the clear-chat-history confirm button and recipe-form's discard-changes confirm (same bg-destructive text-destructive-foreground pattern) fell back to the default dark text color on a solid red background. Added the missing variable (white, matching --primary-foreground's light value — both themes use a saturated enough red that white stays legible), mapped through @theme inline alongside the existing --color-destructive. Verified locally: screenshotted the clear-history confirm dialog, button now shows white text on red. --- apps/web/app/globals.css | 3 +++ 1 file changed, 3 insertions(+) diff --git a/apps/web/app/globals.css b/apps/web/app/globals.css index 652c905..971deac 100644 --- a/apps/web/app/globals.css +++ b/apps/web/app/globals.css @@ -27,6 +27,7 @@ --color-input: var(--input); --color-border: var(--border); --color-destructive: var(--destructive); + --color-destructive-foreground: var(--destructive-foreground); --color-accent-foreground: var(--accent-foreground); --color-accent: var(--accent); --color-muted-foreground: var(--muted-foreground); @@ -64,6 +65,7 @@ --accent: oklch(0.97 0 0); --accent-foreground: oklch(0.205 0 0); --destructive: oklch(0.577 0.245 27.325); + --destructive-foreground: oklch(0.985 0 0); --border: oklch(0.922 0 0); --input: oklch(0.922 0 0); --ring: oklch(0.708 0 0); @@ -99,6 +101,7 @@ --accent: oklch(0.269 0 0); --accent-foreground: oklch(0.985 0 0); --destructive: oklch(0.704 0.191 22.216); + --destructive-foreground: oklch(0.985 0 0); --border: oklch(1 0 0 / 10%); --input: oklch(1 0 0 / 15%); --ring: oklch(0.556 0 0);