UNPKG

@nexusui/components

Version:

These are custom components specially-developed for NexusUI applications. They will make your life easier by giving you out-of-the-box implementations for various high-level UI elements that you can drop directly into your application.

44 lines (43 loc) 1.8 kB
import React from 'react'; import { CustomContentProps } from 'notistack'; import { AlertProps } from '@mui/material/Alert/Alert'; import { AlertTitleProps } from '@mui/material/AlertTitle'; import { SxProps, Theme } from '@mui/material/styles'; export interface BaseVariantProperties { /** * The title of the SnackbarAlert. It can be a string or a React node. */ title?: React.ReactNode; /** * The description of the SnackbarAlert. It can be a string or a React node. * If the description is not provided, the message will be used as the description. */ description?: React.ReactNode; /** * The icon to be displayed in the SnackbarAlert. It should be a React node. * If false, no icon will be displayed. */ icon?: React.ReactNode; /** * Determines whether the close button is enabled for the SnackbarAlert. * @default false */ enableClose?: boolean; /** * The additional properties to be passed to the underlying Alert component, excluding severity, action, icon, onClose, sx, and children. * Refer to https://mui.com/material-ui/api/alert/ */ alertProps?: Omit<AlertProps, 'severity' | 'action' | 'icon' | 'onClose' | 'sx' | 'children'>; /** * The additional properties to be passed to the AlertTitle component, excluding children. * Refer to https://mui.com/material-ui/api/alert-title/ */ alertTitleProps?: Omit<AlertTitleProps, 'children'>; /** * The custom styles to be applied to the SnackbarAlert. */ sx?: SxProps<Theme>; } export interface SnackbarAlertProps extends CustomContentProps, BaseVariantProperties { } export declare const SnackbarAlert: React.ForwardRefExoticComponent<SnackbarAlertProps & React.RefAttributes<HTMLDivElement>>;