From 3a6f928b3a0077b36e7d793842535652fbb202ca Mon Sep 17 00:00:00 2001 From: Patrick Erichsen Date: Mon, 14 Jul 2025 14:18:32 -0700 Subject: [PATCH] Update StepContainer.tsx --- gui/src/components/StepContainer/StepContainer.tsx | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/gui/src/components/StepContainer/StepContainer.tsx b/gui/src/components/StepContainer/StepContainer.tsx index 91533848c..67ea6d647 100644 --- a/gui/src/components/StepContainer/StepContainer.tsx +++ b/gui/src/components/StepContainer/StepContainer.tsx @@ -38,13 +38,9 @@ export default function StepContainer(props: StepContainerProps) { ); const uiConfig = useAppSelector(selectUIConfig); - const isUserOrSysOrLastMsg = - historyItemAfterThis?.message.role === "user" || - historyItemAfterThis?.message.role === "system" || - !historyItemAfterThis; - - const showResponseActions = - isUserOrSysOrLastMsg && !(isStreaming && props.isLast); + const isAssistantOrThinkingMsg = + historyItemAfterThis?.message.role === "assistant" || + historyItemAfterThis?.message.role === "thinking"; useEffect(() => { if (!isStreaming) { @@ -106,9 +102,9 @@ export default function StepContainer(props: StepContainerProps) { {props.isLast && } {/* We want to occupy space in the DOM regardless of whether the actions are visible to avoid jank on stream complete */} - {isUserOrSysOrLastMsg && ( + {isAssistantOrThinkingMsg && props.isLast && (
- {showResponseActions && ( + {!isStreaming && (