"use client" import { AreaChartIcon, BarChartBigIcon, HexagonIcon, LineChartIcon, MousePointer2Icon, PieChartIcon, RadarIcon, } from "lucide-react" import { cn } from "@/lib/utils" import { ChartCodeViewer } from "@/components/chart-code-viewer" import { ChartCopyButton } from "@/components/chart-copy-button" import { Chart } from "@/components/chart-display" import { Separator } from "@/registry/new-york-v4/ui/separator" export function ChartToolbar({ chart, className, children, }: { chart: Chart } & React.ComponentProps<"div">) { return (
{children}
) } function ChartTitle({ chart }: { chart: Chart }) { if (chart.name.includes("charts-line")) { return ( <> Line Chart ) } if (chart.name.includes("chart-bar")) { return ( <> Bar Chart ) } if (chart.name.includes("chart-pie")) { return ( <> Pie Chart ) } if (chart.name.includes("chart-area")) { return ( <> Area Chart ) } if (chart.name.includes("chart-radar")) { return ( <> Radar Chart ) } if (chart.name.includes("chart-radial")) { return ( <> Radial Chart ) } if (chart.name.includes("chart-tooltip")) { return ( <> Tooltip ) } return chart.name }