Toast
Toast wrapper and function. Toast internally uses Sonner
Usage
Toast Props
Prop | Type | Default |
---|---|---|
description | string | - |
duration | number | 4000 |
position | "top-left" | "top-right" | "bottom-left" | "bottom-right" | "top-center" | "bottom-center" | "bottom-right" |
dismissible | boolean | true |
icon | ReactNode | - |
invert | boolean | false |
closeButton | boolean | false |
unstyled | boolean | false |
action | { label: string; onClick: () => void; } | - |
cancel | { label: string; onClick: () => void; } | - |
actionButtonStyle | CSSProperties | {} |
cancelButtonStyle | CSSProperties | {} |
onDismiss | () => void | - |
onAutoClose | () => void | - |
id | string | - |