From bca0a1f32c73428f7545c26f57d3a5452864bd48 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Tue, 18 Feb 2020 23:03:04 -0800 Subject: [PATCH] Snippet for book covers Fixes #20 --- fedireads/templates/snippets/book.html | 2 +- fedireads/templates/snippets/book_cover.html | 1 + fedireads/templates/user.html | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 fedireads/templates/snippets/book_cover.html diff --git a/fedireads/templates/snippets/book.html b/fedireads/templates/snippets/book.html index eec9b357d..8bdcd7af1 100644 --- a/fedireads/templates/snippets/book.html +++ b/fedireads/templates/snippets/book.html @@ -1,5 +1,5 @@ {% load fr_display %} - +{% include 'snippets/book_cover.html' with book=book %}

{{ book.data.title }}

diff --git a/fedireads/templates/snippets/book_cover.html b/fedireads/templates/snippets/book_cover.html new file mode 100644 index 000000000..02d1447ac --- /dev/null +++ b/fedireads/templates/snippets/book_cover.html @@ -0,0 +1 @@ + diff --git a/fedireads/templates/user.html b/fedireads/templates/user.html index 6093fe03d..27b2f7e9d 100644 --- a/fedireads/templates/user.html +++ b/fedireads/templates/user.html @@ -89,7 +89,7 @@ {% for book in shelf.books.all %} - + {% include 'snippets/book_cover.html' with book=book %} {{ book.data.title }}