From 7d738c0e49de07a063dcd832afccc27138b2d41c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc-Andr=C3=A9=20Bombeck?= Date: Thu, 8 Oct 2026 19:03:32 +0200 Subject: [PATCH] Lead the meta line with the unit in the phone measurement list MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On a phone a long unit beside the value ('12,5 Atemzüge/min') pushed the row's controls. The value stands alone and the unit opens the muted meta line beside the time and source, where meta belongs. --- .../measurements/measurement-list.tsx | 39 +++++++++++-------- 1 file changed, 22 insertions(+), 17 deletions(-) diff --git a/src/components/measurements/measurement-list.tsx b/src/components/measurements/measurement-list.tsx index ba8e71c6f..72f48cc4e 100644 --- a/src/components/measurements/measurement-list.tsx +++ b/src/components/measurements/measurement-list.tsx @@ -1500,23 +1500,14 @@ export function MeasurementList({ their native decimal precision so "78.4 kg" no longer truncates to "78". v1.11.5 — sleep rows render TIME ASLEEP. */} - {isSleep ? ( - formatDurationMinutes(m.value, t) - ) : ( - <> - {isGrouped - ? fmt.integer(m.value) - : fmt.number( - rowDisplay(m).value, - rawDisplayFractionDigits(m.type), - )}{" "} - {measurementUnitLabel( - m.type, - isGrouped ? m.unit : rowDisplay(m).unit, - t, - )} - - )} + {isSleep + ? formatDurationMinutes(m.value, t) + : isGrouped + ? fmt.integer(m.value) + : fmt.number( + rowDisplay(m).value, + rawDisplayFractionDigits(m.type), + )} {isSleep ? ( @@ -1536,6 +1527,20 @@ export function MeasurementList({ site. Relative under 24 h, absolute older. */} + {/* The unit is meta, and on a phone a long + one ("Atemzüge/min") beside the value pushed + the row's controls; it leads the meta line + instead. Sleep reads as a duration. */} + {isSleep ? null : ( + + {measurementUnitLabel( + m.type, + isGrouped ? m.unit : rowDisplay(m).unit, + t, + )} + {" · "} + + )} {m.dayKey !== undefined ? ( {formatDateOrRelative(m.measuredAt, t)}