@mui/x-charts
Version:
The community edition of MUI X Charts components.
13 lines • 856 B
TypeScript
import { type ChartPlugin } from "../../models/index.js";
import type { UseChartSeriesState, UseChartSeriesSignature } from "./useChartSeries.types.js";
import { type ChartSeriesType } from "../../../../models/seriesType/config.js";
import type { SeriesItemIdentifier, SeriesItemIdentifierWithType, SeriesId } from "../../../../models/seriesType/index.js";
type RetrunedType<SeriesType extends ChartSeriesType, Item> = Item extends SeriesItemIdentifier<SeriesType> ? SeriesItemIdentifierWithType<SeriesType> : Item & {
type: SeriesType;
};
export declare function createIdentifierWithType(state: UseChartSeriesState): <SeriesType extends ChartSeriesType, Item extends {
seriesId: SeriesId;
type?: SeriesType;
}>(identifier: Item) => RetrunedType<SeriesType, Item>;
export declare const useChartSeries: ChartPlugin<UseChartSeriesSignature>;
export {};