import { ReactNode } from 'react'; export interface NotificationConfig { channels: { toast?: ToastChannelConfig; bell?: BellChannelConfig; push?: PushChannelConfig; email?: EmailChannelConfig; }; defaultDuration?: number; position?: NotificationPosition; maxStack?: number; } export interface NotificationOptions { id?: string; title: string; message?: string; type?: NotificationType; duration?: number | 'persistent'; actions?: NotificationAction[]; icon?: ReactNode; image?: string; data?: Record; channels?: NotificationChannels; audience?: NotificationAudience; priority?: 'high' | 'normal' | 'low'; sound?: boolean; vibrate?: boolean; link?: NotificationLink; avatar?: NotificationAvatar; progress?: NotificationProgress; status?: NotificationStatus; badge?: NotificationBadge; } export type NotificationType = 'info' | 'success' | 'warning' | 'error' | 'loading'; export type NotificationPosition = | 'top-left' | 'top-center' | 'top-right' | 'bottom-left' | 'bottom-center' | 'bottom-right'; export interface NotificationAction { label: string; action: (() => void) | 'dismiss' | 'snooze'; style?: 'primary' | 'secondary' | 'danger'; icon?: ReactNode; } export interface NotificationChannels { toast?: boolean; bell?: boolean; push?: boolean; email?: boolean; } export interface NotificationAudience { users?: string[]; roles?: string[]; departments?: string[]; segments?: string[]; exclude?: string[]; } export interface Notification { id: string; title: string; message?: string; type: NotificationType; createdAt: Date; readAt?: Date; dismissedAt?: Date; expiresAt?: Date; actions?: NotificationAction[]; data?: Record; sender?: { id: string; name: string; avatar?: string; }; link?: NotificationLink; avatar?: NotificationAvatar; progress?: NotificationProgress; status?: NotificationStatus; badge?: NotificationBadge; } export interface NotificationUpdate { id: string; title?: string; message?: string; type?: NotificationType; loading?: boolean; progress?: number; actions?: NotificationAction[]; link?: NotificationLink; avatar?: NotificationAvatar; status?: NotificationStatus; badge?: NotificationBadge; } export interface NotificationStats { total: number; unread: number; byType: Record; byChannel: Record; } export interface NotificationLink { href: string; label?: string; target?: '_self' | '_blank' | '_parent' | '_top'; external?: boolean; } export interface NotificationAvatar { src?: string; alt?: string; name?: string; color?: string; icon?: ReactNode; } export interface NotificationProgress { value: number; max?: number; label?: string; color?: string; animated?: boolean; striped?: boolean; } export interface NotificationStatus { type: 'pending' | 'processing' | 'completed' | 'failed' | 'cancelled'; label?: string; color?: string; icon?: ReactNode; } export interface NotificationBadge { label: string; color?: string; variant?: 'filled' | 'light' | 'outline' | 'dot'; size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl'; }