mirror of
https://github.com/ae-utbm/sith.git
synced 2026-05-22 08:50:17 +00:00
apply review comments
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
x-init='$notifications.addMany([
|
||||
{%- for message in messages -%}
|
||||
{%- if not message.extra_tags -%}
|
||||
{ tag: {{ message.tags|string|tojson }}, text: {{ message|string|tojson }} },
|
||||
{ tag: "{{ message.tags }}", text: {{ message|string|tojson }} },
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
])'
|
||||
|
||||
@@ -237,14 +237,18 @@
|
||||
clear : optional boolean that controls if notifications should be cleared first. True is the default
|
||||
#}
|
||||
{% if messages %}
|
||||
<div x-init="() => {
|
||||
<div x-init='() => {
|
||||
{%- if clear -%}
|
||||
$notifications.clear();
|
||||
{%- endif -%}
|
||||
$notifications.addMany([
|
||||
{%- for message in messages -%}
|
||||
$notifications.{{ message.tags }}('{{ message }}');
|
||||
{%- if not message.extra_tags -%}
|
||||
{ tag: "{{ message.tags }}", text: {{ message|string|tojson }} },
|
||||
{%- endif -%}
|
||||
{%- endfor -%}
|
||||
}"></div>
|
||||
])
|
||||
}'></div>
|
||||
{% endif %}
|
||||
{% endmacro %}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user