diff --git a/src/components/ui/__tests__/score-pill.test.tsx b/src/components/ui/__tests__/score-pill.test.tsx index 402a06172..10dfc0daf 100644 --- a/src/components/ui/__tests__/score-pill.test.tsx +++ b/src/components/ui/__tests__/score-pill.test.tsx @@ -17,7 +17,7 @@ describe("", () => { it("defaults to the neutral tone", () => { const html = renderToStaticMarkup(Low); - expect(html).toContain("bg-secondary text-muted-foreground"); + expect(html).toContain("bg-secondary text-secondary-foreground"); expect(html).toContain('data-tone="neutral"'); }); diff --git a/src/components/ui/score-pill.tsx b/src/components/ui/score-pill.tsx index c503c561d..33ba2931d 100644 --- a/src/components/ui/score-pill.tsx +++ b/src/components/ui/score-pill.tsx @@ -30,7 +30,10 @@ const scorePillVariants = cva( info: "bg-info/15 text-info", warning: "bg-warning/15 text-warning", destructive: "bg-destructive/15 text-destructive", - neutral: "bg-secondary text-muted-foreground", + // The secondary surface's own foreground: muted text on the secondary + // fill measured 3.6:1 in the dark theme, under the AA floor a pill + // label needs. + neutral: "bg-secondary text-secondary-foreground", }, numeric: { true: "font-semibold tabular-nums",