mirror of
https://github.com/bookwyrm-social/bookwyrm.git
synced 2024-11-22 17:41:08 +00:00
Use content warnings in notifications
This commit is contained in:
parent
11a0c1691b
commit
be5e1be5f6
1 changed files with 14 additions and 1 deletions
|
@ -1,4 +1,17 @@
|
|||
{% if status.content %}
|
||||
{% load i18n %}
|
||||
{% if status.content_warning %}
|
||||
|
||||
{% trans "Content warning" as text %}
|
||||
<span>
|
||||
<span class="icon icon-warning is-size-5" title="{{ text }}">
|
||||
<span class="is-sr-only">{{ text }}</span>
|
||||
</span>
|
||||
|
||||
<a href="{{ status.local_path }}">
|
||||
{{ status.content_warning }}
|
||||
</a>
|
||||
</span>
|
||||
{% elif status.content %}
|
||||
<a href="{{ status.local_path }}">
|
||||
{{ status.content | safe | truncatewords_html:10 }}{% if status.mention_books %} <em>{{ status.mention_books.first.title }}</em>{% endif %}
|
||||
</a>
|
||||
|
|
Loading…
Reference in a new issue