From 99fbe827c921f9ac80f9d4ab1d71a49650069bfa Mon Sep 17 00:00:00 2001 From: Commander1024 Date: Sun, 16 Aug 2020 11:56:13 +0200 Subject: [PATCH] Changed pagination template to show disabled nav elements. --- lostplaces/lostplaces_app/static/main.css | 2 ++ .../templates/partials/nav/pagination.html | 14 ++++++++++++++ 2 files changed, 16 insertions(+) diff --git a/lostplaces/lostplaces_app/static/main.css b/lostplaces/lostplaces_app/static/main.css index 782faa4..8f90181 100644 --- a/lostplaces/lostplaces_app/static/main.css +++ b/lostplaces/lostplaces_app/static/main.css @@ -264,6 +264,8 @@ body { flex-direction: row; } .LP-Pagination .LP-Pagination__Item { margin: 0 4px; } + .LP-Pagination .LP-Pagination__Item--disabled { + color: #b6b6b6; } .LP-Pagination .LP-Pagination__Item--current .LP-Link { background-color: #D7CEC7; border-radius: 2px; } diff --git a/lostplaces/lostplaces_app/templates/partials/nav/pagination.html b/lostplaces/lostplaces_app/templates/partials/nav/pagination.html index 8f2efc0..5b62df2 100644 --- a/lostplaces/lostplaces_app/templates/partials/nav/pagination.html +++ b/lostplaces/lostplaces_app/templates/partials/nav/pagination.html @@ -8,6 +8,13 @@
  • previous
  • + {% else %} +
  • + first +
  • +
  • + previous +
  • {% endif %} {% for i in page_obj.paginator %} {% if i.number == page_obj.number %} @@ -25,6 +32,13 @@
  • last
  • + {% else %} +
  • + next +
  • +
  • + last +
  • {% endif %}