- Created package.json for dependencies and scripts - Added tsconfig.json for TypeScript configuration - Implemented fake stdio MCP server with basic calculator and environment variable printing tools - Added shell script to run the fake stdio MCP server - Updated root tsconfig.json for project references and path mapping
53 lines
1.5 KiB
TypeScript
53 lines
1.5 KiB
TypeScript
import {
|
|
AlertDialog,
|
|
AlertDialogAction,
|
|
AlertDialogCancel,
|
|
AlertDialogContent,
|
|
AlertDialogDescription,
|
|
AlertDialogFooter,
|
|
AlertDialogHeader,
|
|
AlertDialogTitle,
|
|
} from "@/components/ui/alert-dialog";
|
|
|
|
interface DeleteChatDialogProps {
|
|
isOpen: boolean;
|
|
onOpenChange: (open: boolean) => void;
|
|
onConfirmDelete: () => void;
|
|
chatTitle?: string;
|
|
}
|
|
|
|
export function DeleteChatDialog({
|
|
isOpen,
|
|
onOpenChange,
|
|
onConfirmDelete,
|
|
chatTitle,
|
|
}: DeleteChatDialogProps) {
|
|
return (
|
|
<AlertDialog open={isOpen} onOpenChange={onOpenChange}>
|
|
<AlertDialogContent>
|
|
<AlertDialogHeader>
|
|
<AlertDialogTitle>Delete Chat</AlertDialogTitle>
|
|
<AlertDialogDescription>
|
|
Are you sure you want to delete "{chatTitle || "this chat"}"? This
|
|
action cannot be undone and all messages in this chat will be
|
|
permanently lost.
|
|
<br />
|
|
<br />
|
|
<strong>Note:</strong> Any code changes that have already been
|
|
accepted will be kept.
|
|
</AlertDialogDescription>
|
|
</AlertDialogHeader>
|
|
<AlertDialogFooter>
|
|
<AlertDialogCancel>Cancel</AlertDialogCancel>
|
|
<AlertDialogAction
|
|
onClick={onConfirmDelete}
|
|
className="bg-red-600 text-white hover:bg-red-700 dark:bg-red-600 dark:text-white dark:hover:bg-red-700"
|
|
>
|
|
Delete Chat
|
|
</AlertDialogAction>
|
|
</AlertDialogFooter>
|
|
</AlertDialogContent>
|
|
</AlertDialog>
|
|
);
|
|
}
|