sigilUI

Alert

Display a status message with a title and supporting detail.

@sigil-ui/componentsReact

Preview

Live preview Interactive

Import

import { Alert, AlertTitle, AlertDescription } from "@sigil-ui/components";

Usage

<Alert>
    <AlertTitle>Heads up</AlertTitle>
    <AlertDescription>This is an alert message.</AlertDescription>
  </Alert>

Sub-components

This component includes the following parts:

  • <AlertTitle>
  • <AlertDescription>

Props

PropTypeDefaultDescription
variantAlertVariantdefaultVisual variant controlling accent color and background.
fillAlertFilloutlineFill style. "outline" = border only, "filled" = solid bg, "soft" = tinted bg.
onClose() => void—Callback to render a close button. When provided, an X button appears.

Token integration

CSS VariablePurpose
--s-borderBorder
--s-textText
--s-surfaceSurface
--s-errorError
--s-successSuccess
--s-warningWarning
--s-infoInfo
--s-primary-contrastPrimary contrast
--s-radius-mdRadius md
--s-border-styleBorder style
--s-radius-smRadius sm
--s-ringRing