import { MessageVariant } from './Message.types'; import { ReactNode } from 'react'; /** * Descriptor for an individual snackbar alert */ export interface SnackbarAlert { /** * Unique identifier for the alert */ id: string; /** * The message content to display */ message: ReactNode; /** * The variant/type of message to display */ variant: MessageVariant; /** * Optional action button configuration */ action?: { label: string; onClick: () => void; }; /** * Whether to show the close button * @default true */ showCloseButton?: boolean; /** * Auto-hide duration in milliseconds * Set to null or 0 to disable auto-hide * @default 5000 */ autoHideDuration?: number | null; } /** * Props for the SnackbarStack component */ export interface SnackbarStackProps { /** * Map of alerts to display, keyed by unique ID */ alerts: Map; /** * Callback when an alert's action button is clicked */ onAction?: (id: string) => void; /** * Callback when an alert is closed */ onClose?: (id: string) => void; /** * Optional CSS class name */ className?: string; /** * Position of the snackbar stack * @default 'bottom-center' */ position?: 'bottom-center' | 'bottom-left' | 'bottom-right' | 'top-center' | 'top-left' | 'top-right'; /** * Maximum width for snackbars in the stack */ maxWidth?: string | number; /** * Test ID for testing */ dataTestId?: string; } /** * Ref props for the SnackbarStack component */ export interface SnackbarStackRef { /** * Programmatically close an alert by ID */ closeAlert: (id: string) => void; } //# sourceMappingURL=SnackbarStack.types.d.ts.map