"use client"; import { Fragment, type ReactNode } from "react"; import classNames from "@calcom/ui/classNames"; import { PanelCard } from "@calcom/ui/components/card"; import { Tooltip } from "@calcom/ui/components/tooltip"; type LegendItem = { label: string; color: string; // hex format }; export type LegendSize = "sm" | "default"; export function ChartCard({ title, subtitle, cta, legend, legendSize, children, }: { title: string | ReactNode; subtitle?: string; cta?: { label: string; onClick: () => void }; legend?: Array; legendSize?: LegendSize; children: ReactNode; }) { const legendComponent = legend && legend.length > 0 ? : null; return ( {children} ); } export function ChartCardItem({ count, className, children, }: { count?: number | string; className?: string; children: ReactNode; }) { return (
{children}
{count !== undefined &&
{count}
}
); } function Legend({ items, size = "default" }: { items: LegendItem[]; size?: LegendSize }) { return (
{items.map((item, index) => (

{item.label}

{index < items.length - 1 &&
} ))}
); }