Examples
Default
Vip Earn Without Icon
All Variants
Default Closable
Multiple Dismissible
Props
Snackbar
A prominent inline message with optional title, description, action buttons, and close control. Supports three layout variants:default, vipEarn, and welcome.
boolean
default:"false"
Whether to show the close button.
string
default:"Close snackbar"
Accessible label for the close button.
ReactNode
Descriptive body text.
ReactNode
Icon element displayed at the leading edge (used by the
vipEarn variant).(() => void)
Callback fired when the close button is clicked.
string
Primary CTA label โ renders a default
Button.(() => void)
Click handler for the primary CTA (used together with
primaryLabel).ReactNode
Custom element rendered as the primary CTA. Overrides
primaryLabel / primaryOnClick.string
Secondary CTA label โ renders a default
Button.(() => void)
Click handler for the secondary CTA (used together with
secondaryLabel).ReactNode
Custom element rendered as the secondary CTA. Overrides
secondaryLabel / secondaryOnClick.boolean
default:"true"
Whether to show primary/secondary action buttons.
ReactNode
Title content.
"default" | "vipEarn" | "welcome"
default:"default"
Layout variant of the snackbar.
Exported types
Also exported from@fanvue/ui: SnackbarProps, SnackbarVariant.
Setup: Installation ยท Theming