diff --git a/src/web-ui/src/flow_chat/components/FlowTextBlock.tsx b/src/web-ui/src/flow_chat/components/FlowTextBlock.tsx index 7eba231d54..e0a0c6a59f 100644 --- a/src/web-ui/src/flow_chat/components/FlowTextBlock.tsx +++ b/src/web-ui/src/flow_chat/components/FlowTextBlock.tsx @@ -170,8 +170,8 @@ export const FlowTextBlock = React.memo(({ // A live message stays one selection/reveal owner. Only its changing suffix // enters ReactMarkdown; sealed semantic prefixes keep memoized renderers. const sections = useMemo(() => markdownSection || parsedContent.hasProtocol || !textItem.isMarkdown - ? [{ start: 0, end: displayContent.length }] : markdownSections(displayContent), - [displayContent, markdownSection, parsedContent.hasProtocol, textItem.isMarkdown]); + ? [{ start: 0, end: displayContent.length }] : markdownSections(displayContent, { streaming: isVisuallyStreaming }), + [displayContent, isVisuallyStreaming, markdownSection, parsedContent.hasProtocol, textItem.isMarkdown]); const renderMarkdown = (markdownContent: string, key?: React.Key, streaming = markdownStreaming, continuation = false) => (