forked from mirrors/bookwyrm
Flatten and rework sidebar update
This commit is contained in:
parent
32346cf9a3
commit
edba55f7c2
2 changed files with 25 additions and 29 deletions
|
@ -47,17 +47,11 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-content">
|
<div class="card-content">
|
||||||
<div class="columns is-gapless">
|
{% include 'snippets/shelve_button.html' with book=book %}
|
||||||
<div class="column is-narrow">
|
{% active_shelf book as active_shelf %}
|
||||||
{% include 'snippets/shelve_button.html' with book=book %}
|
{% if active_shelf.shelf.identifier == 'reading' and book.latest_readthrough %}
|
||||||
</div>
|
{% include 'snippets/progress_update.html' with readthrough=book.latest_readthrough %}
|
||||||
{% active_shelf book as active_shelf %}
|
{% endif %}
|
||||||
{% if active_shelf.shelf.identifier == 'reading' and book.latest_readthrough %}
|
|
||||||
<div class="column">
|
|
||||||
{% include 'snippets/progress_update.html' with readthrough=book.latest_readthrough %}
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
</div>
|
|
||||||
{% include 'snippets/create_status.html' with book=book %}
|
{% include 'snippets/create_status.html' with book=book %}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -1,25 +1,27 @@
|
||||||
<form class="field is-grouped is-small pl-2" action="/edit-readthrough" method="POST">
|
<form class="field is-grouped is-small" action="/edit-readthrough" method="POST">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<input type="hidden" name="id" value="{{ readthrough.id }}"/>
|
<input type="hidden" name="id" value="{{ readthrough.id }}"/>
|
||||||
|
<label class="label is-align-self-center mb-0 pr-2" for="progress">Currently at</label>
|
||||||
<div class="control">
|
<div class="control">
|
||||||
{% if readthrough.progress_mode == 'PG' %}
|
<div class="field has-addons">
|
||||||
on page
|
<div class="control">
|
||||||
{% else %}
|
<input
|
||||||
currently at
|
aria-label="{% if readthrough.progress_mode == 'PG' %}Current page{% else %}Percent read{% endif %}"
|
||||||
{% endif %}
|
class="input is-small" type="number"
|
||||||
|
name="progress" size="3" value="{{ readthrough.progress|default:'' }}">
|
||||||
|
</div>
|
||||||
|
<div class="control">
|
||||||
|
<a class="button is-small is-static">
|
||||||
|
{% if readthrough.progress_mode == 'PG' %}
|
||||||
|
pages
|
||||||
|
{% else %}
|
||||||
|
%
|
||||||
|
{% endif %}
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="control">
|
<div class="control">
|
||||||
<input
|
<button class="button is-small px-2" type="submit">Save</button>
|
||||||
aria-label="{% if readthrough.progress_mode == 'PG' %}Current page{% else %}Percent read{% endif %}"
|
|
||||||
class="input is-small" type="text"
|
|
||||||
name="progress" size="3" value="{{ readthrough.progress|default:'' }}">
|
|
||||||
</div>
|
|
||||||
<div class="control">
|
|
||||||
{% if readthrough.progress_mode == 'PG' %}
|
|
||||||
{% if book.pages %} of {{ book.pages }} {% endif %}
|
|
||||||
{% else %} % {% endif %}
|
|
||||||
</div>
|
|
||||||
<div class="control">
|
|
||||||
<button class="button is-small px-2" type="submit">Go</button>
|
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
Loading…
Reference in a new issue