From 806e2778dfe828e27f2d2ce6460434b1bf4d35da Mon Sep 17 00:00:00 2001 From: Hugh Rundle Date: Sun, 12 Jun 2022 19:41:50 +1000 Subject: [PATCH] add help button if page has tour - include logic in main layout to add button if there is a page tour available - add button for main user feed page --- bookwyrm/templates/layout.html | 6 ++++++ bookwyrm/views/feed.py | 1 + 2 files changed, 7 insertions(+) diff --git a/bookwyrm/templates/layout.html b/bookwyrm/templates/layout.html index 6b9e4daa1..426d5cd0b 100644 --- a/bookwyrm/templates/layout.html +++ b/bookwyrm/templates/layout.html @@ -85,6 +85,10 @@ {% trans "Discover" %} + {% if has_tour %} + + {% endif %} {% endif %} @@ -219,6 +223,8 @@ + + {% block scripts %}{% endblock %} diff --git a/bookwyrm/views/feed.py b/bookwyrm/views/feed.py index 2814e9399..eb4678f75 100644 --- a/bookwyrm/views/feed.py +++ b/bookwyrm/views/feed.py @@ -65,6 +65,7 @@ class Feed(View): "filters_applied": filters_applied, "path": f"/{tab['key']}", "annual_summary_year": get_annual_summary_year(), + "has_tour": True, }, } return TemplateResponse(request, "feed/feed.html", data)