mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-08 12:32:43 +00:00
Height is a profile column, not a MeasurementType, so the display transform that carries the metric/imperial preference across every reading surface never reached it. Add the adapter that closes the gap. With imperial selected both entry surfaces render a feet + inches pair instead of a centimetres box; with metric selected the field is what it was. The adapter converts to canonical centimetres at the entry boundary, so storage, the wire, the Zod bound, and every consumer of the value stay unchanged. Imperial entry quantises to whole inches, which map to centimetres without a remainder, so save-then-reopen returns the typed pair. The offered feet window rounds inward against the canonical 50-300 window so a height the fields allow is never refused on save. The unit select shares the Settings card with the height field, so a flip re-expresses the in-flight draft through the new branch rather than stranding an empty field.