diff --git a/src/components/ToolResultBody.vue b/src/components/ToolResultBody.vue index ad26a92..3310ab2 100644 --- a/src/components/ToolResultBody.vue +++ b/src/components/ToolResultBody.vue @@ -19,12 +19,13 @@ +
-
- :{{ m.line }} +
+ {{ m.line }} + {{ m.content }}
- {{ m.content }}
@@ -96,14 +97,15 @@ {{ $t('aiTool.grepCountLines', { n: c.count }) }}
- + +
-
+
{{ m.file }} - :{{ m.line }} + {{ m.line }} + {{ m.content }}
- {{ m.content }}
{{ m.context }}
@@ -350,26 +352,37 @@ watch(() => props.tc.status, (s) => { .ai-tool-grep-match:last-child { border-bottom: none; } -.ai-tool-grep-match-head { +/* BUG-260626-01:命中行主体 = 单行 flex row(文件名 | 行号 gutter | 内容 并排), + 取代原 head 块 + content 块的垂直两行堆叠(行号内容分行根因)。 */ +.ai-tool-grep-match-main { display: flex; - align-items: baseline; - gap: 1px; + align-items: flex-start; + gap: 10px; font-family: var(--df-font-mono); - font-size: 10px; - margin-bottom: 1px; + font-size: 11px; } .ai-tool-grep-file { color: var(--df-accent); + flex-shrink: 0; + max-width: 40%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; + font-size: 10px; + padding-top: 1px; } .ai-tool-grep-line { color: var(--df-text-dim); flex-shrink: 0; + min-width: 2em; + text-align: right; + font-size: 10px; + user-select: none; + padding-top: 1px; } .ai-tool-grep-content { - display: block; + flex: 1; + min-width: 0; font-family: var(--df-font-mono); font-size: 11px; color: var(--df-text);