export declare type ChartType = 'pie' | 'donut' | 'funnel' | 'pyramid' | 'polar' | 'radar' | 'radarArea' | 'radial' | 'radialBar' | 'bar' | 'column' | 'columnpyramid' | 'line' | 'area' | 'spline' | 'areaspline' | 'scatter' | 'bubble' | 'treemap' | 'heatmap' | 'boxplot' | 'columnrange' | 'arearange' | 'areasplinerange' | 'rangeArea' | 'rangeBar' | 'rangeColumn' | 'map' | string; export declare function values(...values: T[]): DataProvider; export declare function field(name: string): DataProvider; export declare function mapField(name: string, map: Map): DataProvider; export declare function joinFields(separator?: string, ...names: string[]): DataProvider; export declare function combineFields(combiner: (args: any[]) => T, names: string[]): DataProvider; export declare function joinProviders(separator?: string, ...providers: DataProvider[]): DataProvider; export declare function combineProviders(combiner: (args: T[]) => R, ...providers: DataProvider[]): DataProvider; export declare function joiner(separator?: string): (args: any[]) => string; export declare function rangeFields(minName: string, maxName: string): DataProvider; export declare function buildSingleSerieChart(objects: any[], provider: ChartProvider, defaultValue?: Y): CommonChart; export declare function buildChart(objects: any[], provider: ChartProvider, defaultValue?: Y): CommonChart; export declare function distinct(objects: any[], providers: DataProvider[]): T[]; export interface UnitConfig { baseUnit: string; scales: ScaleConfig[]; precision?: number; formatter?: (v: number, selectedUnit: string) => string; } export interface ScaleConfig { unit: string; scale: number; threshold?: number; } export interface ChartProvider { title?: string; subtitle?: string; xtitle?: string; ytitle?: string | string[]; width?: number; height?: number; stacked?: boolean; pivot?: boolean; continue?: boolean; xorder?: Sort; series?: SerieProvider[]; options?: any; showToolbar?: boolean; group?: string; groupSync?: 'all' | 'datazoom' | 'tooltip' | ('datazoom' | 'tooltip')[]; mapEndpoint?: string; mapParam?: string; mapDefaultValue?: string; mapColor?: 'blue' | 'green' | 'purple' | 'orange' | 'grey' | string; mapJoinBy?: [string, string]; yUnit?: string | UnitConfig; } export interface SerieProvider { data: CoordinateProvider; name?: string | DataProvider; stack?: string | DataProvider; color?: string | DataProvider; type?: string | DataProvider; visible?: boolean | DataProvider; unit?: string; yAxisIndex?: number; yAxisConfig?: Record; } export declare type Coordinate2D = { x: XaxisType; y: YaxisType; }; export declare type XaxisType = number | string | Date; export declare type YaxisType = number | number[]; export declare type CoordinateProvider = { x: DataProvider; y: DataProvider; }; export declare type DataProvider = (o: any, idx: number) => T; export declare type Sort = 'asc' | 'desc'; export interface CommonChart { series: CommonSerie[]; categories?: X[]; title?: string; subtitle?: string; xtitle?: string; ytitle?: string | string[]; width?: number; height?: number; pivot?: boolean; continue?: boolean; stacked?: boolean; xorder?: Sort; options?: any; showToolbar?: boolean; } export interface CommonSerie { data: Y[]; name?: string; stack?: string; color?: string; unit?: string; visible?: boolean; type?: string; yAxisIndex?: number; yAxisConfig?: Record; } export declare function naturalFieldComparator(sens: Sort, provider: DataProvider): (o1: any, o2: any) => number; export declare function naturalComparator(sens: Sort): (o1: T, o2: T) => number; export declare function groupByFiled(arr: [], name: string): { [key: string]: T[]; }; export declare function groupBy(arr: [], fn: DataProvider): { [key: string]: T[]; }; export interface ChartView { config: ChartProvider; data: any[]; isLoading?: boolean; canPivot?: boolean; debug?: boolean; }