This commit is contained in:
giles 2024-09-26 21:39:09 +01:00
parent 4fbf65d2a0
commit 7211d1d1e9
1 changed files with 4 additions and 4 deletions

View File

@ -1,7 +1,7 @@
<div>
<div
hx-get="shop/totals/"
hx-trigger="load delay:1ms"
hx-trigger="every 1ms"
hx-on::config-request="
event.detail.path = !(
new URLSearchParams(window.location.search
@ -15,7 +15,7 @@
id="order-form-rose-ash-shop"
hx-get="shop/order"
hx-swap="outerHTML"
hx-trigger="load delay:1s"
hx-trigger="every 1s"
hx-target="#order-form-rose-ash-shop"
hx-on::config-request="event.detail.path += window.location.search;"
hx-on::confirm="
@ -34,10 +34,10 @@
<div
id="order-detail-rose-ash-shop"
hx-get="shop/order"
hx-trigger="load delay:1ms"
hx-trigger="every 1s"
hx-on::config-request="event.detail.path = new URLSearchParams(window.location.search).get('orderId') ? 'shop/order/' + new URLSearchParams(window.location.search).get('orderId')+ '/' : null; "
hx-on::confirm=" if (!new URLSearchParams(window.location.search).get('orderId')) { event.preventDefault(); }"
hx-swap="innerHTML"
hx-swap="outerHTML"
>
</div>
</div>