Replace native confirm() dialogs with styled confirm modals.
Deploy Ladill Servers / deploy (push) Successful in 29s

Add shared confirm-dialog component, Alpine ladillConfirm store, and
swap browser confirms for consistent bottom-sheet modals across user,
admin, and hosting flows.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-06-07 21:11:10 +00:00
co-authored by Cursor
parent b5513283da
commit 29cdfe67b8
21 changed files with 499 additions and 85 deletions
+13 -4
View File
@@ -74,10 +74,19 @@
<div class="mt-4 rounded-2xl border border-rose-200 bg-white p-5">
<h2 class="text-sm font-semibold text-rose-700">Delete mailbox</h2>
<p class="mt-0.5 text-xs text-slate-400">This permanently removes the mailbox and its email.</p>
<form method="POST" action="{{ route('email.mailboxes.destroy', $mailbox['id']) }}" class="mt-3" onsubmit="return confirm('Delete {{ $mailbox['address'] }}? This cannot be undone.')">
@csrf @method('DELETE')
<button class="rounded-lg bg-rose-600 px-4 py-2 text-sm font-semibold text-white hover:bg-rose-700">Delete mailbox</button>
</form>
<x-confirm-dialog
:name="'delete-mailbox-'.$mailbox['id']"
title="Delete mailbox?"
:message="'Delete '.$mailbox['address'].'? This cannot be undone.'"
:action="route('email.mailboxes.destroy', $mailbox['id'])"
method="DELETE"
confirm-label="Delete mailbox"
class="mt-3"
>
<x-slot:trigger>
<button type="button" class="rounded-lg bg-rose-600 px-4 py-2 text-sm font-semibold text-white hover:bg-rose-700">Delete mailbox</button>
</x-slot:trigger>
</x-confirm-dialog>
</div>
</div>
@endsection