feat(web): move theme toggle into Settings modal#87
Merged
Conversation
User feedback (scott, th_19ec50e131a_a3283e): theme switching is not used often enough to warrant a dedicated row on the icon rail. Moves the three-state ☀/🌙/💻 toggle into a new "主题" fieldset inside the Settings modal, frees up the rail bottom for higher-frequency surfaces later. - index.html: remove .icon-rail-bottom wrapper + #theme-toggle from <nav>; add new 主题 fieldset in #settings-modal hosting the same toggle markup (same ids/classes so the JS init in app.js keeps working unchanged). - style.css: drop .icon-rail-bottom rules; restyle .theme-toggle / .theme-toggle-btn to use semantic tokens (surface-2 / border / text-mute / surface-hover) so it reads well on the light settings surface; bump button size 22→28 to match modal density. Active blue pill + click flash animation kept as-is.
🤖 bot-review (comment-only · phase 1)Diff: Red-line checks:
Phase 2: auto-approve + auto-merge fire only when red-lines are clean, author is internal, and no needs-human path is touched. Block with |
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
将左下角 icon-rail 底部的三态主题切换 (☀/🌙/💻) 移动到 Settings 模态框 的新 "主题" fieldset。
Why
Scott 反馈 (th_19ec50e131a_a3283e):theme 切换并不是高频功能,常驻 rail 底部占位浪费。放到 Settings 里更合适,rail 底部留给后续更高频的入口。
How
web/index.html<nav>里的.icon-rail-bottom+#theme-toggle块。#settings-modal头像 fieldset 和系统通知 fieldset 之间新增 主题 fieldset,复用相同的id="theme-toggle"和.theme-toggle-btn标记,所以app.js的 init 逻辑不用改。web/style.css.icon-rail-bottom规则(DOM 已移除)。.theme-toggle/.theme-toggle-btn:从硬编码的暗色透明叠层 (rgba(255,255,255,0.04)、#cfd2d8) 切到语义 token (--surface-2/--border/--text-mute/--surface-hover),确保在 Settings 浅色面板上对比正常。Testing
— judy 🔍