Skip to content
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

[BUG] Some text can't be translated due to fields out of translations #993

Closed
crwilcox opened this issue Mar 24, 2020 · 0 comments · Fixed by #994
Closed

[BUG] Some text can't be translated due to fields out of translations #993

crwilcox opened this issue Mar 24, 2020 · 0 comments · Fixed by #994
Labels
bug Something isn't working

Comments

@crwilcox
Copy link
Contributor

Some entries are hard to translate as text is built up with separate contexts.

From #981 :

Yes, they are numbers and dates and I can keep them. But there are some texts that are added outside the templates, such as (from https://github.com/nextstrain/auspice/blob/master/src/components/info/info.js#L91)

const prefix = branchLengthsToDisplay !== "divOnly" ? t("and comprising") : t("comprising");
const filterText = arrayToSentence(filterTextArr, {prefix: prefix, capatalise: false});
if (filterText.length) {
summary += ${filterText};
} else {
summary += ". ";
}
In this case, the code assumes that you can add filterText after the template and there's currently no way to control it.

@crwilcox crwilcox added the bug Something isn't working label Mar 24, 2020
crwilcox added a commit to crwilcox/auspice that referenced this issue Mar 24, 2020
jameshadfield added a commit that referenced this issue Mar 26, 2020
* pr-994:
  Fix linting, key names and double period ".." strings
  add periods to english translations
  Fixes #993 by creating separate translations for compound sentences
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant