forked from mirrors/bookwyrm
display import books in a row
This commit is contained in:
parent
772ba1840b
commit
8d7ded1c69
3 changed files with 42 additions and 30 deletions
|
@ -607,3 +607,7 @@ a .icon {
|
|||
position: absolute;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.book-row .book-cover {
|
||||
float: none;
|
||||
}
|
||||
|
|
|
@ -22,36 +22,8 @@
|
|||
</span>
|
||||
</h2>
|
||||
|
||||
{% if not hide_book and status.mention_books.count %}
|
||||
{% for book in status.mention_books.all|slice:"0:3" %}
|
||||
<div class="book-preview">
|
||||
{% if status.status_type == 'Review' %}
|
||||
{% include 'snippets/book.html' with book=book %}
|
||||
{% else %}
|
||||
{% include 'snippets/book.html' with book=book description=True %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% if not hide_book and status.book%}
|
||||
<div class="book-preview">
|
||||
{% if status.status_type == 'Review' %}
|
||||
{% include 'snippets/book.html' with book=status.book %}
|
||||
{% else %}
|
||||
{% include 'snippets/book.html' with book=status.book description=True %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if status.status_type == 'Review' %}<h4>{{ status.name }}
|
||||
<small>{{ status.rating | stars }} stars, by {% include 'snippets/username.html' with user=status.user %}</small>
|
||||
</h4>{% endif %}
|
||||
{% if status.status_type != 'Update' and status.status_type != 'Boost' %}
|
||||
<blockquote>{{ status.content | safe }}</blockquote>
|
||||
{% endif %}
|
||||
{% if status.status_type == 'Boost' %}
|
||||
{% include 'snippets/status.html' with status=status.boosted_status depth=depth|add:1 %}
|
||||
{% endif %}
|
||||
{% if not max_depth and status.reply_parent or status|replies %}<p><a href="{{ status.absolute_id }}">Thread</a>{% endif %}
|
||||
{% include 'snippets/status_content.html' with status=status %}
|
||||
|
||||
</div>
|
||||
{% if status.status_type != 'Boost' %}
|
||||
{% include 'snippets/interaction.html' with activity=status %}
|
||||
|
|
36
fedireads/templates/snippets/status_content.html
Normal file
36
fedireads/templates/snippets/status_content.html
Normal file
|
@ -0,0 +1,36 @@
|
|||
{% load fr_display %}
|
||||
|
||||
{% if not hide_book and status.mention_books.count %}
|
||||
<div class="row book-row">
|
||||
{% for book in status.mention_books.all|slice:"0:3" %}
|
||||
<div class="book-preview">
|
||||
{% if status.status_type == 'Review' %}
|
||||
{% include 'snippets/book.html' with book=book %}
|
||||
{% else %}
|
||||
{% include 'snippets/book.html' with book=book description=True %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% if not hide_book and status.book%}
|
||||
<div class="book-preview">
|
||||
{% if status.status_type == 'Review' %}
|
||||
{% include 'snippets/book.html' with book=status.book %}
|
||||
{% else %}
|
||||
{% include 'snippets/book.html' with book=status.book description=True %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% if status.status_type == 'Review' %}<h4>{{ status.name }}
|
||||
<small>{{ status.rating | stars }} stars, by {% include 'snippets/username.html' with user=status.user %}</small>
|
||||
</h4>{% endif %}
|
||||
{% if status.status_type != 'Update' and status.status_type != 'Boost' %}
|
||||
<blockquote>{{ status.content | safe }}</blockquote>
|
||||
{% endif %}
|
||||
{% if status.status_type == 'Boost' %}
|
||||
{% include 'snippets/status.html' with status=status.boosted_status %}
|
||||
{% endif %}
|
||||
{% if not max_depth and status.reply_parent or status|replies %}<p><a href="{{ status.absolute_id }}">Thread</a>{% endif %}
|
||||
|
Loading…
Reference in a new issue