Skip to content

Releases: slang-i18n/slang

fast_i18n v3.0.1

18 Mar 15:59
b8055af
Compare
Choose a tag to compare
  • add real project example
  • update FAQ in README
  • depend on null-safety version of recase package

fast_i18n v3.0.0

13 Mar 14:26
cc3294a
Compare
Choose a tag to compare

New Features:

  • null safety support
  • add type-safe functions LocaleSettings.setLocaleTyped and LocaleSettings.currentLocaleTyped

Breaking:

  • output_translate_var renamed to translate_var in build.yaml config file

fast_i18n v2.3.1

04 Mar 14:08
31b9073
Compare
Choose a tag to compare

Bug Fix:

  • make locales case sensitive to comply with MaterialApp's supportedLocales.

fast_i18n v2.3.0

03 Mar 01:34
24bb58f
Compare
Choose a tag to compare

New Feature:

  • Add supportedLocales property that can be used to fill MaterialApp's supportedLocales argument.

fast_i18n v2.2.1

28 Feb 21:05
fa09672
Compare
Choose a tag to compare

Bug Fix:

  • compilation error occurring when non-standard name (not 'strings.i18n.json') is used for json files (thanks to @Pavel-Sulimau)

fast_i18n v2.2.0

02 Feb 17:38
77b33dd
Compare
Choose a tag to compare

New config: output_translate_var, renames default t variable
Internal: device locale now fetched via Platform.localeName

fast_i18n v2.1.0

13 Nov 18:18
b0812a7
Compare
Choose a tag to compare

A rebuild is needed: flutter pub run build_runner build.

  • API change: LocaleSettings.useDeviceLocale() is no longer asynchronous, now returns the new locale (Future<void> -> String)
  • API change: LocaleSettings.setLocale(locale) now also returns the new locale (void -> String)

Just in case you use internal API:
FastI18n.findDeviceLocale has been renamed to FastI18n.getDeviceLocale

fast_i18n v2.0.0

04 Nov 16:57
0709f3a
Compare
Choose a tag to compare

Thanks to @DenchikBY.

  • Now it's possible to set in and out directories for files.
  • You can set the pattern by which to search for files.
  • Generated keys can be switched to another case in generated classes.
  • Removed dependency on devicelocale.
  • Configs with baseLocale and maps moved from config.i18n.json to build.yaml
  • Generators replaced with fields for keys with static values.
  • Arguments now can be wrapped with braces like ${key}.
  • Removed deprecated #map mode (deprecated in 1.5.0)

Example of new config in build.yaml:

targets:
  $default:
    builders:
      fast_i18n:i18nBuilder:
        options:
          base_locale: en
          input_directory: lib/i18n
          input_file_pattern: .i18n.json
          output_directory: lib/i18n
          output_file_pattern: .g.dart
          key_case: snake
          maps:
            - a
            - b
            - c.d

fast_i18n v1.8.2

04 Nov 13:15
74067f5
Compare
Choose a tag to compare

Hotfix:
possible NPE when calling Translations.of(context)

fast_i18n v1.8.1

30 Oct 20:55
0f07a3b
Compare
Choose a tag to compare

Hotfix:
possible NPE error when calling LocaleSettings.useDeviceLocale or LocaleSettings.setLocale