Skip to content

Commit 20fc4f6

Browse files
celiasclaude
andcommitted
fix: correct @theme inline, apply amber palette, and add light mode (GAB-44)
Fixes circular self-references in @theme block (must be @theme inline in Tailwind v4 so utilities emit var() references at runtime). Swaps the pink/neon palette for amber/warm, adds light mode via prefers-color-scheme, removes dead glow utility classes, and cleans up component color tokens to drop the now-gone --color-secondary and --color-tertiary. Deletes stitch/grid-view.html design reference. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent f27deab commit 20fc4f6

7 files changed

Lines changed: 58 additions & 561 deletions

File tree

dashboard/src/components/AlertCard.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ export default function AlertCard({ alert, onSelect }: AlertCardProps) {
176176
style={{
177177
fontFamily: "Space Grotesk, sans-serif",
178178
fontSize: "0.7rem",
179-
color: "var(--color-tertiary)",
179+
color: "var(--color-primary)",
180180
fontWeight: 600,
181181
}}
182182
>
@@ -207,7 +207,7 @@ export default function AlertCard({ alert, onSelect }: AlertCardProps) {
207207
style={{
208208
fontFamily: "Space Grotesk, sans-serif",
209209
fontSize: "0.65rem",
210-
color: "var(--color-secondary)",
210+
color: "var(--color-on-surface-muted)",
211211
marginBottom: "0.35rem",
212212
}}
213213
>

dashboard/src/components/AlertDetail.tsx

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -182,16 +182,9 @@ export default function AlertDetail({ alert, weights }: AlertDetailProps) {
182182
rel="noopener noreferrer"
183183
className="text-xs underline transition-all"
184184
style={{
185-
color: "var(--color-secondary)",
185+
color: "var(--color-primary)",
186186
fontFamily: "Space Grotesk, sans-serif",
187187
}}
188-
onMouseEnter={(e) => {
189-
(e.target as HTMLElement).style.textShadow =
190-
"0 0 8px var(--color-secondary)";
191-
}}
192-
onMouseLeave={(e) => {
193-
(e.target as HTMLElement).style.textShadow = "none";
194-
}}
195188
>
196189
View on Reddit →
197190
</a>

dashboard/src/components/AlertRow.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -110,9 +110,9 @@ export default function AlertRow({
110110
className="text-xs px-2 py-0.5 shrink-0"
111111
style={{
112112
fontFamily: "Space Grotesk, sans-serif",
113-
background: "var(--color-secondary-container)",
114-
color: "var(--color-secondary)",
115-
border: "1px solid rgba(0, 255, 204, 0.4)",
113+
background: "var(--color-primary-container)",
114+
color: "var(--color-primary)",
115+
border: "1px solid var(--color-outline)",
116116
borderRadius: "4px",
117117
}}
118118
>

dashboard/src/components/Header.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export default function Header({
1515
<header className="flex items-center justify-between mb-6">
1616
<div className="flex items-center gap-3">
1717
<h1
18-
className="text-2xl font-bold tracking-tight glow-pink"
18+
className="text-2xl font-bold tracking-tight"
1919
style={{
2020
fontFamily: "Sora, sans-serif",
2121
color: "var(--color-primary)",
@@ -26,7 +26,7 @@ export default function Header({
2626
<span
2727
className="inline-block w-2.5 h-2.5 rounded-full transition-colors"
2828
style={{
29-
background: connected ? "var(--color-secondary)" : "#ff4444",
29+
background: connected ? "var(--color-primary)" : "#b91c1c",
3030
}}
3131
title={connected ? "Connected" : "Disconnected"}
3232
/>

dashboard/src/components/NavBar.tsx

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -293,11 +293,8 @@ export default function NavBar({
293293
width: 8,
294294
height: 8,
295295
borderRadius: "50%",
296-
background: connected ? "var(--color-secondary)" : "#ff4444",
296+
background: connected ? "var(--color-primary)" : "#b91c1c",
297297
display: "inline-block",
298-
boxShadow: connected
299-
? "0 0 6px var(--color-secondary)"
300-
: "0 0 6px #ff4444",
301298
}}
302299
title={connected ? "Connected" : "Disconnected"}
303300
/>

dashboard/src/index.css

Lines changed: 49 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,44 +1,60 @@
11
@import "tailwindcss";
22

3-
:root {
4-
--color-bg: #0a0a12;
5-
--color-surface: #0f0f1a;
6-
--color-surface-container: #141422;
7-
--color-surface-container-high: #1e1e30;
8-
--color-surface-container-highest: #28283e;
9-
--color-primary: #ff2d78;
10-
--color-primary-container: #b3004e;
11-
--color-secondary: #00ffcc;
12-
--color-secondary-container: #004d3d;
13-
--color-tertiary: #ffe04a;
14-
--color-on-surface: #e8e0f0;
15-
--color-on-surface-muted: #a098b0;
16-
--color-outline: #5a5068;
17-
--color-outline-variant: #302840;
3+
@theme inline {
4+
--color-bg: var(--color-bg);
5+
--color-surface: var(--color-surface);
6+
--color-surface-container: var(--color-surface-container);
7+
--color-surface-container-high: var(--color-surface-container-high);
8+
--color-surface-container-highest: var(--color-surface-container-highest);
9+
--color-primary: var(--color-primary);
10+
--color-primary-container: var(--color-primary-container);
11+
--color-on-surface: var(--color-on-surface);
12+
--color-on-surface-muted: var(--color-on-surface-muted);
13+
--color-outline: var(--color-outline);
14+
--color-outline-variant: var(--color-outline-variant);
1815
}
1916

20-
body {
21-
background: var(--color-bg);
22-
color: var(--color-on-surface);
23-
font-family: Inter, sans-serif;
24-
min-height: 100vh;
25-
}
17+
/* ── Dark mode (default) ─────────────────────────────── */
18+
:root {
19+
--color-bg: #111110;
20+
--color-surface: #1a1916;
21+
--color-surface-container: #211f1c;
22+
--color-surface-container-high: #2b2925;
23+
--color-surface-container-highest: #363330;
2624

27-
/* Neon glow utilities */
28-
.glow-pink {
29-
text-shadow: 0 0 8px var(--color-primary);
30-
}
25+
--color-primary: #d97706;
26+
--color-primary-container: #292008;
3127

32-
.glow-border-pink {
33-
border-color: rgba(255, 45, 120, 0.5);
34-
box-shadow: inset 0 0 12px rgba(255, 45, 120, 0.1);
28+
--color-on-surface: #e8e3d8;
29+
--color-on-surface-muted: #8a8070;
30+
31+
--color-outline: #48433c;
32+
--color-outline-variant: #2e2b26;
3533
}
3634

37-
.glow-box-pink {
38-
box-shadow: 0 0 16px rgba(255, 45, 120, 0.4);
35+
/* ── Light mode ──────────────────────────────────────── */
36+
@media (prefers-color-scheme: light) {
37+
:root {
38+
--color-bg: #f5f2ec;
39+
--color-surface: #faf8f4;
40+
--color-surface-container: #ede9e1;
41+
--color-surface-container-high: #e2ddd4;
42+
--color-surface-container-highest: #d4cec4;
43+
44+
--color-primary: #b45309;
45+
--color-primary-container: #fef3c7;
46+
47+
--color-on-surface: #1c1a16;
48+
--color-on-surface-muted: #6b6355;
49+
50+
--color-outline: #b0a898;
51+
--color-outline-variant: #d4cfc8;
52+
}
3953
}
4054

41-
.glow-border-pink-full {
42-
border-color: var(--color-primary);
43-
box-shadow: 0 0 12px rgba(255, 45, 120, 0.25);
55+
body {
56+
background: var(--color-bg);
57+
color: var(--color-on-surface);
58+
font-family: Inter, sans-serif;
59+
min-height: 100vh;
4460
}

0 commit comments

Comments
 (0)