From cded3e973dfbcae309b79e486000f6f29d6947be Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Wed, 6 Jul 2022 19:16:14 -0700 Subject: [PATCH] Fixes html on notifications page --- .../notifications/items/follow_request.html | 4 ++ .../templates/notifications/items/layout.html | 46 +++++++++---------- .../templates/notifications/items/report.html | 1 + bookwyrm/templates/search/barcode_modal.html | 4 +- bookwyrm/views/notifications.py | 3 +- 5 files changed, 31 insertions(+), 27 deletions(-) diff --git a/bookwyrm/templates/notifications/items/follow_request.html b/bookwyrm/templates/notifications/items/follow_request.html index 804c35282..320c69e43 100644 --- a/bookwyrm/templates/notifications/items/follow_request.html +++ b/bookwyrm/templates/notifications/items/follow_request.html @@ -3,6 +3,10 @@ {% load i18n %} {% load utilities %} +{% block primary_link %}{% spaceless %} +{% url 'user-followers' request.user.localname %} +{% endspaceless %}{% endblock %} + {% block icon %} {% endblock %} diff --git a/bookwyrm/templates/notifications/items/layout.html b/bookwyrm/templates/notifications/items/layout.html index b19f87edd..3830e7e40 100644 --- a/bookwyrm/templates/notifications/items/layout.html +++ b/bookwyrm/templates/notifications/items/layout.html @@ -27,31 +27,29 @@ {% endif %}
-

- {% if related_user_count == 1 %} - {% with user=related_users.first %} - {% spaceless %} - - {% include 'snippets/avatar.html' with user=user %} - - {% endspaceless %} - {% endwith %} - {% endif %} + {% if related_user_count == 1 %} + {% with user=related_users.first %} + {% spaceless %} + + {% include 'snippets/avatar.html' with user=user %} + + {% endspaceless %} + {% endwith %} + {% endif %} - {% with related_user=related_users.first.display_name %} - {% with related_user_link=related_users.first.local_path %} - {% with second_user=related_users.1.display_name %} - {% with second_user_link=related_users.1.local_path %} - {% with other_user_count=related_user_count|add:"-1" %} - {% with other_user_display_count=other_user_count|intcomma %} - {% block description %}{% endblock %} - {% endwith %} - {% endwith %} - {% endwith %} - {% endwith %} - {% endwith %} - {% endwith %} -

+ {% with related_user=related_users.first.display_name %} + {% with related_user_link=related_users.first.local_path %} + {% with second_user=related_users.1.display_name %} + {% with second_user_link=related_users.1.local_path %} + {% with other_user_count=related_user_count|add:"-1" %} + {% with other_user_display_count=other_user_count|intcomma %} + {% block description %}{% endblock %} + {% endwith %} + {% endwith %} + {% endwith %} + {% endwith %} + {% endwith %} + {% endwith %}
{% if related_status %} diff --git a/bookwyrm/templates/notifications/items/report.html b/bookwyrm/templates/notifications/items/report.html index 5e95a685c..44756ce16 100644 --- a/bookwyrm/templates/notifications/items/report.html +++ b/bookwyrm/templates/notifications/items/report.html @@ -3,6 +3,7 @@ {% load i18n %} {% block primary_link %}{% spaceless %} +{% url 'settings-reports' %} {% endspaceless %}{% endblock %} {% block icon %} diff --git a/bookwyrm/templates/search/barcode_modal.html b/bookwyrm/templates/search/barcode_modal.html index 07e95f59e..70481b20a 100644 --- a/bookwyrm/templates/search/barcode_modal.html +++ b/bookwyrm/templates/search/barcode_modal.html @@ -16,11 +16,11 @@ - +