diff --git a/src/app/insights/page.tsx b/src/app/insights/page.tsx index 191c9433d..e6be98228 100644 --- a/src/app/insights/page.tsx +++ b/src/app/insights/page.tsx @@ -16,6 +16,10 @@ import { HeroStrip } from "@/components/insights/hero-strip"; import { useInsightsAdvisorQuery } from "@/components/insights/use-insights-advisor"; import { useCoachLaunch } from "@/lib/insights/coach-launch-context"; import { useAnalyticsQuery } from "@/lib/queries/use-analytics-query"; +// v1.4.41 W-ORG — shared shape lives in `src/types/analytics.ts` as +// `InsightsAnalyticsData`; aliased back to the local name to keep the +// rest of this file readable. +import type { InsightsAnalyticsData as AnalyticsData } from "@/types/analytics"; /** * v1.4.33 IW2 — defer the three below-the-fold mother-page blocks @@ -94,11 +98,6 @@ interface ComprehensiveData { totalMeasurements: number; } -// v1.4.41 W-ORG — shared shape lives in `src/types/analytics.ts` as -// `InsightsAnalyticsData`; aliased back to the local name to keep the -// rest of this file readable. -import type { InsightsAnalyticsData as AnalyticsData } from "@/types/analytics"; - export default function InsightsPage() { const { isAuthenticated, user } = useAuth(); const { t } = useTranslations(); diff --git a/src/app/page.tsx b/src/app/page.tsx index a3da7be6e..2caa13078 100644 --- a/src/app/page.tsx +++ b/src/app/page.tsx @@ -24,7 +24,6 @@ import { resolveDashboardLayout, type DashboardLayout, } from "@/lib/dashboard-layout"; -import type { DataSummary as DataSummaryType } from "@/lib/analytics/trends"; import type { DashboardAnalyticsData as AnalyticsData } from "@/types/analytics"; import dynamic from "next/dynamic"; import { Button } from "@/components/ui/button"; @@ -240,7 +239,7 @@ export default function DashboardPage() { bpInTargetPctPriorMonth: merged.bpInTargetPctPriorMonth, bpInTargetPctPriorYear: merged.bpInTargetPctPriorYear, glucoseByContext: merged.glucoseByContext as - | Record + | Record | undefined, }; }, [analyticsSlimQuery.data, analyticsThickQuery.data]); diff --git a/src/components/onboarding/getting-started-checklist.tsx b/src/components/onboarding/getting-started-checklist.tsx index 5f7d4236a..d911b1d0b 100644 --- a/src/components/onboarding/getting-started-checklist.tsx +++ b/src/components/onboarding/getting-started-checklist.tsx @@ -14,6 +14,9 @@ import { X, } from "lucide-react"; import type { LucideIcon } from "lucide-react"; +// v1.4.41 W-ORG — shared shape lives in `src/types/analytics.ts` as +// `ChecklistAnalyticsData`; aliased back to the local name. +import type { ChecklistAnalyticsData as AnalyticsData } from "@/types/analytics"; import { Button } from "@/components/ui/button"; import { useAuth } from "@/hooks/use-auth"; @@ -70,10 +73,6 @@ const ITEM_LABEL_KEYS: Record< }, }; -// v1.4.41 W-ORG — shared shape lives in `src/types/analytics.ts` as -// `ChecklistAnalyticsData`; aliased back to the local name. -import type { ChecklistAnalyticsData as AnalyticsData } from "@/types/analytics"; - interface WithingsStatus { connected?: boolean; } diff --git a/src/types/analytics.ts b/src/types/analytics.ts index 2dad35b06..61ef34f54 100644 --- a/src/types/analytics.ts +++ b/src/types/analytics.ts @@ -35,7 +35,6 @@ * shape loses it. */ import type { DataSummary } from "@/lib/analytics/trends"; -import type { DataSummary as DataSummaryType } from "@/lib/analytics/trends"; import type { CorrelationResult } from "@/lib/insights/correlations"; /** Shape consumed by every `/insights//page.tsx`. */ @@ -77,7 +76,7 @@ export interface DashboardAnalyticsData { */ bpInTargetPctPriorMonth?: number | null; bpInTargetPctPriorYear?: number | null; - glucoseByContext?: Record; + glucoseByContext?: Record; /** * v1.4.34 IW-B — per-type freshness map from `/api/analytics`. The * tile-strip helper reads `lastSeenByType[type]?.daysAgo` and forwards