mirror of
https://github.com/ae-utbm/sith.git
synced 2026-09-09 22:09:14 +00:00
Merge pull request #1481 from ae-utbm/htmx4
Fix bad hx-swap on club list and moderation view
This commit is contained in:
@@ -69,6 +69,7 @@ htmx.registerExtension("aria-busy", {
|
||||
},
|
||||
});
|
||||
|
||||
htmx.config.transitions = true;
|
||||
Object.assign(window, { htmx });
|
||||
|
||||
/**
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
{% if is_fragment %}
|
||||
hx-post="{{ action }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
{% endif %}
|
||||
>{% trans %}Confirm{% endtrans %}</button>
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
{% if is_fragment %}
|
||||
hx-get="{{ previous }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
{% else %}
|
||||
action="window.history.back()"
|
||||
{% endif %}
|
||||
|
||||
@@ -39,13 +39,13 @@
|
||||
<p><button
|
||||
hx-get="{{ url('core:file_moderate', file_id=f.id) }}"
|
||||
hx-target="#content"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
>{% trans %}Moderate{% endtrans %}</button> -
|
||||
{% set current_page = url('core:file_moderation') + "?page=" + page_obj.number | string %}
|
||||
<button
|
||||
hx-get="{{ url('core:file_delete', file_id=f.id) }}?next={{ current_page | urlencode }}&previous={{ current_page | urlencode }}"
|
||||
hx-target="#file-{{ loop.index }}"
|
||||
hx-swap="outerHtml"
|
||||
hx-swap="innerHTML"
|
||||
>{% trans %}Delete{% endtrans %}</button></p>
|
||||
</div>
|
||||
{% endfor %}
|
||||
|
||||
Reference in New Issue
Block a user