feat(frontend): add Chinese UI language toggle#557
Open
zxstar7789 wants to merge 1 commit into
Open
Conversation
|
Hello, |
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 does this PR do?
Adds a lightweight frontend internationalization layer with English and Simplified Chinese UI support.
This PR introduces:
en-USas the default and fallback locale.Connector setup tutorials and some backend/runtime strings remain in English to avoid changing third-party setup instructions or raw server-provided content.
How was this tested?
Tested locally on macOS with the frontend and backend running against Ollama.
Commands run:
Manual testing performed:
Verified the default UI remains English.
Switched language to Simplified Chinese from Settings > Appearance.
Verified the main UI updates to Chinese.
Refreshed the browser and confirmed the language selection persists.
Switched back to English and confirmed the UI returns to English.
Verified the frontend loads at http://127.0.0.1:5173/.
Verified the backend health endpoint returns OK.
Verified model listing works with the local backend.
Checklist
uv run pytest tests/ -v)uv run ruff check src/ tests/)uv run ruff format --check src/ tests/)Note: this PR only changes the frontend, so the Python
uv run pytest,ruff check, andruff formatchecklist items were not run. Frontend build and Vitest passed.