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

Translation process and localization improvements #3268

Open
pdcp1 opened this issue Dec 6, 2024 · 0 comments
Open

Translation process and localization improvements #3268

pdcp1 opened this issue Dec 6, 2024 · 0 comments
Assignees
Labels
Agile: Epic Relating to an Agile Epic

Comments

@pdcp1
Copy link
Collaborator

pdcp1 commented Dec 6, 2024

Pain points

1. Env variable

GATSBY_AVAILABLE_LANGUAGES=en,es,fr,ja

2. i18n config file

site/gatsby-site/i18n/config.json

3. UI translations

JSON files with the translations under the folder site/gatsby-site/i18n/locales/[language code]. E.g: site/gatsby-site/i18n/locales/ja/account.json

Improvements

  • The meta i18n page helps to identify pending translations
  • We should implement fallback to English translations when a new text lacks a translation.

4. Site language switcher

Change site/gatsby-site/src/components/i18n/LanguageSwitcher.js code adding the new language

5. Atlas rules

Add the Atlas rules file for the translations/reports_[language code] collection.

Improvements

  • We are going to leave Atlas soon ✅

6. Gatsby type definition

Add Gatsby type definition to this file: site/gatsby-site/typeDefs.js

7. Sorting option on Discover page

Add Sorting option to Discover page for each field: site/gatsby-site/src/components/discover/SORTING_LISTS.js

Improvements

8. Report translation MongoDB query

Add report translation query on site/gatsby-site/src/graphql/reports.js

Improvements

9. Blog posts translations

Not mandatory since we have translations fallback to English

10. Gatsby graphql queries

For example, in the landingPage.js file, we have latestIncidentsReports_[language code] query as part of the Gatsby page query.

Improvements

  • Remove all language dependency from Gatsby page queries, not just from the landing page.
@pdcp1 pdcp1 self-assigned this Dec 6, 2024
@pdcp1 pdcp1 changed the title WIP Translation process improvements WIP Translation process and localization improvements Dec 16, 2024
@pdcp1 pdcp1 added the Agile: Epic Relating to an Agile Epic label Dec 16, 2024
@pdcp1 pdcp1 changed the title WIP Translation process and localization improvements Translation process and localization improvements Dec 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Agile: Epic Relating to an Agile Epic
Projects
None yet
Development

No branches or pull requests

1 participant