Repository navigation
Web UI: English interface (#31); CI isolation - #93
Merged
Merged
Conversation
…lation - English UI: Chinese stays the source language. In English mode core.js loads ui/lang/en.json (1765 strings; 122 KB, 49 KB gzip; never fetched in Chinese mode) before the first render and translates what h() renders (text, placeholder / title / aria-label / alt): exact match, else known fragments of concatenated strings via one precompiled regex; a string that would stay half Chinese (user data) is shown as it is. Language from the browser, a switch in the nav and on the login page. - tools/i18n.py check (in CI): every UI literal is translated, no Chinese or lost spacing in translations, no text that bypasses h() without tr(); `missing` / `fmt` for maintenance. - CI: private tmpfs over mr's runtime directories too (concurrent runs shared the notification lock); an opt-in stress loop for the trojan-hu first-connection failure (#51). Closes #31 Claude-Session: https://claude.ai/code/session_01HWeUjo1dmS7gBkCYHrVjCr
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
core.jsloadsui/lang/en.jsonbefore the first render: 1765 strings, 122 KB (49 KB gzip). Chinese mode never fetches it.h()renders: text, and theplaceholder/title/aria-label/altattributes. Exact matches first; for concatenated strings, known fragments are replaced via one precompiled regex.tools/i18n.pycheckruns in CI. It fails when a UI literal has no translation, when a translation contains Chinese or loses its leading/trailing spaces, or when UI code bypassesh()withouttr().missingandfmthelp maintain the file.docs/MODULES.md.Not translated: the standalone read-only panel page (
/panel), user data, and plurals.Verification
mr/ui_i18n_test.goloads the realcore.jsanden.jsonin node.sh tools/ci.sh: ALL CHECKS PASSED.Closes #31
https://claude.ai/code/session_01HWeUjo1dmS7gBkCYHrVjCr