{# Confirmation modal, the Dialog port from shadcn/ui. It covers both
places an "are you sure" prompt appears: an Action's form, and the
list's per-row Delete. One teleported instance backs both, opening on
a window-level `action-confirm-request` event carrying
`{message, onConfirm}`. `onConfirm` is a plain callback because a
form submit and htmx's confirm hook need different follow-through
(`form.submit()` versus `issueRequest(true)`), so the modal stays
agnostic.
The confirmation text is never serialized into a JS or HTML string:
it arrives as an attribute value or as htmx's own event detail, and
is handed to the modal through a CustomEvent as a live JS value,
never re-embedded into markup. #}
{# Assigning the callback straight from the event in one statement
makes Alpine invoke it immediately rather than store it: the modal
would flash open with the action already done. Routing it through a
plain local first avoids that. #}