import 'package:dynamic_color/dynamic_color.dart'; import 'package:flutter/material.dart'; import 'package:voyagehandbook/util/color_schemes.g.dart'; import 'package:voyagehandbook/views/home.dart'; /* Voyage Handbook - The open-source WikiVoyage reader Copyright (C) 2023 Matyáš Caras This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 3 as published by the Free Software Foundation. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . */ void main() { runApp(const MyApp()); } class MyApp extends StatelessWidget { const MyApp({super.key}); // This widget is the root of your application. @override Widget build(BuildContext context) { return DynamicColorBuilder( builder: (lightDynamic, darkDynamic) => MaterialApp( title: 'Voyage Handbook', theme: ThemeData( useMaterial3: true, colorScheme: lightDynamic ?? lightColorScheme), darkTheme: ThemeData( useMaterial3: true, colorScheme: darkDynamic ?? darkColorScheme), home: const HomeView(), ), ); } }