From f046e5413ca19c78880b672cc3d4550acf1fa63c Mon Sep 17 00:00:00 2001 From: castrojo Date: Tue, 8 Sep 2026 14:02:05 +0000 Subject: [PATCH] fix(analytics): align family sparkline domains with images Derive workstation sparkline domain keys directly from BLUEFIN_FAMILY_IMAGES so the shared small-multiples domain reflects the exact variants rendered in the family grid (Bluefin, Bluefin LTS, Dakota, Utah) rather than hardcoded keys that included external Aurora and omitted Dakota/Utah. Fixes #1085 Signed-off-by: castrojo --- src/components/analytics/CountmeAnalyticsCharts.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/components/analytics/CountmeAnalyticsCharts.tsx b/src/components/analytics/CountmeAnalyticsCharts.tsx index d7e489aa..df16602b 100644 --- a/src/components/analytics/CountmeAnalyticsCharts.tsx +++ b/src/components/analytics/CountmeAnalyticsCharts.tsx @@ -183,11 +183,11 @@ export default function CountmeAnalyticsCharts(): React.JSX.Element { ).length; }, [filteredWeeks]); - // Shared domain for workstation small multiples + // Shared domain for workstation family small multiples (derived from rendered family images) const workstationDomain = useMemo<[number, number]>(() => { let min = Infinity; let max = -Infinity; - const workstationKeys = ["bluefin", "aurora", "bluefin-lts"] as const; + const workstationKeys = BLUEFIN_FAMILY_IMAGES.map((img) => img.id); for (const w of weeks) { for (const k of workstationKeys) { const val = w[k];