diff options
Diffstat (limited to 'templates/macros/pagination.html')
-rw-r--r-- | templates/macros/pagination.html | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/templates/macros/pagination.html b/templates/macros/pagination.html new file mode 100644 index 0000000..077cc5a --- /dev/null +++ b/templates/macros/pagination.html @@ -0,0 +1,15 @@ +{% macro render_pagination(pagination) %} + <div class="pagination"> + {% if pagination.has_prev %} + <a href="{{ pagination.prev|url }}">« Previous</a> + {% else %} + <span class="disabled">« Previous</span> + {% endif %} + | {{ pagination.page }} | + {% if pagination.has_next %} + <a href="{{ pagination.next|url }}">Next »</a> + {% else %} + <span class="disabled">Next »</span> + {% endif %} + </div> +{% endmacro %} |