Add clinical threshold lines to AGP/Dagoverzicht charts, TIR stacked bar to Samenvatting

Closes gitea #14, #15.
This commit is contained in:
2026-08-01 22:26:26 +02:00
parent 699848b479
commit 00fb81b283
5 changed files with 135 additions and 3 deletions
+9 -1
View File
@@ -9,7 +9,13 @@ from reporting import (
sensor_active_percent,
tir_breakdown_5band,
)
from ui_common import load_range_data, render_completeness_warning, select_period_days
from ui_common import (
build_tir_stacked_bar_figure,
get_colors,
load_range_data,
render_completeness_warning,
select_period_days,
)
st.set_page_config(page_title="Glucose dashboard — Samenvatting", page_icon="📊", layout="wide")
require_auth()
@@ -66,6 +72,8 @@ cols = st.columns(5)
for col, band in zip(cols, band_labels, strict=True):
col.metric(band_labels[band], f"{tir[band]:.0f}%", help=f"Streefwaarde: {band_targets[band]}")
st.plotly_chart(build_tir_stacked_bar_figure(tir, get_colors()), width="stretch")
st.caption(
f"Periode: {start.strftime('%d-%m-%Y')} t/m {end.strftime('%d-%m-%Y')} "
f"({len(glucose)} metingen) · streefwaarden volgens Battelino et al. 2019"