portfolio/_includes/post-paginator.html

33 lines
1012 B
HTML
Raw Normal View History

{% if paginator.total_pages > 1 %}
2023-12-26 04:37:38 +00:00
<nav aria-label="Page Navigation">
<ul class="pagination">
<!-- left arrow -->
{% if paginator.previous_page %}
{% assign prev_url = paginator.previous_page_path | prepend: site.baseurl %}
{% else %}
{% assign prev_url = '' %}
{% endif %}
<li class="page-item {% unless paginator.previous_page %}disabled{% endunless %}">
<a class="page-link" href="{{ prev_url }}" aria-label="previous-page">
<i class="fa fa-angle-left"></i>
</a>
</li>
<!-- right arrow -->
{% if paginator.next_page_path %}
{% assign next_url = paginator.next_page_path | prepend: site.baseurl %}
{% else %}
{% assign next_url = '#' %}
{% endif %}
<li class="page-item {% unless paginator.next_page_path %}disabled{% endunless %}">
<a class="page-link" href="{{ next_url }}" aria-label="next-page">
<i class="fa fa-angle-right"></i>
</a>
</li>
</ul>
</nav>
<!-- .pagination -->
{% endif %}