Skip to content

Latest commit

 

History

History
81 lines (62 loc) · 2.27 KB

CHANGELOG.md

File metadata and controls

81 lines (62 loc) · 2.27 KB

[2.1.0] 2022-02-03

  • Added multiples path files.

[2.0.0+1] 2022-01-24

Now the Localization package is fully integrated into Flutter and can reflect changes made natively by the SDK.

  • BREAK CHANGE: Removed packages translation files;
  • BREAK CHANGE: .i18n() parameters are a positional args now;
  • BREAK CHANGE: Removed conditions. After long discussions, we decided that this is a developer responsibility, for example:
final items = 10;
if(items == 1) return 'title-label-singular'.i18n();
if(items > 1) return 'title-label-plural'.i18n();

[1.1.2-dev.1] 2022-01-13

Added support of translation files just with language, for example pt.json;

await Localization.configuration(showDebugPrintMode: false);

[1.1.1] 2021-11-22

deixar Log ocional, para desativa-lo basta utilizar

await Localization.configuration(showDebugPrintMode: false);

You can set the variable calling the function:

Localization.setShowDebugPrintMode(false);

[1.1.0] 2021-08-29

  • BREAK CHANGE: The parameters from method 'welcome'.i18n(["22/06"]) e Localization.translate('welcome', ["22/06"]) are named;
  • BREAK CHANGE: Use "welcome".i18n(args: ["22/06"]) ao invés de "welcome".i18n(["22/06"])
  • BREAK CHANGE: Use Localization.translate('welcome', args: ["22/06"]) ao invés de Localization.translate('welcome', ["22/06"])

New features

  • Adição de possibilidade de usar condicionais utilize o %b{condicao_verdadeira:condição_falsa} para configurar as suas traduções
{
	'quantidade':  '%s %b{Resultados:Resultado} %b{encontrados:encontrado}'
}

Será necessário na parâmetro conditions passar uma lista de Booleanos de forma posicional

Localization.translate(
	'testeQuantidade',
	args: ['2'],
	conditions: [true, true],
)
'testeQuantidade'.i18n(
	args: ['1'],
	conditions: [false, false],
)

[1.0.0] 2021-07-28

  • Use Text("welcome".i18n(args: ["22/06"])), ao inves de Text("welcome".i18n(["22/06"])),

[1.0.0] 2021-07-28

  • Adicionada possibilidade de multiplos diretórios de tradução;

[0.2.0-nullsafety] 2021-03-01

  • Migração Nullsafety;

[0.1.0] 2020-06-11

  • Atualizado README;
  • Adicionada automação no SLIDY CLI;

[0.0.2] 2020-02-25

  • Initial release.