@brizy/ui
Version:
React elements in Brizy style
12 lines (11 loc) • 572 B
TypeScript
import { ReactElement } from "react";
import { CSSTransitionProps } from "react-transition-group/CSSTransition";
export type Props<T extends string | number, Ref extends HTMLElement | undefined> = CSSTransitionProps<Ref> & {
id: T;
text: string;
type: "success" | "info" | "error";
onClose: (id: T) => void;
duration?: number;
closable?: boolean;
};
export declare const Notice: <T extends string | number, Ref extends HTMLElement | undefined>({ id, text, type, closable, duration, onClose, ...cssTransitionProps }: Props<T, Ref>) => ReactElement;