-
I've been struggling with attempting to modify the accent colour in FlutterFire UI. Namely, I'd like to change the blue accent colour above to a different material colour, such as purple. I've messed around with the app theming to no avail, as none of the ThemeData parameters seem to influence this colour so far. I was wondering if this was possible? Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I ended up finding the answer to my own question. Turns out the theming is part of the buttons, and you have to individually define a few properties. I ended up defining the following: textButtonTheme: TextButtonThemeData(
style: TextButton.styleFrom(
primary: Colors.deepPurpleAccent,
),
),
elevatedButtonTheme: ElevatedButtonThemeData(
style: ElevatedButton.styleFrom(
primary: Colors.deepPurpleAccent,
),
),
outlinedButtonTheme: OutlinedButtonThemeData(
style: OutlinedButton.styleFrom(
primary: Colors.deepPurpleAccent,
),
),
colorScheme: ColorScheme.fromSwatch().copyWith(
primary: Colors.deepPurpleAccent,
secondary: Colors.deepPurpleAccent,
brightness: Brightness.light) This set them all to deepPurpleAccent! |
Beta Was this translation helpful? Give feedback.
I ended up finding the answer to my own question. Turns out the theming is part of the buttons, and you have to individually define a few properties. I ended up defining the following: