A bunch of cosmetic tweaks; add an index page
[books.alexwlchan.net] / templates / review.html
1 {% extends "base.html" %}
2
3 {% block content %}
4   {% if review_entry.book.cover_image %}
5     <div class="book-cover">
6       {% set book = review_entry.book %}
7       {% include "_book_cover.html" %}
8     </div>
9   {% endif %}
10
11   <h1>My review of <span class="book-title">{{ review_entry.book.title }}</span></h1>
12
13   <table class="book_metadata">
14     <tr>
15       <td>author:</td>
16       <th>{{ review_entry.book.author }}
17         {%- if review_entry.book.publication_year %}
18           ({{ review_entry.book.publication_year}})
19         {%- endif -%}
20       </th>
21     </tr>
22     <tr>
23       <td>rating:</td>
24       <th>
25         {% for _ in range(review_entry.review.rating) %}
26         ★
27         {% endfor %}
28         {% for _ in range(5 - review_entry.review.rating) %}
29         ☆
30         {% endfor %}
31       </th>
32     </tr>
33     <tr>
34       <td>date read:</td>
35       <th>{{ review_entry.review.date_read | render_date }}</th>
36     </tr>
37   </table>
38
39   {{ review_entry.review.text | render_markdown | safe }}
40
41   <p>(see <a href="/reviews">all reviews</a>)</p>
42 {% endblock %}