diff --git a/packages/ui/src/components/session-turn.tsx b/packages/ui/src/components/session-turn.tsx index ae1321bac14..a8eb61dc71c 100644 --- a/packages/ui/src/components/session-turn.tsx +++ b/packages/ui/src/components/session-turn.tsx @@ -271,6 +271,17 @@ export function SessionTurn( const isShellMode = createMemo(() => !!shellModePart()) + const hasReasoningParts = createMemo(() => { + for (const m of assistantMessages()) { + const msgParts = data.store.part[m.id] + if (!msgParts) continue + for (const p of msgParts) { + if (p?.type === "reasoning") return true + } + } + return false + }) + const rawStatus = createMemo(() => { const msgs = assistantMessages() let last: PartType | undefined @@ -376,6 +387,8 @@ export function SessionTurn( diffLimit: diffInit, status: rawStatus(), duration: duration(), + userMessageHovered: false, + showReasoning: false, }) createEffect( @@ -564,7 +577,7 @@ export function SessionTurn( message={assistantMessage} responsePartId={responsePartId()} hideResponsePart={hideResponsePart()} - hideReasoning={!working()} + hideReasoning={!working() && !store.showReasoning} /> )} @@ -596,6 +609,17 @@ export function SessionTurn(

Response

+ + + + +
+ + {(assistantMessage) => ( + + )} + +
+