fix;设置和深浅色
This commit is contained in:
+4
-1
@@ -7,6 +7,7 @@ import '../routing/app_router.dart';
|
||||
import '../theme/app_theme.dart';
|
||||
import '../theme/yanting_text.dart';
|
||||
import '../theme/yanting_shad_theme.dart';
|
||||
import '../theme/theme_controller.dart';
|
||||
|
||||
class ReportNotebooklmApp extends ConsumerWidget {
|
||||
const ReportNotebooklmApp({super.key});
|
||||
@@ -14,6 +15,7 @@ class ReportNotebooklmApp extends ConsumerWidget {
|
||||
@override
|
||||
Widget build(BuildContext context, WidgetRef ref) {
|
||||
final router = ref.watch(routerProvider);
|
||||
final themeMode = ref.watch(themeModeProvider);
|
||||
final dmSansStyle = GoogleFonts.dmSans().copyWith(
|
||||
fontFamilyFallback: YantingText.fontFallback,
|
||||
);
|
||||
@@ -23,9 +25,10 @@ class ReportNotebooklmApp extends ConsumerWidget {
|
||||
debugShowCheckedModeBanner: false,
|
||||
theme: buildYantingShadTheme(),
|
||||
darkTheme: buildYantingDarkShadTheme(),
|
||||
themeMode: themeMode,
|
||||
routerConfig: router,
|
||||
scrollBehavior: const ShadScrollBehavior(),
|
||||
materialThemeBuilder: (context, theme) => buildAppTheme(),
|
||||
materialThemeBuilder: (context, theme) => buildAppTheme(theme.brightness),
|
||||
builder: (context, child) {
|
||||
return DefaultTextStyle.merge(
|
||||
style: TextStyle(fontFamilyFallback: dmSansStyle.fontFamilyFallback),
|
||||
|
||||
Reference in New Issue
Block a user