moviewyrm/bookwyrm/templates/snippets/status/status_header.html

44 lines
2.2 KiB
HTML
Raw Normal View History

2020-12-13 02:25:04 +00:00
{% load bookwyrm_tags %}
2021-02-28 02:48:10 +00:00
{% load i18n %}
2021-03-07 16:42:30 +00:00
<a href="{{ status.user.local_path }}">
{% include 'snippets/avatar.html' with user=status.user ariaHide="true" %}
2021-03-07 18:24:46 +00:00
{{ status.user.display_name }}
2021-03-07 16:42:30 +00:00
</a>
2020-04-01 21:55:32 +00:00
2020-11-02 19:46:23 +00:00
{% if status.status_type == 'GeneratedNote' %}
{{ status.content | safe }}
{% elif status.status_type == 'Rating' %}
2021-02-28 02:48:10 +00:00
{% trans "rated" %}
2020-11-02 19:46:23 +00:00
{% elif status.status_type == 'Review' %}
2021-02-28 02:48:10 +00:00
{% trans "reviewed" %}
2020-11-02 19:46:23 +00:00
{% elif status.status_type == 'Comment' %}
2021-02-28 02:48:10 +00:00
{% trans "commented on" %}
2020-11-02 19:46:23 +00:00
{% elif status.status_type == 'Quotation' %}
2021-02-28 02:48:10 +00:00
{% trans "quoted" %}
2020-11-02 19:46:23 +00:00
{% elif status.reply_parent %}
{% with parent_status=status|parent %}
2021-03-07 18:24:46 +00:00
{% 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 %}
2020-11-02 19:46:23 +00:00
{% endwith %}
{% endif %}
{% if status.book %}
<a href="/book/{{ status.book.id }}">{{ status.book.title }}</a>
{% elif status.mention_books %}
<a href="/book/{{ status.mention_books.first.id }}">{{ status.mention_books.first.title }}</a>
{% endif %}
2021-03-21 01:03:20 +00:00
{% if status.progress %}
<p class="help">
({% if status.progress_mode == 'PG' %}page {{ status.progress }}{%else %}{{ status.progress }}%{% endif %})
</p>
{% endif %}