diff --git a/src/utils/messageHandler.ts b/src/utils/messageHandler.ts index ff6e5fd..7ebdcff 100644 --- a/src/utils/messageHandler.ts +++ b/src/utils/messageHandler.ts @@ -401,6 +401,11 @@ async function handleUserMessageWithBackend( isComplete: true, }); + // 发送任务完成消息 + panel.webview.postMessage({ + command: "taskComplete", + }); + // 发送系统通知 - AI 响应完成 const notificationService = NotificationService.getInstance(); notificationService.success( diff --git a/src/views/webviewContent.ts b/src/views/webviewContent.ts index 5fd48b3..7317134 100644 --- a/src/views/webviewContent.ts +++ b/src/views/webviewContent.ts @@ -780,6 +780,11 @@ export function getWebviewContent( hideLoadingIndicator(); break; + case 'taskComplete': + // 显示任务完成提示 + addMessage('✅ 任务已完成', 'bot'); + break; + case 'workspaceStatus': // 更新工作区状态 if (typeof hasWorkspace !== 'undefined') {