You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There are five types of alerts, applied by the prop type: success, danger, warning, info and neutral (default).
Every alert comes with an icon that helps identifying the type of alert for colorblind people.
Code
<Alert>Lorem ipsum dolor sit</Alert><Alerttype="success">Loremipsumdolorsit</Alert><Alerttype="danger">Lorem ipsum dolor sit</Alert><Alerttype="warning">Loremipsumdolorsit</Alert><Alerttype="info">Lorem ipsum dolor sit</Alert><Alerttype="neutral">Loremipsumdolorsit</Alert>
onClose
The onClose prop is responsible for showing the close button and executing the passed function.
Code
<Alerttype="success"onClose={()=>{}}>
Lorem ipsum
</Alert>
Props overview
Prop
Description
Type
Default
type
define the size of component
success, danger, warning, info, neutral
neutral
onClose
if present, shows a close button and executes a function