diff --git a/NucleicRemote/NucleicRemote/Views/HomeView.swift b/NucleicRemote/NucleicRemote/Views/HomeView.swift index dcb3427..5f06fd7 100644 --- a/NucleicRemote/NucleicRemote/Views/HomeView.swift +++ b/NucleicRemote/NucleicRemote/Views/HomeView.swift @@ -218,8 +218,9 @@ struct ActivityGrid: View { let startOfWeek = cal.date(byAdding: .day, value: -(weekday - 1), to: today)! let gridStart = cal.date(byAdding: .day, value: -7 * (weeks - 1), to: startOfWeek)! // Brightness relative to *this user's* activity, outliers excluded so a few marathon - // days don't crush the everyday range. Computed once for the whole grid (mirrors Mac). - let scale = ActivityScale(activityByDay: activityByDay) + // days don't crush the everyday range. Shades by tokens-per-day, falling back to message + // count for days without recorded usage. Computed once for the whole grid (mirrors Mac). + let shading = ActivityShading(tokensByDay: tokensByDay, messagesByDay: activityByDay) return HStack(alignment: .top, spacing: gap) { ForEach(0..