{% load i18n %} {% load cache %} {% load bookwyrm_tags %} {# 6 month cache #} {% cache 15552000 suggested_books request.user.id %} {% suggested_books as suggested_books %}

{% 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 %}
{% endcache %}