import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'core/theme/app_theme.dart'; import 'features/auth/presentation/bloc/auth_bloc.dart'; import 'routing/app_router.dart'; /// Root widget for the FocusFlow app. /// /// Provides BLoCs at the top of the tree so they are available to every /// route, then delegates to GoRouter for navigation. class FocusFlowApp extends StatelessWidget { const FocusFlowApp({super.key}); @override Widget build(BuildContext context) { return MultiBlocProvider( providers: [ BlocProvider(create: (_) => AuthBloc()..add(AuthCheckRequested())), ], child: MaterialApp.router( title: 'FocusFlow', debugShowCheckedModeBanner: false, theme: AppTheme.light, darkTheme: AppTheme.dark, themeMode: ThemeMode.system, routerConfig: AppRouter.router, ), ); } }