Theme:
Ui3nNotification
Notification component for displaying messages with different types and positions.
Props
| Name | Type | Default | Description |
|---|---|---|---|
id | string | undefined | — | Notification ID |
type | "error" | "success" | "info" | "warning" | undefined | "info" | Notification type |
content* | string | — | Notification content |
position | "right" | "left" | "center" | undefined | "center" | Notification position |
duration | number | undefined | 0 | Notification duration in milliseconds |
withIcon | boolean | undefined | true | Whether to display icon |
onOpen | (() => void) | undefined | () => { } | Called when notification opens |
onClose | (() => void) | undefined | () => { } | Called when notification closes |
Usage Examples
Basic notification
Basic notification
Simple notification with default settings
Notification types
Notification types
Different notification types: success, warning, info, error
Auto-close notification
Auto-close notification
Notification that closes automatically after specified duration