mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-18 16:12:11 +00:00
feat(cycle): per-phase what's-happening education card
This commit is contained in:
1 parent
93d47ddd05
commit
81ec98fc97
10 files changed
+462
-1
No files matched your search
@@ -0,0 +1,23 @@
|
||||
/**
|
||||
* v1.15.1 — per-phase education copy → i18n leaf mapping.
|
||||
*
|
||||
* The `PhaseEducationCard` renders a short, factual "what's happening" line for
|
||||
* the active cycle phase. The copy is curated, descriptive-only (no clinical
|
||||
* advice, no medical claims) and lives entirely under `cycle.phaseEducation.*`
|
||||
* in the message bundles — this module only maps a phase to its leaf key so the
|
||||
* i18n-call-site-coverage guard sees the literal `t()` arguments at the call
|
||||
* site and the copy stays translatable across all six locales.
|
||||
*/
|
||||
import type { CyclePhase } from "@/lib/cycle/types";
|
||||
|
||||
/**
|
||||
* The phase → i18n leaf for the "what's happening now" descriptive line. The
|
||||
* keys are spelled out as string literals (not interpolated) so the
|
||||
* call-site-coverage walker resolves each one against `messages/en.json`.
|
||||
*/
|
||||
export const PHASE_WHATS_HAPPENING_KEY: Record<CyclePhase, string> = {
|
||||
MENSTRUAL: "cycle.phaseEducation.whatsHappening.MENSTRUAL",
|
||||
FOLLICULAR: "cycle.phaseEducation.whatsHappening.FOLLICULAR",
|
||||
OVULATORY: "cycle.phaseEducation.whatsHappening.OVULATORY",
|
||||
LUTEAL: "cycle.phaseEducation.whatsHappening.LUTEAL",
|
||||
};
|
||||
Reference in new issue
Block a user