diff --git a/src/components/insights/daily-briefing.tsx b/src/components/insights/daily-briefing.tsx index f62aa1cfc..27bc08591 100644 --- a/src/components/insights/daily-briefing.tsx +++ b/src/components/insights/daily-briefing.tsx @@ -179,40 +179,51 @@ function DeltaBadge({ ); } -function KeyFindingRow({ finding }: { finding: DailyBriefingKeyFinding }) { - const Icon = METRIC_ICON[finding.sourceMetric]; - const href = METRIC_HREF[finding.sourceMetric]; - // v1.4.27 MB7 / CF-68 — when the briefing's `sourceMetric` maps to - // a routed sub-page, wrap the entire row in a `` so the - // whole card is tappable on mobile instead of the user having to - // hit the small headline text. Hover + focus paint a subtle bg - // shift; metrics that don't have a sub-page yet render the - // original static row. +/** + * v1.18.7 — shared row layout for the key-finding row and the signal-of-the-day + * row. Both render the same tone bar + metric icon + headline/body/delta and + * the same "wrap in a `` when the metric owns a sub-page" behaviour; the + * two only differ in their `data-slot` and the body copy they pass. + */ +function BriefingRow({ + sourceMetric, + tone, + headline, + body, + delta, + dataSlot, +}: { + sourceMetric: DailyBriefingKeyFinding["sourceMetric"]; + tone: DailyBriefingKeyFinding["tone"]; + headline: string; + body: string; + delta: string | null; + dataSlot: "daily-briefing-finding" | "daily-briefing-signal"; +}) { + const Icon = METRIC_ICON[sourceMetric]; + const href = METRIC_HREF[sourceMetric]; const rowContent = ( <>
- {stripChartTokens(finding.headline)} + {stripChartTokens(headline)}
-- {stripChartTokens(finding.detail)} + {stripChartTokens(body)}
- {stripChartTokens(signal.headline)} -
-- {stripChartTokens(signal.nudge)} -
-