UNPKG

ivt

Version:

Ivt Components Library

56 lines (53 loc) 2.15 kB
import * as react_jsx_runtime from 'react/jsx-runtime'; import * as React from 'react'; import * as RechartsPrimitive from 'recharts'; declare const THEMES: { readonly light: ""; readonly dark: ".dark"; }; type ChartConfig = { [k in string]: { label?: React.ReactNode; icon?: React.ComponentType; } & ({ color?: string; theme?: never; } | { color?: never; theme: Record<keyof typeof THEMES, string>; }); }; declare function ChartContainer({ id, className, children, config, ...props }: React.ComponentProps<"div"> & { config: ChartConfig; children: React.ComponentProps<typeof RechartsPrimitive.ResponsiveContainer>["children"]; }): react_jsx_runtime.JSX.Element; declare const ChartStyle: ({ id, config }: { id: string; config: ChartConfig; }) => react_jsx_runtime.JSX.Element | null; declare const ChartTooltip: typeof RechartsPrimitive.Tooltip; declare function ChartTooltipContent({ active, payload, className, indicator, hideLabel, hideIndicator, label, labelFormatter, labelClassName, formatter, color, nameKey, labelKey, }: Omit<React.ComponentProps<typeof RechartsPrimitive.Tooltip>, "payload"> & React.ComponentProps<"div"> & { payload?: Array<{ name?: string; dataKey?: string; value?: any; color?: string; payload?: Record<string, any>; [key: string]: any; }>; hideLabel?: boolean; hideIndicator?: boolean; indicator?: "line" | "dot" | "dashed"; nameKey?: string; labelKey?: string; label?: string; }): react_jsx_runtime.JSX.Element | null; declare const ChartLegend: typeof RechartsPrimitive.Legend; declare function ChartLegendContent({ className, hideIcon, payload, verticalAlign, nameKey, }: React.ComponentProps<"div"> & { payload?: RechartsPrimitive.LegendPayload[]; verticalAlign?: RechartsPrimitive.LegendProps["verticalAlign"]; hideIcon?: boolean; nameKey?: string; }): react_jsx_runtime.JSX.Element | null; export { ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent }; export type { ChartConfig };