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

WIP - Localization / l10n #40

Merged
merged 70 commits into from May 5, 2019
Merged

WIP - Localization / l10n #40

merged 70 commits into from May 5, 2019

Conversation

danielweck
Copy link
Member

@danielweck danielweck commented Mar 7, 2019

WIP

Also fixes issue #14

  • live / dynamic refresh of UI (no need to restart app)
  • persistent preferences / user settings via electron-store (JSON)
  • en (generic English) as default / fallback language.
  • fr (generic French) is provided (needs reviewing).
  • i18next to handle the JSON resources (language catalogs), simple starter API with powerful extensions: https://www.i18next.com

…efault, FR second (TODO), currently menu only (other UI TODO)
@danielweck danielweck added the enhancement New feature or request label Mar 7, 2019
const browseForFileOrFolder2 = browseForFileOrFolderArray[1].trim();
const browseForFileOrFolder3 = browseForFileOrFolderArray[2].trim();
const browseForFileOrFolder4 = browseForFileOrFolderArray[3].trim();
const browseForFileOrFolder5 = browseForFileOrFolderArray[4].trim();
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is ugly as hell, but this works fine for a first shot. TODO: regexp

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PS: i18next supports templates of course...but I haven't looked into breaking-down this particular splash message into a template-compatible form.

@danielweck
Copy link
Member Author

TODO:

  • ace-report in ace monorepo (HTML template l10n)
  • axe-core message l10n (again, see the monorepo package dependency)

@danielweck
Copy link
Member Author

Related Ace "core" PR: daisy/ace#223

@danielweck danielweck requested a review from rdeltour May 5, 2019 17:38
Copy link
Member

@rdeltour rdeltour left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I just checked on French macOS to suggest more accurate translations (sorry for the extra work 😉, I should have done it in the first place!)

src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
src/shared/l10n/locales/fr.json Outdated Show resolved Hide resolved
@danielweck danielweck requested a review from rdeltour May 5, 2019 21:08
@danielweck
Copy link
Member Author

Thank you for your l10n peer review Romain! Tedious work.

@danielweck danielweck merged commit 93d21af into master May 5, 2019
@danielweck danielweck deleted the feature/l10n branch May 5, 2019 21:13
Copy link
Member

@rdeltour rdeltour left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

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

Successfully merging this pull request may close these issues.

None yet

3 participants