"use client" import * as React from "react" import { MoreHorizontal } from "lucide-react" import { toast } from "sonner" import { AlertDialog, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogTitle, } from "@/registry/new-york-v4/ui/alert-dialog" import { Button } from "@/registry/new-york-v4/ui/button" import { Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, } from "@/registry/new-york-v4/ui/dialog" import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuSeparator, DropdownMenuTrigger, } from "@/registry/new-york-v4/ui/dropdown-menu" import { Label } from "@/registry/new-york-v4/ui/label" import { Switch } from "@/registry/new-york-v4/ui/switch" export function PresetActions() { const [open, setIsOpen] = React.useState(false) const [showDeleteDialog, setShowDeleteDialog] = React.useState(false) return ( <> Actions setIsOpen(true)}> Content filter preferences setShowDeleteDialog(true)} className="text-red-600" > Delete preset Content filter preferences The content filter flags text that may violate our content policy. It's powered by our moderation endpoint which is free to use to moderate your OpenAI API traffic. Learn more. Playground Warnings Show a warning when content is flagged A warning will be shown when sexual, hateful, violent or self-harm content is detected. Close Are you absolutely sure? This action cannot be undone. This preset will no longer be accessible by you or others you've shared it with. Cancel { setShowDeleteDialog(false) toast.success("This preset has been deleted.") }} > Delete > ) }