Skip to content

Commit a738a6d

Browse files
committed
fix stream persistence
1 parent 2abf6ac commit a738a6d

File tree

2 files changed

+6
-9
lines changed
  • apps/sim
    • app/workspace/[workspaceId]/home/components/message-content/components/chat-content
    • lib/copilot/request/go

2 files changed

+6
-9
lines changed

apps/sim/app/workspace/[workspaceId]/home/components/message-content/components/chat-content/chat-content.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -207,7 +207,12 @@ export function ChatContent({ content, isStreaming = false, onOptionSelect }: Ch
207207

208208
return (
209209
<div className={cn(PROSE_CLASSES, '[&>:first-child]:mt-0 [&>:last-child]:mb-0')}>
210-
<Streamdown isAnimating={isStreaming} animated components={MARKDOWN_COMPONENTS}>
210+
<Streamdown
211+
mode={isStreaming ? undefined : 'static'}
212+
isAnimating={isStreaming}
213+
animated={isStreaming}
214+
components={MARKDOWN_COMPONENTS}
215+
>
211216
{rendered}
212217
</Streamdown>
213218
</div>

apps/sim/lib/copilot/request/go/stream.ts

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -277,14 +277,6 @@ export async function runStreamLoop(
277277
return
278278
}
279279

280-
if (
281-
streamEvent.type === MothershipStreamV1EventType.text &&
282-
typeof streamEvent.payload.text === 'string'
283-
) {
284-
await options.onEvent?.(streamEvent)
285-
return
286-
}
287-
288280
if (
289281
streamEvent.type === MothershipStreamV1EventType.tool &&
290282
streamEvent.payload.phase === 'args_delta' &&

0 commit comments

Comments
 (0)