import { type IPreparedExecution } from "@gooddata/sdk-backend-spi"; import { type IBucket } from "@gooddata/sdk-model"; import { type IBucketChartProps, type ICoreChartProps } from "../../interfaces/chartProps.js"; /** * Defines all the functions needed to render a chart. */ export interface IChartDefinition { chartName: string; /** * Function that may do initial transformation of the props. The returned props will then be used in * all following steps. If this function is not specified, then the props will be passed as-is. */ propTransformation?: (props: TProps) => TProps; /** * Function converting bucket props to the relevant buckets. */ bucketsFactory: (props: TBucketProps) => IBucket[]; /** * All the keys in the chart BucketProps interface. */ bucketPropsKeys: Array; /** * Function creating an execution from props and buckets. */ executionFactory: (props: TProps, buckets: IBucket[]) => IPreparedExecution; /** * Function creating prop overrides from props and buckets (e.g. custom config). */ propOverridesFactory?: (props: TProps, buckets: IBucket[]) => Partial; /** * Place to put any side-effectful functions, like validation of props to show a warning etc. */ onBeforePropsConversion?: (props: TProps) => void; } export declare const getCoreChartProps: (chart: IChartDefinition) => (props: TProps) => ICoreChartProps; //# sourceMappingURL=chartDefinition.d.ts.map