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

Fix localization import order #12993

Merged
merged 3 commits into from
Oct 24, 2023
Merged

Conversation

msujew
Copy link
Member

@msujew msujew commented Oct 12, 2023

What it does

Closes #12977

Fixes two localization based issues, see the first two commits for more info. The issue came from the fact that we now import a bit more code during our preload script and accidentally imported code that was supposed to be translated during its import time - effectively removing the ability to translate those files.

The same thing happened for monaco, where we import code from @theia/monaco-editor-core before being able to localize the monaco texts. This code has been moved to the correct package.

How to test

  1. Open Theia (Electron) and change the locale
  2. Assert that common commands and monaco commands are localized

Review checklist

Reminder for reviewers

@msujew msujew added the localization issues related to localization/internalization/nls label Oct 12, 2023
@JonasHelming JonasHelming requested a review from planger October 24, 2023 14:11
Copy link
Contributor

@planger planger left a comment

Choose a reason for hiding this comment

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

Thank you, this change looks fine to me!

I can confirm that on master several translations don't work in a Theia Electron app anymore and with this change they work again just fine. 👍 Also, the move of the language registration to the Monaco extension makes more sense now in general.

Thank you for this fix @msujew!

@msujew msujew merged commit c6eef68 into master Oct 24, 2023
12 checks passed
@msujew msujew deleted the msujew/fix-localizations-after-preload branch October 24, 2023 21:30
@github-actions github-actions bot added this to the 1.43.0 milestone Oct 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
localization issues related to localization/internalization/nls
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

Preloading Localization Occurs After Partial Internal Content Localization, Resulting in Localization Failure
2 participants