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

Improve plural marks #3948

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

quiple
Copy link
Contributor

@quiple quiple commented May 10, 2024

This PR combines duplicate parts of plural strings.

Before:

#: src/components/moderation/LabelsOnMe.tsx:57
msgid "{0, plural, one {# label has been placed on this account} other {# labels have been placed on this account}}"
msgstr ""

#: src/components/moderation/LabelsOnMe.tsx:63
msgid "{0, plural, one {# label has been placed on this content} other {# labels have been placed on this content}}"
msgstr ""

After:

#: src/components/moderation/LabelsOnMe.tsx:57
msgid "{0, plural, one {# label has} other {# labels have}} been placed on this account"
msgstr ""

#: src/components/moderation/LabelsOnMe.tsx:63
msgid "{0, plural, one {# label has} other {# labels have}} been placed on this content"
msgstr ""

@gaearon
Copy link
Contributor

gaearon commented May 10, 2024

Hmm. I'm not sure this makes sense because it leaves less freedom to other languages to rearrange words (if needed for grammar).

@quiple
Copy link
Contributor Author

quiple commented May 10, 2024

@gaearon It looks like you can freely reposition the plural string ({0, plural, one {# label has} other {# labels have}} in the example above) or put multiple of them in <Trans>.

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

Successfully merging this pull request may close these issues.

None yet

2 participants