{#
/**
 * @file
 * Template for Accordion component.
 */
#}
{% set open = open|default(false) %}
{% set attributes = attributes|default(create_attribute()) %}

<details {{ attributes.addClass('kern-accordion') }} {% if open %}open{% endif %}>
  <summary class="kern-accordion__header">
    <span class="kern-title">
      {% block title %}
        {{ title }}
      {% endblock %}
    </span>
  </summary>
  <section class="kern-accordion__body">
    {% block body %}
      <p class="kern-body">{{ body }}</p>
    {% endblock %}
  </section>
</details>

