i18n: register all 8 translated locales in Starlight config - #5347
Conversation
Adds zh-cn, zh-tw, ja, ko, ru, fr, pt, de to the Starlight locales block in astro.config.mjs so the language switcher surfaces all translated pages. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
There was a problem hiding this comment.
Pull request overview
Registers additional Starlight i18n locales in the docs site configuration so the language switcher can surface translated documentation routes.
Changes:
- Expands the Starlight
localesmap to includezh-cn,zh-tw,ja,ko,ru,fr,pt, andde. - Adds per-locale
label,lang, anddirmetadata for the language switcher / HTML language attributes.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| "zh-cn": { label: "简体中文", lang: "zh-CN", dir: "ltr" }, | ||
| "zh-tw": { label: "繁體中文", lang: "zh-TW", dir: "ltr" }, | ||
| ja: { label: "日本語", lang: "ja", dir: "ltr" }, | ||
| ko: { label: "한국어", lang: "ko", dir: "ltr" }, | ||
| ru: { label: "Русский", lang: "ru", dir: "ltr" }, | ||
| fr: { label: "Français", lang: "fr", dir: "ltr" }, | ||
| pt: { label: "Português (Brasil)", lang: "pt-BR", dir: "ltr" }, | ||
| de: { label: "Deutsch", lang: "de", dir: "ltr" }, |
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
WalkthroughThe documentation configuration is expanded to support multiple languages in the Starlight site integration. The locales map previously contained only English; it now includes nine language variants (English, Chinese Simplified/Traditional, Japanese, Korean, Russian, French, Brazilian Portuguese, German) with their corresponding labels and language settings. ChangesDocumentation Locales Configuration
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Suggested labels
Poem
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
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. Comment |
…r all 8 translated locales in Starlight config
Registers all 8 translated locales in
docs/astro.config.mjsso the Starlight language switcher surfaces translated pages.Changes
docs/astro.config.mjs— adds 8 locale entries to the Starlightlocalesblock:zh-cnzh-twjakorufrptdeWithout these entries, translated
.mdxfiles exist on disk but Starlight doesn't expose them through the language switcher (as noted in #5343).🤖 Generated with Claude Code
Summary by CodeRabbit