@techie_doubts/tui.chart.2026 4.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +165 -0
- package/dist/esm/animator.d.ts +32 -0
- package/dist/esm/animator.js +102 -0
- package/dist/esm/brushes/axis.d.ts +3 -0
- package/dist/esm/brushes/axis.js +21 -0
- package/dist/esm/brushes/basic.d.ts +9 -0
- package/dist/esm/brushes/basic.js +95 -0
- package/dist/esm/brushes/boxPlot.d.ts +2 -0
- package/dist/esm/brushes/boxPlot.js +22 -0
- package/dist/esm/brushes/circleLegend.d.ts +2 -0
- package/dist/esm/brushes/circleLegend.js +26 -0
- package/dist/esm/brushes/dataLabel.d.ts +6 -0
- package/dist/esm/brushes/dataLabel.js +176 -0
- package/dist/esm/brushes/exportMenu.d.ts +2 -0
- package/dist/esm/brushes/exportMenu.js +55 -0
- package/dist/esm/brushes/gauge.d.ts +2 -0
- package/dist/esm/brushes/gauge.js +39 -0
- package/dist/esm/brushes/label.d.ts +34 -0
- package/dist/esm/brushes/label.js +165 -0
- package/dist/esm/brushes/legend.d.ts +7 -0
- package/dist/esm/brushes/legend.js +162 -0
- package/dist/esm/brushes/lineSeries.d.ts +5 -0
- package/dist/esm/brushes/lineSeries.js +41 -0
- package/dist/esm/brushes/polygon.d.ts +2 -0
- package/dist/esm/brushes/polygon.js +24 -0
- package/dist/esm/brushes/resetButton.d.ts +3 -0
- package/dist/esm/brushes/resetButton.js +112 -0
- package/dist/esm/brushes/scatterSeries.d.ts +2 -0
- package/dist/esm/brushes/scatterSeries.js +125 -0
- package/dist/esm/brushes/sector.d.ts +2 -0
- package/dist/esm/brushes/sector.js +54 -0
- package/dist/esm/brushes/spectrumLegend.d.ts +14 -0
- package/dist/esm/brushes/spectrumLegend.js +199 -0
- package/dist/esm/charts/areaChart.d.ts +254 -0
- package/dist/esm/charts/areaChart.js +358 -0
- package/dist/esm/charts/barChart.d.ts +203 -0
- package/dist/esm/charts/barChart.js +300 -0
- package/dist/esm/charts/boxPlotChart.d.ts +209 -0
- package/dist/esm/charts/boxPlotChart.js +288 -0
- package/dist/esm/charts/bubbleChart.d.ts +188 -0
- package/dist/esm/charts/bubbleChart.js +263 -0
- package/dist/esm/charts/bulletChart.d.ts +199 -0
- package/dist/esm/charts/bulletChart.js +278 -0
- package/dist/esm/charts/chart.d.ts +133 -0
- package/dist/esm/charts/chart.js +484 -0
- package/dist/esm/charts/columnChart.d.ts +205 -0
- package/dist/esm/charts/columnChart.js +299 -0
- package/dist/esm/charts/columnLineChart.d.ts +271 -0
- package/dist/esm/charts/columnLineChart.js +386 -0
- package/dist/esm/charts/gaugeChart.d.ts +191 -0
- package/dist/esm/charts/gaugeChart.js +279 -0
- package/dist/esm/charts/heatmapChart.d.ts +199 -0
- package/dist/esm/charts/heatmapChart.js +292 -0
- package/dist/esm/charts/lineAreaChart.d.ts +271 -0
- package/dist/esm/charts/lineAreaChart.js +374 -0
- package/dist/esm/charts/lineChart.d.ts +253 -0
- package/dist/esm/charts/lineChart.js +360 -0
- package/dist/esm/charts/lineScatterChart.d.ts +200 -0
- package/dist/esm/charts/lineScatterChart.js +285 -0
- package/dist/esm/charts/nestedPieChart.d.ts +192 -0
- package/dist/esm/charts/nestedPieChart.js +268 -0
- package/dist/esm/charts/pieChart.d.ts +156 -0
- package/dist/esm/charts/pieChart.js +224 -0
- package/dist/esm/charts/radarChart.d.ts +169 -0
- package/dist/esm/charts/radarChart.js +240 -0
- package/dist/esm/charts/radialBarChart.d.ts +172 -0
- package/dist/esm/charts/radialBarChart.js +251 -0
- package/dist/esm/charts/scatterChart.d.ts +184 -0
- package/dist/esm/charts/scatterChart.js +279 -0
- package/dist/esm/charts/treemapChart.d.ts +166 -0
- package/dist/esm/charts/treemapChart.js +239 -0
- package/dist/esm/component/areaSeries.d.ts +96 -0
- package/dist/esm/component/areaSeries.js +474 -0
- package/dist/esm/component/axis.d.ts +40 -0
- package/dist/esm/component/axis.js +176 -0
- package/dist/esm/component/axisTitle.d.ts +25 -0
- package/dist/esm/component/axisTitle.js +67 -0
- package/dist/esm/component/axisUsingCenterY.d.ts +32 -0
- package/dist/esm/component/axisUsingCenterY.js +175 -0
- package/dist/esm/component/backButton.d.ts +13 -0
- package/dist/esm/component/backButton.js +26 -0
- package/dist/esm/component/background.d.ts +10 -0
- package/dist/esm/component/background.js +15 -0
- package/dist/esm/component/boxPlotSeries.d.ts +126 -0
- package/dist/esm/component/boxPlotSeries.js +410 -0
- package/dist/esm/component/boxSeries.d.ts +211 -0
- package/dist/esm/component/boxSeries.js +603 -0
- package/dist/esm/component/boxStackSeries.d.ts +62 -0
- package/dist/esm/component/boxStackSeries.js +447 -0
- package/dist/esm/component/bubbleSeries.d.ts +35 -0
- package/dist/esm/component/bubbleSeries.js +174 -0
- package/dist/esm/component/bulletSeries.d.ts +89 -0
- package/dist/esm/component/bulletSeries.js +392 -0
- package/dist/esm/component/circleLegend.d.ts +10 -0
- package/dist/esm/component/circleLegend.js +37 -0
- package/dist/esm/component/component.d.ts +64 -0
- package/dist/esm/component/component.js +170 -0
- package/dist/esm/component/componentManager.d.ts +23 -0
- package/dist/esm/component/componentManager.js +45 -0
- package/dist/esm/component/dataLabels.d.ts +23 -0
- package/dist/esm/component/dataLabels.js +134 -0
- package/dist/esm/component/exportMenu.d.ts +38 -0
- package/dist/esm/component/exportMenu.js +147 -0
- package/dist/esm/component/gaugeSeries.d.ts +160 -0
- package/dist/esm/component/gaugeSeries.js +447 -0
- package/dist/esm/component/heatmapSeries.d.ts +64 -0
- package/dist/esm/component/heatmapSeries.js +152 -0
- package/dist/esm/component/hoveredSeries.d.ts +27 -0
- package/dist/esm/component/hoveredSeries.js +95 -0
- package/dist/esm/component/legend.d.ts +26 -0
- package/dist/esm/component/legend.js +149 -0
- package/dist/esm/component/lineSeries.d.ts +69 -0
- package/dist/esm/component/lineSeries.js +319 -0
- package/dist/esm/component/noDataText.d.ts +9 -0
- package/dist/esm/component/noDataText.js +31 -0
- package/dist/esm/component/pieSeries.d.ts +137 -0
- package/dist/esm/component/pieSeries.js +390 -0
- package/dist/esm/component/plot.d.ts +37 -0
- package/dist/esm/component/plot.js +163 -0
- package/dist/esm/component/radarSeries.d.ts +85 -0
- package/dist/esm/component/radarSeries.js +222 -0
- package/dist/esm/component/radialAxis.d.ts +26 -0
- package/dist/esm/component/radialAxis.js +210 -0
- package/dist/esm/component/radialBarSeries.d.ts +111 -0
- package/dist/esm/component/radialBarSeries.js +349 -0
- package/dist/esm/component/radialPlot.d.ts +55 -0
- package/dist/esm/component/radialPlot.js +188 -0
- package/dist/esm/component/rangeSelection.d.ts +61 -0
- package/dist/esm/component/rangeSelection.js +150 -0
- package/dist/esm/component/resetButton.d.ts +13 -0
- package/dist/esm/component/resetButton.js +26 -0
- package/dist/esm/component/scatterSeries.d.ts +34 -0
- package/dist/esm/component/scatterSeries.js +159 -0
- package/dist/esm/component/selectedSeries.d.ts +26 -0
- package/dist/esm/component/selectedSeries.js +109 -0
- package/dist/esm/component/spectrumLegend.d.ts +15 -0
- package/dist/esm/component/spectrumLegend.js +76 -0
- package/dist/esm/component/title.d.ts +12 -0
- package/dist/esm/component/title.js +53 -0
- package/dist/esm/component/tooltip.d.ts +41 -0
- package/dist/esm/component/tooltip.js +131 -0
- package/dist/esm/component/treemapSeries.d.ts +57 -0
- package/dist/esm/component/treemapSeries.js +191 -0
- package/dist/esm/component/zeroAxis.d.ts +9 -0
- package/dist/esm/component/zeroAxis.js +49 -0
- package/dist/esm/eventEmitter.d.ts +8 -0
- package/dist/esm/eventEmitter.js +15 -0
- package/dist/esm/helpers/arrayUtil.d.ts +10 -0
- package/dist/esm/helpers/arrayUtil.js +54 -0
- package/dist/esm/helpers/axes.d.ts +67 -0
- package/dist/esm/helpers/axes.js +345 -0
- package/dist/esm/helpers/boxSeries.d.ts +5 -0
- package/dist/esm/helpers/boxSeries.js +71 -0
- package/dist/esm/helpers/calculator.d.ts +19 -0
- package/dist/esm/helpers/calculator.js +153 -0
- package/dist/esm/helpers/color.d.ts +153 -0
- package/dist/esm/helpers/color.js +218 -0
- package/dist/esm/helpers/colorSpectrum.d.ts +5 -0
- package/dist/esm/helpers/colorSpectrum.js +17 -0
- package/dist/esm/helpers/coordinate.d.ts +9 -0
- package/dist/esm/helpers/coordinate.js +51 -0
- package/dist/esm/helpers/dataLabels.d.ts +36 -0
- package/dist/esm/helpers/dataLabels.js +405 -0
- package/dist/esm/helpers/dom.d.ts +2 -0
- package/dist/esm/helpers/dom.js +8 -0
- package/dist/esm/helpers/downloader.d.ts +7 -0
- package/dist/esm/helpers/downloader.js +287 -0
- package/dist/esm/helpers/formatDate.d.ts +16 -0
- package/dist/esm/helpers/formatDate.js +140 -0
- package/dist/esm/helpers/geometric.d.ts +3 -0
- package/dist/esm/helpers/geometric.js +35 -0
- package/dist/esm/helpers/googleAnalytics.d.ts +1 -0
- package/dist/esm/helpers/googleAnalytics.js +39 -0
- package/dist/esm/helpers/htmlSanitizer.d.ts +1 -0
- package/dist/esm/helpers/htmlSanitizer.js +86 -0
- package/dist/esm/helpers/legend.d.ts +9 -0
- package/dist/esm/helpers/legend.js +47 -0
- package/dist/esm/helpers/pieSeries.d.ts +15 -0
- package/dist/esm/helpers/pieSeries.js +72 -0
- package/dist/esm/helpers/plot.d.ts +2 -0
- package/dist/esm/helpers/plot.js +4 -0
- package/dist/esm/helpers/radarSeries.d.ts +1 -0
- package/dist/esm/helpers/radarSeries.js +7 -0
- package/dist/esm/helpers/range.d.ts +6 -0
- package/dist/esm/helpers/range.js +16 -0
- package/dist/esm/helpers/responders.d.ts +37 -0
- package/dist/esm/helpers/responders.js +197 -0
- package/dist/esm/helpers/sector.d.ts +55 -0
- package/dist/esm/helpers/sector.js +117 -0
- package/dist/esm/helpers/squarifier.d.ts +8 -0
- package/dist/esm/helpers/squarifier.js +110 -0
- package/dist/esm/helpers/style.d.ts +14 -0
- package/dist/esm/helpers/style.js +48 -0
- package/dist/esm/helpers/theme.d.ts +58 -0
- package/dist/esm/helpers/theme.js +557 -0
- package/dist/esm/helpers/tooltip.d.ts +2 -0
- package/dist/esm/helpers/tooltip.js +18 -0
- package/dist/esm/helpers/tooltipTemplate.d.ts +21 -0
- package/dist/esm/helpers/tooltipTemplate.js +147 -0
- package/dist/esm/helpers/utils.d.ts +42 -0
- package/dist/esm/helpers/utils.js +268 -0
- package/dist/esm/helpers/validation.d.ts +6 -0
- package/dist/esm/helpers/validation.js +16 -0
- package/dist/esm/index.d.ts +40 -0
- package/dist/esm/index.js +75 -0
- package/dist/esm/message.d.ts +11 -0
- package/dist/esm/message.js +11 -0
- package/dist/esm/painter.d.ts +27 -0
- package/dist/esm/painter.js +88 -0
- package/dist/esm/responderDetectors.d.ts +6 -0
- package/dist/esm/responderDetectors.js +124 -0
- package/dist/esm/scale/coordinateScaleCalculator.d.ts +24 -0
- package/dist/esm/scale/coordinateScaleCalculator.js +174 -0
- package/dist/esm/scale/datetimeScaleCalculator.d.ts +20 -0
- package/dist/esm/scale/datetimeScaleCalculator.js +59 -0
- package/dist/esm/store/axes.d.ts +30 -0
- package/dist/esm/store/axes.js +282 -0
- package/dist/esm/store/category.d.ts +4 -0
- package/dist/esm/store/category.js +73 -0
- package/dist/esm/store/colorValueScale.d.ts +3 -0
- package/dist/esm/store/colorValueScale.js +56 -0
- package/dist/esm/store/dataRange.d.ts +4 -0
- package/dist/esm/store/dataRange.js +170 -0
- package/dist/esm/store/gaugeAxes.d.ts +4 -0
- package/dist/esm/store/gaugeAxes.js +175 -0
- package/dist/esm/store/heatmapAxes.d.ts +3 -0
- package/dist/esm/store/heatmapAxes.js +98 -0
- package/dist/esm/store/heatmapSeriesData.d.ts +3 -0
- package/dist/esm/store/heatmapSeriesData.js +34 -0
- package/dist/esm/store/layout.d.ts +12 -0
- package/dist/esm/store/layout.js +487 -0
- package/dist/esm/store/legend.d.ts +3 -0
- package/dist/esm/store/legend.js +435 -0
- package/dist/esm/store/nestedPieSeriesData.d.ts +3 -0
- package/dist/esm/store/nestedPieSeriesData.js +49 -0
- package/dist/esm/store/options.d.ts +3 -0
- package/dist/esm/store/options.js +62 -0
- package/dist/esm/store/plot.d.ts +3 -0
- package/dist/esm/store/plot.js +102 -0
- package/dist/esm/store/radialAxes.d.ts +8 -0
- package/dist/esm/store/radialAxes.js +199 -0
- package/dist/esm/store/reactive.d.ts +11 -0
- package/dist/esm/store/reactive.js +196 -0
- package/dist/esm/store/root.d.ts +3 -0
- package/dist/esm/store/root.js +46 -0
- package/dist/esm/store/scale.d.ts +3 -0
- package/dist/esm/store/scale.js +102 -0
- package/dist/esm/store/seriesData.d.ts +3 -0
- package/dist/esm/store/seriesData.js +299 -0
- package/dist/esm/store/stackSeriesData.d.ts +8 -0
- package/dist/esm/store/stackSeriesData.js +192 -0
- package/dist/esm/store/store.d.ts +20 -0
- package/dist/esm/store/store.js +112 -0
- package/dist/esm/store/theme.d.ts +3 -0
- package/dist/esm/store/theme.js +139 -0
- package/dist/esm/store/treemapSeriesData.d.ts +4 -0
- package/dist/esm/store/treemapSeriesData.js +93 -0
- package/dist/td-chart.css +127 -0
- package/dist/td-chart.js +41463 -0
- package/dist/td-chart.min.css +6 -0
- package/dist/td-chart.min.js +9 -0
- package/package.json +112 -0
- package/types/brushes.d.ts +30 -0
- package/types/charts.d.ts +152 -0
- package/types/components/axis.d.ts +71 -0
- package/types/components/circleLegend.d.ts +9 -0
- package/types/components/dataLabels.d.ts +119 -0
- package/types/components/exportMenu.d.ts +14 -0
- package/types/components/legend.d.ts +27 -0
- package/types/components/plot.d.ts +8 -0
- package/types/components/radialAxis.d.ts +22 -0
- package/types/components/radialPlot.d.ts +11 -0
- package/types/components/rangeSelection.d.ts +3 -0
- package/types/components/resetButton.d.ts +13 -0
- package/types/components/series.d.ts +386 -0
- package/types/components/spectrumLegend.d.ts +25 -0
- package/types/components/tooltip.d.ts +58 -0
- package/types/components/zoom.d.ts +3 -0
- package/types/eventEmitter.d.ts +12 -0
- package/types/index.d.ts +615 -0
- package/types/options.d.ts +833 -0
- package/types/resizeObserver.d.ts +54 -0
- package/types/store/store.d.ts +564 -0
- package/types/theme.d.ts +670 -0
|
@@ -0,0 +1,833 @@
|
|
|
1
|
+
import { Categories, RawSeries, Options, StoreModule } from './store/store';
|
|
2
|
+
import { TooltipData, TooltipModel } from './components/tooltip';
|
|
3
|
+
import { ScatterSeriesIconType } from './components/series';
|
|
4
|
+
import {
|
|
5
|
+
AreaChartThemeOptions,
|
|
6
|
+
BaseThemeOptions,
|
|
7
|
+
BubbleChartThemeOptions,
|
|
8
|
+
HeatmapChartThemeOptions,
|
|
9
|
+
LineAreaChartThemeOptions,
|
|
10
|
+
LineChartThemeOptions,
|
|
11
|
+
LineScatterChartThemeOptions,
|
|
12
|
+
NestedPieChartThemeOptions,
|
|
13
|
+
PieChartThemeOptions,
|
|
14
|
+
ScatterChartThemeOptions,
|
|
15
|
+
TooltipTheme,
|
|
16
|
+
TreemapChartThemeOptions,
|
|
17
|
+
RadarChartThemeOptions,
|
|
18
|
+
BoxChartThemeOptions,
|
|
19
|
+
BoxPlotCharThemeOptions,
|
|
20
|
+
BulletCharThemeOptions,
|
|
21
|
+
ColumnLineChartThemeOptions,
|
|
22
|
+
RadialBarChartThemeOptions,
|
|
23
|
+
GaugeChartThemeOptions,
|
|
24
|
+
} from './theme';
|
|
25
|
+
|
|
26
|
+
export type RangeDataType<T> = [T, T];
|
|
27
|
+
export type BoxSeriesDataType = number | RangeDataType<number> | null;
|
|
28
|
+
type LineSeriesDataType = number | Point | [number, number] | [string, number] | null;
|
|
29
|
+
type HeatmapSeriesDataType = (number | null)[];
|
|
30
|
+
export type HeatmapCategoriesType = { x: string[]; y: string[] };
|
|
31
|
+
export type AreaSeriesDataType = number | RangeDataType<number> | null;
|
|
32
|
+
export type Align = 'top' | 'bottom' | 'right' | 'left';
|
|
33
|
+
export interface Point {
|
|
34
|
+
x: number;
|
|
35
|
+
y: number;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export type CoordinateDataType = [number, number] | Point | DatetimePoint;
|
|
39
|
+
type ObjectTypeDatetimePoint = { x: Date; y: number } | { x: string; y: number };
|
|
40
|
+
type TupleTypeDatetimePoint = [string, number] | [Date, number];
|
|
41
|
+
export type DatetimePoint = ObjectTypeDatetimePoint | TupleTypeDatetimePoint;
|
|
42
|
+
export type BubblePoint = (Point | ObjectTypeDatetimePoint) & { r: number };
|
|
43
|
+
export type BubbleSeriesDataType = { label: string } & BubblePoint;
|
|
44
|
+
export type GaugeSeriesDataType = string | number;
|
|
45
|
+
|
|
46
|
+
export type LineTypeEventDetectType = 'near' | 'nearest' | 'grouped' | 'point';
|
|
47
|
+
export type BoxTypeEventDetectType = 'grouped' | 'point';
|
|
48
|
+
export type CircleTypeEventDetectType = 'grouped' | 'point';
|
|
49
|
+
|
|
50
|
+
export type BezierPoint = {
|
|
51
|
+
controlPoint?: {
|
|
52
|
+
next: Point;
|
|
53
|
+
prev: Point;
|
|
54
|
+
};
|
|
55
|
+
} & Point;
|
|
56
|
+
|
|
57
|
+
export interface Size {
|
|
58
|
+
width: number;
|
|
59
|
+
height: number;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export type Rect = Point & Size;
|
|
63
|
+
|
|
64
|
+
export interface AreaSeriesType {
|
|
65
|
+
name: string;
|
|
66
|
+
rawData: AreaSeriesDataType[];
|
|
67
|
+
data: AreaSeriesDataType[];
|
|
68
|
+
color: string;
|
|
69
|
+
visible?: boolean;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export type AreaSeriesInput = Pick<AreaSeriesType, 'name' | 'data' | 'visible'>;
|
|
73
|
+
|
|
74
|
+
export interface AreaSeriesData {
|
|
75
|
+
categories: string[];
|
|
76
|
+
series: AreaSeriesInput[];
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export interface LineSeriesType {
|
|
80
|
+
name: string;
|
|
81
|
+
data: LineSeriesDataType[];
|
|
82
|
+
rawData: LineSeriesDataType[];
|
|
83
|
+
color: string;
|
|
84
|
+
visible?: boolean;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
export type LineSeriesInput = Pick<LineSeriesType, 'name' | 'data' | 'visible'>;
|
|
88
|
+
|
|
89
|
+
export interface LineSeriesData {
|
|
90
|
+
categories?: string[];
|
|
91
|
+
series: LineSeriesInput[];
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export interface HeatmapSeriesType {
|
|
95
|
+
data: HeatmapSeriesDataType;
|
|
96
|
+
yCategory: string;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
export interface TreemapSeriesType {
|
|
100
|
+
label: string;
|
|
101
|
+
data?: number | null;
|
|
102
|
+
colorValue?: number;
|
|
103
|
+
children?: TreemapSeriesType[];
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
export interface TreemapSeriesData {
|
|
107
|
+
series: TreemapSeriesType[];
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
export interface HeatmapSeriesData {
|
|
111
|
+
categories: HeatmapCategoriesType;
|
|
112
|
+
series: HeatmapSeriesDataType[];
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
export interface ScatterSeriesType {
|
|
116
|
+
name: string;
|
|
117
|
+
data: (CoordinateDataType | null)[];
|
|
118
|
+
color: string;
|
|
119
|
+
iconType: ScatterSeriesIconType;
|
|
120
|
+
visible?: boolean;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
export interface LineScatterData {
|
|
124
|
+
series: {
|
|
125
|
+
line: LineSeriesInput[];
|
|
126
|
+
scatter: ScatterSeriesInput[];
|
|
127
|
+
};
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export interface LineAreaData {
|
|
131
|
+
categories: string[];
|
|
132
|
+
series: {
|
|
133
|
+
line: LineSeriesInput[];
|
|
134
|
+
area: AreaSeriesInput[];
|
|
135
|
+
};
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
export interface BubbleSeriesType {
|
|
139
|
+
name: string;
|
|
140
|
+
data: (BubbleSeriesDataType | null)[];
|
|
141
|
+
color: string;
|
|
142
|
+
visible?: boolean;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
export type ScatterSeriesInput = Pick<ScatterSeriesType, 'name' | 'data' | 'visible'>;
|
|
146
|
+
|
|
147
|
+
export interface ScatterSeriesData {
|
|
148
|
+
categories?: string[];
|
|
149
|
+
series: ScatterSeriesInput[];
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
export type BubbleSeriesInput = Pick<BubbleSeriesType, 'name' | 'data' | 'visible'>;
|
|
153
|
+
|
|
154
|
+
export interface BubbleSeriesData {
|
|
155
|
+
series: BubbleSeriesInput[];
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
export type PieSeriesType = {
|
|
159
|
+
name: string;
|
|
160
|
+
data: number | null;
|
|
161
|
+
parentName?: string;
|
|
162
|
+
rootParentName?: string;
|
|
163
|
+
color?: string;
|
|
164
|
+
visible?: boolean;
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
export type PieSeriesData = {
|
|
168
|
+
categories?: string[];
|
|
169
|
+
series: PieSeriesType[];
|
|
170
|
+
};
|
|
171
|
+
|
|
172
|
+
interface TitleOption {
|
|
173
|
+
text: string;
|
|
174
|
+
offsetX?: number;
|
|
175
|
+
offsetY?: number;
|
|
176
|
+
align?: 'left' | 'right' | 'center';
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
type BaseSizeOptions = Partial<Size>;
|
|
180
|
+
|
|
181
|
+
type AnimationOptions = boolean | { duration: number };
|
|
182
|
+
|
|
183
|
+
type ChartSizeInput = number | 'auto';
|
|
184
|
+
|
|
185
|
+
type ChartSize = {
|
|
186
|
+
width?: ChartSizeInput;
|
|
187
|
+
height?: ChartSizeInput;
|
|
188
|
+
};
|
|
189
|
+
|
|
190
|
+
export type BaseChartOptions = {
|
|
191
|
+
title?: string | TitleOption;
|
|
192
|
+
animation?: AnimationOptions;
|
|
193
|
+
} & ChartSize;
|
|
194
|
+
|
|
195
|
+
export interface Scale {
|
|
196
|
+
min?: number;
|
|
197
|
+
max?: number;
|
|
198
|
+
stepSize?: 'auto' | number;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
type AxisLabelInfo = {
|
|
202
|
+
axisName: 'xAxis' | 'yAxis' | 'secondaryYAxis';
|
|
203
|
+
labels: string[];
|
|
204
|
+
index: number;
|
|
205
|
+
};
|
|
206
|
+
type AxisFormatter = (value: string, axisLabelInfo: AxisLabelInfo) => string;
|
|
207
|
+
export type AxisTitleOption = Omit<TitleOption, 'align'>;
|
|
208
|
+
type AxisTitle = string | AxisTitleOption;
|
|
209
|
+
|
|
210
|
+
type BaseAxisOptions = {
|
|
211
|
+
tick?: {
|
|
212
|
+
interval?: number;
|
|
213
|
+
};
|
|
214
|
+
label?: {
|
|
215
|
+
interval?: number;
|
|
216
|
+
formatter?: AxisFormatter;
|
|
217
|
+
margin?: number;
|
|
218
|
+
};
|
|
219
|
+
scale?: Scale;
|
|
220
|
+
title?: AxisTitle;
|
|
221
|
+
} & BaseSizeOptions;
|
|
222
|
+
|
|
223
|
+
interface LineTypeXAxisOptions extends BaseXAxisOptions {
|
|
224
|
+
pointOnColumn?: boolean;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
type YAxisOptions = BaseAxisOptions & {
|
|
228
|
+
chartType?: string;
|
|
229
|
+
};
|
|
230
|
+
|
|
231
|
+
type BothSidesYAxisOptions = YAxisOptions | YAxisOptions[];
|
|
232
|
+
|
|
233
|
+
type DateOption = boolean | { format: string };
|
|
234
|
+
|
|
235
|
+
interface BaseXAxisOptions extends BaseAxisOptions {
|
|
236
|
+
date?: DateOption;
|
|
237
|
+
label?: {
|
|
238
|
+
interval?: number;
|
|
239
|
+
formatter?: AxisFormatter;
|
|
240
|
+
margin?: number;
|
|
241
|
+
rotatable?: boolean;
|
|
242
|
+
};
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
type BarTypeYAxisOption = BaseAxisOptions & {
|
|
246
|
+
align?: 'center';
|
|
247
|
+
categories?: string[];
|
|
248
|
+
};
|
|
249
|
+
type BarTypeYAxisOptions = BarTypeYAxisOption | BarTypeYAxisOption[];
|
|
250
|
+
|
|
251
|
+
export type PlotXPointType = number | string;
|
|
252
|
+
|
|
253
|
+
export type PlotRangeType = RangeDataType<PlotXPointType>;
|
|
254
|
+
|
|
255
|
+
export type PlotLine = {
|
|
256
|
+
value: PlotXPointType;
|
|
257
|
+
color: string;
|
|
258
|
+
opacity?: number;
|
|
259
|
+
id?: string;
|
|
260
|
+
};
|
|
261
|
+
|
|
262
|
+
export type PlotBand = {
|
|
263
|
+
range: PlotRangeType | PlotRangeType[];
|
|
264
|
+
color: string;
|
|
265
|
+
opacity?: number;
|
|
266
|
+
mergeOverlappingRanges?: boolean;
|
|
267
|
+
id?: string;
|
|
268
|
+
};
|
|
269
|
+
|
|
270
|
+
type PlotOptions = BaseSizeOptions & {
|
|
271
|
+
visible?: boolean;
|
|
272
|
+
};
|
|
273
|
+
|
|
274
|
+
export type LineTypePlotOptions = PlotOptions & {
|
|
275
|
+
lines?: PlotLine[];
|
|
276
|
+
bands?: PlotBand[];
|
|
277
|
+
};
|
|
278
|
+
|
|
279
|
+
interface ExportMenuOptions {
|
|
280
|
+
filename?: string;
|
|
281
|
+
visible?: boolean;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
type DataLabelData = GaugeSeriesDataType[];
|
|
285
|
+
|
|
286
|
+
type TooltipFormatter = (value: SeriesDataType, tooltipDataInfo?: TooltipData) => string;
|
|
287
|
+
type ValueFormatter = (value: SeriesDataType, dataLabelData?: DataLabelData) => string;
|
|
288
|
+
export type DefaultTooltipTemplate = { header: string; body: string };
|
|
289
|
+
|
|
290
|
+
export type TooltipTemplateFunc = (
|
|
291
|
+
model: TooltipModel,
|
|
292
|
+
defaultTemplate: DefaultTooltipTemplate,
|
|
293
|
+
theme: Required<TooltipTheme>
|
|
294
|
+
) => string;
|
|
295
|
+
|
|
296
|
+
interface BaseTooltipOptions {
|
|
297
|
+
template?: TooltipTemplateFunc;
|
|
298
|
+
offsetX?: number;
|
|
299
|
+
offsetY?: number;
|
|
300
|
+
formatter?: TooltipFormatter;
|
|
301
|
+
transition?: string | boolean;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
interface LangOptions {
|
|
305
|
+
noData?: string;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
export interface BaseOptions {
|
|
309
|
+
chart?: BaseChartOptions;
|
|
310
|
+
lang?: LangOptions;
|
|
311
|
+
series?: BaseSeriesOptions;
|
|
312
|
+
xAxis?: BaseXAxisOptions;
|
|
313
|
+
legend?: BaseLegendOptions;
|
|
314
|
+
exportMenu?: ExportMenuOptions;
|
|
315
|
+
tooltip?: BaseTooltipOptions;
|
|
316
|
+
plot?: BaseSizeOptions;
|
|
317
|
+
theme?: BaseThemeOptions;
|
|
318
|
+
responsive?: ResponsiveOptions;
|
|
319
|
+
usageStatistics?: boolean;
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
type ResponsiveRule = {
|
|
323
|
+
condition: ({ width, height }: Size) => boolean;
|
|
324
|
+
options: Options;
|
|
325
|
+
};
|
|
326
|
+
|
|
327
|
+
type ResponsiveOptions = {
|
|
328
|
+
animation?: AnimationOptions;
|
|
329
|
+
rules?: ResponsiveRule[];
|
|
330
|
+
};
|
|
331
|
+
|
|
332
|
+
interface BaseLegendOptions {
|
|
333
|
+
align?: Align;
|
|
334
|
+
visible?: boolean;
|
|
335
|
+
width?: number;
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
interface NormalLegendOptions extends BaseLegendOptions {
|
|
339
|
+
showCheckbox?: boolean;
|
|
340
|
+
item?: {
|
|
341
|
+
width?: number;
|
|
342
|
+
overflow?: 'ellipsis';
|
|
343
|
+
};
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
interface CircleLegendOptions {
|
|
347
|
+
visible?: boolean;
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
interface BaseSeriesOptions {
|
|
351
|
+
selectable?: boolean;
|
|
352
|
+
}
|
|
353
|
+
|
|
354
|
+
interface BoxPlotSeriesOptions extends BaseSeriesOptions {
|
|
355
|
+
eventDetectType?: BoxTypeEventDetectType;
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
export interface HeatmapChartOptions extends BaseOptions {
|
|
359
|
+
yAxis?: BaseAxisOptions & { date?: DateOption };
|
|
360
|
+
theme?: HeatmapChartThemeOptions;
|
|
361
|
+
series?: BaseSeriesOptions & { shift?: boolean; dataLabels?: Omit<DataLabelOptions, 'anchor'> };
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
export interface BoxPlotChartOptions extends BaseOptions {
|
|
365
|
+
series?: BoxPlotSeriesOptions;
|
|
366
|
+
yAxis?: BaseAxisOptions;
|
|
367
|
+
plot?: PlotOptions;
|
|
368
|
+
theme?: BoxPlotCharThemeOptions;
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
interface LineTypeSeriesOptions extends BaseSeriesOptions {
|
|
372
|
+
showDot?: boolean;
|
|
373
|
+
spline?: boolean;
|
|
374
|
+
zoomable?: boolean;
|
|
375
|
+
rangeSelectable?: boolean;
|
|
376
|
+
eventDetectType?: LineTypeEventDetectType;
|
|
377
|
+
shift?: boolean;
|
|
378
|
+
dataLabels?: Omit<DataLabelOptions, 'anchor'>;
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
interface AreaSeriesOptions extends LineTypeSeriesOptions {
|
|
382
|
+
stack?: StackOptionType;
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
export interface AreaChartOptions extends BaseOptions {
|
|
386
|
+
series?: AreaSeriesOptions;
|
|
387
|
+
xAxis?: LineTypeXAxisOptions;
|
|
388
|
+
yAxis?: BothSidesYAxisOptions;
|
|
389
|
+
plot?: LineTypePlotOptions;
|
|
390
|
+
legend?: NormalLegendOptions;
|
|
391
|
+
theme?: AreaChartThemeOptions;
|
|
392
|
+
}
|
|
393
|
+
|
|
394
|
+
export interface LineChartOptions extends BaseOptions {
|
|
395
|
+
series?: LineTypeSeriesOptions;
|
|
396
|
+
xAxis?: LineTypeXAxisOptions;
|
|
397
|
+
yAxis?: BothSidesYAxisOptions;
|
|
398
|
+
plot?: LineTypePlotOptions;
|
|
399
|
+
legend?: NormalLegendOptions;
|
|
400
|
+
theme?: LineChartThemeOptions;
|
|
401
|
+
}
|
|
402
|
+
|
|
403
|
+
type LineScatterChartSeriesOptions = {
|
|
404
|
+
line?: Pick<LineTypeSeriesOptions, 'spline' | 'showDot'>;
|
|
405
|
+
dataLabels?: DataLabelOptions;
|
|
406
|
+
legend?: NormalLegendOptions;
|
|
407
|
+
} & BaseSeriesOptions;
|
|
408
|
+
|
|
409
|
+
export interface LineScatterChartOptions extends BaseOptions {
|
|
410
|
+
series?: LineScatterChartSeriesOptions;
|
|
411
|
+
yAxis?: BothSidesYAxisOptions;
|
|
412
|
+
plot?: LineTypePlotOptions;
|
|
413
|
+
legend?: NormalLegendOptions;
|
|
414
|
+
theme?: LineScatterChartThemeOptions;
|
|
415
|
+
}
|
|
416
|
+
|
|
417
|
+
export interface LineAreaChartOptions extends BaseOptions {
|
|
418
|
+
series?: LineAreaChartSeriesOptions;
|
|
419
|
+
plot?: LineTypePlotOptions;
|
|
420
|
+
yAxis?: BothSidesYAxisOptions;
|
|
421
|
+
legend?: NormalLegendOptions;
|
|
422
|
+
theme?: LineAreaChartThemeOptions;
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
type LineAreaChartSeriesOptions = {
|
|
426
|
+
line?: Pick<LineTypeSeriesOptions, 'spline' | 'showDot' | 'dataLabels'> & BaseSeriesOptions;
|
|
427
|
+
area?: Pick<AreaSeriesOptions, 'stack' | 'spline' | 'showDot' | 'dataLabels'> & BaseSeriesOptions;
|
|
428
|
+
zoomable?: boolean;
|
|
429
|
+
rangeSelectable?: boolean;
|
|
430
|
+
showDot?: boolean;
|
|
431
|
+
spline?: boolean;
|
|
432
|
+
shift?: boolean;
|
|
433
|
+
dataLabels?: DataLabelOptions;
|
|
434
|
+
} & BaseSeriesOptions;
|
|
435
|
+
|
|
436
|
+
export interface ScatterChartOptions extends BaseOptions {
|
|
437
|
+
series?: BaseSeriesOptions;
|
|
438
|
+
xAxis?: BaseXAxisOptions;
|
|
439
|
+
yAxis?: BaseAxisOptions;
|
|
440
|
+
plot?: PlotOptions;
|
|
441
|
+
legend?: NormalLegendOptions;
|
|
442
|
+
theme?: ScatterChartThemeOptions;
|
|
443
|
+
}
|
|
444
|
+
|
|
445
|
+
export interface BubbleChartOptions extends BaseOptions {
|
|
446
|
+
series?: BaseSeriesOptions;
|
|
447
|
+
xAxis?: BaseXAxisOptions;
|
|
448
|
+
yAxis?: BaseAxisOptions;
|
|
449
|
+
circleLegend?: CircleLegendOptions;
|
|
450
|
+
plot?: PlotOptions;
|
|
451
|
+
legend?: NormalLegendOptions;
|
|
452
|
+
theme?: BubbleChartThemeOptions;
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
export interface TreemapChartSeriesOptions extends BaseSeriesOptions {
|
|
456
|
+
useColorValue?: boolean;
|
|
457
|
+
zoomable?: boolean;
|
|
458
|
+
dataLabels?: TreemapDataLabels;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
export interface TreemapChartOptions extends BaseOptions {
|
|
462
|
+
series?: TreemapChartSeriesOptions;
|
|
463
|
+
theme?: TreemapChartThemeOptions;
|
|
464
|
+
}
|
|
465
|
+
|
|
466
|
+
export type StackType = 'normal' | 'percent';
|
|
467
|
+
|
|
468
|
+
interface StackInfo {
|
|
469
|
+
type: StackType;
|
|
470
|
+
connector?: boolean;
|
|
471
|
+
}
|
|
472
|
+
|
|
473
|
+
type StackOptionType = boolean | StackInfo;
|
|
474
|
+
export interface BoxSeriesOptions extends BaseSeriesOptions {
|
|
475
|
+
diverging?: boolean;
|
|
476
|
+
stack?: StackOptionType;
|
|
477
|
+
eventDetectType?: BoxTypeEventDetectType;
|
|
478
|
+
dataLabels?: BoxDataLabels;
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
export interface BarChartOptions extends BaseOptions {
|
|
482
|
+
series?: BoxSeriesOptions;
|
|
483
|
+
yAxis?: BarTypeYAxisOptions;
|
|
484
|
+
plot?: PlotOptions;
|
|
485
|
+
legend?: NormalLegendOptions;
|
|
486
|
+
theme?: BoxChartThemeOptions;
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
export type ColumnChartBoxSeriesOptions = BoxSeriesOptions & {
|
|
490
|
+
shift?: boolean;
|
|
491
|
+
rangeSelectable?: boolean;
|
|
492
|
+
};
|
|
493
|
+
|
|
494
|
+
export interface ColumnChartOptions extends BaseOptions {
|
|
495
|
+
series?: ColumnChartBoxSeriesOptions;
|
|
496
|
+
yAxis?: BothSidesYAxisOptions;
|
|
497
|
+
plot?: PlotOptions;
|
|
498
|
+
legend?: NormalLegendOptions;
|
|
499
|
+
theme?: BoxChartThemeOptions;
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
export type BoxPlotSeriesType = {
|
|
503
|
+
name: string;
|
|
504
|
+
data: number[][] | null;
|
|
505
|
+
outliers?: number[][] | null;
|
|
506
|
+
color?: string;
|
|
507
|
+
visible?: boolean;
|
|
508
|
+
};
|
|
509
|
+
|
|
510
|
+
export type BoxPlotSeriesData = {
|
|
511
|
+
categories: string[];
|
|
512
|
+
series: BoxPlotSeriesType[];
|
|
513
|
+
};
|
|
514
|
+
|
|
515
|
+
interface PieSeriesOptions extends BaseSeriesOptions {
|
|
516
|
+
radiusRange?: {
|
|
517
|
+
inner?: number | string;
|
|
518
|
+
outer?: number | string;
|
|
519
|
+
};
|
|
520
|
+
angleRange?: {
|
|
521
|
+
start?: number;
|
|
522
|
+
end?: number;
|
|
523
|
+
};
|
|
524
|
+
clockwise?: boolean;
|
|
525
|
+
dataLabels?: PieDataLabels;
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
export interface PieChartOptions extends BaseOptions {
|
|
529
|
+
series?: PieSeriesOptions;
|
|
530
|
+
legend?: NormalLegendOptions;
|
|
531
|
+
theme?: PieChartThemeOptions;
|
|
532
|
+
}
|
|
533
|
+
|
|
534
|
+
export type RadarSeriesType = {
|
|
535
|
+
name: string;
|
|
536
|
+
data: Array<number | null>;
|
|
537
|
+
color?: string;
|
|
538
|
+
visible?: boolean;
|
|
539
|
+
};
|
|
540
|
+
|
|
541
|
+
export type RadarSeriesInput = Pick<RadarSeriesType, 'name' | 'data' | 'visible'>;
|
|
542
|
+
|
|
543
|
+
export type RadarSeriesData = {
|
|
544
|
+
categories: string[];
|
|
545
|
+
series: RadarSeriesInput[];
|
|
546
|
+
};
|
|
547
|
+
|
|
548
|
+
interface RadarSeriesOptions extends BaseSeriesOptions {
|
|
549
|
+
showDot?: boolean;
|
|
550
|
+
showArea?: boolean;
|
|
551
|
+
}
|
|
552
|
+
|
|
553
|
+
export type RadarPlotType = 'spiderweb' | 'circle';
|
|
554
|
+
|
|
555
|
+
export interface RadarChartOptions extends BaseOptions {
|
|
556
|
+
series?: RadarSeriesOptions;
|
|
557
|
+
plot?: BaseSizeOptions & { type?: RadarPlotType };
|
|
558
|
+
verticalAxis?: RadialValueAxisOptions;
|
|
559
|
+
circularAxis?: BaseRadialAxisOptions;
|
|
560
|
+
legend?: NormalLegendOptions;
|
|
561
|
+
theme?: RadarChartThemeOptions;
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
export type BoxSeriesInput<T extends BoxSeriesDataType> = Pick<
|
|
565
|
+
BoxSeriesType<T>,
|
|
566
|
+
'data' | 'name' | 'stackGroup' | 'visible'
|
|
567
|
+
>;
|
|
568
|
+
|
|
569
|
+
export interface BoxSeriesType<T extends BoxSeriesDataType> {
|
|
570
|
+
name: string;
|
|
571
|
+
data: T[];
|
|
572
|
+
rawData: T[];
|
|
573
|
+
color: string | string[];
|
|
574
|
+
stackGroup?: string;
|
|
575
|
+
visible?: boolean;
|
|
576
|
+
colorByCategories?: boolean;
|
|
577
|
+
}
|
|
578
|
+
|
|
579
|
+
export interface BoxSeriesData {
|
|
580
|
+
categories: string[];
|
|
581
|
+
series: BoxSeriesInput<BoxSeriesDataType>[];
|
|
582
|
+
colorByCategories?: boolean;
|
|
583
|
+
}
|
|
584
|
+
|
|
585
|
+
export interface ChartProps<T> {
|
|
586
|
+
el: HTMLElement;
|
|
587
|
+
series: RawSeries;
|
|
588
|
+
categories?: Categories;
|
|
589
|
+
modules?: StoreModule[];
|
|
590
|
+
options: T;
|
|
591
|
+
}
|
|
592
|
+
|
|
593
|
+
export type SeriesDataType =
|
|
594
|
+
| BoxSeriesDataType
|
|
595
|
+
| AreaSeriesDataType
|
|
596
|
+
| LineSeriesDataType
|
|
597
|
+
| CoordinateDataType
|
|
598
|
+
| BubbleSeriesDataType
|
|
599
|
+
| GaugeSeriesDataType;
|
|
600
|
+
|
|
601
|
+
export type DataLabelAnchor = 'center' | 'start' | 'end' | 'auto' | 'outer';
|
|
602
|
+
|
|
603
|
+
export type StackTotalDataLabel = {
|
|
604
|
+
visible?: boolean;
|
|
605
|
+
formatter?: ValueFormatter;
|
|
606
|
+
};
|
|
607
|
+
|
|
608
|
+
export type DataLabelPieSeriesName = {
|
|
609
|
+
visible: boolean;
|
|
610
|
+
anchor?: 'center' | 'outer';
|
|
611
|
+
};
|
|
612
|
+
|
|
613
|
+
export type DataLabelOptions = {
|
|
614
|
+
visible?: boolean;
|
|
615
|
+
anchor?: DataLabelAnchor;
|
|
616
|
+
offsetX?: number;
|
|
617
|
+
offsetY?: number;
|
|
618
|
+
formatter?: ValueFormatter;
|
|
619
|
+
};
|
|
620
|
+
|
|
621
|
+
export interface BoxDataLabels extends DataLabelOptions {
|
|
622
|
+
stackTotal?: StackTotalDataLabel;
|
|
623
|
+
}
|
|
624
|
+
export interface PieDataLabels extends DataLabelOptions {
|
|
625
|
+
pieSeriesName?: DataLabelPieSeriesName;
|
|
626
|
+
}
|
|
627
|
+
|
|
628
|
+
export interface TreemapDataLabels extends Omit<DataLabelOptions, 'anchor'> {
|
|
629
|
+
useTreemapLeaf?: boolean;
|
|
630
|
+
}
|
|
631
|
+
|
|
632
|
+
export interface BulletChartOptions extends BaseOptions {
|
|
633
|
+
yAxis?: BaseAxisOptions;
|
|
634
|
+
series?: BulletSeriesOptions;
|
|
635
|
+
plot?: PlotOptions;
|
|
636
|
+
theme?: BulletCharThemeOptions;
|
|
637
|
+
}
|
|
638
|
+
|
|
639
|
+
export type BulletSeriesType = {
|
|
640
|
+
name: string;
|
|
641
|
+
data: number | null;
|
|
642
|
+
markers?: number[];
|
|
643
|
+
ranges?: Array<RangeDataType<number> | null>;
|
|
644
|
+
color?: string;
|
|
645
|
+
visible?: boolean;
|
|
646
|
+
};
|
|
647
|
+
|
|
648
|
+
export type BulletSeriesData = {
|
|
649
|
+
series: BulletSeriesType[];
|
|
650
|
+
};
|
|
651
|
+
|
|
652
|
+
export interface BulletSeriesOptions extends BaseSeriesOptions {
|
|
653
|
+
vertical?: boolean;
|
|
654
|
+
dataLabels?: DataLabelOptions;
|
|
655
|
+
eventDetectType?: BoxTypeEventDetectType;
|
|
656
|
+
}
|
|
657
|
+
|
|
658
|
+
type ColumnLineChartSeriesOptions = {
|
|
659
|
+
column?: Pick<BoxSeriesOptions, 'stack' | 'dataLabels' | 'selectable'>;
|
|
660
|
+
line?: Pick<LineTypeSeriesOptions, 'spline' | 'showDot' | 'dataLabels' | 'selectable'>;
|
|
661
|
+
shift?: boolean;
|
|
662
|
+
dataLabels?: DataLabelOptions;
|
|
663
|
+
eventDetectType?: BoxTypeEventDetectType;
|
|
664
|
+
rangeSelectable?: boolean;
|
|
665
|
+
} & BaseSeriesOptions;
|
|
666
|
+
|
|
667
|
+
export interface ColumnLineChartOptions extends BaseOptions {
|
|
668
|
+
series?: ColumnLineChartSeriesOptions;
|
|
669
|
+
plot?: LineTypePlotOptions;
|
|
670
|
+
yAxis?: BothSidesYAxisOptions;
|
|
671
|
+
legend?: NormalLegendOptions;
|
|
672
|
+
theme?: ColumnLineChartThemeOptions;
|
|
673
|
+
}
|
|
674
|
+
|
|
675
|
+
export type ColumnLineData = {
|
|
676
|
+
categories: string[];
|
|
677
|
+
series: {
|
|
678
|
+
column: Pick<BoxSeriesType<BoxSeriesDataType>, 'name' | 'data' | 'visible'>[];
|
|
679
|
+
line: Pick<LineSeriesType, 'name' | 'data' | 'visible'>[];
|
|
680
|
+
};
|
|
681
|
+
};
|
|
682
|
+
|
|
683
|
+
export type NestedPieSeriesType = {
|
|
684
|
+
name: string;
|
|
685
|
+
data: PieSeriesType[];
|
|
686
|
+
};
|
|
687
|
+
|
|
688
|
+
export type NestedPieSeriesData = {
|
|
689
|
+
categories?: string[];
|
|
690
|
+
series: NestedPieSeriesType[];
|
|
691
|
+
};
|
|
692
|
+
|
|
693
|
+
export type NestedPieSeriesOptions = Record<string, PieSeriesOptions> &
|
|
694
|
+
BaseSeriesOptions & { dataLabels?: PieDataLabels };
|
|
695
|
+
|
|
696
|
+
export interface NestedPieChartOptions extends BaseOptions {
|
|
697
|
+
series?: NestedPieSeriesOptions;
|
|
698
|
+
legend?: NormalLegendOptions;
|
|
699
|
+
theme?: NestedPieChartThemeOptions;
|
|
700
|
+
}
|
|
701
|
+
|
|
702
|
+
export interface RadialBarSeriesType {
|
|
703
|
+
name: string;
|
|
704
|
+
data: (number | null)[];
|
|
705
|
+
color?: string;
|
|
706
|
+
visible?: boolean;
|
|
707
|
+
}
|
|
708
|
+
|
|
709
|
+
export interface RadialBarSeriesData {
|
|
710
|
+
categories: string[];
|
|
711
|
+
series: RadialBarSeriesType[];
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
interface BaseRadialAxisOptions {
|
|
715
|
+
tick?: {
|
|
716
|
+
interval?: number;
|
|
717
|
+
};
|
|
718
|
+
label?: {
|
|
719
|
+
interval?: number;
|
|
720
|
+
formatter?: AxisFormatter;
|
|
721
|
+
margin?: number;
|
|
722
|
+
};
|
|
723
|
+
}
|
|
724
|
+
|
|
725
|
+
interface RadialValueAxisOptions extends BaseRadialAxisOptions {
|
|
726
|
+
scale?: Scale;
|
|
727
|
+
}
|
|
728
|
+
|
|
729
|
+
export interface RadialBarChartOptions extends BaseOptions {
|
|
730
|
+
verticalAxis?: BaseRadialAxisOptions;
|
|
731
|
+
circularAxis?: RadialValueAxisOptions;
|
|
732
|
+
series?: RadialBarSeriesOptions;
|
|
733
|
+
legend?: NormalLegendOptions;
|
|
734
|
+
theme?: RadialBarChartThemeOptions;
|
|
735
|
+
}
|
|
736
|
+
|
|
737
|
+
interface RadialBarSeriesOptions extends BaseSeriesOptions {
|
|
738
|
+
radiusRange?: {
|
|
739
|
+
inner?: number | string;
|
|
740
|
+
outer?: number | string;
|
|
741
|
+
};
|
|
742
|
+
clockwise?: boolean;
|
|
743
|
+
angleRange?: {
|
|
744
|
+
start: number;
|
|
745
|
+
end: number;
|
|
746
|
+
};
|
|
747
|
+
eventDetectType?: CircleTypeEventDetectType;
|
|
748
|
+
dataLabels?: DataLabelOptions;
|
|
749
|
+
}
|
|
750
|
+
|
|
751
|
+
export type GaugeSeriesType = {
|
|
752
|
+
name: string;
|
|
753
|
+
data: GaugeSeriesDataType[];
|
|
754
|
+
color?: string;
|
|
755
|
+
};
|
|
756
|
+
|
|
757
|
+
export interface GaugeSeriesData {
|
|
758
|
+
categories?: string[];
|
|
759
|
+
series: Omit<GaugeSeriesType, 'color'>[];
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
type GaugePlotBand = {
|
|
763
|
+
color: string;
|
|
764
|
+
range: number[] | string[];
|
|
765
|
+
id?: string;
|
|
766
|
+
};
|
|
767
|
+
export interface GaugeChartOptions extends BaseOptions {
|
|
768
|
+
circularAxis?: GaugeAxisOptions;
|
|
769
|
+
series?: GaugeSeriesOptions;
|
|
770
|
+
plot?: BaseSizeOptions & {
|
|
771
|
+
bands?: GaugePlotBand[];
|
|
772
|
+
};
|
|
773
|
+
theme?: GaugeChartThemeOptions;
|
|
774
|
+
}
|
|
775
|
+
|
|
776
|
+
type GaugeSolidOptions = {
|
|
777
|
+
clockHand: boolean;
|
|
778
|
+
};
|
|
779
|
+
|
|
780
|
+
interface GaugeAxisOptions extends BaseRadialAxisOptions {
|
|
781
|
+
scale?: Scale;
|
|
782
|
+
title?: AxisTitle;
|
|
783
|
+
}
|
|
784
|
+
export interface GaugeSeriesOptions extends BaseSeriesOptions {
|
|
785
|
+
solid?: boolean | Partial<GaugeSolidOptions>;
|
|
786
|
+
clockwise?: boolean;
|
|
787
|
+
angleRange?: {
|
|
788
|
+
start: number;
|
|
789
|
+
end: number;
|
|
790
|
+
};
|
|
791
|
+
dataLabels?: Omit<DataLabelOptions, 'anchor'>;
|
|
792
|
+
}
|
|
793
|
+
|
|
794
|
+
type GaugeSeriesInput = Omit<GaugeSeriesType, 'color'>;
|
|
795
|
+
|
|
796
|
+
export type SeriesDataInput =
|
|
797
|
+
| LineSeriesInput
|
|
798
|
+
| AreaSeriesInput
|
|
799
|
+
| ScatterSeriesInput
|
|
800
|
+
| BubbleSeriesInput
|
|
801
|
+
| TreemapSeriesType
|
|
802
|
+
| RadarSeriesInput
|
|
803
|
+
| PieSeriesType
|
|
804
|
+
| HeatmapSeriesDataType
|
|
805
|
+
| BulletSeriesType
|
|
806
|
+
| BoxPlotSeriesType
|
|
807
|
+
| BoxSeriesInput<BoxSeriesDataType>
|
|
808
|
+
| NestedPieSeriesType
|
|
809
|
+
| RadialBarSeriesType
|
|
810
|
+
| GaugeSeriesType;
|
|
811
|
+
|
|
812
|
+
export type DataInput =
|
|
813
|
+
| LineSeriesData
|
|
814
|
+
| AreaSeriesData
|
|
815
|
+
| BoxSeriesData
|
|
816
|
+
| BoxPlotSeriesData
|
|
817
|
+
| ScatterSeriesData
|
|
818
|
+
| BubbleSeriesData
|
|
819
|
+
| BulletSeriesData
|
|
820
|
+
| HeatmapSeriesData
|
|
821
|
+
| PieSeriesData
|
|
822
|
+
| RadarSeriesData
|
|
823
|
+
| TreemapSeriesData
|
|
824
|
+
| LineAreaData
|
|
825
|
+
| LineScatterData
|
|
826
|
+
| ColumnLineData
|
|
827
|
+
| NestedPieSeriesData
|
|
828
|
+
| RadialBarSeriesData
|
|
829
|
+
| GaugeSeriesData;
|
|
830
|
+
|
|
831
|
+
type UsingRadialAxesChartTypeTheme =
|
|
832
|
+
| Required<RadarChartThemeOptions>
|
|
833
|
+
| Required<RadialBarChartThemeOptions>;
|