Heart And Vitals
Status: Current implemented behavior. One parametric screen serves all ten metrics. Audience: Users and contributors. Implementation:
features/heart,features/vitals,features/manualentry/vitals,data/repository/HeartRepository.kt,data/repository/VitalsRepository.kt. Navigation:Screen.Metric, vitals entry routes; heart and vitals dashboard widgets. Related: Feature map, Manual entry of metrics, Statistics.
Heart and vitals are related but distinct feature areas, and the split is in the data layer, not the screen layer.
features/heartowns heart-rate-oriented state, presentation mapping, and route wrappers for average heart rate, resting heart rate, and HRV.features/vitalsowns vitals-facing screens and UI helpers such as blood pressure, SpO2, VO2 max, respiratory rate, body temperature, blood glucose, skin temperature, and the Today Vitals overview.- The read split is real:
HeartRepositoryserves heart rate / resting heart rate / HRV,VitalsRepositoryserves the rest, andLoadHeartPeriodUseCasecombines them so one screen can load either family.
The current implementation still shares HeartViewModel and the heart period loader across heart and vitals routes. That is an intentional transitional boundary: the user-facing vitals UI lives in features/vitals, while some loading and state infrastructure remains shared until a deeper split is worth the extra complexity.
Implemented Metrics
Heart metrics:
- Average heart rate.
- Resting heart rate.
- HRV.
Vitals metrics:
- Blood pressure.
- SpO2.
- VO2 max.
- Respiratory rate.
- Body temperature.
- Blood glucose.
- Skin temperature.
Detail Pattern
Heart and vitals detail screens use the shared metric detail scaffold:
- Day, week, month, and year ranges.
- Selected anchor date.
- Previous/next period navigation.
- Calendar date picking.
- Pull to refresh.
- Intraday charts where sample data is available.
- Period charts, statistics, thresholds, comparisons, data confidence, source labels, and entry lists.
- Reorderable sections.
OpenVitals-created vitals entries can be edited or deleted when the app has write permission and ownership can be verified. External records stay read-only.
Today Vitals
Each heart and vitals dashboard tile opens its own focused metric screen directly - tapping Blood pressure opens the blood pressure detail, not an intermediate overview.
Data Boundaries
Heart-rate and vitals records are read through feature-facing repository/use-case APIs rather than a global browser. Manual vitals entry lives under features/manualentry/vitals. Dashboard heart and vitals tiles open their per-metric screens directly.