flutter_i18n_translator 0.2.0
flutter_i18n_translator: ^0.2.0 copied to clipboard
A Flutter/Dart CLI tool that detects missing keys in JSON localization files, auto-translates them, and can regenerate Dart i18n helpers.
Changelog #
All notable changes to this project are documented in this file.
0.2.0 — 2025-03-02 #
✨ Added #
- Added setup steps for integrating the package with:
- VS Code
- Cursor
- Android Studio
- Added additional missing
WidgetsLocalizationsoverrides.
0.1.9 — 2025-12-10 #
- Added a donation link.
PayPal:
https://paypal.me/mazenelgayar
InstaPay:
https://ipn.eg/S/mazenel-gayarcib/instapay/0ecfXw
Tag: mazenel-gayarcib@instapay
0.1.8 - 2025-09-29 #
Added #
--enhanceGeneratedFileand--no-enhanceGeneratedFileCLI flags- Enhances the generated
I18nfile by:- Modifying the
localesetter to automatically reload and update callingonLocaleChangedautomatically - Adding a static
currentinstance ofI18nso you can access translations withoutBuildContext
- Modifying the
- Default is
--enhanceGeneratedFileenabled; can be explicitly disabled with--no-enhanceGeneratedFile.
- Enhances the generated
- New example in
example.dartfor--enhanceGeneratedFile.
0.1.7 - 2025-09-25 #
- Added
--autoDartFixGeneratedFileand--no-autoDartFixGeneratedFileCLI flags- Allows automatically running
dart fix --applyon generated files after code generation - Enabled by default, can be disabled with
--no-autoDartFixGeneratedFile
- Allows automatically running
0.1.6 - 2025-09-25 #
Fixed #
- Corrected all key case conversion functions:
_toCamelCase,_toPascalCase,_toSnakeCase,_toKebabCase.- Now accurately converts any input without breaking internal capitalization or producing incorrect outputs.
0.1.5 - 2025-09-25 #
Added #
- Steps in README for adding
flutter_i18n_translatoras an External Tool in Android Studio. - Example shortcuts via Keymap for quick access.
Changed #
i18PrintNormalnow prints tostdoutinstead ofstderrso normal messages are no longer displayed in red.i18PrintErrorstill prints tostderrin red.i18PrintDebugprints tostderrin green (if debug is enabled).
0.1.4 - 2025-09-25 #
Added #
--key-caseflag to automatically convert all JSON keys to a specific case.- Supported key case styles:
camel,camelcase,camel_case→ camelCasepascal,pascalcase,pascal_case→ PascalCasesnake,snakecase,snake_case→ snake_casekebab,kebabcase,kebab_case,dash,dashcase,dash_case→ kebab-case
- New examples in
example.dartfor each--key-casestyle. - Updated README with
--key-casedocumentation.
Changed #
- Updated CLI help to show all supported
--key-caseoptions.
0.1.3 - 2025-09-25 #
Added #
--autoGenerateflag to automatically regenerate i18n files (runsdart run i18n_json).--no-autoGenerateflag to explicitly disable automatic generation.--addMissingOverridesflag to ensure missingWidgetsLocalizationsoverrides are injected into the rootI18nclass after generation.--no-addMissingOverridesflag to skip injecting missing overrides.
Changed #
- Updated CLI help message to include the new options.
0.1.0 - 2025-09-24 #
- Initial release of i18n_translator CLI tool.
- Features:
- Detects missing keys in JSON localization files.
- Supports automatic translation using Google Translator.
- Allows batching translations with a configurable character limit.
- Options to auto-translate and apply without manual confirmation.
- Debug logging with
--show-debugand--no-debug. - CLI help with
--help.