forked from mirrors/bookwyrm
97 lines
3.5 KiB
HTML
97 lines
3.5 KiB
HTML
{% extends 'layout.html' %}
|
|
{% load fr_display %}
|
|
{% block content %}
|
|
|
|
<div class="columns">
|
|
<div class="column is-one-third">
|
|
<h2 class="title is-5">Your books</h2>
|
|
{% if not suggested_books %}
|
|
<p>There are no books here right now! Try searching for a book to get started</p>
|
|
{% else %}
|
|
<div class="tabs is-small">
|
|
<ul>
|
|
{% for shelf in suggested_books %}
|
|
{% if shelf.books.count %}
|
|
{% with shelf_counter=forloop.counter %}
|
|
<li>
|
|
<p>{{ shelf.name }}</p>
|
|
<div class="tabs is-small is-toggle">
|
|
<ul>
|
|
{% for book in shelf.books %}
|
|
<li class="{% if shelf_counter == 1 and forloop.first %}is-active{% endif %}" data-id="tab-book-{{ book.id }}">
|
|
<label for="book-{{ book.id }}" onclick="tabChange(event)"><a>{% include 'snippets/book_cover.html' with book=book size="medium" %}</a></label>
|
|
</li>
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
</li>
|
|
{% endwith %}
|
|
{% endif %}
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
{% for shelf in suggested_books %}
|
|
{% with shelf_counter=forloop.counter %}
|
|
{% for book in shelf.books %}
|
|
<div>
|
|
<input class="toggle-control" type="radio" name="recent-books" id="book-{{ book.id }}" {% if shelf_counter == 1 and forloop.first %}checked{% endif %}>
|
|
<div class="toggle-content hidden">
|
|
<div class="block">
|
|
{% include 'snippets/book_titleby.html' with book=book %}
|
|
{% include 'snippets/shelve_button.html' with book=book %}
|
|
</div>
|
|
{% include 'snippets/create_status.html' with book=book %}
|
|
</div>
|
|
</div>
|
|
{% endfor %}
|
|
{% endwith %}
|
|
{% endfor %}
|
|
{% endif %}
|
|
</div>
|
|
|
|
<div class="column is-two-thirds" id="feed">
|
|
<div class="tabs">
|
|
<ul>
|
|
<li class="{% if tab == 'home' %}is-active{% endif %}">
|
|
<a href="/#feed">Home</a>
|
|
</li>
|
|
<li class="{% if tab == 'local' %}is-active{% endif %}">
|
|
<a href="/local#feed">Local</a>
|
|
</li>
|
|
<li class="{% if tab == 'federated' %}is-active{% endif %}">
|
|
<a href="/federated#feed">Federated</a>
|
|
</li>
|
|
</ul>
|
|
</div>
|
|
|
|
{% if not activities %}
|
|
<p>There aren't any activities right now! Try following a user to get started</p>
|
|
{% endif %}
|
|
{% for activity in activities %}
|
|
<div class="block">
|
|
{% include 'snippets/status.html' with status=activity %}
|
|
</div>
|
|
{% endfor %}
|
|
|
|
<nav class="pagination" role="navigation" aria-label="pagination">
|
|
{% if prev %}
|
|
<p class="pagination-previous">
|
|
<a href="{{ prev }}">
|
|
<span class="icon icon-arrow-left"></span>
|
|
Previous
|
|
</a>
|
|
</p>
|
|
{% endif %}
|
|
|
|
{% if next %}
|
|
<p class="pagination-next">
|
|
<a href="{{ next }}">
|
|
Next
|
|
<span class="icon icon-arrow-right"></span>
|
|
</a>
|
|
</p>
|
|
{% endif %}
|
|
</nav>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|