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

Have a clear consistent language code #22

Open
ghassanmas opened this issue Sep 27, 2023 · 0 comments
Open

Have a clear consistent language code #22

ghassanmas opened this issue Sep 27, 2023 · 0 comments

Comments

@ghassanmas
Copy link
Member

ghassanmas commented Sep 27, 2023

Langague codes are used in multiple places, starting with transfiex typically lang locale is sepreated by _ but in code - is used.

One main of the inconsistente is that how TX have langauge code vs how MFEs refer to them.

If opreator would want to override a langauge strings, they would need to know how they set/referred to in MFEs, but that might not the same code in TX.

https://github.com/openedx/frontend-app-account/blob/5ce3995f5b59a81ace25844ed9646f969b4a4874/src/i18n/index.js#L21-L38

const appMessages = {
  ar: arMessages,
  'es-419': es419Messages,
  'fa-ir': faIRMessages,
  fr: frMessages,
  'zh-cn': zhcnMessages,
  pt: ptMessages,
  it: itMessages,
  de: deMessages,
  hi: hiMessages,
  'fr-ca': frCAMessages,
  ru: ruMessages,
  uk: ukMessages,
  'de-de': dedeCAMessages,
  'it-it': ititCAMessages,
  'pt-pt': ptptCAMessages,
};


In the above code - is used to override lang per locale, but in TX we have _ as shown in screenshot below, also in the latter UPPERCASE is used:

Image

The outcome of this issue is:

  • Should we stick with - or _
  • Are alll langauges locale inclued in account settings for example user can select it but notit_IT of which the latter is the one with the most completion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

1 participant