action | The action of Alert | ReactNode | - | — |
afterClose | Called when close animation is finished, please use closable.afterClose instead | () => void | - | — |
banner | Whether to show as banner | boolean | false | — |
variant | Variant of Alert style | outlined | filled | outlined | 6.4.0 |
classNames | Customize class for each semantic structure inside the component. Supports object or function | Record<SemanticDOM, string> | (info: { props }) => Record<SemanticDOM, string> | - | — |
closable | The config of closable | boolean | ClosableType & React.AriaAttributes | false | — |
closeIcon | (Only supports global configuration) Custom close icon | ReactNode | - | × |
description | Additional content of Alert | ReactNode | - | — |
errorIcon | (Only supports global configuration) Custom error icon in Alert icon | ReactNode | - | × |
icon | Custom icon, effective when showIcon is true | ReactNode | - | — |
infoIcon | (Only supports global configuration) Custom info icon in Alert icon | ReactNode | - | × |
message | Content of Alert, please use title instead | ReactNode | - | — |
onClose | Callback when Alert is closed, please use closable.onClose instead | (e: MouseEvent) => void | - | — |
closeIcon | Custom close icon, please use closable.closeIcon instead | ReactNode | - | - |
closeText | Close text to show, please use closable.closeIcon instead | ReactNode | - | - |
showIcon | Whether to show icon | boolean | false, in banner mode default is true | — |
styles | Customize inline style for each semantic structure inside the component. Supports object or function | Record<SemanticDOM, CSSProperties> | (info: { props }) => Record<SemanticDOM, CSSProperties> | - | — |
successIcon | (Only supports global configuration) Custom success icon in Alert icon | ReactNode | - | × |
title | Content of Alert | ReactNode | - | — |
type | Type of Alert styles, options: success, info, warning, error | string | info, in banner mode default is warning | — |
warningIcon | (Only supports global configuration) Custom warning icon in Alert icon | ReactNode | - | × |