fix(i18n): map Asturian to Spanish chrome in boot splash
The pre-init BootstrapSplash passed the raw device locale to its MaterialApp, so booting under an Asturian (ast) device locale threw the 'locale not supported by localization delegates' warning — the Material/Cupertino delegates ship no ast. The main app already routes ast to Spanish framework chrome via materialLocaleFor; apply the same mapping in the splash. Drop @visibleForTesting since it's now shared production code.
This commit is contained in:
parent
63f48db5c2
commit
491bc918eb
2 changed files with 3 additions and 2 deletions
|
|
@ -110,7 +110,9 @@ class BootstrapSplash extends StatelessWidget {
|
|||
return MaterialApp(
|
||||
debugShowCheckedModeBanner: false,
|
||||
theme: buildTaneTheme(),
|
||||
locale: TranslationProvider.of(context).flutterLocale,
|
||||
// Asturian (`ast`) has no bundled Material/Cupertino localizations, so map
|
||||
// it to Spanish for the framework chrome — same as the main app (app.dart).
|
||||
locale: materialLocaleFor(TranslationProvider.of(context).flutterLocale),
|
||||
supportedLocales: AppLocaleUtils.supportedLocales,
|
||||
localizationsDelegates: const [
|
||||
GlobalMaterialLocalizations.delegate,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue