@@ -26,6 +26,7 @@ import {
2626 isVoiceRecordingAttachment ,
2727 type LocalMessage ,
2828 type MessageComposerState ,
29+ type MessageResponse ,
2930 type PollResponseData ,
3031 type SharedLocationResponseData ,
3132 type TranslationLanguages ,
@@ -55,7 +56,7 @@ const messageComposerStateStoreSelector = (state: MessageComposerState) => ({
5556} ) ;
5657
5758export type QuotedMessagePreviewProps = {
58- getQuotedMessageAuthor ?: ( message : LocalMessage ) => string ;
59+ getQuotedMessageAuthor ?: ( message : LocalMessage | MessageResponse ) => string ;
5960 renderText ?: MessageContextValue [ 'renderText' ] ;
6061} ;
6162
@@ -96,7 +97,7 @@ type GroupedAttachments = Record<AttachmentType, Attachment[]> & {
9697 total : number ;
9798} ;
9899
99- const getGroupedAttachments = ( quotedMessage : LocalMessage | null ) => {
100+ const getGroupedAttachments = ( quotedMessage : LocalMessage | MessageResponse | null ) => {
100101 const groupedAttachments = {
101102 documents : [ ] ,
102103 giphies : [ ] ,
@@ -169,7 +170,7 @@ type PreviewType =
169170 | 'mixed' ;
170171
171172const getAttachmentIconWithType = (
172- quotedMessage : LocalMessage | null ,
173+ quotedMessage : LocalMessage | MessageResponse | null ,
173174 giphyVersionName : GiphyVersions ,
174175) : {
175176 groupedAttachments : GroupedAttachments ;
@@ -314,7 +315,7 @@ export const QuotedMessagePreview = ({
314315} ;
315316
316317type QuotedMessagePreviewUIProps = QuotedMessagePreviewProps & {
317- quotedMessage : LocalMessage ;
318+ quotedMessage : LocalMessage | MessageResponse ;
318319 authorLabel ?: ReactNode ;
319320 className ?: string ;
320321 onClick ?: MouseEventHandler < HTMLDivElement > ;
0 commit comments