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

Add custom placeholders to Transifex #11660

Open
rffontenelle opened this issue Oct 8, 2024 · 1 comment
Open

Add custom placeholders to Transifex #11660

rffontenelle opened this issue Oct 8, 2024 · 1 comment

Comments

@rffontenelle
Copy link
Contributor

What's the problem this feature will solve?

Prevent translators from translating words/expressions that were expected by developers/maintainers to be kept in English.

Describe the solution you'd like

Add custom placeholders to Translation Checks for terms that should be kept in English in the translation.

They can be set in:

  1. https://app.transifex.com/readthedocs/settings/validations/
  2. PO File (.po, .pot) checks > Manage placeholders (last item)
  3. set starting pattern and end pattern for each placeholders, and save
  4. Browse the translation strings of any language in the readthedocs project (UI)

Great candidates to be placeholders are:

  • {{term}} (start with {{ and end with }})
  • {term} (single {}, after the above as order matters)
  • Read the Docs
  • any other you feel that would be interesting (consider checking the msgid lines in any PO file for the source strings).

Alternative solutions

Do nothing, and translators will keep being able to translate variables in the translation strings.

Additional context

See Setting Translation Checks in Transifex docs.

Custom placeholders are added at organization level, which means it applies for the UI (readthedocs project), docs (readthedocs-docs project) and theme (sphinx-rtd-theme project).

If the translator doesn't keep the placeholder text in their translation, a ⚠️ warning banner will be displayed stating that fact. The translation is still saved, though.

@humitos
Copy link
Member

humitos commented Oct 10, 2024

Thanks for opening this issue. This would be a great validation 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants