LobeChatLobeHub
UI
Components
Chat
Mobile
Awesome
Brand
Mdx
Color
Changelog
Ctrl K
General
ActionIcon
ActionIconGroup
Icon
FileTypeIcon
MaterialFileTypeIcon
Data Display
Avatar
Collapse
EmptyCard
FluentEmoji
Highlighter
Image
List
Markdown
Mermaid
Snippet
SortableList
Tag
Tooltip
Video
Data Entry
CodeEditor
ContextMenu
CopyButton
EditableText
EmojiPicker
Form
FormModal
Input
SearchBar
SelectWithImg
SliderWithInput
Swatches
ThemeSwitch
Feedback
Alert
Modal
Layout
DraggablePanel
Footer
Grid
Header
Layout
Navigation
Burger
SideNav
TabsNav
Toc
Theme
ConfigProvider
FontLoader
ThemeProvider

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.

import { Alert } from '@lobehub/ui';
NPM
UNPKG
BundlePhobia
PackagePhobia
Anvaka Graph
Source
Edit
Previous
ThemeSwitch
Next
Modal

Resources

Lobe UI-AIGC Components
Lobe Icon-AI / LLM Icon Collection
Lobe Charts-Modern Charts
Lobe TTS-TTS / STT Library

Community

Report Bug
Request Feature

Help

GitHub
Changelog

More Products

🤯 Lobe Chat-AI / LLM Chat Framework
🧸 Lobe Vidol-Virtual Idols for EveryOne
🅰️ Lobe Theme-Stable Diffusion Extension
🌐 Lobe i18n-AI i18next CLI
Copyright © 2022-2025
Made with 🤯 by LobeHub
LobeHub

Default

Extra

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--
Informational Notes
Alert Title
Informational Notes
Alert Title
Show Details