summaryrefslogtreecommitdiffstats
path: root/templates
diff options
context:
space:
mode:
authorAndrew Godwin2022-12-05 19:54:47 -0700
committerAndrew Godwin2022-12-05 19:54:47 -0700
commite2d28a4be08ccc629def8c85327b657b0bf36f90 (patch)
tree4929ed303b0545fc5b5848f23dee74dbbbcad1f8 /templates
parentf22869693a04080c3953a904ffa99e9b317d1736 (diff)
downloadtakahe-e2d28a4be08ccc629def8c85327b657b0bf36f90.tar.gz
takahe-e2d28a4be08ccc629def8c85327b657b0bf36f90.tar.bz2
takahe-e2d28a4be08ccc629def8c85327b657b0bf36f90.zip
Add pagination and search to federation page
Diffstat (limited to 'templates')
-rw-r--r--templates/admin/federation.html14
1 files changed, 13 insertions, 1 deletions
diff --git a/templates/admin/federation.html b/templates/admin/federation.html
index 1a48176..98ee09d 100644
--- a/templates/admin/federation.html
+++ b/templates/admin/federation.html
@@ -3,8 +3,12 @@
{% block subtitle %}Federation{% endblock %}
{% block content %}
+ <form action="." class="search">
+ <input type="search" name="query" value="{{ query }}" placeholder="Search by domain">
+ <button><i class="fa-solid fa-search"></i></button>
+ </form>
<section class="icon-menu">
- {% for domain in domains %}
+ {% for domain in page_obj %}
<a class="option" href="{{ domain.urls.edit_federation }}">
<i class="fa-solid fa-globe"></i>
<span class="handle">
@@ -20,5 +24,13 @@
{% empty %}
<p class="option empty">There are no federation links yet.</p>
{% endfor %}
+ <div class="load-more">
+ {% if page_obj.has_previous %}
+ <a class="button" href=".?page={{ page_obj.previous_page_number }}">Previous Page</a>
+ {% endif %}
+ {% if page_obj.has_next %}
+ <a class="button" href=".?page={{ page_obj.next_page_number }}">Next Page</a>
+ {% endif %}
+ </div>
</section>
{% endblock %}