import { Problem } from '@/models/problem.model';

export interface Notification {
  id: string;
  details?: string | Problem;
  type: NotificationType;
  text: string;
}

export interface NotificationSettings {
  display: number;
  delay: number;
}

export enum NotificationType {
  success = 'success',
  error = 'error',
}

export interface NotificationInstance {
  success: (text: string, details?: string, time?: number) => void;
  error: (text: string, details?: string | Problem, time?: number) => void;
  dismiss: (id: string) => void;
}
