fix: 完善剧本完成状态限制并优化表单对齐与配色

This commit is contained in:
GouJ
2026-09-01 22:37:51 +08:00
parent a24326b85d
commit 370e7bb4a6
19 changed files with 340 additions and 67 deletions
+5 -2
View File
@@ -122,10 +122,13 @@ describe('微信风格明暗主题', () => {
// 全站直角;输入区域与普通按钮共享底色,保持明暗模式一致。
expect(common?.borderRadius).toBe('0px')
expect(common?.borderRadiusSmall).toBe('0px')
expect(Input?.color).toBe(tokens.control)
expect(Input?.color).toBe('var(--app-field)')
expect(Button?.color).toBe(tokens.control)
expect(Button?.colorHover).toBe(tokens['control-hover'])
expect(Select?.peers?.InternalSelection?.color).toBe(tokens.control)
expect(Select?.peers?.InternalSelection?.color).toBe('var(--app-field)')
expect(contrast(tokens.field!, tokens.body!)).toBeGreaterThan(1.1)
expect(contrast(tokens.control!, tokens.surface!)).toBeGreaterThan(1.1)
expect(state.overrides.value.Checkbox?.checkMarkColor).toBe('#ffffff')
expect(Button?.textColorPrimary).toBe(tokens['on-accent'])
expect(Button?.colorPrimary).toBe(tokens['button-primary'])
expect(Button?.colorHoverPrimary).toBe(tokens['button-hover'])
+6 -6
View File
@@ -50,8 +50,8 @@ export function useTheme() {
// 静态边界交给底色;聚焦与错误边框仍由控件的状态主题负责。
const focusBorder = `1px solid ${accentText}`
const selection = {
color: control,
colorActive: control,
color: 'var(--app-field)',
colorActive: 'var(--app-field)',
border: 'none',
borderHover: 'none',
borderFocus: focusBorder,
@@ -147,9 +147,9 @@ export function useTheme() {
textColorGhostSuccess: accentText
},
Input: {
color: control,
colorHover: controlHover,
colorFocus: control,
color: 'var(--app-field)',
colorHover: 'var(--app-field-hover)',
colorFocus: 'var(--app-field)',
border: 'none',
borderHover: 'none',
borderDisabled: 'none',
@@ -226,7 +226,7 @@ export function useTheme() {
borderWarning: 'none',
borderError: 'none'
},
Checkbox: { checkMarkColor: '#082b17' },
Checkbox: { checkMarkColor: '#ffffff' },
Switch: { railColorActive: primary },
Progress: { fillColor: primary }
} satisfies GlobalThemeOverrides