mirror of
https://github.com/eitchtee/WYGIWYH.git
synced 2026-04-25 01:58:54 +02:00
feat: try to keep selected transactions between htmx swaps
This commit is contained in:
@@ -2,7 +2,7 @@
|
|||||||
<div class="transaction d-flex my-1">
|
<div class="transaction d-flex my-1">
|
||||||
{% if not disable_selection %}
|
{% if not disable_selection %}
|
||||||
<label class="px-3 d-flex align-items-center justify-content-center">
|
<label class="px-3 d-flex align-items-center justify-content-center">
|
||||||
<input class="form-check-input" type="checkbox" name="transactions" value="{{ transaction.id }}" aria-label="{% translate 'Select' %}">
|
<input class="form-check-input" type="checkbox" name="transactions" value="{{ transaction.id }}" id="check-{{ transaction.id }}" aria-label="{% translate 'Select' %}" hx-preserve>
|
||||||
</label>
|
</label>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
<div class="tw-border-s-6 tw-border-e-0 tw-border-t-0 tw-border-b-0 border-bottom
|
<div class="tw-border-s-6 tw-border-e-0 tw-border-t-0 tw-border-b-0 border-bottom
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% load i18n %}
|
{% load i18n %}
|
||||||
<div class="tw-sticky tw-bottom-4 tw-left-0 tw-right-0 tw-z-50 tw-hidden mx-auto tw-w-fit" id="actions-bar"
|
<div class="tw-sticky tw-bottom-4 tw-left-0 tw-right-0 tw-z-50 tw-hidden mx-auto tw-w-fit" id="actions-bar"
|
||||||
_="on change from #transactions-list or htmx:afterSettle
|
_="on change from #transactions-list or htmx:afterSettle from window
|
||||||
if no <input[type='checkbox']:checked/> in #transactions-list
|
if no <input[type='checkbox']:checked/> in #transactions-list
|
||||||
add .tw-hidden to #actions-bar
|
add .tw-hidden to #actions-bar
|
||||||
else
|
else
|
||||||
|
|||||||
Reference in New Issue
Block a user