From 3afc7da39c16d3e69e37a85856980820d62f7c83 Mon Sep 17 00:00:00 2001 From: Matt Rubens Date: Fri, 17 Oct 2025 01:06:35 -0400 Subject: [PATCH] Remove request content from UI messages --- src/core/task/Task.ts | 4 --- src/core/task/__tests__/Task.spec.ts | 2 -- webview-ui/src/components/chat/ChatRow.tsx | 39 ++-------------------- 3 files changed, 3 insertions(+), 42 deletions(-) diff --git a/src/core/task/Task.ts b/src/core/task/Task.ts index 851df91e6c5e..8beaf1235e8c 100644 --- a/src/core/task/Task.ts +++ b/src/core/task/Task.ts @@ -1793,9 +1793,6 @@ export class Task extends EventEmitter implements TaskLike { await this.say( "api_req_started", JSON.stringify({ - request: - currentUserContent.map((block) => formatContentBlockToMarkdown(block)).join("\n\n") + - "\n\nLoading...", apiProtocol, }), ) @@ -1835,7 +1832,6 @@ export class Task extends EventEmitter implements TaskLike { const lastApiReqIndex = findLastIndex(this.clineMessages, (m) => m.say === "api_req_started") this.clineMessages[lastApiReqIndex].text = JSON.stringify({ - request: finalUserContent.map((block) => formatContentBlockToMarkdown(block)).join("\n\n"), apiProtocol, } satisfies ClineApiReqInfo) diff --git a/src/core/task/__tests__/Task.spec.ts b/src/core/task/__tests__/Task.spec.ts index 116c78d76096..3083fa19245d 100644 --- a/src/core/task/__tests__/Task.spec.ts +++ b/src/core/task/__tests__/Task.spec.ts @@ -704,7 +704,6 @@ describe("Cline", () => { tokensOut: 50, cacheWrites: 0, cacheReads: 0, - request: "test request", }), }, ] @@ -829,7 +828,6 @@ describe("Cline", () => { tokensOut: 50, cacheWrites: 0, cacheReads: 0, - request: "test request", }), }, ] diff --git a/webview-ui/src/components/chat/ChatRow.tsx b/webview-ui/src/components/chat/ChatRow.tsx index 26bc71074adb..b0b87e7a2ddd 100644 --- a/webview-ui/src/components/chat/ChatRow.tsx +++ b/webview-ui/src/components/chat/ChatRow.tsx @@ -46,8 +46,6 @@ import { ChatTextArea } from "./ChatTextArea" import { MAX_IMAGES_PER_MESSAGE } from "./ChatView" import { useSelectedModel } from "../ui/hooks/useSelectedModel" import { - ChevronRight, - ChevronDown, Eye, FileDiff, ListTree, @@ -289,11 +287,7 @@ export const ChatRowContent = ({ getIconSpan("error", errorColor) ) ) : cost !== null && cost !== undefined ? ( - isExpanded ? ( - - ) : ( - - ) + getIconSpan("arrow-swap", normalColor) ) : apiRequestFailedMessage ? ( getIconSpan("error", errorColor) ) : ( @@ -325,17 +319,7 @@ export const ChatRowContent = ({ default: return [null, null] } - }, [ - type, - isCommandExecuting, - message, - isMcpServerResponding, - apiReqCancelReason, - cost, - apiRequestFailedMessage, - t, - isExpanded, - ]) + }, [type, isCommandExecuting, message, isMcpServerResponding, apiReqCancelReason, cost, apiRequestFailedMessage, t]) const headerStyle: React.CSSProperties = { display: "flex", @@ -1062,13 +1046,7 @@ export const ChatRowContent = ({ ? 10 : 0, justifyContent: "space-between", - cursor: "pointer", - userSelect: "none", - WebkitUserSelect: "none", - MozUserSelect: "none", - msUserSelect: "none", - }} - onClick={handleToggleExpand}> + }}>
{icon} {title} @@ -1101,17 +1079,6 @@ export const ChatRowContent = ({ } /> )} - - {isExpanded && ( -
- (message.text)?.request} - language="markdown" - isExpanded={true} - onToggleExpand={handleToggleExpand} - /> -
- )} ) case "api_req_finished":