ooni / explorer

OONI Explorer: uncover evidence of internet censorship worldwide
https://explorer.ooni.org
BSD 3-Clause "New" or "Revised" License
74 stars 38 forks source link

Ensure translation of country names and continents on OONI Explorer Countries page #716

Closed agrabeli closed 9 months ago

agrabeli commented 2 years ago

The various country names, continents (as listed above), and the "Search for countries" field are untranslated.

countries

Sarath mentioned that we could potentially use the standard translation of countries from the browser for the country names (instead of requiring Transifex translators to translate every single country name), while keeping an eye out for how that translates for places like Taiwan and Hong Kong.

We should probably add "Search for countries" to a string on Transifex though.

hellais commented 2 years ago

I think we should update country-util to support pulling in the translated country names from unicode cldr: https://github.com/unicode-org/cldr-json/tree/main/cldr-json/cldr-localenames-full/main

thara003 commented 2 years ago

I would like to work on this. Have a few questions.

  1. How to work with transfix translators?
  2. Is there any documentation for the same?
hellais commented 2 years ago

I think what should be done to implement this is the following:

  1. Add support for generating translated country names inside of country-util: https://github.com/ooni/country-util
  2. Depending on the selected language resolve the country name inside of country-util

While we are at it, we should update the country-util download script to fetch data from the new unicode repository (see: https://github.com/ooni/country-util/blob/master/scripts/download-data.py#L13).

I don't think any transifex interaction is necessary for this. Since all the country names are already translated by unicode, we shouldn't require our translators to duplicate all this work.

majakomel commented 9 months ago

This has been fixed: we're using Intl.DisplayNames from format.js which uses https://cldr.unicode.org/ as a source