v0.11.11 updated user suspend/delete rules

This commit is contained in:
2026-03-21 18:55:07 -04:00
parent 253bc1f963
commit 9245c6032b
5 changed files with 43 additions and 17 deletions

View File

@@ -1,6 +1,6 @@
{
"name": "jama-frontend",
"version": "0.11.10",
"version": "0.11.11",
"private": true,
"scripts": {
"dev": "vite",

View File

@@ -63,7 +63,7 @@ function UserRow({ u, onUpdated }) {
};
const handleDelete = async () => {
if (u.role === 'admin') return toast('Demote to member before deleting an admin', 'error');
if (!confirm(`Delete ${u.name}? Their messages will remain but they cannot log in.`)) return;
if (!confirm(`Delete ${u.name}?\n\nThis will:\n• Anonymise their account and free their email for re-use\n• Remove all their messages from conversations\n• Freeze any direct messages they were part of\n• Remove all their group memberships\n\nThis cannot be undone.`)) return;
try { await api.deleteUser(u.id); toast('User deleted', 'success'); onUpdated(); }
catch (e) { toast(e.message, 'error'); }
};