From 5dab0a679577a2822ebca776348697cd4ca0bb5e Mon Sep 17 00:00:00 2001 From: Chris Bobbe Date: Wed, 4 Sep 2024 00:11:05 -0700 Subject: [PATCH] msglist: Fix mark-as-read button icon color in dark mode After sweeping through the message-list screen to implement dark theme (#843), in late July, the Flutter framework merged flutter/flutter#143501, in early August. This made it so our `foregroundColor` no longer controlled the icon color, as promised in the dartdocs of `foregroundColor` and `iconColor`. I opened an issue for Flutter about the inconsistency with the doc: https://github.com/flutter/flutter/issues/154644 and sent a PR to resolve it, by updating the doc (which the author of 143501 had said was the right fix): https://github.com/flutter/flutter/pull/154646 Fixes: #926 --- lib/widgets/message_list.dart | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/widgets/message_list.dart b/lib/widgets/message_list.dart index 936758cd9f..bf123e7402 100644 --- a/lib/widgets/message_list.dart +++ b/lib/widgets/message_list.dart @@ -758,6 +758,7 @@ class _MarkAsReadWidgetState extends State { // state is disabled, pressed, etc. We handle those states // separately, via MarkAsReadAnimation. foregroundColor: const WidgetStatePropertyAll(Colors.white), + iconColor: const WidgetStatePropertyAll(Colors.white), backgroundColor: WidgetStatePropertyAll(messageListTheme.unreadMarker), ), onPressed: _loading ? null : () => _handlePress(context),