From dce14fb40cb3a6c59b03d2cece1c818722129318 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Bombeck?= Date: Thu, 21 May 2026 19:06:08 +0200 Subject: [PATCH] chore(cleanup): drop two dead re-exports before the knip gate flip W1-KNIP's reconcile callouts identified two re-exports that no caller ever consumed: - `src/lib/tz/resolver.ts:51` re-exported `listSupportedTimezones` from `./format`, but both call-sites (`components/settings/timezone-picker.tsx` and `components/admin/general-settings-section.tsx`) import directly from `@/lib/tz/format`. - `src/components/medications/glp1-medication-card.tsx:595-596` re-exported `describeInjectionSite` "so the parent doesn't need to import it", but every real consumer (`therapy-timeline.tsx`, `injection-site-picker.tsx`, the unit test) imports the source from `@/lib/medications/injection-sites` directly. Drops both re-exports and the now-orphaned `describeInjectionSite` import in `glp1-medication-card.tsx`. Clears the last knip findings so the gate flip in the next commit lands clean. --- src/components/medications/glp1-medication-card.tsx | 4 ---- src/lib/tz/resolver.ts | 1 - 2 files changed, 5 deletions(-) diff --git a/src/components/medications/glp1-medication-card.tsx b/src/components/medications/glp1-medication-card.tsx index a3ebdca42..d94ff7b7e 100644 --- a/src/components/medications/glp1-medication-card.tsx +++ b/src/components/medications/glp1-medication-card.tsx @@ -38,7 +38,6 @@ import { formatDateTime, formatTime } from "@/lib/format"; import { formatTimeWindowRange } from "@/lib/time-window-format"; import { getMedicationCategoryLabel } from "@/lib/medications/category-label"; import { - describeInjectionSite, nextInjectionSite, type InjectionSiteKey, } from "@/lib/medications/injection-sites"; @@ -591,6 +590,3 @@ function siteSuffix(site: InjectionSiteKey): string { .map((part) => part.charAt(0).toUpperCase() + part.slice(1)) .join(""); } - -/** Re-export so the parent doesn't need to import describeInjectionSite. */ -export { describeInjectionSite }; diff --git a/src/lib/tz/resolver.ts b/src/lib/tz/resolver.ts index 4465802a7..f8899a015 100644 --- a/src/lib/tz/resolver.ts +++ b/src/lib/tz/resolver.ts @@ -48,7 +48,6 @@ export { DEFAULT_TIMEZONE, isValidTimezone, isNearUtc, - listSupportedTimezones, detectBrowserTimezone, formatInUserTz, userDayKey,