flutter_translate icon indicating copy to clipboard operation
flutter_translate copied to clipboard

Pluralization feature not working for static keys

Open oysteinhodne opened this issue 1 year ago • 1 comments

It seems like the generation of plural keys is not working correctly at the moment. The generated keys file in the static_keys example does not generate the key "Plural.demo", only the children of it (Plural.demo.zero etc.). Which in turn gives a compilation error when I try to use the key in my widget, as the key does not exist.

I thought originally i was doing something wrong, but the generated files in the example also does this.

image

Am i correct in assuming that the example will not work either? Or am i doing something wrong when i get the compilation error when running:

translatePlural(Keys.Plural_Demo, _counter)

oysteinhodne avatar Jul 11 '22 12:07 oysteinhodne

I think the generation of plural keys needs to be updated in flutter_translate_gen in order for pluralization to work correctly after the latest changes in flutter_translate.

I don't have time currently to update the generator.

bratan avatar Jul 11 '22 12:07 bratan

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Sep 09 '22 15:09 stale[bot]

This issue shouldn't be closed if it's not resolved, it's still a problem.

faustodc avatar Nov 07 '22 12:11 faustodc

This issue is related to Flutter-Translate-Gen which is discontinued and is not going to be updated any longer.

bratan avatar Nov 07 '22 13:11 bratan

Sorry for not realizing that, then perhaps the readme and wiki should be updated to reflect that.

faustodc avatar Nov 07 '22 13:11 faustodc