import type { ReactNode } from 'react'; import type { CSSProperties } from 'react'; import type { SxProp } from '../Layout/sx.cjs'; import type { Aggregate } from './chartScale.cjs'; export interface BarSeries { /** Key into each datum for this series' value. */ key: string; /** Legend / tooltip label. Defaults to `key`. */ label?: string; /** Override the series color. */ color?: string; } export interface BarChartProps = Record> { data: D[]; /** Key for the category label on the x-axis. */ xKey: string; series: BarSeries[]; height?: number; /** Accessible label for the chart (svg `aria-label` + hidden table caption). */ label?: string; /** Stack the series instead of grouping them side by side. */ stacked?: boolean; grid?: boolean; legend?: boolean; /** Clicking a legend entry hides / shows that series. Default `true`. */ legendToggle?: boolean; /** Content shown instead of the chart when there is no data. Default "No data". */ empty?: ReactNode; /** * Max bars drawn. More categories than this are aggregated into contiguous buckets * (labelled "first – last"). Default: as many as fit at ~6px each. */ maxBars?: number; /** How bucketed categories combine when `maxBars` kicks in. Default `'sum'`. */ aggregate?: Aggregate; /** Entrance animation (and smooth transitions when data changes). Default `true`; off under reduced motion and for very large charts. */ animate?: boolean; /** Format y-axis tick values. Default compact (1.2K, 3M). */ yTickFormatter?: (value: number) => string; /** Format x-axis category labels. */ xTickFormatter?: (value: string) => string; /** Custom tooltip body for a hovered category. */ renderTooltip?: (params: { label: string; datum: D; }) => ReactNode; className?: string; style?: CSSProperties; /** * One-off CSS, same as `Box`'s `sx`: each value may be a scalar or a * responsive breakpoint map (`{ base, sm, md, lg, xl }`). Scalar-only sx * merges into inline style; responsive sx injects a scoped class. Applied to * the chart's outer container. */ sx?: SxProp; } export declare function BarChart>({ data: dataProp, xKey, series: allSeries, height, label, stacked, grid, legend, legendToggle, empty, maxBars, aggregate, animate, yTickFormatter, xTickFormatter, renderTooltip, className, style, sx, }: BarChartProps): import("react/jsx-runtime").JSX.Element;