diff --git a/bookwyrm/templates/feed/direct_messages.html b/bookwyrm/templates/feed/direct_messages.html index 0b7dcd79c..30a50cd0a 100644 --- a/bookwyrm/templates/feed/direct_messages.html +++ b/bookwyrm/templates/feed/direct_messages.html @@ -1,4 +1,4 @@ -{% extends 'feed/feed_layout.html' %} +{% extends 'feed/layout.html' %} {% load i18n %} {% block panel %} diff --git a/bookwyrm/templates/feed/feed.html b/bookwyrm/templates/feed/feed.html index 21e71ae18..44ee5c930 100644 --- a/bookwyrm/templates/feed/feed.html +++ b/bookwyrm/templates/feed/feed.html @@ -1,4 +1,4 @@ -{% extends 'feed/feed_layout.html' %} +{% extends 'feed/layout.html' %} {% load i18n %} {% block panel %} diff --git a/bookwyrm/templates/feed/feed_layout.html b/bookwyrm/templates/feed/feed_layout.html deleted file mode 100644 index 3c6b65a1b..000000000 --- a/bookwyrm/templates/feed/feed_layout.html +++ /dev/null @@ -1,107 +0,0 @@ -{% extends 'layout.html' %} -{% load i18n %} - -{% block title %}{% trans "Updates" %}{% endblock %} - -{% block content %} -
- {% if user.is_authenticated %} -
-

{% trans "Your books" %}

- {% if not suggested_books %} -

{% trans "There are no books here right now! Try searching for a book to get started" %}

- {% else %} - {% with active_book=request.GET.book %} -
-
-
    - {% for shelf in suggested_books %} - {% if shelf.books %} - {% with shelf_counter=forloop.counter %} -
  • -

    - {% if shelf.identifier == 'to-read' %}{% trans "To Read" %} - {% elif shelf.identifier == 'reading' %}{% trans "Currently Reading" %} - {% elif shelf.identifier == 'read' %}{% trans "Read" %} - {% else %}{{ shelf.name }}{% endif %} -

    -
    - -
    -
  • - {% endwith %} - {% endif %} - {% endfor %} -
-
- {% for shelf in suggested_books %} - {% with shelf_counter=forloop.counter %} - {% for book in shelf.books %} -
- -
-
-
-

{% include 'snippets/book_titleby.html' with book=book %}

- {% include 'snippets/shelve_button/shelve_button.html' with book=book %} -
-
-
- {% trans "Close" as button_text %} - {% include 'snippets/toggle/toggle_button.html' with label=button_text controls_text="book" controls_uid=book.id class="delete" nonbutton=True pressed=True %} -
-
-
- {% include 'snippets/create_status.html' with book=book %} -
-
- {% endfor %} - {% endwith %} - {% endfor %} -
- {% endwith %} - {% endif %} - - {% if goal %} -
-
-

{% blocktrans with yar=goal.year %}{{ year }} Reading Goal{% endblocktrans %}

- {% include 'snippets/goal_progress.html' with goal=goal %} -
-
- {% endif %} -
- {% endif %} - -
- {% block panel %}{% endblock %} - - {% if activities %} - {% include 'snippets/pagination.html' with page=activities path=path anchor="#feed" %} - {% endif %} -
-
-{% endblock %} - -{% block scripts %} - -{% endblock %} diff --git a/bookwyrm/templates/feed/layout.html b/bookwyrm/templates/feed/layout.html new file mode 100644 index 000000000..57305df72 --- /dev/null +++ b/bookwyrm/templates/feed/layout.html @@ -0,0 +1,109 @@ +{% extends 'layout.html' %} +{% load i18n %} + +{% block title %}{% trans "Updates" %}{% endblock %} + +{% block content %} +
+ {% if user.is_authenticated %} +
+
+

{% trans "Your books" %}

+ {% if not suggested_books %} +

{% trans "There are no books here right now! Try searching for a book to get started" %}

+ {% else %} + {% with active_book=request.GET.book %} +
+
+
    + {% for shelf in suggested_books %} + {% if shelf.books %} + {% with shelf_counter=forloop.counter %} +
  • +

    + {% if shelf.identifier == 'to-read' %}{% trans "To Read" %} + {% elif shelf.identifier == 'reading' %}{% trans "Currently Reading" %} + {% elif shelf.identifier == 'read' %}{% trans "Read" %} + {% else %}{{ shelf.name }}{% endif %} +

    +
    + +
    +
  • + {% endwith %} + {% endif %} + {% endfor %} +
+
+ {% for shelf in suggested_books %} + {% with shelf_counter=forloop.counter %} + {% for book in shelf.books %} +
+ +
+
+
+

{% include 'snippets/book_titleby.html' with book=book %}

+ {% include 'snippets/shelve_button/shelve_button.html' with book=book %} +
+
+
+ {% trans "Close" as button_text %} + {% include 'snippets/toggle/toggle_button.html' with label=button_text controls_text="book" controls_uid=book.id class="delete" nonbutton=True pressed=True %} +
+
+
+ {% include 'snippets/create_status.html' with book=book %} +
+
+ {% endfor %} + {% endwith %} + {% endfor %} +
+ {% endwith %} + {% endif %} +
+ + {% if goal %} +
+
+

{% blocktrans with yar=goal.year %}{{ year }} Reading Goal{% endblocktrans %}

+ {% include 'snippets/goal_progress.html' with goal=goal %} +
+
+ {% endif %} +
+ {% endif %} + +
+ {% block panel %}{% endblock %} + + {% if activities %} + {% include 'snippets/pagination.html' with page=activities path=path anchor="#feed" %} + {% endif %} +
+
+{% endblock %} + +{% block scripts %} + +{% endblock %} diff --git a/bookwyrm/templates/feed/status.html b/bookwyrm/templates/feed/status.html index 9f90f355d..903ca7907 100644 --- a/bookwyrm/templates/feed/status.html +++ b/bookwyrm/templates/feed/status.html @@ -1,4 +1,4 @@ -{% extends 'feed/feed_layout.html' %} +{% extends 'feed/layout.html' %} {% load i18n %} {% block panel %}