@@ -78,14 +78,19 @@ const extractAttachedFilesMetadata = (metadata: Record<string, string>): FileMet
7878const extractTeamsAttachmentsMetadata = (
7979 attachments : ChatAttachment [ ] ,
8080 resourceCache ?: Record < string , string >
81- ) : { /* @conditional -compile-remove(file-sharing) */ files : FileMetadata [ ] ; inlineImages : InlineImageMetadata [ ] } => {
81+ ) : {
82+ /* @conditional -compile-remove(file-sharing) */ files : FileMetadata [ ] ;
83+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */ inlineImages : InlineImageMetadata [ ] ;
84+ } => {
8285 /* @conditional -compile-remove(file-sharing) */
8386 const files : FileMetadata [ ] = [ ] ;
87+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */
8488 const inlineImages : InlineImageMetadata [ ] = [ ] ;
8589 attachments . forEach ( ( attachment ) => {
8690 const attachmentType = mapAttachmentType ( attachment . attachmentType ) ;
8791 /* @conditional -compile-remove(file-sharing) */
8892 const contentType = extractAttachmentContentTypeFromName ( attachment . name ) ;
93+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */
8994 if ( attachmentType === 'inlineImage' ) {
9095 inlineImages . push ( {
9196 attachmentType : attachmentType ,
@@ -107,7 +112,10 @@ const extractTeamsAttachmentsMetadata = (
107112 } ) ;
108113 }
109114 } ) ;
110- return { /* @conditional -compile-remove(file-sharing) */ files, inlineImages } ;
115+ return {
116+ /* @conditional -compile-remove(file-sharing) */ files,
117+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */ inlineImages
118+ } ;
111119} ;
112120
113121/* @conditional -compile-remove(data-loss-prevention) */
@@ -217,9 +225,13 @@ const extractAttachmentContentTypeFromName = (name?: string): string => {
217225/* @conditional -compile-remove(file-sharing) @conditional-compile-remove(teams-inline-images-and-file-sharing) */
218226const extractAttachmentsMetadata = (
219227 message : ChatMessageWithStatus
220- ) : { /* @conditional -compile-remove(file-sharing) */ files : FileMetadata [ ] ; inlineImages : InlineImageMetadata [ ] } => {
228+ ) : {
229+ /* @conditional -compile-remove(file-sharing) */ files : FileMetadata [ ] ;
230+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */ inlineImages : InlineImageMetadata [ ] ;
231+ } => {
221232 /* @conditional -compile-remove(file-sharing) */
222233 let files : FileMetadata [ ] = [ ] ;
234+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */
223235 let inlineImages : InlineImageMetadata [ ] = [ ] ;
224236
225237 /* @conditional -compile-remove(file-sharing) */
@@ -232,10 +244,14 @@ const extractAttachmentsMetadata = (
232244 const teamsAttachments = extractTeamsAttachmentsMetadata ( message . content ?. attachments , message . resourceCache ) ;
233245 /* @conditional -compile-remove(file-sharing) */
234246 files = files . concat ( teamsAttachments . files ) ;
247+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */
235248 inlineImages = inlineImages . concat ( teamsAttachments . inlineImages ) ;
236249 }
237250
238- return { /* @conditional -compile-remove(file-sharing) */ files, inlineImages } ;
251+ return {
252+ /* @conditional -compile-remove(file-sharing) */ files,
253+ /* @conditional -compile-remove(teams-inline-images-and-file-sharing) */ inlineImages
254+ } ;
239255} ;
240256const convertToUiChatMessage = (
241257 message : ChatMessageWithStatus ,
0 commit comments