add auth, format
This commit is contained in:
16
lib/app.dart
16
lib/app.dart
@@ -33,7 +33,6 @@ class WorkerApp extends ConsumerWidget {
|
||||
theme: AppTheme.lightTheme(),
|
||||
darkTheme: AppTheme.darkTheme(),
|
||||
themeMode: ThemeMode.light, // TODO: Make this configurable from settings
|
||||
|
||||
// ==================== Localization Configuration ====================
|
||||
// Support for Vietnamese (primary) and English (secondary)
|
||||
localizationsDelegates: const [
|
||||
@@ -53,8 +52,10 @@ class WorkerApp extends ConsumerWidget {
|
||||
],
|
||||
|
||||
// Default locale (Vietnamese)
|
||||
locale: const Locale('vi', 'VN'), // TODO: Make this configurable from settings
|
||||
|
||||
locale: const Locale(
|
||||
'vi',
|
||||
'VN',
|
||||
), // TODO: Make this configurable from settings
|
||||
// Locale resolution strategy
|
||||
localeResolutionCallback: (locale, supportedLocales) {
|
||||
// Check if the device locale is supported
|
||||
@@ -71,9 +72,7 @@ class WorkerApp extends ConsumerWidget {
|
||||
// ==================== Material App Configuration ====================
|
||||
// Builder for additional context-dependent widgets
|
||||
builder: (context, child) {
|
||||
return _AppBuilder(
|
||||
child: child ?? const SizedBox.shrink(),
|
||||
);
|
||||
return _AppBuilder(child: child ?? const SizedBox.shrink());
|
||||
},
|
||||
);
|
||||
}
|
||||
@@ -86,9 +85,7 @@ class WorkerApp extends ConsumerWidget {
|
||||
/// - Connectivity listener
|
||||
/// - Global overlays (loading, snackbars)
|
||||
class _AppBuilder extends ConsumerWidget {
|
||||
const _AppBuilder({
|
||||
required this.child,
|
||||
});
|
||||
const _AppBuilder({required this.child});
|
||||
|
||||
final Widget child;
|
||||
|
||||
@@ -116,4 +113,3 @@ class _AppBuilder extends ConsumerWidget {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user