Alert

Alert is a component used to display important messages or notifications to the user. It can be customized with different types, icons, and actions.

Default

Extra

Show Details

APIs

NameDescriptionTypeDefault
classNames--{alert?:string;container?:string}--
colorfulText--boolean--
extra--ReactNode--
extraDefaultExpand--boolean--
extraIsolate--boolean--
text--{detail?:string}--
variant--"ghost"|"block"|"default"|"pure"--
typeType of Alert styles, options:`success`, `info`, `warning`, `error`"error"|"success"|"info"|"warning"--
closableWhether Alert can be closed{closeIcon?:ReactNode;disabled?:boolean}|boolean--
closeText--ReactNode--
messageContent of AlertReactNode--
descriptionAdditional content of AlertReactNode--
onCloseCallback when close Alert(event:E)=>void--
afterCloseTrigger when animation ending of Alert()=>void--
showIconWhether to show iconboolean--
rolehttps://www.w3.org/TR/2014/REC-html5-20141028/dom.html#aria-role-attributestring--
style--{}--
prefixCls--string--
className--string--
rootClassName--string--
banner--boolean--
icon--ReactNode--
closeIcon--ReactNode--
action--ReactNode--
onMouseEnter--(event:E)=>void--
onMouseLeave--(event:E)=>void--
onClick--(event:E)=>void--
id--string--