mirror of
https://github.com/spiral-project/ihatemoney.git
synced 2025-04-28 17:32:38 +02:00
Avoid HTML markup in translation strings
This commit is contained in:
parent
7d26870975
commit
bff44ae415
3 changed files with 13 additions and 14 deletions
|
@ -103,18 +103,17 @@
|
||||||
{% if current_log_pref == LoggingMode.DISABLED or (current_log_pref != LoggingMode.RECORD_IP and any_ip_addresses) %}
|
{% if current_log_pref == LoggingMode.DISABLED or (current_log_pref != LoggingMode.RECORD_IP and any_ip_addresses) %}
|
||||||
<div id="history_warnings" class="card card-body bg-light">
|
<div id="history_warnings" class="card card-body bg-light">
|
||||||
{% if current_log_pref == LoggingMode.DISABLED %}
|
{% if current_log_pref == LoggingMode.DISABLED %}
|
||||||
<p>{% set url = url_for(".edit_project") %}
|
<p>
|
||||||
{% trans %}
|
<i>{{ _("This project has history disabled. New actions won't appear below.") }}
|
||||||
<i>This project has history disabled. New actions won't appear below. You can enable history on the</i>
|
<a href="{{ url_for(".edit_project") }}">{{ _("You can enable history on the settings page.") }}</a>
|
||||||
<a href="{{ url }}">settings page</a>
|
</i>
|
||||||
{% endtrans %}
|
|
||||||
</p>
|
</p>
|
||||||
{% if history %}
|
{% if history %}
|
||||||
<p>
|
<p>
|
||||||
{% trans %}
|
<i>{{ _("The table below reflects actions recorded prior to disabling project history.") }}
|
||||||
<i>The table below reflects actions recorded prior to disabling project history. You can
|
<a href="#" data-toggle="modal" data-keyboard="false" data-target="#confirm-erase">{{ _("You can clear the project history to remove them.") }}</a>
|
||||||
<a href="#" data-toggle="modal" data-keyboard="false" data-target="#confirm-erase">clear project history</a> to remove them.</i></p>
|
</i>
|
||||||
{% endtrans %}
|
</p>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% if current_log_pref != LoggingMode.RECORD_IP and any_ip_addresses %}
|
{% if current_log_pref != LoggingMode.RECORD_IP and any_ip_addresses %}
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
<tr>
|
<tr>
|
||||||
<td>
|
<td>
|
||||||
<h3>{{ _('Scan QR code') }}</h3>
|
<h3>{{ _('Scan QR code') }}</h3>
|
||||||
<p><small>{% trans download_mobile=url_for(".mobile") %}On a mobile device, with <a href="{{ download_mobile }}">a compatible app installed</a>.{% endtrans %}</small></p>
|
<p><small><a href="{{ url_for(".mobile") }}">{{ _("Use a mobile device with a compatible app.") }}</a></small></p>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
{{ qrcode | safe }}
|
{{ qrcode | safe }}
|
||||||
|
|
|
@ -55,7 +55,7 @@ class HistoryTestCase(IhatemoneyTestCase):
|
||||||
def assert_empty_history_logging_disabled(self):
|
def assert_empty_history_logging_disabled(self):
|
||||||
resp = self.client.get("/demo/history")
|
resp = self.client.get("/demo/history")
|
||||||
self.assertIn(
|
self.assertIn(
|
||||||
"This project has history disabled. New actions won't appear below. ",
|
"This project has history disabled. New actions won't appear below.",
|
||||||
resp.data.decode("utf-8"),
|
resp.data.decode("utf-8"),
|
||||||
)
|
)
|
||||||
self.assertIn("Nothing to list", resp.data.decode("utf-8"))
|
self.assertIn("Nothing to list", resp.data.decode("utf-8"))
|
||||||
|
@ -248,7 +248,7 @@ class HistoryTestCase(IhatemoneyTestCase):
|
||||||
resp = self.client.get("/demo/history")
|
resp = self.client.get("/demo/history")
|
||||||
self.assertEqual(resp.status_code, 200)
|
self.assertEqual(resp.status_code, 200)
|
||||||
self.assertIn(
|
self.assertIn(
|
||||||
"This project has history disabled. New actions won't appear below. ",
|
"This project has history disabled. New actions won't appear below.",
|
||||||
resp.data.decode("utf-8"),
|
resp.data.decode("utf-8"),
|
||||||
)
|
)
|
||||||
self.assertIn(
|
self.assertIn(
|
||||||
|
@ -287,7 +287,7 @@ class HistoryTestCase(IhatemoneyTestCase):
|
||||||
resp = self.client.get("/demo/history")
|
resp = self.client.get("/demo/history")
|
||||||
self.assertEqual(resp.status_code, 200)
|
self.assertEqual(resp.status_code, 200)
|
||||||
self.assertNotIn(
|
self.assertNotIn(
|
||||||
"This project has history disabled. New actions won't appear below. ",
|
"This project has history disabled. New actions won't appear below.",
|
||||||
resp.data.decode("utf-8"),
|
resp.data.decode("utf-8"),
|
||||||
)
|
)
|
||||||
self.assertNotIn(
|
self.assertNotIn(
|
||||||
|
@ -332,7 +332,7 @@ class HistoryTestCase(IhatemoneyTestCase):
|
||||||
|
|
||||||
self.assertEqual(resp.status_code, 200)
|
self.assertEqual(resp.status_code, 200)
|
||||||
self.assertNotIn(
|
self.assertNotIn(
|
||||||
"This project has history disabled. New actions won't appear below. ",
|
"This project has history disabled. New actions won't appear below.",
|
||||||
resp.data.decode("utf-8"),
|
resp.data.decode("utf-8"),
|
||||||
)
|
)
|
||||||
self.assertNotIn(
|
self.assertNotIn(
|
||||||
|
|
Loading…
Reference in a new issue