Merge branch 'paginate-comments'

This commit is contained in:
Kevin Morris 2022-08-14 19:50:21 -07:00
commit edacde48e5
No known key found for this signature in database
GPG key ID: F7E46DED420788F3
3 changed files with 22 additions and 2 deletions

View file

@ -33,6 +33,14 @@
<span class="text">{{ "Latest Comments" | tr }}</span>
<span class="arrow"></span>
</h3>
{% set page = ((O / PP) | int) %}
{% set pages = ((comments_total / PP) | ceil) %}
{% if pages > 1 %}
<p class="comments-header-nav">
{{ page | pager_nav(comments_total, prefix) | safe }}
<p>
{% endif %}
</div>
{% for comment in comments.all() %}
{% include "partials/packages/comment.html" %}