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

Does not handle ICU offset #69

Open
Flydiverny opened this issue Jun 13, 2021 · 2 comments
Open

Does not handle ICU offset #69

Flydiverny opened this issue Jun 13, 2021 · 2 comments

Comments

@Flydiverny
Copy link

ICU format specifies offset:N which eo-locale currently doesn't handle parsing, neither ignoring or using.

Example from ICU user guide http://userguide.icu-project.org/formatparse/messages

{num_guests, plural, offset:1 "
      "=0 {{host} does not give a party.}"
      "=1 {{host} invites {guest} to her party.}"
      "=2 {{host} invites {guest} and one other person to her party.}

eo-locale will just print the entire translation text in this case.
image

This makes eo-locale hard to use with pluralisation or tools like Phrase which seem to add offset:0 by default 😅

@pret-a-porter
Copy link
Collaborator

pret-a-porter commented Jun 14, 2021

Hi @Flydiverny thank you for the issue! Do you think this property makes sense for real use cases?

@Flydiverny
Copy link
Author

I haven't seen anyone actually use it, and to be fair I don't really know why one would. I suppose there might be use for it in some localisation but with the plural syntax what I see most translations end up with just one and other regardless of being able to add more forms.

For our usage now I just made this dirty fix using patch-package since it was blocking our release 😄
image

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