mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-10 21:32:18 +00:00
docs(medications): correct the GLP-1 card equal-height comment
The reserved-slot comment claimed the compliance bars and action row align "row-for-row across the grid" with a generic sibling. That overstates it: the GLP-1-only rotation-hint block sits between the reserved slot and the compliance bars, so the bars are pushed down by its height and do not share a Y with a generic card's bars. What the layout actually guarantees is equal card height and a shared bottom action baseline (`h-full` + `mt-auto`); only the header, the reserved slot, and the pinned action row align across a mixed-variant row. Reword the comment to claim exactly that. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> (cherry picked from commit 7320c8b1b9f704d22eaba10be42a560594a5ca11)
This commit is contained in:
1 parent
ada9006d9c
commit
1c91abcf2a
1 file changed
+8
-3
@@ -422,9 +422,14 @@ export function Glp1MedicationCard({
|
||||
|
||||
{/* Injection state — last + next. The reserved min-height keeps a
|
||||
card whose last-injection line is absent the same vertical
|
||||
footprint as one that renders both lines, so the compliance bars
|
||||
and action row below align row-for-row across the grid — matching
|
||||
the generic medication card's reserved last/next slot. */}
|
||||
footprint as one that renders both lines, matching the generic
|
||||
medication card's reserved last/next slot. This — together with
|
||||
`h-full` + `mt-auto` — equalises the card height and pins a
|
||||
shared bottom action baseline across the grid row. Note it does
|
||||
NOT align the compliance bars row-for-row with a generic
|
||||
sibling: the GLP-1-only rotation-hint block below pushes the
|
||||
bars down by its own height, so only the header, the reserved
|
||||
slot, and the pinned action row share a Y. */}
|
||||
<div className="min-h-[2.75rem] space-y-1 text-sm">
|
||||
{medication.lastTakenAt && (
|
||||
<p className="text-muted-foreground">
|
||||
|
||||
Reference in new issue
Block a user