memmy icon indicating copy to clipboard operation
memmy copied to clipboard

Language fallback

Open flx-sta opened this issue 11 months ago • 0 comments

PR Creator Checklist

Ensure you've checked the following before submitting your PR:

  • [X] You've discussed making your changes with a member of the dev team per contributing rules in the README
  • [X] Your changes are free of any lint errors
  • [X] Your changes are free of any typescript errors
  • [X] You've tested your changes

Summary

It implements a logic for fallback languages. Ultimately all languages will fall back to en-US instead of showing the raw translation key. That way its still visible if a translation is missing but you can still "understand" it (as long as you know english).

It will also now use the full translations code (e.g. en-US, de-DE) if possible but fall back to existing ones (e.g. de-AU will fall back to de-DE)

Screenshots

Nothing changed in the UI..

Test Plan

  1. Start the Simulator
  2. Go to Settings
  3. Read the "Check Lemmy Status" label
  4. switch to czech or romanian (those don't have that translation
  5. It will still read the english label instead of some cryptic stuff

flx-sta avatar Aug 03 '23 07:08 flx-sta