Skip to content
This repository was archived by the owner on Jun 13, 2024. It is now read-only.
This repository was archived by the owner on Jun 13, 2024. It is now read-only.

[i18n] Some of the translations incorrectly handle placeholder values #462

@shihaohong

Description

@shihaohong

When generating translations for the gallery, the translations are pulled from Google's translation console. We handle placeholders within translated Strings by interpolating variables into them from the application code. However, some of the translations incorrectly have the names of the variables translated as well, which would result in a bad string:

Example:
In the arb file, "അടുത്തറിയുക {ലക്ഷ്യസ്ഥാനത്തിന്റെ പേര്}" should be "അടുത്തറിയുക {destinationName}" for cardsDemoExploreSemantics.

This is because in the code, this string would be created by calling something like GalleryLocalizations.of(context).cardsDemoExploreSemantics('The Destination'), and the code would look something like:

String cardsDemoExploreSemantics(String destinationName) => 'അടുത്തറിയുക $destinationName';

I've already submitted fix suggestions in the translation console and am creating this issue to just track when these are resolved.

See #460 for the list of mistakes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions