@masaischool/lotus
Version:
Masai UI component library designed to work seamlessly with Chakra UI
14 lines (13 loc) • 575 B
TypeScript
interface Props {
type: 'error' | 'success' | 'warning' | 'info' | undefined;
description: string;
isClosable?: boolean;
}
declare const useSnackBar: () => {
success: (message: string, isClosable?: boolean | undefined) => void;
error: (message: string, isClosable?: boolean | undefined) => void;
warning: (message: string, isClosable?: boolean | undefined) => void;
info: (message: string, isClosable?: boolean | undefined) => void;
fireSnackBar: ({ type, description, isClosable }: Props) => void;
};
export default useSnackBar;