UNPKG

@mui/x-charts

Version:

The community edition of MUI X Charts components.

11 lines 764 B
import type { SeriesLegendItemParams } from "../ChartsLegend/index.js"; import type { ChartSeriesDefaultized, ChartSeriesType } from "../models/seriesType/config.js"; import type { SeriesProcessorResult } from "./plugins/corePlugins/useChartSeriesConfig/types/seriesProcessor.types.js"; type SeriesTypeWithLegendFields = { [T in ChartSeriesType]: ChartSeriesDefaultized<T> extends { label?: unknown; labelMarkType?: unknown; color: string; } ? T : never }[ChartSeriesType]; /** One legend item per series (bar, scatter, rangeBar, radar). */ export declare function getSeriesLegendItems<T extends SeriesTypeWithLegendFields>(type: T, params: SeriesProcessorResult<T>, defaultMarkType?: SeriesLegendItemParams['markType']): SeriesLegendItemParams[]; export {};