Alert
Uso
Referencia de la API
VoltAlertDescription — volt-alert-description
| Entrada | Tipo | Por defecto |
|---|---|---|
| class | string | '' |
VoltAlertTitle — volt-alert-title
| Entrada | Tipo | Por defecto |
|---|---|---|
| class | string | '' |
VoltAlert — volt-alert
| Entrada | Tipo | Por defecto |
|---|---|---|
| variant | AlertVariants['variant'] | 'default' |
| role | AlertRole | null |
| class | string | '' |
Variantes CVA
| Propiedad | Opciones | Por defecto |
|---|---|---|
| variant | default | info | success | warning | destructive | default |
Código del componente
Instalar por CLI:
npx @voltui/cli add alertTypeScript
Cargando el editor…
Copia este código en tu proyecto. El componente usa class-variance-authority.