Closed
Bug 1481729
Opened 6 years ago
Closed 6 years ago
Bootstrap list of native language names
Categories
(Mozilla Localizations :: Other, enhancement)
Mozilla Localizations
Other
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: flod, Assigned: flod)
References
Details
Currently, in Firefox, we use language names localized in the language of the build, i.e. "French
" if the build is in English, instead of the native language.
We want to change that, using a curated list of language names in JSON format:
- Use the native name
- Ignore the region code whenever possible, for example "Deutsch", but "Español (ES)" for es-ES.
There are some potential challenges, like capitalization, or understand if we need more than one form for languages with grammar cases. Currently, we use the language name in:
- Language switcher in preferences (https://bug1469684.bmoattachments.org/attachment.cgi?id=8994275)
- Dialog to customize accept-languages (preferences for language used by web content)
- Spell checking in context menu
A first version of the curated list is available here
https://github.com/mozilla-l10n/firefox-languages/blob/master/output/languages_curated.json
In HTML version
https://mozilla-l10n.github.io/firefox-languages/
The repository includes a set of script used to analyze data from Mozilla and CLDR.
CLDR has a language name for most of the languages we support
https://github.com/unicode-cldr/cldr-localenames-full/
And rules to transform these names for "UI list or menu", which is exactly our case, e.g. for French
https://github.com/unicode-cldr/cldr-misc-full/blob/master/main/fr/contextTransforms.json
Results: https://mozilla-l10n.github.io/firefox-languages/complete.html
Comment 1•6 years ago
|
||
> There are some potential challenges, like capitalization
I see in CLDR there's no context transform information available for Basque, so the language name is kept as-is in the resulting complete list linked above. However, if the name appears at the beginning of a sentence (also in UI items like dropdowns), the name must be capitalized.
Assignee | ||
Comment 2•6 years ago
|
||
(In reply to Julen Ruiz Aizpuru from comment #1)
> > There are some potential challenges, like capitalization
>
> I see in CLDR there's no context transform information available for Basque,
> so the language name is kept as-is in the resulting complete list linked
> above. However, if the name appears at the beginning of a sentence (also in
> UI items like dropdowns), the name must be capitalized.
Thanks, updating. Indeed, looks like Basque is not complete on CLDR
https://github.com/unicode-cldr/cldr-misc-full/tree/master/main/eu
Comment 3•6 years ago
|
||
Same should apply to Lithuanian (lt), it should use titlecase-firstword transformation.
Assignee | ||
Comment 4•6 years ago
|
||
(In reply to Paulius Andriekus from comment #3)
> Same should apply to Lithuanian (lt), it should use titlecase-firstword
> transformation.
Updated. I'm starting to wonder if we should assume missing=capitalize :-\
Assignee | ||
Updated•6 years ago
|
Summary: Bootstrap list of localized language names → Bootstrap list of native language names
Comment 5•6 years ago
|
||
Sorry to create another exception from CLDR again, but we use 正體中文 project-wise for Traditional Chinese...
https://transvision.mozfr.org/?recherche=Traditional+Chinese&repo=gecko_strings&sourcelocale=en-US&locale=zh-TW&search_type=strings
Assignee | ||
Comment 6•6 years ago
|
||
(In reply to Peter Pin-Guang Chen [:petercpg] (MozTW.org) from comment #5)
> Sorry to create another exception from CLDR again, but we use 正體中文
> project-wise for Traditional Chinese...
>
> https://transvision.mozfr.org/
> ?recherche=Traditional+Chinese&repo=gecko_strings&sourcelocale=en-
> US&locale=zh-TW&search_type=strings
That's OK. Updated the list.
Assignee | ||
Comment 7•6 years ago
|
||
Considering this fixed at this point.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•