aboutsummaryrefslogtreecommitdiffhomepage
path: root/apioforum/templates/common.html
diff options
context:
space:
mode:
authorthe lemons <citrons@mondecitronne.com>2022-03-01 13:00:36 -0600
committerubq323 <ubq323@ubq323.website>2022-03-02 14:59:08 +0000
commit3644b35b92494965edb4916fdb368fd49c8d4bf2 (patch)
tree72615047f97b423ff1455605b18e3c8a558093a2 /apioforum/templates/common.html
parentb96542d91a7fb8ce6c4275b97f72b90c5227d6f3 (diff)
improve pagination navigation
* pages show more content * the navigation bar is shown regardless of scroll position * the navigation bar now lives in a box * the navigation bar adapts to small screen sizes I changed the padding now.
Diffstat (limited to 'apioforum/templates/common.html')
-rw-r--r--apioforum/templates/common.html14
1 files changed, 12 insertions, 2 deletions
diff --git a/apioforum/templates/common.html b/apioforum/templates/common.html
index 638c423..46402df 100644
--- a/apioforum/templates/common.html
+++ b/apioforum/templates/common.html
@@ -141,14 +141,24 @@
{% macro pagination_nav(page,max_pageno,view) %}
<nav aria-label="pagination" id="pages">
+ <div class="links">
{% if page > 1 %}
<a href="{{url_for(view,**kwargs)}}" aria-label="first page">&lt;&lt; first</a>
<a href="{{url_for(view,page=page-1,**kwargs)}}" aria-label="previous page">&lt; prev</a>
+ {% else %}
+ <a aria-label="first page">&lt;&lt; first</a>
+ <a aria-label="previous page">&lt; prev</a>
{% endif %}
- page {{page}} of {{max_pageno}}
- {% if page < max_pageno %} {# > #}
+ </div>
+ <div class="pageno"><span id="the-word-page">page </span>{{page}} of {{max_pageno}}</div>
+ <div class="links">
+ {% if page < max_pageno %}
<a href="{{url_for(view,page=page+1,**kwargs)}}" aria-label="next page">next &gt;</a>
<a href="{{url_for(view,page=max_pageno,**kwargs)}}" aria-label="last page">last &gt;&gt;</a>
+ {% else %}
+ <a aria-label="next page">next &gt;</a>
+ <a aria-label="last page">last &gt;&gt;</a>
{% endif %}
+ </div>
</nav>
{% endmacro %}