{#
/**
 * @file
 * Template for Alert component.
 */
#}
{% set variant = variant|default('info') %}

{% set classes = [
  'kern-alert',
  'kern-alert--' ~ variant,
] %}

<div {{ attributes.addClass(classes) }} role="alert">
  <div class="kern-alert__header">
    {% embed 'kern_ux_canvas:icon' with {icon: variant} %}{% endembed %}
    <span class="kern-title">{{ title }}</span>
  </div>
  {% if body or link %}
    <div class="kern-alert__body">
      {% if body %}
        <div class="kern-body">{{ body }}</div>
      {% endif %}
      {{ link }}
    </div>
  {% endif %}
</div>

