UNPKG

@cometchat/chat-uikit-react-native

Version:

Ready-to-use Chat UI Components for React Native

36 lines (35 loc) 1.45 kB
import { CometChat } from "@cometchat/chat-sdk-react-native"; import { JSX } from "react"; import { CometChatMessageTemplate } from "../shared"; import { CometChatTheme } from "../theme/type"; import { DeepPartial } from "../shared/helper/types"; type Recipient = { sender: CometChat.User | CometChat.Group; deliveredAt: number; readAt: number; sentAt: number; }; export interface CometChatMessageInformationInterface { title?: string; message: CometChat.BaseMessage; template?: CometChatMessageTemplate; BubbleView?: (message: CometChat.BaseMessage) => JSX.Element; ListItemView?: (message: CometChat.BaseMessage, receipt: Recipient) => JSX.Element; receiptDatePattern?: (timestamp: any) => string; onBack?: () => void; onError?: (e: CometChat.CometChatException) => void; EmptyStateView?: () => JSX.Element; emptyStateText?: string; ErrorStateView?: () => JSX.Element; errorStateText?: string; LoadingStateView?: () => JSX.Element; style?: DeepPartial<CometChatTheme["messageInformationStyles"]>; } /** * CometChatMessageInformation component renders the message information view along with message receipts. * * @param props - Properties for configuring the component. * @returns A JSX.Element containing the rendered message information. */ export declare const CometChatMessageInformation: (props: CometChatMessageInformationInterface) => JSX.Element; export {};