Merge pull request #836 from mouse-reeve/goal-covers

Simplifies reading goal progress covers view
This commit is contained in:
Mouse Reeve 2021-03-31 12:09:55 -07:00 committed by GitHub
commit ca14d1789d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 6 deletions

View file

@ -55,11 +55,9 @@
</h2> </h2>
<div class="columns is-multiline"> <div class="columns is-multiline">
{% for book in goal.books %} {% for book in goal.books %}
<div class="column is-narrow"> <div class="column is-one-fifth">
<div class="box"> <div class="is-clipped">
<a href="{{ book.book.local_path }}"> <a href="{{ book.local_path }}">{% include 'snippets/book_cover.html' with book=book.book %}</a>
{% include 'discover/small-book.html' with book=book.book rating=goal.ratings %}
</a>
</div> </div>
</div> </div>
{% endfor %} {% endfor %}

View file

@ -1,7 +1,7 @@
{% load bookwyrm_tags %} {% load bookwyrm_tags %}
<div class="cover-container is-{{ size }}"> <div class="cover-container is-{{ size }}">
{% if book.cover %} {% if book.cover %}
<img class="book-cover" src="/images/{{ book.cover }}" alt="{{ book.alt_text }}"> <img class="book-cover" src="/images/{{ book.cover }}" alt="{{ book.alt_text }}" title="{{ book.alt_text }}">
{% else %} {% else %}
<div class="no-cover book-cover"> <div class="no-cover book-cover">
<img class="book-cover" src="/static/images/no_cover.jpg" alt="No cover"> <img class="book-cover" src="/static/images/no_cover.jpg" alt="No cover">