2025-01-19 17:31:46 +00:00
|
|
|
import { X } from 'lucide-react';
|
2024-12-31 10:30:14 +05:30
|
|
|
import Code from '~/components/Code';
|
|
|
|
|
import Dialog from '~/components/Dialog';
|
2024-05-15 21:52:19 -04:00
|
|
|
|
|
|
|
|
interface Props {
|
2024-12-31 10:30:14 +05:30
|
|
|
username: string;
|
2024-05-15 21:52:19 -04:00
|
|
|
}
|
|
|
|
|
|
2024-10-10 10:03:21 -04:00
|
|
|
export default function Remove({ username }: Props) {
|
2024-05-15 21:52:19 -04:00
|
|
|
return (
|
2025-01-26 15:04:13 -05:00
|
|
|
<Dialog>
|
|
|
|
|
<Dialog.IconButton label={`Delete ${username}`}>
|
2025-01-19 17:31:46 +00:00
|
|
|
<X className="p-0.5" />
|
2025-01-26 15:04:13 -05:00
|
|
|
</Dialog.IconButton>
|
|
|
|
|
<Dialog.Panel>
|
|
|
|
|
<Dialog.Title>Delete {username}?</Dialog.Title>
|
|
|
|
|
<Dialog.Text className="mb-8">
|
|
|
|
|
Are you sure you want to delete {username}? A deleted user cannot be
|
|
|
|
|
recovered.
|
|
|
|
|
</Dialog.Text>
|
|
|
|
|
<input type="hidden" name="_method" value="delete" />
|
|
|
|
|
<input type="hidden" name="username" value={username} />
|
|
|
|
|
</Dialog.Panel>
|
|
|
|
|
</Dialog>
|
2024-12-31 10:30:14 +05:30
|
|
|
);
|
2024-05-15 21:52:19 -04:00
|
|
|
}
|