[WIP] feat(extension): i18n support #35

Closed
kiyui wants to merge 4 commits from i18n into master
kiyui commented 3 years ago (Migrated from github.com)
Owner

This should address the concerns in #34.

Changes:

  • Did some code refactor such that all strings are centralized
  • Added a .pot file with all the strings
  • Add some languages for testing and initial release
  • Add build script so .mo files do not need to be included (add to package.json or introduce meson)

Contributing:
Where $lang is a language such as en_US, do the following in the extension directory:

  • mkdir -p locale/$lang/LC_MESSAGES
  • msginit -i night-light-slider.pot -o locale/$lang/LC_MESSAGES/night-light-slider.po
  • Modify locale/$lang/LC_MESSAGES/night-light-slider.po with your locale
  • msgfmt locale/$lang/LC_MESSAGES/night-light-slider.po -o locale/$lang/LC_MESSAGES/night-light-slider.mo
  • Submit a PR without the compiled .mo files
This should address the concerns in #34. Changes: - [x] Did some code refactor such that all strings are centralized - [x] Added a `.pot` file with all the strings - [ ] Add some languages for testing and initial release - [ ] Add build script so `.mo` files do not need to be included (add to `package.json` or introduce `meson`) Contributing: Where `$lang` is a language such as `en_US`, do the following in the extension directory: - `mkdir -p locale/$lang/LC_MESSAGES` - `msginit -i night-light-slider.pot -o locale/$lang/LC_MESSAGES/night-light-slider.po` - Modify `locale/$lang/LC_MESSAGES/night-light-slider.po` with your locale - `msgfmt locale/$lang/LC_MESSAGES/night-light-slider.po -o locale/$lang/LC_MESSAGES/night-light-slider.mo` - Submit a PR without the compiled `.mo` files
Owner

I'm working on this in a separate branch now.

I'm working on this in a separate branch now.
kiyui closed this pull request 8 months ago
kiyui deleted branch i18n 8 months ago
This pull request cannot be reopened because the branch was deleted.
Sign in to join this conversation.
No reviewers
No Milestone
No Assignees
1 Participants
Notifications
Due Date

No due date set.

Dependencies

This pull request currently doesn't have any dependencies.

Loading…
There is no content yet.