logo-icon
STW UI

Alert

Alert informs users about important events.

Usage

svelte
import { Alert } from 'stwui';
// OR
import Alert from 'stwui/alert'; // for tree shaking

Basic

With Description

With Action

The Kitchen Sink

Alert Props

type 'info' | 'warn' | 'success' | 'error' info

Alert Slots

leading <Alert.Leading slot="leading" />
title <Alert.Title slot="title" />
description <Alert.Description slot="description" />
extra <Alert.Extra slot="extra" />

Alert.Leading Props

data string (IconData)
viewBox string 0 0 24 24
size string 24px
width string 24px
height string 24px
color string currentColor
stroke string | undefined
fill string currentColor

Alert.Title Slots

default

Alert.Description Slots

default

Alert.Extra Slots

default

Alert Class Identifiers

stwui-alert
stwui-alert-leading
stwui-alert-title-description-wrapper
stwui-alert-title
stwui-alert-description
stwui-alert-extra