forked from mirrors/bookwyrm
Move footer some items to header
- Header elements are now enclosed in a media layout - Footer elements are not in a card-footer anymore
This commit is contained in:
parent
58aeb72afa
commit
13957c2f44
2 changed files with 81 additions and 76 deletions
|
@ -13,7 +13,7 @@
|
||||||
{% block card-content %}{% endblock %}
|
{% block card-content %}{% endblock %}
|
||||||
|
|
||||||
{% block card-footer %}
|
{% block card-footer %}
|
||||||
<div class="card-footer-item">
|
<div class="card-content pt-0">
|
||||||
{% if moderation_mode and perms.bookwyrm.moderate_post %}
|
{% if moderation_mode and perms.bookwyrm.moderate_post %}
|
||||||
|
|
||||||
{# moderation options #}
|
{# moderation options #}
|
||||||
|
@ -55,19 +55,6 @@
|
||||||
</a>
|
</a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="card-footer-item">
|
|
||||||
{% include 'snippets/privacy-icons.html' with item=status %}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="card-footer-item">
|
|
||||||
<a href="{{ status.remote_id }}">{{ status.published_date | post_date }}</a>
|
|
||||||
</div>
|
|
||||||
{% if not moderation_mode %}
|
|
||||||
<div class="card-footer-item">
|
|
||||||
{% include 'snippets/status/status_options.html' with class="is-small" right=True %}
|
|
||||||
</div>
|
|
||||||
{% endif %}
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -1,72 +1,90 @@
|
||||||
{% load bookwyrm_tags %}
|
{% load bookwyrm_tags %}
|
||||||
{% load i18n %}
|
{% load i18n %}
|
||||||
<span
|
|
||||||
itemprop="author"
|
|
||||||
itemscope
|
|
||||||
itemtype="https://schema.org/Person"
|
|
||||||
>
|
|
||||||
<a
|
|
||||||
href="{{ status.user.local_path }}"
|
|
||||||
itemprop="url"
|
|
||||||
>
|
|
||||||
{% include 'snippets/avatar.html' with user=status.user ariaHide="true" %}
|
|
||||||
|
|
||||||
<span itemprop="name">{{ status.user.display_name }}</span>
|
<div class="media">
|
||||||
</a>
|
<figure class="media-left">
|
||||||
</span>
|
<a class="image is-48x48" href="{{ status.user.local_path }}">
|
||||||
|
{% include 'snippets/avatar.html' with user=status.user ariaHide="true" medium="true" %}
|
||||||
|
</a>
|
||||||
|
</figure>
|
||||||
|
|
||||||
{% if status.status_type == 'GeneratedNote' %}
|
<div class="media-content">
|
||||||
{{ status.content | safe }}
|
<p class="is-size-7">
|
||||||
{% elif status.status_type == 'Rating' %}
|
<a href="{{ status.remote_id }}">{{ status.published_date | post_date }}</a>
|
||||||
{% trans "rated" %}
|
{% include 'snippets/privacy-icons.html' with item=status %}
|
||||||
{% elif status.status_type == 'Review' %}
|
</p>
|
||||||
{% trans "reviewed" %}
|
|
||||||
{% elif status.status_type == 'Comment' %}
|
|
||||||
{% trans "commented on" %}
|
|
||||||
{% elif status.status_type == 'Quotation' %}
|
|
||||||
{% trans "quoted" %}
|
|
||||||
{% elif status.reply_parent %}
|
|
||||||
{% with parent_status=status|parent %}
|
|
||||||
|
|
||||||
{% if parent_status.status_type == 'Review' %}
|
|
||||||
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">review</a>{% endblocktrans %}
|
|
||||||
{% elif parent_status.status_type == 'Comment' %}
|
|
||||||
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">comment</a>{% endblocktrans %}
|
|
||||||
{% elif parent_status.status_type == 'Quotation' %}
|
|
||||||
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">quote</a>{% endblocktrans %}
|
|
||||||
{% else %}
|
|
||||||
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">status</a>{% endblocktrans %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% endwith %}
|
|
||||||
{% endif %}
|
|
||||||
|
|
||||||
{% if status.book %}
|
|
||||||
{% if status.status_type == 'GeneratedNote' or status.status_type == 'Rating' %}
|
|
||||||
<a href="/book/{{ status.book.id }}">{{ status.book.title }}</a>{% if status.status_type == 'Rating' %}:
|
|
||||||
<span
|
<span
|
||||||
itemprop="reviewRating"
|
itemprop="author"
|
||||||
itemscope
|
itemscope
|
||||||
itemtype="https://schema.org/Rating"
|
itemtype="https://schema.org/Person"
|
||||||
>
|
>
|
||||||
<span class="is-hidden" {{ rating_type }}>
|
<a
|
||||||
<meta itemprop="ratingValue" content="{{ status.rating|floatformat }}">
|
href="{{ status.user.local_path }}"
|
||||||
|
itemprop="url"
|
||||||
{# @todo Is it possible to not hard-code the value? #}
|
>
|
||||||
<meta itemprop="bestRating" content="5">
|
<span itemprop="name">{{ status.user.display_name }}</span>
|
||||||
|
</a>
|
||||||
</span>
|
</span>
|
||||||
|
|
||||||
{% include 'snippets/stars.html' with rating=status.rating %}
|
{% if status.status_type == 'GeneratedNote' %}
|
||||||
{% endif %}
|
{{ status.content | safe }}
|
||||||
{% else %}
|
{% elif status.status_type == 'Rating' %}
|
||||||
{% include 'snippets/book_titleby.html' with book=status.book %}
|
{% trans "rated" %}
|
||||||
{% endif %}
|
{% elif status.status_type == 'Review' %}
|
||||||
{% elif status.mention_books %}
|
{% trans "reviewed" %}
|
||||||
<a href="/book/{{ status.mention_books.first.id }}">{{ status.mention_books.first.title }}</a>
|
{% elif status.status_type == 'Comment' %}
|
||||||
{% endif %}
|
{% trans "commented on" %}
|
||||||
|
{% elif status.status_type == 'Quotation' %}
|
||||||
|
{% trans "quoted" %}
|
||||||
|
{% elif status.reply_parent %}
|
||||||
|
{% with parent_status=status|parent %}
|
||||||
|
|
||||||
|
{% if parent_status.status_type == 'Review' %}
|
||||||
|
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">review</a>{% endblocktrans %}
|
||||||
|
{% elif parent_status.status_type == 'Comment' %}
|
||||||
|
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">comment</a>{% endblocktrans %}
|
||||||
|
{% elif parent_status.status_type == 'Quotation' %}
|
||||||
|
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">quote</a>{% endblocktrans %}
|
||||||
|
{% else %}
|
||||||
|
{% blocktrans with username=parent_status.user.display_name user_path=parent_status.user.local_path status_path=parent_status.local_path %}replied to <a href="{{ user_path }}">{{ username}}'s</a> <a href="{{ status_path }}">status</a>{% endblocktrans %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% endwith %}
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if status.book %}
|
||||||
|
{% if status.status_type == 'GeneratedNote' or status.status_type == 'Rating' %}
|
||||||
|
<a href="/book/{{ status.book.id }}">{{ status.book.title }}</a>{% if status.status_type == 'Rating' %}:
|
||||||
|
<span
|
||||||
|
itemprop="reviewRating"
|
||||||
|
itemscope
|
||||||
|
itemtype="https://schema.org/Rating"
|
||||||
|
>
|
||||||
|
<span class="is-hidden" {{ rating_type }}>
|
||||||
|
<meta itemprop="ratingValue" content="{{ status.rating|floatformat }}">
|
||||||
|
|
||||||
|
{# @todo Is it possible to not hard-code the value? #}
|
||||||
|
<meta itemprop="bestRating" content="5">
|
||||||
|
</span>
|
||||||
|
|
||||||
|
{% include 'snippets/stars.html' with rating=status.rating %}
|
||||||
|
{% endif %}
|
||||||
|
{% else %}
|
||||||
|
{% include 'snippets/book_titleby.html' with book=status.book %}
|
||||||
|
{% endif %}
|
||||||
|
{% elif status.mention_books %}
|
||||||
|
<a href="/book/{{ status.mention_books.first.id }}">{{ status.mention_books.first.title }}</a>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{% if status.progress %}
|
||||||
|
<p class="help">
|
||||||
|
({% if status.progress_mode == 'PG' %}
|
||||||
|
{% include 'snippets/page_text.html' with page=status.progress total_pages=status.book.pages %}
|
||||||
|
{% else %}
|
||||||
|
{{ status.progress }}%
|
||||||
|
{% endif %})
|
||||||
|
</p>
|
||||||
|
{% endif %}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
{% if status.progress %}
|
|
||||||
<p class="help">
|
|
||||||
({% if status.progress_mode == 'PG' %}{% include 'snippets/page_text.html' with page=status.progress total_pages=status.book.pages %}{% else %}{{ status.progress }}%{% endif %})
|
|
||||||
</p>
|
|
||||||
{% endif %}
|
|
||||||
|
|
Loading…
Reference in a new issue