Announce news or a notice in a strip across the top of a page, loud or quiet, that slides away when dismissed.
View as MarkdownInstallation
Component API
| Prop | Type | Default | Description |
|---|---|---|---|
children | ReactNode | - | The message. |
| The message. | |||
action | ReactNode | - | A link or button at the message's end. |
| A link or button at the message's end. | |||
dismissible | boolean | true | Adds a button that slides the banner away. |
| Adds a button that slides the banner away. | |||
onDismiss | () => void | - | Called once the banner is dismissed, such as to remember it. |
| Called once the banner is dismissed, such as to remember it. | |||
variant | loud | quiet | loud | Filled in the fill color for news, or in the well color for a notice. |
| Filled in the fill color for news, or in the well color for a notice. | |||
shape | none | rounded | rounded | |
className | string | - | |
focus | boolean | string | true | |