@gravity-ui/chartkit 4.20.1 → 5.1.0
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/build/components/ChartKit.css +20 -20
- package/build/components/ChartKit.d.ts +2 -2
- package/build/components/ErrorBoundary/ErrorBoundary.js +1 -1
- package/build/libs/settings/settings.d.ts +1 -1
- package/build/libs/settings/settings.js +1 -1
- package/build/plugins/d3/examples/area/PercentStacking.js +1 -1
- package/build/plugins/d3/examples/area/StackedArea.js +1 -1
- package/build/plugins/d3/examples/combined/LineAndBarX.js +1 -1
- package/build/plugins/d3/examples/pie/DonutWithTotals.js +1 -1
- package/build/plugins/d3/renderer/D3Widget.d.ts +1 -1
- package/build/plugins/d3/renderer/D3Widget.js +1 -1
- package/build/plugins/d3/renderer/components/AxisX.d.ts +1 -1
- package/build/plugins/d3/renderer/components/AxisX.js +2 -2
- package/build/plugins/d3/renderer/components/AxisY.js +1 -1
- package/build/plugins/d3/renderer/components/Chart.js +13 -4
- package/build/plugins/d3/renderer/components/Legend.d.ts +1 -1
- package/build/plugins/d3/renderer/components/Legend.js +2 -2
- package/build/plugins/d3/renderer/components/Tooltip/DefaultContent.js +1 -1
- package/build/plugins/d3/renderer/components/Tooltip/TooltipTriggerArea.js +19 -7
- package/build/plugins/d3/renderer/components/Tooltip/index.js +1 -1
- package/build/plugins/d3/renderer/components/styles.css +1 -1
- package/build/plugins/d3/renderer/d3-dispatcher.js +1 -1
- package/build/plugins/d3/renderer/hooks/useAxisScales/index.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useAxisScales/index.js +2 -2
- package/build/plugins/d3/renderer/hooks/useChartOptions/types.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useChartOptions/x-axis.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useChartOptions/x-axis.js +1 -1
- package/build/plugins/d3/renderer/hooks/useChartOptions/y-axis.js +2 -2
- package/build/plugins/d3/renderer/hooks/useSeries/index.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/index.js +2 -2
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-area.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-area.js +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-x.js +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-y.js +2 -2
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-legend.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-legend.js +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-line.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-line.js +2 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-pie.js +3 -2
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-scatter.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useSeries/prepare-scatter.js +2 -2
- package/build/plugins/d3/renderer/hooks/useSeries/prepareSeries.js +2 -2
- package/build/plugins/d3/renderer/hooks/useSeries/types.d.ts +4 -2
- package/build/plugins/d3/renderer/hooks/useSeries/utils.d.ts +2 -2
- package/build/plugins/d3/renderer/hooks/useSeries/utils.js +1 -1
- package/build/plugins/d3/renderer/hooks/useShapes/area/index.js +2 -2
- package/build/plugins/d3/renderer/hooks/useShapes/area/prepare-data.d.ts +2 -2
- package/build/plugins/d3/renderer/hooks/useShapes/area/prepare-data.js +1 -1
- package/build/plugins/d3/renderer/hooks/useShapes/area/types.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useShapes/bar-x/index.js +3 -2
- package/build/plugins/d3/renderer/hooks/useShapes/bar-x/prepare-data.js +1 -0
- package/build/plugins/d3/renderer/hooks/useShapes/bar-x/types.d.ts +2 -1
- package/build/plugins/d3/renderer/hooks/useShapes/bar-y/index.js +3 -2
- package/build/plugins/d3/renderer/hooks/useShapes/bar-y/prepare-data.js +1 -0
- package/build/plugins/d3/renderer/hooks/useShapes/bar-y/types.d.ts +1 -0
- package/build/plugins/d3/renderer/hooks/useShapes/index.d.ts +6 -6
- package/build/plugins/d3/renderer/hooks/useShapes/index.js +6 -6
- package/build/plugins/d3/renderer/hooks/useShapes/line/index.js +3 -2
- package/build/plugins/d3/renderer/hooks/useShapes/line/prepare-data.d.ts +2 -2
- package/build/plugins/d3/renderer/hooks/useShapes/line/prepare-data.js +2 -1
- package/build/plugins/d3/renderer/hooks/useShapes/line/types.d.ts +3 -2
- package/build/plugins/d3/renderer/hooks/useShapes/marker.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useShapes/marker.js +10 -3
- package/build/plugins/d3/renderer/hooks/useShapes/pie/index.js +20 -11
- package/build/plugins/d3/renderer/hooks/useShapes/pie/prepare-data.js +1 -0
- package/build/plugins/d3/renderer/hooks/useShapes/pie/types.d.ts +3 -2
- package/build/plugins/d3/renderer/hooks/useShapes/pie/utils.js +1 -1
- package/build/plugins/d3/renderer/hooks/useShapes/scatter/index.js +14 -4
- package/build/plugins/d3/renderer/hooks/useShapes/scatter/prepare-data.js +2 -0
- package/build/plugins/d3/renderer/hooks/useShapes/scatter/types.d.ts +1 -0
- package/build/plugins/d3/renderer/hooks/useShapes/treemap/index.js +11 -4
- package/build/plugins/d3/renderer/hooks/useShapes/utils.d.ts +1 -1
- package/build/plugins/d3/renderer/hooks/useTooltip/index.d.ts +1 -1
- package/build/plugins/d3/renderer/utils/axis-generators/bottom.js +1 -1
- package/build/plugins/d3/renderer/utils/axis.d.ts +1 -1
- package/build/plugins/d3/renderer/utils/index.js +3 -3
- package/build/plugins/d3/renderer/utils/symbol.js +1 -1
- package/build/plugins/d3/renderer/validation/index.js +1 -1
- package/build/plugins/highcharts/renderer/components/HighchartsComponent.d.ts +1 -1
- package/build/plugins/highcharts/renderer/components/HighchartsComponent.js +2 -2
- package/build/plugins/highcharts/renderer/components/HighchartsReact.js +7 -1
- package/build/plugins/highcharts/renderer/components/StyledSplitPane/StyledSplitPane.css +1 -1
- package/build/plugins/highcharts/renderer/helpers/config/config.js +15 -15
- package/build/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js +1 -1
- package/build/plugins/highcharts/renderer/helpers/config/options.d.ts +98 -98
- package/build/plugins/highcharts/renderer/helpers/config/options.js +1 -1
- package/build/plugins/highcharts/renderer/helpers/config/utils/index.d.ts +39 -10
- package/build/plugins/highcharts/renderer/helpers/graph.css +4 -4
- package/build/plugins/highcharts/renderer/helpers/graph.d.ts +1 -1
- package/build/plugins/highcharts/renderer/helpers/graph.js +2 -2
- package/build/plugins/highcharts/renderer/helpers/highcharts/highcharts.js +2 -2
- package/build/plugins/highcharts/renderer/helpers/prepare-data.js +2 -2
- package/build/plugins/highcharts/renderer/helpers/tooltip/index.js +1 -1
- package/build/plugins/highcharts/renderer/helpers/tooltip/tooltip.css +6 -7
- package/build/plugins/highcharts/types/highcharts-extends.d.ts +1 -0
- package/build/plugins/highcharts/types/widget.d.ts +2 -2
- package/build/plugins/indicator/renderer/IndicatorWidget.css +1 -1
- package/build/plugins/indicator/renderer/IndicatorWidget.js +1 -1
- package/build/plugins/shared/format-number/format-number.d.ts +1 -1
- package/build/plugins/shared/format-number/format-number.js +2 -2
- package/build/plugins/shared/format-number/format-number.test.js +1 -1
- package/build/plugins/yagr/renderer/YagrWidget.css +1 -1
- package/build/plugins/yagr/renderer/YagrWidget.js +5 -3
- package/build/plugins/yagr/renderer/tooltip/tooltip.css +15 -16
- package/build/plugins/yagr/renderer/utils.d.ts +1 -1
- package/build/plugins/yagr/renderer/utils.js +1 -1
- package/build/types/index.d.ts +1 -1
- package/build/types/widget-data/area.d.ts +15 -0
- package/build/types/widget-data/bar-x.d.ts +3 -1
- package/build/types/widget-data/bar-y.d.ts +3 -1
- package/build/types/widget-data/chart.d.ts +6 -0
- package/build/types/widget-data/line.d.ts +10 -1
- package/build/types/widget-data/pie.d.ts +2 -0
- package/build/types/widget-data/scatter.d.ts +3 -0
- package/build/types/widget-data/series.d.ts +6 -6
- package/build/types/widget-data/tooltip.d.ts +3 -3
- package/build/types/widget.d.ts +2 -2
- package/package.json +23 -24
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
/* eslint new-cap: 0, complexity: 0 */
|
|
2
|
+
import { dateTime } from '@gravity-ui/date-utils';
|
|
2
3
|
import Highcharts from 'highcharts';
|
|
3
|
-
import merge from 'lodash/merge';
|
|
4
|
-
import mergeWith from 'lodash/mergeWith';
|
|
5
|
-
import get from 'lodash/get';
|
|
6
4
|
import clamp from 'lodash/clamp';
|
|
5
|
+
import debounce from 'lodash/debounce';
|
|
6
|
+
import get from 'lodash/get';
|
|
7
7
|
import isEmpty from 'lodash/isEmpty';
|
|
8
8
|
import isNumber from 'lodash/isNumber';
|
|
9
|
-
import
|
|
9
|
+
import merge from 'lodash/merge';
|
|
10
|
+
import mergeWith from 'lodash/mergeWith';
|
|
10
11
|
import pick from 'lodash/pick';
|
|
11
|
-
import
|
|
12
|
-
import { dateTime } from '@gravity-ui/date-utils';
|
|
12
|
+
import throttle from 'lodash/throttle';
|
|
13
13
|
import { i18n } from '../../../../../i18n';
|
|
14
|
-
import { formatNumber } from '../../../../shared';
|
|
15
14
|
import { block } from '../../../../../utils/cn';
|
|
16
|
-
import {
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import { calculatePrecision, isTooltipShared, isSafari, mergeArrayWithObject, concatStrings, buildNavigatorFallback, addShowInNavigatorToSeries, setNavigatorDefaultPeriod, numberFormat, getFormatOptionsFromLine, checkTooltipPinningAvailability, getSortedData, } from './utils';
|
|
15
|
+
import { formatNumber } from '../../../../shared';
|
|
16
|
+
import { drawComments, drawOnlyRendererComments, getCommentsOnLine, hideComments, } from '../comments/drawing';
|
|
17
|
+
import formatTooltip, { SERIES_NAME_DATA_ATTRIBUTE, TOOLTIP_CONTAINER_CLASS_NAME, TOOLTIP_FOOTER_CLASS_NAME, TOOLTIP_HEADER_CLASS_NAME, TOOLTIP_LIST_CLASS_NAME, TOOLTIP_ROW_CLASS_NAME, TOOLTIP_ROW_NAME_CLASS_NANE, } from '../tooltip';
|
|
20
18
|
import { handleLegendItemClick } from './handleLegendItemClick';
|
|
19
|
+
import defaultOptions from './options';
|
|
20
|
+
import { addShowInNavigatorToSeries, buildNavigatorFallback, calculatePrecision, checkTooltipPinningAvailability, concatStrings, getFormatOptionsFromLine, getSortedData, isSafari, isTooltipShared, mergeArrayWithObject, numberFormat, setNavigatorDefaultPeriod, } from './utils';
|
|
21
21
|
import { getChartKitFormattedValue } from './utils/getChartKitFormattedValue';
|
|
22
22
|
const b = block('tooltip');
|
|
23
23
|
const TOOLTIP_OFFSET_FROM_CURSOR = 15;
|
|
@@ -159,12 +159,12 @@ export function buildLegend(options) {
|
|
|
159
159
|
}
|
|
160
160
|
},
|
|
161
161
|
navigation: {
|
|
162
|
-
activeColor: 'var(--
|
|
163
|
-
inactiveColor: 'var(--
|
|
164
|
-
style: { color: 'var(--
|
|
162
|
+
activeColor: 'var(--g-color-text-brand)',
|
|
163
|
+
inactiveColor: 'var(--g-color-base-generic-accent-disabled)',
|
|
164
|
+
style: { color: 'var(--g-color-text-primary)' },
|
|
165
165
|
},
|
|
166
166
|
title: {
|
|
167
|
-
style: { color: 'var(--
|
|
167
|
+
style: { color: 'var(--g-color-text-secondary)' },
|
|
168
168
|
},
|
|
169
169
|
};
|
|
170
170
|
if (options.outsideLegend) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import Highcharts from 'highcharts';
|
|
1
2
|
import { drawComments, hideComments } from '../comments/drawing';
|
|
2
3
|
import { isNavigatorSeries } from './utils';
|
|
3
|
-
import Highcharts from 'highcharts';
|
|
4
4
|
const getSeriesIdentifier = (item) => {
|
|
5
5
|
if (item instanceof Highcharts.Point) {
|
|
6
6
|
return item.name;
|
|
@@ -1,94 +1,94 @@
|
|
|
1
1
|
export default options;
|
|
2
2
|
declare namespace options {
|
|
3
3
|
namespace chart {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
let zoomType: string;
|
|
5
|
+
let backgroundColor: string;
|
|
6
|
+
let className: string;
|
|
7
7
|
}
|
|
8
8
|
namespace title {
|
|
9
9
|
namespace style {
|
|
10
|
-
|
|
10
|
+
let color: string;
|
|
11
11
|
}
|
|
12
12
|
}
|
|
13
13
|
namespace tooltip {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
14
|
+
let split: boolean;
|
|
15
|
+
let shared: boolean;
|
|
16
|
+
let outside: boolean;
|
|
17
|
+
let followPointer: boolean;
|
|
18
18
|
namespace dateTimeLabelFormats {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
19
|
+
let millisecond: string;
|
|
20
|
+
let second: string;
|
|
21
|
+
let minute: string;
|
|
22
|
+
let hour: string;
|
|
23
|
+
let day: string;
|
|
24
|
+
let week: string;
|
|
25
|
+
let quarter: string;
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
28
|
namespace legend {
|
|
29
29
|
namespace itemStyle {
|
|
30
|
-
|
|
30
|
+
let color_1: string;
|
|
31
31
|
export { color_1 as color };
|
|
32
32
|
}
|
|
33
33
|
namespace itemHoverStyle {
|
|
34
|
-
|
|
34
|
+
let color_2: string;
|
|
35
35
|
export { color_2 as color };
|
|
36
36
|
}
|
|
37
37
|
namespace itemHiddenStyle {
|
|
38
|
-
|
|
38
|
+
let color_3: string;
|
|
39
39
|
export { color_3 as color };
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
namespace xAxis {
|
|
43
|
-
export
|
|
44
|
-
export
|
|
45
|
-
export
|
|
43
|
+
export let crosshair: boolean;
|
|
44
|
+
export let gridLineColor: string;
|
|
45
|
+
export let lineColor: string;
|
|
46
46
|
export namespace labels {
|
|
47
47
|
export namespace style_1 {
|
|
48
|
-
|
|
48
|
+
let color_4: string;
|
|
49
49
|
export { color_4 as color };
|
|
50
50
|
}
|
|
51
51
|
export { style_1 as style };
|
|
52
52
|
}
|
|
53
|
-
export
|
|
54
|
-
export
|
|
55
|
-
export
|
|
53
|
+
export let tickPixelInterval: number;
|
|
54
|
+
export let tickColor: string;
|
|
55
|
+
export let tickmarkPlacement: string;
|
|
56
56
|
export namespace dateTimeLabelFormats_1 {
|
|
57
|
-
|
|
57
|
+
let day_1: string;
|
|
58
58
|
export { day_1 as day };
|
|
59
|
-
|
|
59
|
+
let week_1: string;
|
|
60
60
|
export { week_1 as week };
|
|
61
|
-
|
|
61
|
+
let quarter_1: string;
|
|
62
62
|
export { quarter_1 as quarter };
|
|
63
63
|
}
|
|
64
64
|
export { dateTimeLabelFormats_1 as dateTimeLabelFormats };
|
|
65
65
|
}
|
|
66
66
|
namespace yAxis {
|
|
67
|
-
|
|
67
|
+
let gridLineColor_1: string;
|
|
68
68
|
export { gridLineColor_1 as gridLineColor };
|
|
69
|
-
|
|
69
|
+
let lineColor_1: string;
|
|
70
70
|
export { lineColor_1 as lineColor };
|
|
71
71
|
export namespace labels_1 {
|
|
72
72
|
export namespace style_2 {
|
|
73
|
-
|
|
73
|
+
let color_5: string;
|
|
74
74
|
export { color_5 as color };
|
|
75
75
|
}
|
|
76
76
|
export { style_2 as style };
|
|
77
77
|
}
|
|
78
78
|
export { labels_1 as labels };
|
|
79
|
-
|
|
79
|
+
let tickColor_1: string;
|
|
80
80
|
export { tickColor_1 as tickColor };
|
|
81
81
|
export namespace stackLabels {
|
|
82
82
|
export namespace style_3 {
|
|
83
|
-
export
|
|
84
|
-
|
|
83
|
+
export let textOutline: string;
|
|
84
|
+
let color_6: string;
|
|
85
85
|
export { color_6 as color };
|
|
86
86
|
}
|
|
87
87
|
export { style_3 as style };
|
|
88
88
|
}
|
|
89
89
|
export namespace title_1 {
|
|
90
90
|
export namespace style_4 {
|
|
91
|
-
|
|
91
|
+
let color_7: string;
|
|
92
92
|
export { color_7 as color };
|
|
93
93
|
}
|
|
94
94
|
export { style_4 as style };
|
|
@@ -97,27 +97,27 @@ declare namespace options {
|
|
|
97
97
|
}
|
|
98
98
|
namespace plotOptions {
|
|
99
99
|
export namespace series {
|
|
100
|
-
export
|
|
100
|
+
export let borderColor: string;
|
|
101
101
|
export namespace label {
|
|
102
|
-
|
|
102
|
+
let enabled: boolean;
|
|
103
103
|
}
|
|
104
104
|
export namespace tooltip_1 {
|
|
105
|
-
|
|
106
|
-
|
|
105
|
+
let headerFormat: string;
|
|
106
|
+
let pointFormat: string;
|
|
107
107
|
}
|
|
108
108
|
export { tooltip_1 as tooltip };
|
|
109
109
|
export namespace dataLabels {
|
|
110
110
|
export namespace style_5 {
|
|
111
|
-
|
|
111
|
+
let textOutline_1: string;
|
|
112
112
|
export { textOutline_1 as textOutline };
|
|
113
|
-
|
|
113
|
+
let color_8: string;
|
|
114
114
|
export { color_8 as color };
|
|
115
115
|
}
|
|
116
116
|
export { style_5 as style };
|
|
117
117
|
}
|
|
118
|
-
export
|
|
118
|
+
export let turboThreshold: number;
|
|
119
119
|
}
|
|
120
|
-
export
|
|
120
|
+
export let area: {
|
|
121
121
|
boostThreshold: number;
|
|
122
122
|
} & {
|
|
123
123
|
states: {
|
|
@@ -157,7 +157,7 @@ declare namespace options {
|
|
|
157
157
|
};
|
|
158
158
|
};
|
|
159
159
|
export { first as areaspline };
|
|
160
|
-
export
|
|
160
|
+
export let bar: {
|
|
161
161
|
states: {
|
|
162
162
|
hover: {
|
|
163
163
|
lineWidthPlus: number;
|
|
@@ -186,7 +186,7 @@ declare namespace options {
|
|
|
186
186
|
};
|
|
187
187
|
};
|
|
188
188
|
};
|
|
189
|
-
export
|
|
189
|
+
export let column: {
|
|
190
190
|
states: {
|
|
191
191
|
hover: {
|
|
192
192
|
lineWidthPlus: number;
|
|
@@ -215,7 +215,7 @@ declare namespace options {
|
|
|
215
215
|
};
|
|
216
216
|
};
|
|
217
217
|
};
|
|
218
|
-
export
|
|
218
|
+
export let line: {
|
|
219
219
|
states: {
|
|
220
220
|
hover: {
|
|
221
221
|
lineWidthPlus: number;
|
|
@@ -253,7 +253,7 @@ declare namespace options {
|
|
|
253
253
|
};
|
|
254
254
|
};
|
|
255
255
|
export { first as spline };
|
|
256
|
-
export
|
|
256
|
+
export let arearange: {
|
|
257
257
|
tooltip: {
|
|
258
258
|
pointFormat: string;
|
|
259
259
|
};
|
|
@@ -278,61 +278,61 @@ declare namespace options {
|
|
|
278
278
|
};
|
|
279
279
|
export namespace scatter {
|
|
280
280
|
export namespace tooltip_2 {
|
|
281
|
-
|
|
281
|
+
let headerFormat_1: string;
|
|
282
282
|
export { headerFormat_1 as headerFormat };
|
|
283
|
-
|
|
283
|
+
let pointFormat_1: string;
|
|
284
284
|
export { pointFormat_1 as pointFormat };
|
|
285
285
|
}
|
|
286
286
|
export { tooltip_2 as tooltip };
|
|
287
287
|
}
|
|
288
288
|
export namespace bubble {
|
|
289
289
|
export namespace tooltip_3 {
|
|
290
|
-
|
|
290
|
+
let headerFormat_2: string;
|
|
291
291
|
export { headerFormat_2 as headerFormat };
|
|
292
|
-
|
|
292
|
+
let pointFormat_2: string;
|
|
293
293
|
export { pointFormat_2 as pointFormat };
|
|
294
294
|
}
|
|
295
295
|
export { tooltip_3 as tooltip };
|
|
296
296
|
}
|
|
297
297
|
export namespace sankey {
|
|
298
298
|
export namespace tooltip_4 {
|
|
299
|
-
|
|
299
|
+
let headerFormat_3: string;
|
|
300
300
|
export { headerFormat_3 as headerFormat };
|
|
301
|
-
|
|
301
|
+
let pointFormat_3: string;
|
|
302
302
|
export { pointFormat_3 as pointFormat };
|
|
303
303
|
}
|
|
304
304
|
export { tooltip_4 as tooltip };
|
|
305
305
|
}
|
|
306
306
|
export namespace heatmap {
|
|
307
307
|
export namespace tooltip_5 {
|
|
308
|
-
|
|
308
|
+
let headerFormat_4: string;
|
|
309
309
|
export { headerFormat_4 as headerFormat };
|
|
310
|
-
|
|
310
|
+
let pointFormat_4: string;
|
|
311
311
|
export { pointFormat_4 as pointFormat };
|
|
312
312
|
}
|
|
313
313
|
export { tooltip_5 as tooltip };
|
|
314
314
|
}
|
|
315
315
|
export namespace treemap {
|
|
316
316
|
export namespace tooltip_6 {
|
|
317
|
-
|
|
317
|
+
let headerFormat_5: null;
|
|
318
318
|
export { headerFormat_5 as headerFormat };
|
|
319
|
-
|
|
319
|
+
let pointFormat_5: string;
|
|
320
320
|
export { pointFormat_5 as pointFormat };
|
|
321
321
|
}
|
|
322
322
|
export { tooltip_6 as tooltip };
|
|
323
323
|
}
|
|
324
324
|
export namespace timeline {
|
|
325
325
|
export namespace tooltip_7 {
|
|
326
|
-
|
|
326
|
+
let headerFormat_6: string;
|
|
327
327
|
export { headerFormat_6 as headerFormat };
|
|
328
|
-
|
|
328
|
+
let pointFormat_6: string;
|
|
329
329
|
export { pointFormat_6 as pointFormat };
|
|
330
330
|
}
|
|
331
331
|
export { tooltip_7 as tooltip };
|
|
332
332
|
}
|
|
333
|
-
export
|
|
334
|
-
export
|
|
335
|
-
export
|
|
333
|
+
export let variwide: {};
|
|
334
|
+
export let waterfall: {};
|
|
335
|
+
export let pie: {
|
|
336
336
|
tooltip: {
|
|
337
337
|
headerFormat: null;
|
|
338
338
|
pointFormat: string;
|
|
@@ -354,36 +354,36 @@ declare namespace options {
|
|
|
354
354
|
};
|
|
355
355
|
export namespace histogram {
|
|
356
356
|
export namespace tooltip_8 {
|
|
357
|
-
|
|
357
|
+
let headerFormat_7: null;
|
|
358
358
|
export { headerFormat_7 as headerFormat };
|
|
359
|
-
|
|
359
|
+
let pointFormat_7: string;
|
|
360
360
|
export { pointFormat_7 as pointFormat };
|
|
361
361
|
}
|
|
362
362
|
export { tooltip_8 as tooltip };
|
|
363
363
|
}
|
|
364
|
-
export
|
|
365
|
-
export
|
|
364
|
+
export let bellcurve: {};
|
|
365
|
+
export let streamgraph: {};
|
|
366
366
|
export namespace ohlc {
|
|
367
367
|
export namespace tooltip_9 {
|
|
368
|
-
|
|
368
|
+
let pointFormat_8: string;
|
|
369
369
|
export { pointFormat_8 as pointFormat };
|
|
370
370
|
}
|
|
371
371
|
export { tooltip_9 as tooltip };
|
|
372
372
|
}
|
|
373
|
-
export
|
|
374
|
-
export
|
|
373
|
+
export let ema: {};
|
|
374
|
+
export let sma: {};
|
|
375
375
|
export namespace wordcloud {
|
|
376
376
|
export namespace tooltip_10 {
|
|
377
|
-
|
|
377
|
+
let pointFormat_9: string;
|
|
378
378
|
export { pointFormat_9 as pointFormat };
|
|
379
379
|
}
|
|
380
380
|
export { tooltip_10 as tooltip };
|
|
381
381
|
}
|
|
382
382
|
export namespace xrange {
|
|
383
383
|
export namespace tooltip_11 {
|
|
384
|
-
|
|
384
|
+
let headerFormat_8: string;
|
|
385
385
|
export { headerFormat_8 as headerFormat };
|
|
386
|
-
|
|
386
|
+
let pointFormat_10: string;
|
|
387
387
|
export { pointFormat_10 as pointFormat };
|
|
388
388
|
}
|
|
389
389
|
export { tooltip_11 as tooltip };
|
|
@@ -392,7 +392,7 @@ declare namespace options {
|
|
|
392
392
|
export { second as funnel };
|
|
393
393
|
export namespace boxplot {
|
|
394
394
|
export namespace tooltip_12 {
|
|
395
|
-
|
|
395
|
+
let pointFormat_11: string;
|
|
396
396
|
export { pointFormat_11 as pointFormat };
|
|
397
397
|
}
|
|
398
398
|
export { tooltip_12 as tooltip };
|
|
@@ -401,39 +401,39 @@ declare namespace options {
|
|
|
401
401
|
namespace exporting {
|
|
402
402
|
namespace buttons {
|
|
403
403
|
namespace contextButton {
|
|
404
|
-
|
|
404
|
+
let enabled_1: boolean;
|
|
405
405
|
export { enabled_1 as enabled };
|
|
406
406
|
}
|
|
407
407
|
}
|
|
408
408
|
}
|
|
409
409
|
namespace rangeSelector {
|
|
410
|
-
|
|
410
|
+
let enabled_2: boolean;
|
|
411
411
|
export { enabled_2 as enabled };
|
|
412
|
-
export
|
|
412
|
+
export let inputEnabled: boolean;
|
|
413
413
|
}
|
|
414
414
|
namespace scrollbar {
|
|
415
|
-
|
|
415
|
+
let enabled_3: boolean;
|
|
416
416
|
export { enabled_3 as enabled };
|
|
417
|
-
export
|
|
418
|
-
export
|
|
419
|
-
export
|
|
420
|
-
export
|
|
421
|
-
export
|
|
422
|
-
export
|
|
423
|
-
export
|
|
417
|
+
export let barBackgroundColor: string;
|
|
418
|
+
export let barBorderColor: string;
|
|
419
|
+
export let buttonArrowColor: string;
|
|
420
|
+
export let buttonBorderColor: string;
|
|
421
|
+
export let buttonBackgroundColor: string;
|
|
422
|
+
export let trackBackgroundColor: string;
|
|
423
|
+
export let trackBorderColor: string;
|
|
424
424
|
}
|
|
425
425
|
namespace navigator {
|
|
426
|
-
export
|
|
427
|
-
export
|
|
426
|
+
export let height: number;
|
|
427
|
+
export let outlineColor: string;
|
|
428
428
|
export namespace xAxis_1 {
|
|
429
|
-
|
|
429
|
+
let gridLineColor_2: string;
|
|
430
430
|
export { gridLineColor_2 as gridLineColor };
|
|
431
431
|
}
|
|
432
432
|
export { xAxis_1 as xAxis };
|
|
433
433
|
export namespace handles {
|
|
434
|
-
|
|
434
|
+
let backgroundColor_1: string;
|
|
435
435
|
export { backgroundColor_1 as backgroundColor };
|
|
436
|
-
|
|
436
|
+
let borderColor_1: string;
|
|
437
437
|
export { borderColor_1 as borderColor };
|
|
438
438
|
}
|
|
439
439
|
}
|
|
@@ -441,19 +441,19 @@ declare namespace options {
|
|
|
441
441
|
declare namespace first {
|
|
442
442
|
namespace states {
|
|
443
443
|
namespace hover {
|
|
444
|
-
|
|
444
|
+
let lineWidthPlus: number;
|
|
445
445
|
}
|
|
446
446
|
}
|
|
447
447
|
namespace dataGrouping {
|
|
448
|
-
|
|
448
|
+
let approximation: string;
|
|
449
449
|
}
|
|
450
450
|
namespace marker {
|
|
451
|
-
|
|
451
|
+
let enabled_4: boolean;
|
|
452
452
|
export { enabled_4 as enabled };
|
|
453
|
-
export
|
|
453
|
+
export let radius: number;
|
|
454
454
|
export namespace states_1 {
|
|
455
455
|
export namespace hover_1 {
|
|
456
|
-
|
|
456
|
+
let radiusPlus: number;
|
|
457
457
|
}
|
|
458
458
|
export { hover_1 as hover };
|
|
459
459
|
}
|
|
@@ -461,8 +461,8 @@ declare namespace first {
|
|
|
461
461
|
}
|
|
462
462
|
}
|
|
463
463
|
declare namespace second_1 {
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
464
|
+
let allowPointSelect: boolean;
|
|
465
|
+
let slicedOffset: number;
|
|
466
|
+
let cursor: string;
|
|
467
|
+
let showInLegend: boolean;
|
|
468
468
|
}
|
|
@@ -12,15 +12,44 @@ export { isSafari } from './isSafari';
|
|
|
12
12
|
export { mergeArrayWithObject } from './mergeArrayWithObject';
|
|
13
13
|
export { numberFormat } from './numberFormat';
|
|
14
14
|
export { setNavigatorDefaultPeriod } from './setNavigatorDefaultPeriod';
|
|
15
|
-
export declare const getSortedData: <T extends Record<string, any>>(data: T[], sort?: HighchartsSortData) => (number | T | (() => IterableIterator<T>) |
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
15
|
+
export declare const getSortedData: <T extends Record<string, any>>(data: T[], sort?: HighchartsSortData) => (number | T | (() => IterableIterator<T>) | {
|
|
16
|
+
[x: number]: boolean | undefined;
|
|
17
|
+
length?: boolean | undefined;
|
|
18
|
+
toString?: boolean | undefined;
|
|
19
|
+
toLocaleString?: boolean | undefined;
|
|
20
|
+
pop?: boolean | undefined;
|
|
21
|
+
push?: boolean | undefined;
|
|
22
|
+
concat?: boolean | undefined;
|
|
23
|
+
join?: boolean | undefined;
|
|
24
|
+
reverse?: boolean | undefined;
|
|
25
|
+
shift?: boolean | undefined;
|
|
26
|
+
slice?: boolean | undefined;
|
|
27
|
+
sort?: boolean | undefined;
|
|
28
|
+
splice?: boolean | undefined;
|
|
29
|
+
unshift?: boolean | undefined;
|
|
30
|
+
indexOf?: boolean | undefined;
|
|
31
|
+
lastIndexOf?: boolean | undefined;
|
|
32
|
+
every?: boolean | undefined;
|
|
33
|
+
some?: boolean | undefined;
|
|
34
|
+
forEach?: boolean | undefined;
|
|
35
|
+
map?: boolean | undefined;
|
|
36
|
+
filter?: boolean | undefined;
|
|
37
|
+
reduce?: boolean | undefined;
|
|
38
|
+
reduceRight?: boolean | undefined;
|
|
39
|
+
find?: boolean | undefined;
|
|
40
|
+
findIndex?: boolean | undefined;
|
|
41
|
+
fill?: boolean | undefined;
|
|
42
|
+
copyWithin?: boolean | undefined;
|
|
43
|
+
entries?: boolean | undefined;
|
|
44
|
+
keys?: boolean | undefined;
|
|
45
|
+
values?: boolean | undefined;
|
|
46
|
+
includes?: boolean | undefined;
|
|
47
|
+
flatMap?: boolean | undefined;
|
|
48
|
+
flat?: boolean | undefined;
|
|
49
|
+
[Symbol.iterator]?: boolean | undefined;
|
|
50
|
+
readonly [Symbol.unscopables]?: boolean | undefined;
|
|
51
|
+
at?: boolean | undefined;
|
|
52
|
+
} | (() => string) | (() => string) | (() => T | undefined) | ((...items: T[]) => number) | {
|
|
24
53
|
(...items: ConcatArray<T>[]): T[];
|
|
25
54
|
(...items: (T | ConcatArray<T>)[]): T[];
|
|
26
55
|
} | ((separator?: string | undefined) => string) | (() => T[]) | (() => T | undefined) | ((start?: number | undefined, end?: number | undefined) => T[]) | ((compareFn?: ((a: T, b: T) => number) | undefined) => T[]) | {
|
|
@@ -41,6 +70,6 @@ export declare const getSortedData: <T extends Record<string, any>>(data: T[], s
|
|
|
41
70
|
(callbackfn: (previousValue: T, currentValue: T, currentIndex: number, array: T[]) => T, initialValue: T): T;
|
|
42
71
|
<U_2>(callbackfn: (previousValue: U_2, currentValue: T, currentIndex: number, array: T[]) => U_2, initialValue: U_2): U_2;
|
|
43
72
|
} | {
|
|
44
|
-
<S_2 extends T>(predicate: (
|
|
73
|
+
<S_2 extends T>(predicate: (value: T, index: number, obj: T[]) => value is S_2, thisArg?: any): S_2 | undefined;
|
|
45
74
|
(predicate: (value: T, index: number, obj: T[]) => unknown, thisArg?: any): T | undefined;
|
|
46
75
|
} | ((predicate: (value: T, index: number, obj: T[]) => unknown, thisArg?: any) => number) | ((value: T, start?: number | undefined, end?: number | undefined) => T[]) | ((target: number, start: number, end?: number | undefined) => T[]) | (() => IterableIterator<[number, T]>) | (() => IterableIterator<number>) | (() => IterableIterator<T>) | ((searchElement: T, fromIndex?: number | undefined) => boolean) | (<U_3, This = undefined>(callback: (this: This, value: T, index: number, array: T[]) => U_3 | readonly U_3[], thisArg?: This | undefined) => U_3[]) | (<A, D extends number = 1>(this: A, depth?: D | undefined) => FlatArray<A, D>[]) | ((index: number) => T | undefined))[];
|
|
@@ -8,12 +8,12 @@
|
|
|
8
8
|
}
|
|
9
9
|
|
|
10
10
|
.chartkit-graph .highcharts-legend .highcharts-coloraxis-labels text {
|
|
11
|
-
fill: var(--
|
|
12
|
-
color: var(--
|
|
11
|
+
fill: var(--g-color-text-secondary) !important;
|
|
12
|
+
color: var(--g-color-text-secondary) !important;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
.chartkit-graph .highcharts-legend .highcharts-coloraxis-grid path {
|
|
16
|
-
stroke: var(--
|
|
16
|
+
stroke: var(--g-color-base-background);
|
|
17
17
|
}
|
|
18
18
|
|
|
19
19
|
.chartkit-tooltip {
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
border: none;
|
|
32
32
|
border-radius: 0;
|
|
33
33
|
box-shadow: none;
|
|
34
|
-
border-bottom: 1px solid var(--
|
|
34
|
+
border-bottom: 1px solid var(--g-color-line-generic);
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
.chartkit-tooltip_yandex-map {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ChartKitHolidays } from '../../../../types';
|
|
2
|
-
import type {
|
|
2
|
+
import type { ExtendedHChart, Highcharts, HighchartsComment, HighchartsWidgetData } from '../../types';
|
|
3
3
|
import type { ConfigOptions } from './types';
|
|
4
4
|
import './graph.css';
|
|
5
5
|
type GetGraphArgs = {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { addHolidays } from './add-holidays';
|
|
1
2
|
import { drawComments } from './comments/drawing';
|
|
2
|
-
import { prepareData } from './prepare-data';
|
|
3
3
|
import { prepareConfig } from './config/config';
|
|
4
4
|
import { initHighcharts } from './highcharts/highcharts';
|
|
5
|
-
import {
|
|
5
|
+
import { prepareData } from './prepare-data';
|
|
6
6
|
import './graph.css';
|
|
7
7
|
let highchartsInitialized = false;
|
|
8
8
|
function getGraph({ options, data, comments, isMobile, holidays }) {
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import Highcharts from 'highcharts';
|
|
3
3
|
import get from 'lodash/get';
|
|
4
4
|
import { i18n } from '../../../../../i18n';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
5
|
+
import { getTooltipPositioner, handleScroll, hideFixedTooltip, synchronizeTooltipTablesCellsWidth, } from '../config/config';
|
|
6
|
+
import { TOOLTIP_CONTAINER_CLASS_NAME, TOOLTIP_FOOTER_CLASS_NAME, TOOLTIP_LIST_CLASS_NAME, TOOLTIP_ROW_CLASS_NAME, TOOLTIP_ROW_NAME_CLASS_NANE, } from '../tooltip';
|
|
7
7
|
import colors from './colors';
|
|
8
8
|
import { calculateClosestPointManually } from './utils';
|
|
9
9
|
function formatQ(timestamp) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import lodashMin from 'lodash/min';
|
|
2
1
|
import { dateTime } from '@gravity-ui/date-utils';
|
|
2
|
+
import lodashMin from 'lodash/min';
|
|
3
3
|
import { i18n } from '../../../../i18n';
|
|
4
|
-
import {
|
|
4
|
+
import { CHARTKIT_ERROR_CODE, ChartKitError } from '../../../../libs';
|
|
5
5
|
import { DEFAULT_LINES_LIMIT } from './constants';
|
|
6
6
|
function prepareValue(value, firstValue, options) {
|
|
7
7
|
if (value === null) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/* eslint-disable complexity */
|
|
2
2
|
import _escape from 'lodash/escape';
|
|
3
3
|
import { i18n } from '../../../../../i18n';
|
|
4
|
-
import { renderShapeIcon } from './render-shape-icon';
|
|
5
4
|
import { escapeHTML } from './helpers';
|
|
5
|
+
import { renderShapeIcon } from './render-shape-icon';
|
|
6
6
|
import './tooltip.css';
|
|
7
7
|
export const SERIES_NAME_DATA_ATTRIBUTE = 'data-series-name';
|
|
8
8
|
export const SERIES_IDX_DATA_ATTRIBUTE = 'data-series-idx';
|