feat(score): say which yardstick graded the weight row

The weight pillar has been graded against something for two years and
never said what. The score card's weight row now carries one line: the
user's own target band when they set one, or a plain statement that the
row scored the trend with no target at all. The band rides the analytics
DTO in canonical kg and the page formats it into the reader's display
unit, so an imperial account reads pounds.

The weight sub-page shades the same yardstick: its chart bands follow an
explicit target when one exists and fall back to the height-derived band
only when it does not.
This commit is contained in:
Marc-André Bombeck committed 2026-07-27 23:00:26 +02:00
1 parent b1b76ab68a
commit b0862c0902
11 files changed
+181 -39

No files matched your search

+10
View File
@@ -151,6 +151,16 @@ export interface InsightsAnalyticsData {
weight: number;
source?: "manual" | "withings" | "appleHealth" | "mixed" | "none";
asOf?: string;
/**
* v1.34 — which yardstick graded this row. `"user"` when the account
* has set an explicit weight target (`target` then carries that band
* in kg), `"none"` when the pillar scored the bare trend against no
* target at all. The card renders one disclosure line off this pair;
* until it existed the score graded weight against a BMI-22 band
* nobody chose and no surface named.
*/
targetSource?: "user" | "none";
target?: { min: number; max: number } | null;
};
mood: {
value: number | null;