willdurand / BazingaJsTranslationBundle

A pretty nice way to expose your Symfony translation messages to your client applications.
MIT License
572 stars 178 forks source link

Fix french pluralization #335

Closed nkampa closed 1 year ago

nkampa commented 2 years ago

References:

Accommodate the “new” plural form for French. The form itself isn’t new to the language, it just hasn’t been used on the Internet until recently. The Unicode Consortium (the organization which sets standards for software internationalization) made the change in the rules and recommends supporting this added plural form.

<source>{0} 0 days|{1} 1 day|]1,Inf] %1$s% days</source>
<target state="final">%1$s% jour| %1$s% de jours| %1$s% jours</target>

The second form de is only for numbers above 1000000.

stof commented 2 years ago

your patch does not apply it to French, but to a bunch of other locales too.

Also, the goal of this bundle is to reuse the Symfony translation files in JS easily. So this pluralization change should be adopted in Symfony first.