Created
April 19, 2022 15:45
-
-
Save alperefesahin/1580935d1301c173dd533cf1dc98c582 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class AppWidget extends StatelessWidget { | |
| const AppWidget({Key? key}) : super(key: key); | |
| @override | |
| Widget build(BuildContext context) { | |
| return BlocBuilder<LocalizationCubit, LocalizationState>( | |
| builder: (context, state) { | |
| return MaterialApp( | |
| navigatorKey: navigatorKey, | |
| locale: state.appLanguage, | |
| localizationsDelegates: const [ | |
| PivaLocalizationsDelegate(), | |
| GlobalMaterialLocalizations.delegate, | |
| GlobalWidgetsLocalizations.delegate, | |
| GlobalCupertinoLocalizations.delegate | |
| ], | |
| supportedLocales: const [Locale('en'), Locale('tr')], | |
| debugShowCheckedModeBanner: false, | |
| title: 'Piva', | |
| builder: (context, widget) => ResponsiveWrapperWidget(widget: widget!), | |
| home: const TimerPage(), | |
| ); | |
| }, | |
| ); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment