diff --git a/NucleicRemote/NucleicRemote/Views/HomeView.swift b/NucleicRemote/NucleicRemote/Views/HomeView.swift index 696e20b..0fd8dda 100644 --- a/NucleicRemote/NucleicRemote/Views/HomeView.swift +++ b/NucleicRemote/NucleicRemote/Views/HomeView.swift @@ -18,6 +18,12 @@ struct HomeView: View { Dictionary(store.dashboard.activity.map { (Calendar.current.startOfDay(for: $0.day), $0.count) }, uniquingKeysWith: +) } + /// Tokens used per day — the activity grid's primary intensity signal (falls back to message + /// count for days without recorded usage). Mirrors the Mac home. + private var tokensByDay: [Date: Int] { + Dictionary(store.dashboard.activity.map { (Calendar.current.startOfDay(for: $0.day), $0.tokens) }, + uniquingKeysWith: +) + } /// Current activity streak with streak freezes folded in — the run of consecutive active /// days, where a banked freeze (one earned per five days) bridges a missed day. Shared with