import { useDeleteSSHKey } from '@/api/account/ssh-keys/queries'; import { Dialog } from '@/components/elements/dialog'; import Code from '@/components/elements/Code'; import { DeleteAction } from '@/components/elements/table/RowActions'; export default function DeleteSSHKeyButton({ name, fingerprint }: { name: string; fingerprint: string }) { const deleteSshKey = useDeleteSSHKey(); const onClick = (close: () => void) => { deleteSshKey.mutate({ body: { fingerprint } }, { onSettled: close }); }; return ( onClick(close)} trigger={({ onClick }) => } > Removing the {name} SSH key will invalidate its usage across the Panel. ); }