import { type ComponentType, type MouseEvent, type ReactNode } from "react"; import { type IntlShape } from "react-intl"; import { type IAccessibilityConfigBase } from "../typings/accessibility.js"; /** * @internal */ export type MessageType = "success" | "progress" | "error" | "warning"; /** * @internal */ export type FormatMessageParams = Parameters; /** * @internal */ export interface IMessageDefinition { id?: string; component?: ComponentType; showMore?: string; showLess?: string; errorDetail?: ReactNode; contrast?: boolean; intensive?: boolean; values?: FormatMessageParams[1]; text?: string; node?: ReactNode; type: MessageType; /** * After how long to automatically remove the message. If set to 0, message is shown until removed manually. * Defaults to 2500 ms. */ duration?: number; } /** * @internal */ export interface IMessage extends IMessageDefinition { id: string; createdAt: number; onDismiss?: () => void; } /** * @internal */ export interface IMessageProps { id?: string; className?: string; onClose?(e: MouseEvent): void; type: MessageType; contrast?: boolean; intensive?: boolean; children?: ReactNode; dataTestId?: string; /** Accessibility attributes applied to the message container. */ accessibilityConfig?: IAccessibilityConfigBase; } //# sourceMappingURL=typings.d.ts.map