feat(01-02): wire app.dart and main.dart for launchable app

- App widget with MaterialApp.router, theme/darkTheme from AppTheme, themeMode from ThemeNotifier
- German localization delegates configured, debug banner disabled
- main.dart wraps App in ProviderScope with ensureInitialized
- All 16 tests pass, dart analyze clean, flutter build apk succeeds

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-15 20:06:53 +01:00
parent f2dd737e9e
commit 014722a850
2 changed files with 31 additions and 1 deletions

27
lib/app.dart Normal file
View File

@@ -0,0 +1,27 @@
import 'package:flutter/material.dart';
import 'package:flutter_riverpod/flutter_riverpod.dart';
import 'package:household_keeper/core/router/router.dart';
import 'package:household_keeper/core/theme/app_theme.dart';
import 'package:household_keeper/core/theme/theme_provider.dart';
import 'package:household_keeper/l10n/app_localizations.dart';
class App extends ConsumerWidget {
const App({super.key});
@override
Widget build(BuildContext context, WidgetRef ref) {
final themeMode = ref.watch(themeProvider);
return MaterialApp.router(
routerConfig: router,
theme: AppTheme.lightTheme(),
darkTheme: AppTheme.darkTheme(),
themeMode: themeMode,
localizationsDelegates: AppLocalizations.localizationsDelegates,
supportedLocales: const [Locale('de')],
locale: const Locale('de'),
debugShowCheckedModeBanner: false,
);
}
}