3.1.2 atoms.alert.variant Alert variants

Toggle example guides Toggle HTML markup

Alerts don't have default classes, only base and modifier classes. A default gray alert doesn't make too much sense, so you're required to specify a type via contextual class. Choose from success, info, warning, or danger.

Examples
.alert-success
Success
.alert-info
Information
.alert-warning
Warning
.alert-danger
Danger
Markup: 02-atoms/alert/alert.twig
<div class="alert alert-dismissible fade in {{ modifier_class }}" role="alert">

  <button type="button" class="close" data-dismiss="alert" aria-label="{{ "Close"|t }}">
    <span aria-hidden="true">×</span>
  </button>

  <strong>{{ title }}</strong>
  {{ content }}

</div>
Source: 02-atoms/alert/alert.scss, line 3