@@ -39,6 +39,11 @@ interface AiChatMessagesProps {
3939 flatMode ?: boolean ;
4040 /** Knowledge space AI panel: full-width column, 14px body, gray user / borderless assistant */
4141 knowledgeChatLayout ?: boolean ;
42+ /** Show the export-session entry under assistant messages. The full homepage/task
43+ chat opts in; the lightweight knowledge/file/article docks and share view leave
44+ it off. Independent of knowledgeChatLayout (which is a layout-width flag and is
45+ true for the homepage chat too). */
46+ allowExport ?: boolean ;
4247 /** Overrides empty-state line under the illustration (e.g. knowledge folder QA hint from parent) */
4348 emptyStateHint ?: string ;
4449 /** Overrides the empty-state illustration (defaults to the AI-home image).
@@ -77,6 +82,7 @@ function MessageTreeNode({
7782 currentIndex,
7883 onRegenerate,
7984 knowledgeChatLayout,
85+ allowExport,
8086 onOpenCitationPanel,
8187 activeCitationMessageId,
8288 onPreviewFile,
@@ -88,6 +94,7 @@ function MessageTreeNode({
8894 onRegenerate ?: ( parentMessageId : string ) => void ;
8995 onPreviewFile ?: ( file : ArtifactFile ) => void ;
9096 knowledgeChatLayout ?: boolean ;
97+ allowExport ?: boolean ;
9198 onOpenCitationPanel ?: ( payload : CitationReferencesDesktopPayload ) => void ;
9299 activeCitationMessageId ?: string | null ;
93100} ) {
@@ -132,6 +139,7 @@ function MessageTreeNode({
132139 siblingCount = { siblings . length }
133140 setSiblingIdx = { setSiblingIdx }
134141 knowledgeChatLayout = { knowledgeChatLayout }
142+ allowExport = { allowExport }
135143 onOpenCitationPanel = { onOpenCitationPanel }
136144 activeCitationMessageId = { activeCitationMessageId }
137145 onPreviewFile = { onPreviewFile }
@@ -145,6 +153,7 @@ function MessageTreeNode({
145153 currentIndex = { currentIndex + 1 }
146154 onRegenerate = { onRegenerate }
147155 knowledgeChatLayout = { knowledgeChatLayout }
156+ allowExport = { allowExport }
148157 onOpenCitationPanel = { onOpenCitationPanel }
149158 activeCitationMessageId = { activeCitationMessageId }
150159 onPreviewFile = { onPreviewFile }
@@ -166,6 +175,7 @@ export default function AiChatMessages({
166175 hideHeaderTitle = false ,
167176 flatMode = false ,
168177 knowledgeChatLayout = false ,
178+ allowExport = false ,
169179 emptyStateHint,
170180 emptyStateIllustration,
171181 contentWidthClassName,
@@ -397,6 +407,7 @@ export default function AiChatMessages({
397407 : undefined
398408 }
399409 knowledgeChatLayout = { knowledgeChatLayout }
410+ allowExport = { allowExport }
400411 onOpenCitationPanel = { onOpenCitationPanel }
401412 activeCitationMessageId = { activeCitationMessageId }
402413 onPreviewFile = { onPreviewFile }
@@ -413,6 +424,7 @@ export default function AiChatMessages({
413424 currentIndex = { 0 }
414425 onRegenerate = { onRegenerate }
415426 knowledgeChatLayout = { knowledgeChatLayout }
427+ allowExport = { allowExport }
416428 onOpenCitationPanel = { onOpenCitationPanel }
417429 activeCitationMessageId = { activeCitationMessageId }
418430 onPreviewFile = { onPreviewFile }
0 commit comments