// @flow

import type { TranslatedContent } from '../../../../types';

type ToastHandlerProps = {
  handleMouseIn: () => void,
  handleMouseOut: () => void,
  handleClose: (event: SyntheticEvent<HTMLButtonElement>) => void,
};

type ToastState = {
  show: boolean,
  setShow: (shouldShow: boolean) => void,
  animationTimerId: number,
  setAnimationTimerId: (timeoutId: number) => void,
};

export type InjectedToastProps = ToastHandlerProps & ToastState;

export type Level = 'info' | 'success' | 'error';

export type ToastProps = {
  id?: string,
  children?: TranslatedContent,
  timerDelay?: number,
  onClose?: (toastId?: string) => void,
  level?: Level,
};
