1- /// nodoc
1+ /// @ nodoc
22library ;
33
44import 'dart:async' ;
@@ -65,17 +65,15 @@ import 'ouds_localizations_en.dart';
6565/// be consistent with the languages listed in the OudsLocalizations.supportedLocales
6666/// property.
6767abstract class OudsLocalizations {
68- OudsLocalizations (String locale)
69- : localeName = intl.Intl .canonicalizedLocale (locale.toString ());
68+ OudsLocalizations (String locale) : localeName = intl.Intl .canonicalizedLocale (locale.toString ());
7069
7170 final String localeName;
7271
7372 static OudsLocalizations ? of (BuildContext context) {
7473 return Localizations .of <OudsLocalizations >(context, OudsLocalizations );
7574 }
7675
77- static const LocalizationsDelegate <OudsLocalizations > delegate =
78- _OudsLocalizationsDelegate ();
76+ static const LocalizationsDelegate <OudsLocalizations > delegate = _OudsLocalizationsDelegate ();
7977
8078 /// A list of this localizations delegate along with the default localizations
8179 /// delegates.
@@ -87,19 +85,15 @@ abstract class OudsLocalizations {
8785 /// Additional delegates can be added by appending to this list in
8886 /// MaterialApp. This list does not have to be used at all if a custom list
8987 /// of delegates is preferred or required.
90- static const List <LocalizationsDelegate <dynamic >> localizationsDelegates =
91- < LocalizationsDelegate <dynamic >> [
88+ static const List <LocalizationsDelegate <dynamic >> localizationsDelegates = < LocalizationsDelegate <dynamic >> [
9289 delegate,
9390 GlobalMaterialLocalizations .delegate,
9491 GlobalCupertinoLocalizations .delegate,
9592 GlobalWidgetsLocalizations .delegate,
9693 ];
9794
9895 /// A list of this localizations delegate's supported locales.
99- static const List <Locale > supportedLocales = < Locale > [
100- Locale ('ar' ),
101- Locale ('en' )
102- ];
96+ static const List <Locale > supportedLocales = < Locale > [Locale ('ar' ), Locale ('en' )];
10397
10498 /// No description provided for @core_button_loading_a11y.
10599 ///
@@ -252,19 +246,16 @@ abstract class OudsLocalizations {
252246 String get core_password_input_hint_hide_a11y;
253247}
254248
255- class _OudsLocalizationsDelegate
256- extends LocalizationsDelegate <OudsLocalizations > {
249+ class _OudsLocalizationsDelegate extends LocalizationsDelegate <OudsLocalizations > {
257250 const _OudsLocalizationsDelegate ();
258251
259252 @override
260253 Future <OudsLocalizations > load (Locale locale) {
261- return SynchronousFuture <OudsLocalizations >(
262- lookupOudsLocalizations (locale));
254+ return SynchronousFuture <OudsLocalizations >(lookupOudsLocalizations (locale));
263255 }
264256
265257 @override
266- bool isSupported (Locale locale) =>
267- < String > ['ar' , 'en' ].contains (locale.languageCode);
258+ bool isSupported (Locale locale) => < String > ['ar' , 'en' ].contains (locale.languageCode);
268259
269260 @override
270261 bool shouldReload (_OudsLocalizationsDelegate old) => false ;
@@ -279,8 +270,7 @@ OudsLocalizations lookupOudsLocalizations(Locale locale) {
279270 return OudsLocalizationsEn ();
280271 }
281272
282- throw FlutterError (
283- 'OudsLocalizations.delegate failed to load unsupported locale "$locale ". This is likely '
273+ throw FlutterError ('OudsLocalizations.delegate failed to load unsupported locale "$locale ". This is likely '
284274 'an issue with the localizations generation tool. Please file an issue '
285275 'on GitHub with a reproducible sample app and the gen-l10n configuration '
286276 'that was used.' );
0 commit comments