Skip to content

Commit c0a6afc

Browse files
committed
style: 更新样式和颜色变量,优化组件视觉效果
- 在 base.css 中新增灰色调变量 --gray-25。 - 在 AgentMessageComponent.vue 和 KnowledgeBaseResult.vue 中调整背景颜色,使用新的灰色变量。 - 优化 AgentView.vue 中的样式,移除不必要的样式设置。
1 parent 04aaa2e commit c0a6afc

File tree

4 files changed

+21
-12
lines changed

4 files changed

+21
-12
lines changed

web/src/assets/base.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
/* color palette from <https://github.com/vuejs/theme> */
23
/* https://material-foundation.github.io/material-theme-builder/ */
34
:root {
@@ -29,6 +30,7 @@
2930
--gray-200: #EFF1F2;
3031
--gray-100: #F8FAFB;
3132
--gray-50: #FBFDFE;
33+
--gray-25: #FCFEFF;
3234
--gray-10: #FDFEFF;
3335
--gray-0: #FFFFFF;
3436

web/src/components/AgentMessageComponent.vue

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -230,8 +230,7 @@ const toggleToolCall = (toolCallId) => {
230230
margin-bottom: 15px;
231231
border-radius: 12px;
232232
border: 1px solid var(--gray-200);
233-
background-color: var(--gray-50);
234-
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
233+
background-color: var(--gray-25);
235234
overflow: hidden;
236235
transition: all 0.2s ease;
237236
@@ -248,12 +247,12 @@ const toggleToolCall = (toolCallId) => {
248247
border: none;
249248
250249
.ant-collapse-header {
251-
padding: 12px 16px;
252-
background-color: var(--gray-100);
250+
padding: 8px 12px;
251+
// background-color: var(--gray-100);
253252
font-size: 14px;
254253
font-weight: 500;
255254
color: var(--gray-800);
256-
border-bottom: 1px solid var(--gray-200);
255+
// border-bottom: 1px solid var(--gray-200);
257256
transition: all 0.2s ease;
258257
259258
&:hover {
@@ -317,21 +316,22 @@ const toggleToolCall = (toolCallId) => {
317316
}
318317
319318
:deep(.tool-call-display) {
320-
background-color: var(--gray-50);
319+
background-color: var(--gray-25);
321320
border: 1px solid var(--gray-200);
322321
border-radius: 12px;
323322
overflow: hidden;
324-
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
325323
transition: all 0.2s ease;
326324
327325
&:hover {
326+
background-color: var(--gray-50);
327+
border: 1px solid var(--gray-200);
328328
border-color: var(--main-300);
329329
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08);
330330
}
331331
332332
.tool-header {
333-
padding: 12px 16px;
334-
background-color: var(--gray-100);
333+
padding: 8px 12px;
334+
// background-color: var(--gray-100);
335335
font-size: 14px;
336336
font-weight: 500;
337337
color: var(--gray-800);
@@ -508,6 +508,15 @@ const toggleToolCall = (toolCallId) => {
508508
// padding-left: 1rem;
509509
// }
510510
511+
cite {
512+
font-size: 12px;
513+
color: var(--gray-700);
514+
font-style: normal;
515+
background-color: var(--gray-200);
516+
border-radius: 4px;
517+
outline: 2px solid var(--gray-200);
518+
}
519+
511520
a {
512521
color: var(--main-700);
513522
}

web/src/components/ToolCallingResult/KnowledgeBaseResult.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -328,7 +328,7 @@ const getScoreColor = (score) => {
328328
.score-item {
329329
font-size: 11px;
330330
color: var(--gray-700);
331-
background: var(--main-10);
331+
// background: var(--main-10);
332332
padding: 1px 4px;
333333
border-radius: 4px;
334334
white-space: nowrap;

web/src/views/AgentView.vue

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -693,8 +693,6 @@ const toggleSidebar = () => {
693693
}
694694
695695
.config-modal-content {
696-
max-height: 70vh;
697-
overflow-y: auto;
698696
user-select: text;
699697
700698
div[role="alert"] {

0 commit comments

Comments
 (0)