From bec930383e250b3641f9b241d8b664bacc90d533 Mon Sep 17 00:00:00 2001 From: Peter Stone Date: Wed, 15 Jul 2026 08:13:19 +0000 Subject: fix(widget): match task font color to events; complete instantly TaskRow used a flat hardcoded gray (0xFFDDDDDD) while EventBlock used Color.White (dimmed only when past) at the same size/weight -- the color mismatch read as a font difference. Both now use the same Color.White base. CompleteTaskAction previously did no local update at all: the row stayed visible until CompleteWorker's full complete() -> fetchAndPersist() -> updateAll() round trip finished (two sequential network calls). It now optimistically removes the completed item from the cached list and re-renders immediately, matching RefreshTaskAction's existing synchronous-flag-then-updateAll pattern -- the background worker's own fetchAndPersist still replaces this with the authoritative server state (including a newly-created recurring successor, if any) moments later. Co-Authored-By: Claude Sonnet 5 Claude-Session: https://claude.ai/code/session_01VTUSAEKfsPc6WGDq45yPHD --- android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'android/app/src/main/java/org/terst/doot/widget') diff --git a/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt b/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt index e762d2a..fd8481d 100644 --- a/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt +++ b/android/app/src/main/java/org/terst/doot/widget/ui/DootWidget.kt @@ -86,7 +86,7 @@ internal fun multiDayVariant(item: WidgetItem, renderDay: LocalDate, zone: ZoneI } } -private val json = Json { ignoreUnknownKeys = true } +internal val json = Json { ignoreUnknownKeys = true } class DootWidget : GlanceAppWidget() { @@ -483,7 +483,7 @@ fun TaskRow(task: WidgetItem, textSize: WidgetTextSize) { Text( text = task.title, style = TextStyle( - color = ColorProvider(Color(0xFFDDDDDD.toInt())), + color = ColorProvider(Color.White), fontSize = textSize.scaledContentSize(14), fontWeight = textSize.scaledContentWeight(FontWeight.Normal) ), -- cgit v1.2.3