import { DataPrimitiveFormatter } from '../Formatter'; import { DataType } from '../DataPrimitive'; import { DataFrame } from '../DataFrame'; interface FormatterMapConfig { nameField: string; valueField: string; formatters: { [key: string]: { type: string; config: Record; }; }; } /** * Formatter which accepts a config object containing a map of field-specific formatters. * The field-specific formatter is used to evaluate each fields' corresponding values. * * The three required fields are as follows: * * - `nameField`, which denotes the list of keys with custom formatters to be applied against * * - `valueField`, which denotes the field to derive the values from * * - `formatter1. which is an object that requires the `type` of formatter and the specific required for the specified formatter. * * ```js * primary | seriesByName("pathIds")', // returns ['id1', 'id2'] * areaValues: '> primary | seriesByName("values")', // returns [100, 200] * areaColors: '> primary | multiFormat(areaColorsFormat)' // returns ['#FF0000', '#0000FF'] * }} * dataSources={{ * primary: { * data: { * columns: [['id1', 'id2'], [100, 200]] * fields: [{ name: 'pathIds' }, { name: 'values' }] * } * } * }} * /> * ``` * */ export declare class MultiFormat implements DataPrimitiveFormatter { private readonly config; constructor(formatConfig: FormatterMapConfig); format(f: DataFrame): Record; } export {};