From 0bbf12eaf01e4b8b00afe417ce5a5d25daac3f72 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Mon, 27 Jul 2026 05:25:10 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=8E=A8=20Palette:=20Add=20confirmation=20?= =?UTF-8?q?dialog=20for=20destructive=20ACL=20actions?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: schmug <38227427+schmug@users.noreply.github.com> --- app/components/AclMembersPanel.tsx | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/app/components/AclMembersPanel.tsx b/app/components/AclMembersPanel.tsx index eb618e561..ec2b0d2f9 100644 --- a/app/components/AclMembersPanel.tsx +++ b/app/components/AclMembersPanel.tsx @@ -58,7 +58,15 @@ export function AclMembersPanel({ mailboxId }: AclMembersPanelProps) { variant="secondary" size="sm" loading={lockDown.isPending} - onClick={() => lockDown.mutate(mailboxId)} + onClick={() => { + if ( + window.confirm( + "Are you sure you want to lock down this mailbox? Only you will have access until you add others.", + ) + ) { + lockDown.mutate(mailboxId); + } + }} data-testid="acl-lockdown-btn" > Lock down @@ -89,6 +97,7 @@ export function AclMembersPanel({ mailboxId }: AclMembersPanelProps) { }; const handleRemove = async (email: string) => { + if (!window.confirm(`Are you sure you want to remove ${email}?`)) return; setRemoveError(null); try { await removeMember.mutateAsync(email); @@ -100,6 +109,12 @@ export function AclMembersPanel({ mailboxId }: AclMembersPanelProps) { }; const handleTransfer = async (email: string) => { + if ( + !window.confirm( + `Are you sure you want to transfer ownership to ${email}? You will lose owner privileges.`, + ) + ) + return; setTransferError(null); try { await transferOwnership.mutateAsync(email); @@ -125,6 +140,8 @@ export function AclMembersPanel({ mailboxId }: AclMembersPanelProps) { }; const handleRemoveGroup = async (group: string) => { + if (!window.confirm(`Are you sure you want to remove group ${group}?`)) + return; setRemoveGroupError(null); try { await removeGroup.mutateAsync(group);