{% from 'macros.jinja2' import base_type %}

<div class="mkapi-docstring">
{% for section in docstring.sections %}
<div class="mkapi-section{% if section.name %} mkapi-section-{{ section.name|lower }}{% endif %}">
{% if section.name %}
<div class="mkapi-section-name mkapi-section-name-{{ section.name|lower|replace(' ', '-') }}">
<span class="mkapi-section-name-body">{{ section.name }}</span>
{{ base_type(section) }}
</div>
{% endif %}
<div class="mkapi-section-body{% if section.name %} mkapi-section-body-{{ section.name|lower }}{% endif %}">{{ section.html|safe }}</div>
</div>
{% endfor %}
</div>
