Alert

A status banner for inline feedback — info, success, warning, and error.

Scheduled maintenance
The dashboard will be read-only on Saturday from 02:00–04:00 UTC.
Deploy complete
v0.2.0 is live on all regions.

Import#

import { Alert } from "astralis-ui";

Variants and dismissal#

subtle — the default tinted panel
solid — maximum emphasis
outline — quiet, keeps the surface
left-accent — editorial side rule
Dismissible
The ✕ calls your onClose handler.

Props#

PropTypeDefaultDescription
status"info" | "success" | "warning" | "error""info"Picks the icon, hue, and ARIA role.
variant"subtle" | "solid" | "outline" | "left-accent""subtle"Fill treatment.
colorSchemeall 11 schemesfrom statusHue override (info→blue, success→green, warning→orange, error→red).
iconReactNode | falsestatus iconReplace or hide the leading icon.
onClose() => voidRenders the ✕ dismiss button.

Parts#

PartRendersNotes
Alert.TitledivSemibold heading line.
Alert.DescriptiondivSupporting copy below the title.

Accessibility#

  • error and warning render role="alert" (announced assertively); info and success render role="status" (announced politely).
  • The dismiss button ships with an aria-label; the status icon is decorative (aria-hidden) because the role already conveys the meaning.