profiles: add address management, user edit, fix form redirect

- Add type (Mailing/Billing/Shipping) and isDefault fields to Address
  schema with migration. Unique default enforced server-side.
- Rewrite profiles page with inline address creation form and
  editable user name/email within the profile modal.
- Add upsertAddress and updateUser form actions.
- Fix form redirect by adding use:enhance to AdminForm.
- Disable Update button in AdminForm until a field is changed
  (prevents accidental submissions).
This commit is contained in:
NeilClack
2026-07-07 13:20:35 -05:00
parent faacbab1de
commit 38347f5f24
10 changed files with 1162 additions and 3 deletions
@@ -0,0 +1,3 @@
-- AlterTable
ALTER TABLE "Address" ADD COLUMN "isDefault" BOOLEAN NOT NULL DEFAULT false,
ADD COLUMN "type" TEXT NOT NULL DEFAULT 'Mailing';