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 support for Apple XLIFF #4614

Open
nijel opened this issue Apr 20, 2022 · 1 comment
Open

Add support for Apple XLIFF #4614

nijel opened this issue Apr 20, 2022 · 1 comment
Labels

Comments

@nijel
Copy link
Member

nijel commented Apr 20, 2022

Apple has invented own way of storing plurals in XLIFF, it might be useful to add support for that.

It is same logic as in stringsdict, but rendered in XLIFF.

This is described here:

https://docs.lokalise.com/en/articles/1400816-xliff-xlf-xliff#plural-support

Example:

  <file original="Hello/en.lproj/Localizable.stringsdict" source-language="en" datatype="plaintext" target-language="ru">
    <body>
      <trans-unit id="/plural_test:dict/NSStringLocalizedFormatKey:dict/:string">
        <source>%#@format@</source>
        <target>%#@format@</target>
      </trans-unit>
      <trans-unit id="/plural_test:dict/format:dict/few:dict/:string">
        <source>Other</source>
        <target>Немного</target>
      </trans-unit>
      <trans-unit id="/plural_test:dict/format:dict/many:dict/:string">
        <source>Other</source>
        <target>Много</target>
      </trans-unit>
      <trans-unit id="/plural_test:dict/format:dict/one:dict/:string">
        <source>One</source>
        <target>Один</target>
      </trans-unit>
      <trans-unit id="/plural_test:dict/format:dict/other:dict/:string">
        <source>Other</source>
        <target>Другое</target>
      </trans-unit>
    </body>
  </file>
@nijel nijel added the formats label Apr 20, 2022
@nijel
Copy link
Member Author

nijel commented Dec 8, 2022

#3583 is related for other iOS changes in the format.

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

No branches or pull requests

1 participant