fix(ui): 统一卡片样式并修复深色模式可读性#652
Merged
Merged
Conversation
• 更新了 Card 组件样式,采用新的变量来实现玻璃拟态效果和阴影。 • 修改了 Btn 组件中的按钮样式,以符合新的颜色令牌(tokens)。 • 调整了 Collapsible 组件样式,以获得更好的边框和背景一致性。 • 统一了各设置组件的边框圆角和背景颜色。 • 增强了 AboutSection、CheckUpdateButton 及其他板块,以利用新的设计令牌。 • 优化了应用外壳(app shell)和 aura 表面的全局样式,确保视觉效果的一致性。 • 引入了新的颜色令牌,以实现更好的主题管理和无障碍性。 • 更新了多个组件的 CSS,以反映设计系统的变更,包括按钮状态和背景。
Apply theme before first paint via main.tsx, persist preference locally, and expose a segmented control in General settings with aura-skin contract coverage. Co-authored-by: Cursor <cursoragent@cursor.com>
Replace hardcoded light card backgrounds with --ol-style-* tokens and strengthen dark subtle/input contrast. Co-authored-by: Cursor <cursoragent@cursor.com>
PR Reviewer Guide 🔍Here are some key observations to aid the review process:
|
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.
User description
摘要
Fixes #。
统一 OpenLess 前端卡片 UI 的圆角、悬浮层次和主题颜色,并修复深色模式下局部页面出现浅色背景配浅色文字的问题。重点覆盖设置页、风格页、胶囊控件和 Windows 标题栏等主题相关界面,确保深色、浅色、跟随系统三种模式下保持可读。
修复 / 新增 / 改进
兼容
测试计划
命令:
git diff --check结果:通过
证据路径:
F:\编程\openless命令:
npm run check:aura-skin结果:通过,输出
Aura skin contract OK证据路径:
F:\编程\openless\openless-all\app\scripts\aura-skin-contract.test.mjs命令:
npx tsc --noEmit结果:通过
证据路径:
F:\编程\openless\openless-all\app命令:
npm run build结果:通过,仅保留 Vite 既有 chunk / dynamic import 警告
证据路径:
F:\编程\openless\openless-all\app命令:
npm run dev -- --host 127.0.0.1 --port 5177结果:前端静态页面可打开,深色模式下风格卡片背景和文字颜色正常
证据路径:
http://127.0.0.1:5177/PR Type
Bug fix, Enhancement
Description
Unify card UI styles with CSS design tokens.
Fix dark mode readability across pages and components.
Add Windows native caption theme sync via Tauri command.
Introduce theme switching (system/light/dark) in settings.
Refactor segmented control, toggle, inputs to use tokens.
Diagram Walkthrough
File Walkthrough
38 files
Add Windows caption theme commandRefactor inline styles to tokensUse token border radii in marketplaceUpdate vocab pill radii to tokensTokenize LC panel shells and bubblesUnify onboarding component radiiReplace hardcoded radii in ASR pageAdd data-ol-mobile attributeUse token radii for history itemsRefactor Card, Btn, Collapsible tokensTokenize translation page controlsUse glass background tokensUnify recorder button radiiTokenize provider card and dictation buttonApply token radii to login modalTokenize dropdown trigger and dropdown menuTokenize recording mode selectorTokenize provider section buttonsRefactor segmented control with tokensTokenize update dialog progress barTokenize shortcut section buttonsTokenize toggle and input stylesTokenize remote input toggleAdd theme mode utilitiesAdd theme switching UIUpdate settings tabs to use tokensMinor style token updatesTokenize about sectionTokenize modal border radiusTokenize switch componentMinor token updatesTokenize check update buttonAdd platform detection updatesApply theme before first paintTokenize Claude console sectionAdd new design tokens for cards and dark modeUpdate global styles with tokensUpdate remote server styles3 files
Replace hardcoded backgrounds with tokensTokenize QA panel borders and backgroundsTokenize capsule button and pill styles5 files
Update Japanese translationsUpdate Traditional Chinese translationsUpdate Korean translationsUpdate Simplified Chinese translationsUpdate English translations2 files
Update contract test for new tokensAdd test for Windows caption theme