From 95f7cd7d61f29b2ece37892e3f38d1c79deb9c9c Mon Sep 17 00:00:00 2001 From: wizardchen Date: Fri, 29 May 2026 18:11:58 +0800 Subject: [PATCH] feat(knowledge): add stop-parse button to the trace timeline panel MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The trace drawer had no way to cancel an in-flight parse — users had to go back to the card/list menu. Add a stop-parse control in the timeline header, shown while parse_status is pending / processing / finalizing (mirroring the backend CancelKnowledgeParse gate and the card/list menus). It is a quiet icon-only button matching the other header controls (refresh / close), revealing its destructive error tint only on hover, and opens an in-app TDesign confirm dialog (not the native window.confirm) before calling the existing cancel-parse API. After cancelling it refetches the spans so the trace reflects the cancelled state. Reuses the existing cancel-parse i18n keys, already present in all locales. --- .../knowledge-processing-timeline.vue | 55 ++++++++++++++++++- 1 file changed, 53 insertions(+), 2 deletions(-) diff --git a/frontend/src/components/knowledge-processing-timeline.vue b/frontend/src/components/knowledge-processing-timeline.vue index 781f549f..665b5043 100644 --- a/frontend/src/components/knowledge-processing-timeline.vue +++ b/frontend/src/components/knowledge-processing-timeline.vue @@ -1,8 +1,8 @@