import type { ConnectionCheckResponse } from "@/api/types"; import { Button } from "@/components/ui/button"; type Props = { onClick: () => void | Promise; result: ConnectionCheckResponse | null; isPending?: boolean; disabled?: boolean; label?: string; pendingLabel?: string; }; export function ConnectionCheckAction({ onClick, result, isPending = false, disabled = false, label = "Check Connection", pendingLabel = "Checking...", }: Props) { return (
{result ? ( {result.message} ) : null}
); }