catask/templates/snippets/layout/load_more_questions.html
2025-02-28 07:26:07 +03:00

16 lines
624 B
HTML

{% for item in combined %}
{% with question=item.question, answers=item.answers, showViewQuestionBtn=True, multipleAnswers=True %}
{% include 'snippets/layout/question_card.html' %}
{% endwith %}
{% endfor %}
{% if combined|length == per_page %}
<div class="spinner spinner-border mx-auto d-block my-2"
hx-trigger="intersect"
hx-get="{{ url_for('api.load_more_questions', page=page+1) }}"
hx-target="#question-list"
hx-swap="beforeend"
hx-on::after-request="this.remove(); initTooltips()">
<span class="visually-hidden">Loading...</span>
</div>
{% endif %}