-
-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve translation flexibility #876
Comments
Seems that this has been merged into develop, maybe this issue can be closed? Or do you close these only when merged into master? |
Hi @Arkkimaagi you should be close this issue. |
Closing the issue as it was merged. |
This was referenced Jan 23, 2023
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
String joining can get us only so far regarding translations. In some cases it would be easier to reorder words with the translation strings.
I'd suggest that we'd add support for something like string literals that are coming in future version of js.
For example calendar could support Finnish way of saying the
RUNNING
a bit betteren.js:
fi.js:
Notice the
{timeUntilEnd}
variable there? That will be replaced with the variable during translation.This would be rendered in Finnish as:
Where moment.js returns
viiden minuutin
as we have five minutes left.Here is a screenshot from my mirror (where I have dropped the capitalization with css):
Of course we'd want to keep the translator backwards compatible, we'd want also this to work just as it does now so that all the current implementations do not break:
It should fallback to current approach resulting
I have a working sample of this thing with an example for this calendar thing only, but support could be built for all translations in future to combat rigid string joining problems.
The text was updated successfully, but these errors were encountered: