toThemeData method

ThemeData toThemeData()

Implementation

ThemeData toThemeData() {
  final base = isDark ? ThemeData.dark() : ThemeData.light();
  return base.copyWith(
    scaffoldBackgroundColor: backgroundColor,
    cardColor: cardColor,
    primaryColor: primaryColor,
    colorScheme: base.colorScheme.copyWith(
      primary: primaryColor,
      secondary: secondaryColor,
      surface: surfaceColor,
    ),
  );
}