mirror of
https://github.com/MBombeck/HealthLog.git
synced 2026-11-09 21:10:59 +00:00
Sleep nights collapse per writer instead of per source: several HealthKit apps land behind the same source value, so a phone's coarse awake and in-bed blocks could blend into or fully constitute a night whose stages another writer had recorded. The winning writer per session is the one with the most distinct granular stages, then the user's source ladder, and its rows are kept whole. The device type is threaded through every sleep read including the stage stacked bar, and the sync overlap for late-arriving nights widens from one day to seven so a night scored after the cursor passed is fetched on the next tick — assembly is read-time, so affected nights heal without manual repair. Mood notes expand to their full text in the list on desktop and touch, replacing the hover-only tooltip, and the mood CSV export carries a note column.