Alert

OverviewStyleGuidelinesCodeAccessibilityDemos

Style

An alert is a layout including an icon, title, text, actions, and a close button. It comes in a variety of colors depending on status. A toast is a variant of alert. Instead of having a background color, it has a white background with a drop shadow.

Anatomy

Alert with numbers pointing to parts of the element
  1. Status icon
  2. Title
  3. Body text
  4. Action buttons
  5. Close button
  6. Color background
  7. White background with drop shadow

Variants

Inline

The default alert is inline. At minimum, the status icon and title need to be visible.

Two examples of an inline alert

Inline alternate

There is an alternate inline alert where the border covers all sides.

Two examples of an alternate design for inline alerts

Toast

Same as the inline alert, at minimum, the status icon and title need to be visible.

Two examples of a toast alert

Space

Diagram of spacing for inline alerts Diagram of spacing for toast alerts

Diagram of spacing for alerts on mobile

Interaction states

Refer to these documentation pages for interaction states: