import type { MessageAttachmentBase } from '@rocket.chat/core-typings'; import { isFileAttachment, isQuoteAttachment } from '@rocket.chat/core-typings'; import { memo } from 'react'; import DefaultAttachment from './DefaultAttachment'; import FileAttachment from './FileAttachment'; import { QuoteAttachment } from './QuoteAttachment'; import type { AudioAttachmentSource } from './file/AudioAttachment'; export type AttachmentsItemProps = { attachment: MessageAttachmentBase; id: string | undefined; path: string; source?: AudioAttachmentSource; }; const AttachmentsItem = ({ attachment, id, path, source }: AttachmentsItemProps) => { if (isFileAttachment(attachment)) { return ; } if (isQuoteAttachment(attachment)) { return ; } return ; }; export default memo(AttachmentsItem);