lemmur-app-android/lib/app.dart

31 lines
866 B
Dart
Raw Normal View History

import 'package:flutter/material.dart';
import 'package:keyboard_dismisser/keyboard_dismisser.dart';
import 'l10n/l10n.dart';
import 'pages/home_page.dart';
2022-01-06 15:28:42 +01:00
import 'resources/theme.dart';
import 'stores/config_store.dart';
import 'util/observer_consumers.dart';
class MyApp extends StatelessWidget {
const MyApp();
@override
Widget build(BuildContext context) {
return KeyboardDismisser(
child: ObserverBuilder<ConfigStore>(
builder: (context, store) => MaterialApp(
title: 'lemmur',
supportedLocales: L10n.supportedLocales,
localizationsDelegates: L10n.localizationsDelegates,
themeMode: store.theme,
darkTheme: store.amoledDarkMode ? amoledTheme : darkTheme,
locale: store.locale,
theme: lightTheme,
home: const HomePage(),
),
),
);
}
}