Browse Source

Fix choicebox title color

Neeraj Gupta 3 years ago
parent
commit
fe99a9509c
1 changed files with 4 additions and 1 deletions
  1. 4 1
      lib/ui/common/dialogs.dart

+ 4 - 1
lib/ui/common/dialogs.dart

@@ -6,6 +6,7 @@ enum ActionType {
   confirm,
   critical,
 }
+
 // if dialog is dismissed by tapping outside, this will return null
 Future<DialogUserChoice> showChoiceDialog<T>(
   BuildContext context,
@@ -21,7 +22,9 @@ Future<DialogUserChoice> showChoiceDialog<T>(
     title: Text(
       title,
       style: TextStyle(
-        color: actionType == ActionType.critical ? Colors.red : Colors.white,
+        color: actionType == ActionType.critical
+            ? Colors.red
+            : Theme.of(context).colorScheme.primary,
       ),
     ),
     content: Text(