Alert

Feedback

Communicates status, warnings, or contextual information to the user.

Playground

Controls

Visual severity.

Optional bold heading.

Props

PropTypeDefaultDescription
variant'default' | 'info' | 'success' | 'warning' | 'destructive''default'Visual style and severity.
titlestringOptional heading inside the alert.

Examples

Info
vue
<DsAlert
  variant="info"
  title="Information"
>
  Your session will expire in 10 minutes.
</DsAlert>
Success
vue
<DsAlert
  variant="success"
  title="Saved"
>
  Your changes have been saved successfully.
</DsAlert>
Warning
vue
<DsAlert
  variant="warning"
  title="Warning"
>
  This action cannot be undone.
</DsAlert>
Error
vue
<DsAlert
  variant="destructive"
  title="Error"
>
  Something went wrong. Please try again.
</DsAlert>
Default
vue
<DsAlert variant="default">
  A simple neutral message.
</DsAlert>

Skeleton

Use DsAlertSkeleton as a loading placeholder while content is being fetched.

With title
vue
<DsAlertSkeleton showTitle />
No title
vue
<DsAlertSkeleton :showTitle="false" />

Accessibility

  • Rendered with role="alert" for screen reader announcements.
  • Each variant uses a contextual icon for visual reinforcement.