import React, { useState } from "react"; import { motion, AnimatePresence } from "framer-motion"; import { Download, Braces, FileCode2, Check, Share2, FileJson, Copy, Mail, Link2, } from "lucide-react"; import { Button } from "@/components/ui/button"; import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuSeparator, DropdownMenuTrigger, } from "@/components/ui/dropdown-menu"; import { cn } from "@/lib/utils"; export default function ExportButtons({ isComplete }) { const [downloading, setDownloading] = useState(null); const [copied, setCopied] = useState(false); const handleDownload = (format) => { setDownloading(format); // Simulate download setTimeout(() => { setDownloading(null); }, 1500); }; const handleCopyLink = () => { setCopied(true); setTimeout(() => setCopied(false), 2000); }; if (!isComplete) return null; return ( {/* JSON Download */} {/* XML Download */} {/* More Options Dropdown */} {copied ? ( ) : ( )} {copied ? "Link copied!" : "Copy share link"} Copy to clipboard Send via email Export to Google Sheets ); }