Notification
Last updated
Last updated
Notifications are messages that communicate information to the user. The two main variants of notifications are toast notifications and inline notifications.
title
The title to display.
Type: Widget
Default: required
subtitle
The subtitle to display.
Type: Widget
Default: required
hideCloseButton
Whether the close button should be disabled, or not.
Type: bool
Default: false
kind
The state that the notification represents. It can be error
, info
, success
, or warning
.
Type: CNotificationKind
Default: CNotificationKind.info
lowContrast
Whether you are using the low contrast variant of the notification.
Type: bool
Default: true
onCloseButtonTap
Called when the close button is tapped.
Type: VoidCallback?
Default: optional
onClose
Called after the given timeout
duration has passed.
Type: VoidCallback?
Default: optional
actions
A list of CNotificationActionButton
to display in a row when the notification is inline
.
Type: List<CNotificationActionButton>?
Default: optional