import { ChannelState } from "../../../state/ChannelState"; import { ConversationState } from "../../../state/ConversationState"; import { AriaProps } from "../../AriaProps"; import { CSSProps } from "../../CSSProps"; import { MemberDisplayOptions, MessageStyle, PredefinedMessage } from "../MessagingCanvas/MessagingCanvas.definitions"; /** * @typedef Theme.MessageListThemeProps * @property {CSSProps} DateSeparatorLine - Styles for the line for date separators * @property {CSSProps} DateSeparatorText - Styles for the text for date separators * @property {CSSProps} NewMessageSeparatorLine - Styles for the new message seperator line * @property {CSSProps} NewMessageSeparatorText - Styles for the new message seperator text * @property {CSSProps} TypingIndicator - Styles for the typing indicator * @property {CSSProps} MessageScrollButton - Styles for the message scroll button */ export interface MessageListThemeProps { DateSeparatorLine: CSSProps; DateSeparatorText: CSSProps; NewMessageSeparatorLine: CSSProps; NewMessageSeparatorText: CSSProps; TypingIndicator: CSSProps; MessageScrollButton: CSSProps; } /** * @private * @typedef Theme.CCAIVirtualAgentHandoffThemeProps * @property {CSSProps} Text - Styles for the transfer text * @property {CSSProps} Span - Styles for the transfer time */ export interface CCAIVirtualAgentHandoffThemeProps { Text: CSSProps; Span: CSSProps; } /** * @typedef MessageList.MessageListProps * @property {string} conversationSid - Sid of the conversation. * @property {MemberDisplayOptions} memberDisplayOptions - Chat member display configuration. * @property {MessageStyle} messageStyle - Represents the style of a message. * @property {boolean} showTypingIndicator - It sets whether to display the TypingIndicator component or not. * @property {boolean} showReadStatus - It sets whether to display the MessageReadContainer component or not. * @property {boolean} showWelcomeMessage - It sets whether to inject a WelcomeMessage in the message list or not. * @property {PredefinedMessage} [predefinedMessage] - It sets whether to inject a predefined message in the message list or not. * @property {AriaProps} [listContainerAriaProps] - ListContainer aria props. * @property {boolean} [notVisible] - Determines visibility. * @property {string} [conversationType] - Conversation Type. */ export interface MessageListProps { channelSid: string; conversationSid: string; memberDisplayOptions: MemberDisplayOptions; messageStyle: MessageStyle; showTypingIndicator: boolean; showReadStatus: boolean; showWelcomeMessage: boolean; predefinedMessage?: PredefinedMessage; listContainerAriaProps?: AriaProps; notVisible?: boolean; conversationType?: "email" | "chat"; showDisabledOverlay?: boolean; } /** * @typedef MessageList.MessageListChildrenProps * @property {string} conversationSid - Sid of the conversation * @property {ConversationState.ConversationState} conversation - ConversationState object * @property {boolean} [isAppActive] - It sets whether the chat is active or not * @property {MemberDisplayOptions} memberDisplayOptions - Chat member display configuration * @property {MessageStyle} messageStyle - Represents the style of a message. * @property {boolean} showTypingIndicator - It sets whether to display TypingIndicator component or not * @property {boolean} showReadStatus - It sets whether to display the MessageReadContainer component or not * @property {boolean} showWelcomeMessage - It sets whether to inject a WelcomeMessage in the message list or not * @property {PredefinedMessage} [predefinedMessage] - It sets whether to inject a predefined message in the message list or not * @property {AriaProps} [listContainerAriaProps] - ListContainer aria props */ export interface MessageListChildrenProps extends MessageListProps { channel?: ChannelState; conversation: ConversationState; isAppActive?: boolean; isEmailDisabled?: boolean; } export declare enum MessageListChildrenKeys { typingIndicator = "typing-indicator", twilioWelcomeMessage = "Twilio-WelcomeMessage", predefinedMessage = "predefinedMessage", messageLoading = "message-loading", messageScrollButton = "message-scroll-button", newMessageSeparator = "new-message-separator", newMessageRef = "new-message-ref", newMessageRefFrag = "new-message-ref-frag", newMessageText = "new-message-text", dateSeparator = "date-separator" } export declare enum ChannelEnumType { Email = "EMAIL", Voice = "VOICE", Sms = "SMS", Whatsapp = "WHATSAPP", Web = "WEB", Unknown = "UNKNOWN" }