From c83d4335101835df2c15e99be43267625122a18e Mon Sep 17 00:00:00 2001 From: Nate Kelley Date: Mon, 14 Jul 2025 12:07:29 -0600 Subject: [PATCH] Update styling for todo and reasoning file types --- .../ReasoningFileButtons.tsx | 4 ++++ .../ReasoningMessageFile.tsx | 2 +- .../StreamingMessageStatus.tsx | 16 ++++++++++++++-- 3 files changed, 19 insertions(+), 3 deletions(-) diff --git a/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningFileButtons.tsx b/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningFileButtons.tsx index 2a7a72089..b4e0e7452 100644 --- a/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningFileButtons.tsx +++ b/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningFileButtons.tsx @@ -25,6 +25,10 @@ export const ReasoningFileButtons = React.memo( return; } + if (fileType === 'todo') { + return; + } + return assetParamsToRoute({ chatId, assetId: fileId, diff --git a/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningMessageFile.tsx b/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningMessageFile.tsx index e9d9ec6f8..fc9c43e12 100644 --- a/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningMessageFile.tsx +++ b/apps/web/src/controllers/ReasoningController/ReasoningMessages/ReasoningMessage_Files/ReasoningMessageFile.tsx @@ -29,7 +29,7 @@ export const ReasoningMessage_File: React.FC = React. if (!file || !status || !file_type || !id) return null; return !isCompletedStream ? ( - + ) : ( { + ({ + status, + fileType + }: { + status: BusterChatMessageReasoning_file['status']; + fileType: BusterChatMessageReasoning_file['file_type']; + }) => { const content = useMemo(() => { + if (fileType === 'todo' || fileType === 'agent-action' || fileType === 'reasoning') { + return null; + } + + const _typeCheck: 'metric' | 'dashboard' = fileType; + if (status === 'loading') return (
@@ -36,7 +48,7 @@ export const StreamingMessageStatus = React.memo( Failed ); - }, [status]); + }, [status, fileType]); return (