applyApp method

ThemeData applyApp()

Implementation

ThemeData applyApp() {
  final primaryColor = Colors.deepPurple;

  final newFloatingActionButtonTheme = floatingActionButtonTheme.copyWith(
    backgroundColor: primaryColor,
    foregroundColor: Colors.white,
    shape: const CircleBorder(),
  );

  final newAppBarTheme = appBarTheme.copyWith(
    centerTitle: true,
    elevation: 0,
    backgroundColor: primaryColor,
    foregroundColor: Colors.white,
  );

  final newListTileTheme = listTileTheme.copyWith(
    shape: RoundedRectangleBorder(
      borderRadius: BorderRadius.circular(24),
    ),
    tileColor: Colors.white,
  );

  final newCardTheme = cardTheme.copyWith(
    shape: RoundedRectangleBorder(
      borderRadius: BorderRadius.circular(24),
    ),
    color: Colors.white,
    elevation: 16,
    shadowColor: Colors.black,
  );

  return copyWith(
    floatingActionButtonTheme: newFloatingActionButtonTheme,
    appBarTheme: newAppBarTheme,
    scaffoldBackgroundColor: primaryColor,
    listTileTheme: newListTileTheme,
    cardTheme: newCardTheme,
  );
}