<div id="flashes" class="container mt-2">
{% for label, messages in app.flashes %}
{% if messages is iterable %}
{% for message in messages %}
<div class="alert alert-{{ label }} alert-dismissible fade show" role="alert">
{% if message is iterable %}
{% for key, value in message %}
<p><strong>{{ key }}:</strong> {{ value }}</p>
{% endfor %}
{% else %}
{{ message|trans }}
{% endif %}
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
{% endfor %}
{% else %}
<div class="alert alert-{{ label }} alert-dismissible fade show" role="alert">
{{ message|trans }}
<button type="button" class="btn-close" data-bs-dismiss="alert" aria-label="Close"></button>
</div>
{% endif %}
{% endfor %}
</div>