summaryrefslogtreecommitdiff
path: root/templates/pagination_macros.html
blob: 89e8c984877464b5b507f322112ace54d84fbe34 (plain)
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
{% macro index_pages() %}
  <nav class="pager">
  {% if paginator.next or paginator.previous%}
    {% if paginator.previous %}
    <article class="newer"><a href="{{ paginator.previous }}"> 〈〈 Newer</a></article>
    {% endif %}
    {% if paginator.next %}
    <article class="older"><a href="{{ paginator.next }}"> Older 〉〉</a></article>
    {% endif %}
  {% endif %}
  </nav>
{% endmacro index_pages %}

{% macro page_pages() %}
  <nav class="pager">
  {% if page.lower or page.higher %}
    {% if page.lower %}
    <article class="newer"><a href="{{ page.lower.permalink }}"> 〈〈 {{ page.lower.title }}</a></article>
    {% endif %}
    {% if page.higher %}
    <article class="older"><a href="{{ page.higher.permalink }}"> {{ page.higher.title }} 〉〉</a></article>
    {% endif %}
  {% endif %}
  </nav>
{% endmacro page_pages %}