Merge pull request #534 from mouse-reeve/post-release-ui-fixes

UI fixes for latest release
This commit is contained in:
Mouse Reeve 2021-01-18 12:54:37 -08:00 committed by GitHub
commit 043c1f75a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 8 additions and 5 deletions

View file

@ -247,7 +247,7 @@ class AnnualGoal(BookWyrmModel):
''' the books you've read this year '''
return self.user.readthrough_set.filter(
finish_date__year__gte=self.year
).order_by('finish_date').all()
).order_by('-finish_date').all()
@property

View file

@ -4,10 +4,12 @@
{% endblock %}
</header>
{% if not status or status.status_type != 'GeneratedNote' or status.book or status.mention_books.exists or status.mention_users.exists %}
<section class="card-content">
{% block card-content %}
{% endblock %}
</section>
{% endif %}
<footer class="card-footer has-background-white-bis">
{% block card-footer %}

View file

@ -4,11 +4,12 @@
{% with book.id|uuid as uuid %}
{% active_shelf book as active_shelf %}
<div class="field has-addons">
{% if switch_mode and active_shelf.book != book %}
<div class="control">
{% if switch_mode and active_shelf.book != book %}
{% include 'snippets/switch_edition_button.html' with edition=book size='is-small' %}
{% else %}
</div>
{% else %}
<div class="control">
{% if active_shelf.shelf.identifier == 'read' %}
<button class="button is-small" disabled>
<span>Read</span> <span class="icon icon-check"></span>

View file

@ -1,5 +1,5 @@
<form name="switch-edition" action="/switch-edition" method="POST">
{% csrf_token %}
<input type="hidden" name="edition" value="{{ edition.id }}">
<button class="button {{ size }}">Switch to this edition</button>
<button type="submit" class="button {{ size }}">Switch to this edition</button>
</form>