dark property

ThemeData dark
getter/setter pair

The default dark theme

Features a blueGrey color scheme with dark background and appropriate styling for input fields and buttons.

Example usage:

MaterialApp(
  darkTheme: MkxTheme.dark,
  themeMode: ThemeMode.dark, // Force dark theme
  // ...
)

Implementation

static ThemeData dark = ThemeData(
  brightness: Brightness.dark,
  primarySwatch: Colors.blueGrey,
  colorScheme: ColorScheme.fromSeed(
    seedColor: Colors.blueGrey,
    brightness: Brightness.dark,
  ),
  inputDecorationTheme: InputDecorationTheme(
    border: OutlineInputBorder(
      borderRadius: BorderRadius.circular(8),
    ),
    focusedBorder: OutlineInputBorder(
      borderRadius: BorderRadius.circular(8),
      borderSide: const BorderSide(color: Colors.blueGrey, width: 2),
    ),
  ),
  elevatedButtonTheme: ElevatedButtonThemeData(
    style: ElevatedButton.styleFrom(
      shape: RoundedRectangleBorder(
        borderRadius: BorderRadius.circular(8),
      ),
      padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 12),
    ),
  ),
);