Small changes to get blocktrans to work as expected in move code

This commit is contained in:
Mouse Reeve 2023-11-01 17:19:57 -07:00
parent 621cfa7ed2
commit 2137737d9b
3 changed files with 10 additions and 11 deletions

View file

@ -1,6 +1,5 @@
{% extends 'layout.html' %} {% extends 'layout.html' %}
{% load i18n %} {% load i18n %}
{% load utilities %}
{% block title %}{% trans "Updates" %}{% endblock %} {% block title %}{% trans "Updates" %}{% endblock %}

View file

@ -23,14 +23,14 @@
<div class="notification is-warning"> <div class="notification is-warning">
<p> <p>
{% id_to_username request.user.moved_to as username %} {% id_to_username request.user.moved_to as username %}
{% blocktrans %} {% blocktrans trimmed with moved_to=user.moved_to %}
<strong>You have moved your account</strong> to <a href="{{user.moved_to}}">{{ username }}</a> <strong>You have moved your account</strong> to <a href="{{ moved_to }}">{{ username }}</a>
{% endblocktrans %} {% endblocktrans %}
</p>
<p class="mt-2">
{% trans "You can undo the move to restore full functionality, but some followers may have already unfollowed this account." %}
</p> </p>
{% blocktrans %}
<p class="mt-2">You can undo the move to restore full functionality, but some followers may have already unfollowed this account.</p>
{% endblocktrans %}
</div> </div>
</div> </div>
<div class="columns is-justify-content-center"> <div class="columns is-justify-content-center">
@ -49,4 +49,4 @@
</div> </div>
</div> </div>
</div> </div>
</div> </div>

View file

@ -15,14 +15,14 @@
{% block description %} {% block description %}
{% if related_user_moved_to %} {% if related_user_moved_to %}
{% id_to_username request.user.moved_to as username %} {% id_to_username request.user.moved_to as username %}
{% blocktrans %} {% blocktrans trimmed %}
{{ related_user }} has moved to <a href="{{ related_user_moved_to }}">{{ username }}</a> {{ related_user }} has moved to <a href="{{ related_user_moved_to }}">{{ username }}</a>
{% endblocktrans %} {% endblocktrans %}
<div class="row shrink my-2"> <div class="row shrink my-2">
{% include 'snippets/move_user_buttons.html' with group=notification.related_group %} {% include 'snippets/move_user_buttons.html' with group=notification.related_group %}
</div> </div>
{% else %} {% else %}
{% blocktrans %} {% blocktrans trimmed %}
{{ related_user }} has undone their move {{ related_user }} has undone their move
{% endblocktrans %} {% endblocktrans %}
{% endif %} {% endif %}