Skip to content

feat(i18n): translate behavior settings and shared controls - #885

Merged
LargeModGames merged 1 commit into
LargeModGames:mainfrom
kapok-4o:l10n-zh-settings-behavior
Oct 17, 2026
Merged

LargeModGames merged 1 commit into
LargeModGames:mainfrom
kapok-4o:l10n-zh-settings-behavior

Conversation

@kapok-4o

@kapok-4o kapok-4o commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

The second Chinese translation PR after #877 (refs #726): the Behavior settings and the controls every settings tab shares, in Simplified Chinese (zh-Hans) and Traditional Chinese with Taiwan wording (zh-Hant).

  • src/core/i18n/settings/zh_hans.rs and zh_hant.rs: setting names and descriptions for the Behavior tab, the controls every tab shares (tab names, on/off, the editing and navigation hints) and the option labels, including the new Player Bar Visualizer row from feat(gui): visualizer behind the player bar #879.
  • Only the labels change. What gets saved to config.yml (option tokens such as release_date:desc, key names) stays the same in every language.
  • docs/configuration.md names the Chinese labels of auto.
  • gui/src/bindings/strings.json is regenerated, which is most of the diff.

English is unchanged, and anything not translated yet still falls back to English. Keybinding and theme settings come in the next PR.

Testing

macOS (aarch64), on top of 00753912:

  • cargo fmt --all --check and cargo clippy --locked -- -D warnings: clean.
  • cargo test --locked: 2196 passed, 8 ignored. The gui-feature run leaves no bindings diff.

Additional notes

A native-speaker review of the wording is welcome; any fix is a one-line change in the table.

Summary by CodeRabbit

  • New Features
    • Added Simplified and Traditional Chinese translations throughout the settings interface, including labels, descriptions, options, prompts, and validation messages.
    • The language-picker documentation now shows the localized “Auto (system)” label in Chinese. The saved configuration value remains auto.

Translate behavior setting names and descriptions, shared settings controls and option labels into both Chinese scripts. Persisted option tokens and keybinding values remain unchanged.
@coderabbitai

coderabbitai Bot commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: LargeModGames/spotatui/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: b44096bf-7cca-49c8-a980-012bbad915b8
📥 Commits

Reviewing files that changed from the base of the PR and between 0075391 and c7f1d4c.

⛔ Files ignored due to path filters: 1
  • gui/src/bindings/strings.json is excluded by !gui/src/bindings/**
📒 Files selected for processing: 3
  • docs/configuration.md
  • src/core/i18n/settings/zh_hans.rs
  • src/core/i18n/settings/zh_hant.rs

Included review availability: This review used your included allowance. Your plan provides up to 4 included reviews per hour; 3 remain after this review.

📝 Walkthrough

Simplified and Traditional Chinese translations are added for settings interface strings. The configuration documentation now shows localized “Auto (system)” labels. The stored language-picker value remains auto.

Changes: Settings localization

Layer / File(s) Summary
Chinese settings translations
src/core/i18n/settings/zh_hans.rs, src/core/i18n/settings/zh_hant.rs, docs/configuration.md
The settings strings now include Simplified and Traditional Chinese translations for settings, options, controls, and messages. Fields without translations continue to use English fallback values. The documentation shows the Chinese forms of the “Auto (system)” label, while the stored value remains auto.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~15 minutes

Change: Feature

Merge Risk: ⚪ Minimal · up to c7f1d

The translated labels do not change saved configuration values, and dynamic settings messages retain their substitutions. No concrete merge-blocking risk remains.

Pre-merge checks: Passed 4
Check name Status Explanation
Description Check Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check Passed The title uses the valid conventional-commit prefix feat(i18n):, clearly describes the translation changes, and uses a concise imperative subject.
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.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
✨ Simplify code
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@codecov

codecov Bot commented Oct 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@LargeModGames
LargeModGames merged commit 7e62b7d into LargeModGames:main Oct 17, 2026
32 checks passed
LargeModGames pushed a commit that referenced this pull request Oct 17, 2026
# Summary

The third Chinese translation PR (refs #726), finishing the settings
screen after #885: the Keybindings and Theme tabs in Simplified Chinese
(`zh-Hans`) and Traditional Chinese with Taiwan wording (`zh-Hant`).

- `src/core/i18n/settings/zh_hans.rs` and `zh_hant.rs`: keybinding
descriptions, theme labels and color names, the key-conflict message and
the unknown-color message. With this, every settings entry has a Chinese
translation except the three language names (English / 简体中文 / 繁體中文),
which stay as they are.
- Only the labels change. Saved values in `config.yml` (key names such
as `ctrl-f`, color names such as `LightBlue`, the language token) are
the same in every language.
- Tests: a few settings tests that compared against the table now assert
the actual Chinese text, so they catch a wrong or missing translation
(`src/core/app/settings_schema.rs`, `src/core/i18n/settings.rs`,
`src/tui/handlers/settings.rs`). A new render test,
`chinese_settings_render_localized_choices_without_changing_the_raw_value`,
draws the settings screen in Chinese and checks the language row shows
the Chinese label while its value stays `zh-Hans`.
- `gui/src/bindings/strings.json` is regenerated.

English is unchanged.

# Testing

macOS (aarch64), on top of `7e62b7dd`:

- `cargo fmt --all --check`, and `cargo clippy --locked -- -D warnings`
for default and slim (`telemetry,tui`): clean.
- `cargo test --locked`: default 2198 passed, 8 ignored; slim 1696
passed; gui feature set 2095 passed, 30 ignored, and no bindings diff
afterwards.

# Additional notes

A native-speaker review of the wording is welcome; any fix is a one-line
change in the table.


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

* **New Features**
* Simplified and Traditional Chinese settings now include localized
labels and descriptions for keybindings and theme colors, plus
translations for automatic color selection, color-validation messages,
and named color choices.
* Chinese translations also cover the automatic language option,
playlist date sorting, key-conflict messages, and unknown-color
messages.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->

---------

Co-authored-by: 2570165831 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants