toast Component

Toast Notification System

Debug Info: Open browser console and check if hygge.toast exists. If clicking buttons does nothing, try a hard refresh (Ctrl+F5 or Cmd+Shift+R).

Basic Toast Types

Preview Code
Copy

Toast Sizes

Preview Code
Copy

Toast Positions

Preview Code
Copy

Full Width Positions (Perfect for Mobile):

Style Variants

Preview Code
Copy

Display Time & Progress

Preview Code
Copy

Interactive Features

Preview Code
Copy

Full Width Mobile Patterns

Preview Code
Copy

Advanced Examples

Preview Code
Copy

Alert System Integration (hygge.say)

Preview Code
Copy

The hygge.say function processes complex message arrays and displays them as toasts.

Configuration Options

Preview Code
Copy
Option Type Default Description
header string '' Toast title/header text
description string '' Toast body/description text
type string 'info' success, error, info, warning, primary
icon string auto Custom icon name (overrides type default)
displayTime number/null null Seconds (0=no dismiss, null=auto-calculate)
position string 'top-right' 9 position combinations
size string 'small' tiny, small (default), '', large, big
showProgress boolean false Show countdown progress bar
dismissible boolean true Show close button
variant string 'filled' light, filled, outline
actions array [] Action buttons/links
onClick function null Toast click handler
onClose function null Close event callback