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

add missing French translations; COUNTRY=rbd #1306

Open
wants to merge 22 commits into
base: master
Choose a base branch
from

Conversation

wadhwamatic
Copy link
Member

Description

Add missing translations

How to test the feature:

  • [ ]
  • [ ]

Checklist - did you ...

Test your changes with

  • REACT_APP_COUNTRY=rbd yarn start
  • REACT_APP_COUNTRY=cambodia yarn start
  • REACT_APP_COUNTRY=mozambique yarn start
  • Add / update necessary tests?
  • Add / update outdated documentation?

Screenshot/video of feature:

Copy link

github-actions bot commented Jul 10, 2024

Build succeeded and deployed at https://prism-1306.surge.sh
(hash e71ee45 deployed at 2024-09-25T09:41:00)

@ericboucher
Copy link
Collaborator

ericboucher commented Jul 11, 2024

@wadhwamatic this should help
#1308, I just merged it and updated this branch

@wadhwamatic
Copy link
Member Author

@ericboucher - I'm still not seeing some missing keys listed until after interacting with the app. Hoping we can find a way to show all missing keys when the app first loads.

@wadhwamatic wadhwamatic marked this pull request as ready for review July 18, 2024 18:12
@wadhwamatic wadhwamatic requested a review from ericboucher July 18, 2024 18:12
@ericboucher
Copy link
Collaborator

@wadhwamatic please list those somewhere so that we can keep track

@wadhwamatic
Copy link
Member Author

@wadhwamatic please list those somewhere so that we can keep track

@ericboucher - it seems that until layer are accessed, they may not be evaluated for missing translation keys. In this case, the last few entries in the translation file didn't appear until after I accessed the relevant layers.

  • "Longest consecutive intense rainfall days"
  • "Longest consecutive extreme rainfall days"
  • "Days"
  • "1-4 Days"
  • "5-6 Days"
  • "7-8 Days"
  • "9-10 Days"
  • "11-12 Days"
  • "13-14 Days"
  • "15-16 Days"
  • "17-18 Days"
  • "19-20 Days"
  • "21-22 Days"
  • "23-26 Days"
  • "> 26 Days"
  • "1 Day":
  • "2 Days"
  • "3 Days"
  • "4 Days"
  • "5 Days",
  • "6 Days"
  • "> 14 Days"

@ericboucher
Copy link
Collaborator

ericboucher commented Jul 19, 2024

@wadhwamatic maybe it wasn't super clear but currently we have two processes for missing keys.

The more powerful one is running when we run the test commands and runs for every country and every language in that country, then outputs a table of missing keys. The keys you mentioned above were in the json file I sent you the other day that I created using that system. It accesses json files directly

Screenshot 2024-07-19 at 9 52 52 AM

The other one is the web console. It is more accurate but is linked directly to the translation mechanism and so only lists missing keys on render, when they are actually called on the frontend.

The keys you mentioned should be listed in the test version. I can experiment with adding the missing keys from the tests directly to the list in dev mode to "merge" the two methods but it would be a bit more complicated.

@ericboucher
Copy link
Collaborator

@wadhwamatic updated, I merged the two solutions so now the console missing items is pre-loaded with the missing keys from the layer definitions and legends

@wadhwamatic
Copy link
Member Author

@wadhwamatic maybe it wasn't super clear but currently we have two processes for missing keys.

Yeah, I didn't catch that. So, how do I run the test command version and access that output?

@ericboucher
Copy link
Collaborator

You can simply run "yarn test". But I also just added that output to the frontend list of missing keys for convenience

@wadhwamatic
Copy link
Member Author

Thanks @ericboucher. I see that shared layers that are used were still getting flagged for missing translations. Can we add logic that only checks for shared layers that are implemented in the country instance's prism.json?

@ericboucher
Copy link
Collaborator

@wadhwamatic I added a filter to only show the missing keys for layerIds that appear in prism.json

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants