UNPKG

@cometchat/chat-uikit-react

Version:

Ready-to-use Chat UI Components for React(Javascript/Web)

53 lines (52 loc) 1.72 kB
/// <reference types="react" /> import { CometChatMessageTemplate } from "../../modals"; import { CalendarObject } from "../../utils/CalendarObject"; interface CometChatThreadHeaderProps { /** * Hides the visibility of the date header. * @default false */ hideDate?: boolean; /** * Hides the visibility of the reply count. * @default false */ hideReplyCount?: boolean; /** * Represents the parent message for displaying threaded conversations. */ parentMessage: CometChat.BaseMessage; /** * Template for customizing the appearance of the message. */ template?: CometChatMessageTemplate; /** * Callback function triggered when the threaded message header is closed. * @returns void */ onClose?: () => void; /** * A custom view for rendering the message bubble. * * @param messageObject - The message to be rendered. * @returns A JSX Element to be rendered as message bubble view. */ messageBubbleView?: JSX.Element; /** * Callback function triggered when an error occurs. * * @param error - An instance of CometChat.CometChatException representing the error. * @returns void */ onError?: ((error: CometChat.CometChatException) => void) | null; /** * Format for the date separators in threaded message preview. */ separatorDateTimeFormat?: CalendarObject; /** * Format for the timestamp displayed next to messages. */ messageSentAtDateTimeFormat?: CalendarObject; } declare const CometChatThreadHeader: (props: CometChatThreadHeaderProps) => import("react/jsx-runtime").JSX.Element; export { CometChatThreadHeader };