Skip to content

Commit 66c4929

Browse files
committed
fix: 修复前端暗黑模式下多个页面的白色背景问题
- 修复配置页面子标签(Header规则/会话Header/Body字段)的输入框和下拉框白色背景 - 修复SessionBodyFieldsConfig.vue中Select和MultiSelect下拉面板的白色背景 - 修复HeaderRulesConfig.vue中搜索输入框和过滤器下拉框的白色背景 - 修复session-headers.scss中输入框和下拉框的白色背景 - 将硬编码的#ffffff替换为var(--p-surface-card)以支持暗黑模式自动切换
1 parent 565b4a7 commit 66c4929

35 files changed

Lines changed: 820 additions & 2335 deletions

add_task_dark.png

103 KB
Loading

current_page.png

97.8 KB
Loading

current_page2.png

97.2 KB
Loading

src/frontEnd/src/assets/styles/index.scss

Lines changed: 333 additions & 1497 deletions
Large diffs are not rendered by default.

src/frontEnd/src/assets/styles/variables.scss

Lines changed: 0 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,6 @@ $font-weight-medium: 500;
2828
$font-weight-semibold: 600;
2929
$font-weight-bold: 700;
3030

31-
// 过渡
32-
$transition-base: all 0.2s ease;
33-
3431
// 颜色
3532
$primary-color: #6366f1;
3633
$text-color: #1e293b;
@@ -40,49 +37,3 @@ $bg-color-dark: #0f172a;
4037
// 表面色
4138
$surface-lighter: #f8fafc;
4239
$surface-white: #ffffff;
43-
44-
// ==================== 3D效果变量 ====================
45-
46-
// 阴影效果
47-
$shadow-raised:
48-
0 2px 4px rgba(0, 0, 0, 0.05),
49-
0 4px 8px rgba(0, 0, 0, 0.08),
50-
inset 0 1px 0 rgba(255, 255, 255, 0.8);
51-
52-
$shadow-elevated:
53-
0 8px 16px rgba(0, 0, 0, 0.1),
54-
0 16px 32px rgba(0, 0, 0, 0.08),
55-
inset 0 1px 0 rgba(255, 255, 255, 0.9);
56-
57-
$shadow-floating:
58-
0 12px 24px rgba(0, 0, 0, 0.12),
59-
0 24px 48px rgba(0, 0, 0, 0.1),
60-
inset 0 1px 0 rgba(255, 255, 255, 1);
61-
62-
$shadow-pressed:
63-
inset 0 2px 4px rgba(0, 0, 0, 0.1),
64-
inset 0 4px 8px rgba(0, 0, 0, 0.05),
65-
0 1px 2px rgba(0, 0, 0, 0.05);
66-
67-
$shadow-inset-dark: inset 0 2px 4px rgba(0, 0, 0, 0.08);
68-
$shadow-inset-light: inset 0 1px 2px rgba(255, 255, 255, 0.6);
69-
$shadow-glow: 0 0 20px rgba(99, 102, 241, 0.3);
70-
71-
// 边框效果
72-
$border-highlight: 1px solid rgba(255, 255, 255, 0.8);
73-
$border-shadow: 1px solid rgba(0, 0, 0, 0.08);
74-
75-
// 变换效果
76-
$transform-hover: translateY(-2px);
77-
$transform-press: translateY(1px);
78-
$transform-float: translateY(-4px);
79-
80-
// 渐变效果
81-
$gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
82-
$gradient-secondary: linear-gradient(135deg, #64748b 0%, #475569 100%);
83-
$gradient-success: linear-gradient(135deg, #10b981 0%, #059669 100%);
84-
$gradient-warning: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
85-
$gradient-danger: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
86-
$gradient-rainbow: linear-gradient(90deg,
87-
#ef4444 0%, #f59e0b 16%, #eab308 32%,
88-
#22c55e 48%, #06b6d4 64%, #3b82f6 80%, #8b5cf6 100%);

src/frontEnd/src/components.d.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,11 @@ declare module 'vue' {
3333
InputText: typeof import('primevue/inputtext')['default']
3434
Message: typeof import('primevue/message')['default']
3535
OfflineBanner: typeof import('./components/OfflineBanner.vue')['default']
36+
Password: typeof import('primevue/password')['default']
3637
ProgressSpinner: typeof import('primevue/progressspinner')['default']
3738
RouterLink: typeof import('vue-router')['RouterLink']
3839
RouterView: typeof import('vue-router')['RouterView']
3940
SearchFilterBar: typeof import('./components/SearchFilterBar.vue')['default']
40-
SelectButton: typeof import('primevue/selectbutton')['default']
41-
Slider: typeof import('primevue/slider')['default']
4241
StatCard: typeof import('./components/StatCard.vue')['default']
4342
Tag: typeof import('primevue/tag')['default']
4443
TaskFilter: typeof import('./components/TaskFilter.vue')['default']

src/frontEnd/src/components/BatchActionsToolbar.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,8 @@ defineProps<Props>()
4545
justify-content: space-between;
4646
align-items: center;
4747
padding: 0.75rem 1rem;
48-
background: var(--p-primary-50);
49-
border: 1px solid var(--p-primary-200);
48+
background: var(--p-surface-100);
49+
border: 1px solid var(--p-surface-border);
5050
border-radius: var(--p-border-radius);
5151
margin-bottom: 1rem;
5252
}

src/frontEnd/src/components/GuidedParamEditorDialog.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,8 +142,8 @@ defineExpose({
142142
}
143143
144144
.preset-info-form {
145-
background: linear-gradient(135deg, rgba(99, 102, 241, 0.1) 0%, rgba(139, 92, 246, 0.05) 100%);
146-
border: 1px solid rgba(99, 102, 241, 0.2);
145+
background: var(--p-surface-100);
146+
border: 1px solid var(--p-surface-border);
147147
border-radius: 8px;
148148
padding: 12px 16px;
149149
margin-bottom: 16px;

src/frontEnd/src/components/HttpCodeEditor.vue

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,7 @@ defineExpose({
565565
align-items: center;
566566
gap: 8px;
567567
padding: 8px 12px;
568-
background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
568+
background: var(--p-surface-50);
569569
border-bottom: 1px solid var(--surface-border);
570570
flex-wrap: wrap;
571571
@@ -643,7 +643,6 @@ defineExpose({
643643
display: flex;
644644
gap: 2px;
645645
opacity: 0.5;
646-
transition: opacity 0.2s;
647646
background: var(--surface-card);
648647
border: 1px solid var(--surface-border);
649648
border-radius: 4px;

src/frontEnd/src/components/OfflineBanner.vue

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,9 @@ onUnmounted(() => {
6363
left: 0;
6464
right: 0;
6565
z-index: 999;
66-
background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
67-
color: #78350f;
66+
background: var(--p-yellow-500);
67+
color: var(--p-yellow-900);
6868
padding: 12px 24px;
69-
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
7069
}
7170
7271
.banner-content {

0 commit comments

Comments
 (0)