Closed dukenebur closed 10 months ago
I tried with something like this but it didn't work
Localizations.override( context: context, locale: const Locale('en'), child: Builder( builder: (context) { return DateTimeFormField(
This does not work because your Localizations.override
is around the DateTimeFormField
and the date picker is a dialog with a new route. So when the date picker dialog tries to get the localizations with MaterialLocalizations.of(context)
, it will get the localizations of your MaterialApp
. To change the dialog language to english, set the locale on your MaterialApp
.
Hello! How I can change this?