| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980 |
- import 'package:flutter/material.dart';
- import 'package:flutter/services.dart';
- import 'ui/main_menu.dart';
- import 'utils/colors.dart';
- import 'utils/settings_manager.dart';
- import 'utils/score_manager.dart';
- import 'utils/google_play_games_manager.dart';
- void main() async {
- WidgetsFlutterBinding.ensureInitialized();
- await SettingsManager.init();
- await ScoreManager.initialize();
-
- // Initialize Google Play Games (silent init, don't require sign-in)
- await GooglePlayGamesManager.instance.initialize();
-
- runApp(const ZenTapApp());
- }
- class ZenTapApp extends StatelessWidget {
- const ZenTapApp({super.key});
- @override
- Widget build(BuildContext context) {
- return MaterialApp(
- title: 'ZenTap',
- debugShowCheckedModeBanner: false,
- theme: ThemeData(
- // Use ZenTap color scheme
- colorScheme: ColorScheme.dark(
- primary: ZenColors.buttonBackground,
- secondary: ZenColors.defaultLink,
- surface: ZenColors.uiElements,
- onPrimary: ZenColors.buttonText,
- onSecondary: ZenColors.white,
- onSurface: ZenColors.primaryText,
- ),
- scaffoldBackgroundColor: ZenColors.appBackground,
- appBarTheme: const AppBarTheme(
- backgroundColor: ZenColors.appBackground,
- foregroundColor: ZenColors.primaryText,
- elevation: 0,
- systemOverlayStyle: SystemUiOverlayStyle.light,
- ),
- textTheme: const TextTheme(
- bodyLarge: TextStyle(color: ZenColors.primaryText),
- bodyMedium: TextStyle(color: ZenColors.primaryText),
- bodySmall: TextStyle(color: ZenColors.secondaryText),
- titleLarge: TextStyle(color: ZenColors.primaryText),
- titleMedium: TextStyle(color: ZenColors.primaryText),
- titleSmall: TextStyle(color: ZenColors.primaryText),
- ),
- elevatedButtonTheme: ElevatedButtonThemeData(
- style: ElevatedButton.styleFrom(
- backgroundColor: ZenColors.buttonBackground,
- foregroundColor: ZenColors.buttonText,
- elevation: 4,
- shape: RoundedRectangleBorder(
- borderRadius: BorderRadius.circular(12),
- ),
- ),
- ),
- dialogTheme: DialogThemeData(
- backgroundColor: ZenColors.uiElements,
- titleTextStyle: const TextStyle(
- color: ZenColors.primaryText,
- fontSize: 20,
- fontWeight: FontWeight.bold,
- ),
- contentTextStyle: TextStyle(
- color: ZenColors.secondaryText,
- fontSize: 16,
- ),
- ),
- useMaterial3: true,
- ),
- home: const MainMenu(),
- );
- }
- }
|