-
Notifications
You must be signed in to change notification settings - Fork 200
/
prev-next.html
30 lines (29 loc) · 1.07 KB
/
prev-next.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
{# Define macro for re-use #}
{% macro prev_next(prev, next, prev_title='', next_title='') %}
{%- if prev %}
<div id="prev">
<a class="left-prev" href="{{ prev.link|e }}" title="{{ _('previous') }} {{ _('page') }}">
<i class="prevnext-label fas fa-angle-left"></i>
<div class="prevnext-info">
<p class="prevnext-label">{{ _("previous") }}</p>
<p class="prevnext-title">{{ prev_title or prev.title }}</p>
</div>
</a>
</div>
{%- endif %}
{%- if next %}
<div id="next">
<a class="right-next" href="{{ next.link|e }}" title="{{ _('next') }} {{ _('page') }}">
<div class="prevnext-info">
<p class="prevnext-label">{{ _("next") }}</p>
<p class="prevnext-title">{{ next_title or next.title }}</p>
</div>
<i class="prevnext-label fas fa-angle-right"></i>
</a>
</div>
{%- endif %}
{% endmacro %}
{# Add previous / next buttons to page #}
<div class='prev-next-bottom'>
{{ prev_next(prev, next) }}
</div>