@mui/x-charts
Version:
The community edition of MUI X Charts components.
14 lines • 812 B
TypeScript
import type { ChartSeriesType } from "../../../../models/seriesType/config.js";
import type { ChartSeriesConfig } from "../../models/index.js";
/**
* Serializes a series item identifier into a unique string using the appropriate serializer
* from the provided series configuration.
*
* @param {ChartSeriesConfig<ChartSeriesType>} seriesConfig - The configuration object for chart series.
* @param {SeriesItemIdentifier<ChartSeriesType>} identifier - The series item identifier to serialize.
* @returns {string} A unique string representation of the identifier.
* @throws Will throw an error if no serializer is found for the given series type.
*/
export declare const serializeIdentifier: <T extends ChartSeriesType, U extends {
type: T;
}>(seriesConfig: ChartSeriesConfig<T>, identifier: U) => string;