Skip to content

chore(i18n): translate server config dropdown options (log-level, vram, precision etc.) (v0.8.36)#12026

Open
LifetimeVip wants to merge 4 commits intoComfy-Org:mainfrom
LifetimeVip:fix/server-config-i18n-v3
Open

chore(i18n): translate server config dropdown options (log-level, vram, precision etc.) (v0.8.36)#12026
LifetimeVip wants to merge 4 commits intoComfy-Org:mainfrom
LifetimeVip:fix/server-config-i18n-v3

Conversation

@LifetimeVip
Copy link
Copy Markdown
Contributor

@LifetimeVip LifetimeVip commented May 6, 2026

Summary

Translates the dropdown option values in the Server Config panel.

Problem

When opening Settings -> Server Config, dropdown options like log-level, vram mode, precision were displayed in English.

Changes

src/locales/en/main.json:

  • Added options key to server config items with English display labels.

src/locales/zh/main.json:

  • Added corresponding Chinese translations.

src/platform/settings/components/ServerConfigPanel.vue:

  • Updated translateItem to return { text: translatedLabel, value: originalEnum } objects.
  • Uses t() for i18n lookup with fallback.

E2E Test

Added Playwright test (browser_tests/tests/serverConfigTranslation.spec.ts) to verify:

  • Server Config panel loads with Chinese locale
  • Translation system is properly initialized
  • Panel UI elements are visible after translations load

┆Issue is synchronized with this Notion page by Unito

@LifetimeVip LifetimeVip requested a review from a team May 6, 2026 17:44
@dosubot dosubot Bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label May 6, 2026
@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented May 6, 2026

Review Change Stack
No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: dfe1d7d5-a497-4472-96de-52575423c7f7

📥 Commits

Reviewing files that changed from the base of the PR and between 8108967 and b77c01e.

📒 Files selected for processing (1)
  • src/platform/settings/components/ServerConfigPanel.vue

📝 Walkthrough

Walkthrough

translateItem in ServerConfigPanel.vue now returns an item object with translated name, optional translated tooltip, and an explicit translated options array of { text, value }, falling back to original options when translations are absent.

Changes

Server Config Translation Enhancement

Layer / File(s) Summary
Translation Logic
src/platform/settings/components/ServerConfigPanel.vue
translateItem now builds a translated options array by mapping each option to { text, value } using per-option i18n keys, and returns a merged object containing the translated name, translated tooltip (when present), and an explicit options field with fallback to the original options.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Poem

🐰 I nudged each option to learn a new name,
Names and tooltips now sing in the same frame,
Values stay steady, labels softly unwind,
A multilingual panel, tidy and kind.

🚥 Pre-merge checks | ✅ 7
✅ Passed checks (7 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: translating server config dropdown options with specific examples (log-level, vram, precision).
Description check ✅ Passed The description includes all required template sections: Summary, detailed Changes with file-specific updates, and E2E test verification. It clearly explains the problem and solution.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
End-To-End Regression Coverage For Fixes ✅ Passed The PR title "chore(i18n): translate server config dropdown options..." does not use bug-fix language (fix, fixed, fixes, fixing, bugfix, hotfix). Condition 1 of the check is satisfied.
Adr Compliance For Entity/Litegraph Changes ✅ Passed PR modifies only src/platform/settings/components/ServerConfigPanel.vue, which is not under src/lib/litegraph/, src/ecs/, or graph entity files. ADR compliance check does not apply.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 6, 2026

🎨 Storybook: loading Building...

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 6, 2026

🎭 Playwright: ⏳ Running...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant