odolbeau / phone-number-bundle

Integrates libphonenumber into your Symfony application
MIT License
217 stars 43 forks source link

Fix Catalan locale code in translations filename #116

Closed aprat84 closed 2 years ago

aprat84 commented 2 years ago

Catalan base language code is ca. The ca_ES code is just a country-specific dialect (Catalan from Spain). Just like en, es and pt are base language codes and en_AU (English from Australia), es_419 (Spanish from LATAM) and pt_BR (Portuguese from Brazil) are dialects.

Catalan in wikipedia Common IETF primary language subtags

Nek- commented 2 years ago

Hello,

Thank you very much for your contribution! Links to documentation are a real appreciation, you did great.

This is an interesting mistake here. I have no insight about that... It's ok for me to make this change, but if somebody with a little more knowledge about translation may be valid this, that would be great.

aprat84 commented 2 years ago

Looking at examples from symfony github or some popular libraries, ca is the way to go: Symfony Validator Symfony Security Carbon moment.js

I'll put it another way: if I want to use Catalan in symfony, I'll configure it with ca locale. If I do this, symfony translations (validators, security) work well, but this library's don't.

Nek- commented 2 years ago

Thank you very much for your contribution !