diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 352fa829..744a38c1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -120,8 +120,8 @@ jobs: - name: Generate run: | - make gen make translate + make gen - name: Get Libs ${{ matrix.platform }} run: | diff --git a/lib/core/prefs/locale_prefs.dart b/lib/core/prefs/locale_prefs.dart index 039ce5d6..24a697d3 100644 --- a/lib/core/prefs/locale_prefs.dart +++ b/lib/core/prefs/locale_prefs.dart @@ -10,8 +10,13 @@ part 'locale_prefs.g.dart'; @Riverpod(keepAlive: true) class LocaleNotifier extends _$LocaleNotifier { - late final _pref = - Pref(ref.watch(sharedPreferencesProvider), "locale", AppLocale.en); + late final _pref = Pref( + ref.watch(sharedPreferencesProvider), + "locale", + AppLocale.en, + mapFrom: AppLocale.values.byName, + mapTo: (value) => value.name, + ); @override AppLocale build() => _pref.getValue();