Display a notification message globally.
| Property | Description | Type | Default |
|---|---|---|---|
bottom | Distance from the bottom of the viewport, when placement is bottomRight or bottomLeft (unit: pixels). | number | 24 |
btn | Customized close button | ReactNode | - |
className | Customized CSS class | string | - |
description | The content of notification box (required) | string|ReactNode | - |
duration | Time in seconds before Notification is closed. When set to 0 or null, it will never be closed automatically | number | 4.5 |
getContainer | Return the mount node for Notification | () => HTMLNode | () => document.body |
icon | Customized icon | ReactNode | - |
closeIcon | custom close icon | ReactNode | - |
key | The unique identifier of the Notification | string | - |
message | The title of notification box (required) | string|ReactNode | - |
onClose | Trigger when notification closed | Function | - |
onClick | Specify a function that will be called when the notification is clicked | Function | - |
placement | Position of Notification, can be one of topLeft topRight bottomLeft bottomRight | string | topRight |
style | Customized inline style | - | |
top | Distance from the top of the viewport, when placement is topRight or topLeft (unit: pixels). | number | 24 |
| Property | Description | Type | Default |
|---|---|---|---|
bottom | Distance from the bottom of the viewport, when placement is bottomRight or bottomLeft (unit: pixels). | number | 24 |
closeIcon | custom close icon | ReactNode | - |
duration | Time in seconds before Notification is closed. When set to 0 or null, it will never be closed automatically | number | 4.5 |
getContainer | Return the mount node for Notification | () => HTMLNode | () => document.body |
placement | Position of Notification, can be one of topLeft topRight bottomLeft bottomRight | string | topRight |
top | Distance from the top of the viewport, when placement is topRight or topLeft (unit: pixels). | number | 24 |
rtl | whether to enable RTL mode | boolean | false |