Surface/lib/theme.dart

28 lines
613 B
Dart
Raw Normal View History

2024-11-08 16:09:46 +00:00
import 'package:flutter/material.dart';
class ThemeSet {
ThemeData light;
ThemeData dark;
ThemeSet({required this.light, required this.dark});
}
ThemeSet createAppThemeSet() {
return ThemeSet(
2024-11-10 04:41:56 +00:00
light: createAppTheme(Brightness.light),
dark: createAppTheme(Brightness.dark),
2024-11-08 16:09:46 +00:00
);
}
2024-11-10 04:41:56 +00:00
ThemeData createAppTheme(Brightness brightness) {
2024-11-08 16:09:46 +00:00
return ThemeData(
useMaterial3: false,
colorScheme: ColorScheme.fromSeed(
seedColor: Colors.indigo,
2024-11-10 04:41:56 +00:00
brightness: brightness,
2024-11-08 16:09:46 +00:00
),
2024-11-10 04:41:56 +00:00
brightness: brightness,
iconTheme: const IconThemeData(fill: 0, weight: 400, opticalSize: 20),
2024-11-08 16:09:46 +00:00
);
}