Always expand content status on single status view

On the feed view along with other statuses, the body will be trimmed,
but on the single view, there's no need to trim it. This preserves the
logic for spoiler alerts.
This commit is contained in:
Christof Dorner 2023-02-04 12:50:10 +01:00
parent d94b9f9e30
commit 6af1be28f3
4 changed files with 4 additions and 6 deletions

View file

@ -30,7 +30,7 @@
{% endif %}
{% endfor %}
<div class="is-main block">
{% include 'snippets/status/status.html' with status=status main=True %}
{% include 'snippets/status/status.html' with status=status main=True expand=True %}
</div>
{% for child in children %}

View file

@ -6,9 +6,8 @@
{% if status_type == 'GeneratedNote' or status_type == 'Rating' %}
{% include 'snippets/status/generated_status.html' with status=status %}
{% else %}
{% include 'snippets/status/content_status.html' with status=status %}
{% include 'snippets/status/content_status.html' with status=status expand=expand %}
{% endif %}
{% endwith %}
{% endblock %}

View file

@ -109,7 +109,7 @@
{% endif %}
{% if status.content and status_type != 'GeneratedNote' and status_type != 'Announce' %}
{% with full=status.content|safe no_trim=status.content_warning itemprop="reviewBody" %}
{% with full=status.content|safe no_trim=status.content_warning|default:expand itemprop="reviewBody" %}
{% include 'snippets/trimmed_text.html' %}
{% endwith %}
{% endif %}
@ -155,4 +155,3 @@
</div>
{% endwith %}

View file

@ -10,6 +10,6 @@
{% trans "boosted" %}
{% include 'snippets/status/body.html' with status=status|boosted_status %}
{% else %}
{% include 'snippets/status/body.html' with status=status %}
{% include 'snippets/status/body.html' with status=status expand=expand %}
{% endif %}
{% endif %}