feat: modernize documentation navigation - #21
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The language switcher logic currently behaves incorrectly on pages without a real EN/JA pair (e.g., it can navigate away unexpectedly and/or misapply aria-current).
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR updates the LithoSharp-based documentation site generator to enable local search and to provide a cleaner, language-aware documentation UI (EN/JA), including localized chrome, a language switcher, and same-language pagination for key pages.
Changes:
- Switched the site generator to a custom
PlotreeDocsTemplatewrapper aroundDocsSiteTemplatewithEnableSearch = true. - Replaced the default docs sidebar with a language-specific navigation set and localized key chrome strings for Japanese pages.
- Injected an EN/JA switcher into the docs header and rewrote pagination for the manual/privacy pages to stay within the selected language.
File summaries
| File | Description |
|---|---|
| tools/Plotree.Site/Program.cs | Uses the new template and adds CSS for the language switcher UI. |
| tools/Plotree.Site/PlotreeDocsTemplate.cs | Implements HTML post-processing for language-aware sidebar, header switcher injection, JP chrome localization, and same-language pagination. |
Review details
- Files reviewed: 2/2 changed files
- Comments generated: 2
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
レビュー指摘を反映しました。GetLanguagePair を nullable に変更し、翻訳ペアが存在するマニュアル/プライバシーポリシーの4ページだけ EN/JA スイッチャーを表示します。トップページ、検索、サポートページでは表示せず、意図しないページ遷移と �ria-current の誤判定を防ぎます。Release build と生成後の paired/unpaired ページのスモークチェックも成功しています。 |
Summary
Validation