2020-12-12 21:25:04 -05:00
{% load bookwyrm_tags %}
2020-03-27 11:10:04 -04:00
{% if request.user.is_authenticated %}
2020-02-21 19:26:52 -05:00
2020-11-16 19:34:26 -05:00
{% with book.id|uuid as uuid %}
2020-11-20 13:05:37 -05:00
{% active_shelf book as active_shelf %}
2021-01-17 13:40:40 -05:00
< div class = "field has-addons" >
2021-01-18 15:25:26 -05:00
{% if switch_mode and active_shelf.book != book %}
2021-01-17 13:40:40 -05:00
< div class = "control" >
{% include 'snippets/switch_edition_button.html' with edition=book size='is-small' %}
2021-01-18 15:25:26 -05:00
< / div >
{% else %}
< div class = "control" >
2021-01-30 14:43:40 -05:00
{% include 'snippets/shelve_button_options.html' with class="shelf-option is-small" shelves=request.user.shelf_set.all active_shelf=active_shelf %}
2021-01-18 15:25:26 -05:00
< / div >
2021-01-17 19:48:05 -05:00
{% include 'snippets/shelve_button_dropdown.html' with class="is-small" button_uuid=uuid%}
2020-12-16 17:45:35 -05:00
{% endif %}
2020-11-05 19:48:15 -05:00
< / div >
2021-01-17 13:10:59 -05:00
{% include 'snippets/start_reading_modal.html' with book=active_shelf.book controls_text="start-reading" controls_uid=uuid %}
{% latest_read_through book request.user as readthrough %}
{% include 'snippets/finish_reading_modal.html' with book=active_shelf.book controls_text="finish-reading" controls_uid=uuid readthrough=readthrough %}
2020-11-16 19:34:26 -05:00
{% endwith %}
2020-03-27 11:10:04 -04:00
{% endif %}