@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.
Files changed (118) hide show
  1. package/build/components/ChartKit.css +20 -20
  2. package/build/components/ChartKit.d.ts +2 -2
  3. package/build/components/ErrorBoundary/ErrorBoundary.js +1 -1
  4. package/build/libs/settings/settings.d.ts +1 -1
  5. package/build/libs/settings/settings.js +1 -1
  6. package/build/plugins/d3/examples/area/PercentStacking.js +1 -1
  7. package/build/plugins/d3/examples/area/StackedArea.js +1 -1
  8. package/build/plugins/d3/examples/combined/LineAndBarX.js +1 -1
  9. package/build/plugins/d3/examples/pie/DonutWithTotals.js +1 -1
  10. package/build/plugins/d3/renderer/D3Widget.d.ts +1 -1
  11. package/build/plugins/d3/renderer/D3Widget.js +1 -1
  12. package/build/plugins/d3/renderer/components/AxisX.d.ts +1 -1
  13. package/build/plugins/d3/renderer/components/AxisX.js +2 -2
  14. package/build/plugins/d3/renderer/components/AxisY.js +1 -1
  15. package/build/plugins/d3/renderer/components/Chart.js +13 -4
  16. package/build/plugins/d3/renderer/components/Legend.d.ts +1 -1
  17. package/build/plugins/d3/renderer/components/Legend.js +2 -2
  18. package/build/plugins/d3/renderer/components/Tooltip/DefaultContent.js +1 -1
  19. package/build/plugins/d3/renderer/components/Tooltip/TooltipTriggerArea.js +19 -7
  20. package/build/plugins/d3/renderer/components/Tooltip/index.js +1 -1
  21. package/build/plugins/d3/renderer/components/styles.css +1 -1
  22. package/build/plugins/d3/renderer/d3-dispatcher.js +1 -1
  23. package/build/plugins/d3/renderer/hooks/useAxisScales/index.d.ts +1 -1
  24. package/build/plugins/d3/renderer/hooks/useAxisScales/index.js +2 -2
  25. package/build/plugins/d3/renderer/hooks/useChartOptions/types.d.ts +1 -1
  26. package/build/plugins/d3/renderer/hooks/useChartOptions/x-axis.d.ts +1 -1
  27. package/build/plugins/d3/renderer/hooks/useChartOptions/x-axis.js +1 -1
  28. package/build/plugins/d3/renderer/hooks/useChartOptions/y-axis.js +2 -2
  29. package/build/plugins/d3/renderer/hooks/useSeries/index.d.ts +1 -1
  30. package/build/plugins/d3/renderer/hooks/useSeries/index.js +2 -2
  31. package/build/plugins/d3/renderer/hooks/useSeries/prepare-area.d.ts +1 -1
  32. package/build/plugins/d3/renderer/hooks/useSeries/prepare-area.js +1 -1
  33. package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-x.js +1 -1
  34. package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-y.js +2 -2
  35. package/build/plugins/d3/renderer/hooks/useSeries/prepare-legend.d.ts +1 -1
  36. package/build/plugins/d3/renderer/hooks/useSeries/prepare-legend.js +1 -1
  37. package/build/plugins/d3/renderer/hooks/useSeries/prepare-line.d.ts +1 -1
  38. package/build/plugins/d3/renderer/hooks/useSeries/prepare-line.js +2 -1
  39. package/build/plugins/d3/renderer/hooks/useSeries/prepare-pie.js +3 -2
  40. package/build/plugins/d3/renderer/hooks/useSeries/prepare-scatter.d.ts +1 -1
  41. package/build/plugins/d3/renderer/hooks/useSeries/prepare-scatter.js +2 -2
  42. package/build/plugins/d3/renderer/hooks/useSeries/prepareSeries.js +2 -2
  43. package/build/plugins/d3/renderer/hooks/useSeries/types.d.ts +4 -2
  44. package/build/plugins/d3/renderer/hooks/useSeries/utils.d.ts +2 -2
  45. package/build/plugins/d3/renderer/hooks/useSeries/utils.js +1 -1
  46. package/build/plugins/d3/renderer/hooks/useShapes/area/index.js +2 -2
  47. package/build/plugins/d3/renderer/hooks/useShapes/area/prepare-data.d.ts +2 -2
  48. package/build/plugins/d3/renderer/hooks/useShapes/area/prepare-data.js +1 -1
  49. package/build/plugins/d3/renderer/hooks/useShapes/area/types.d.ts +1 -1
  50. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/index.js +3 -2
  51. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/prepare-data.js +1 -0
  52. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/types.d.ts +2 -1
  53. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/index.js +3 -2
  54. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/prepare-data.js +1 -0
  55. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/types.d.ts +1 -0
  56. package/build/plugins/d3/renderer/hooks/useShapes/index.d.ts +6 -6
  57. package/build/plugins/d3/renderer/hooks/useShapes/index.js +6 -6
  58. package/build/plugins/d3/renderer/hooks/useShapes/line/index.js +3 -2
  59. package/build/plugins/d3/renderer/hooks/useShapes/line/prepare-data.d.ts +2 -2
  60. package/build/plugins/d3/renderer/hooks/useShapes/line/prepare-data.js +2 -1
  61. package/build/plugins/d3/renderer/hooks/useShapes/line/types.d.ts +3 -2
  62. package/build/plugins/d3/renderer/hooks/useShapes/marker.d.ts +1 -1
  63. package/build/plugins/d3/renderer/hooks/useShapes/marker.js +10 -3
  64. package/build/plugins/d3/renderer/hooks/useShapes/pie/index.js +20 -11
  65. package/build/plugins/d3/renderer/hooks/useShapes/pie/prepare-data.js +1 -0
  66. package/build/plugins/d3/renderer/hooks/useShapes/pie/types.d.ts +3 -2
  67. package/build/plugins/d3/renderer/hooks/useShapes/pie/utils.js +1 -1
  68. package/build/plugins/d3/renderer/hooks/useShapes/scatter/index.js +14 -4
  69. package/build/plugins/d3/renderer/hooks/useShapes/scatter/prepare-data.js +2 -0
  70. package/build/plugins/d3/renderer/hooks/useShapes/scatter/types.d.ts +1 -0
  71. package/build/plugins/d3/renderer/hooks/useShapes/treemap/index.js +11 -4
  72. package/build/plugins/d3/renderer/hooks/useShapes/utils.d.ts +1 -1
  73. package/build/plugins/d3/renderer/hooks/useTooltip/index.d.ts +1 -1
  74. package/build/plugins/d3/renderer/utils/axis-generators/bottom.js +1 -1
  75. package/build/plugins/d3/renderer/utils/axis.d.ts +1 -1
  76. package/build/plugins/d3/renderer/utils/index.js +3 -3
  77. package/build/plugins/d3/renderer/utils/symbol.js +1 -1
  78. package/build/plugins/d3/renderer/validation/index.js +1 -1
  79. package/build/plugins/highcharts/renderer/components/HighchartsComponent.d.ts +1 -1
  80. package/build/plugins/highcharts/renderer/components/HighchartsComponent.js +2 -2
  81. package/build/plugins/highcharts/renderer/components/HighchartsReact.js +7 -1
  82. package/build/plugins/highcharts/renderer/components/StyledSplitPane/StyledSplitPane.css +1 -1
  83. package/build/plugins/highcharts/renderer/helpers/config/config.js +15 -15
  84. package/build/plugins/highcharts/renderer/helpers/config/handleLegendItemClick.js +1 -1
  85. package/build/plugins/highcharts/renderer/helpers/config/options.d.ts +98 -98
  86. package/build/plugins/highcharts/renderer/helpers/config/options.js +1 -1
  87. package/build/plugins/highcharts/renderer/helpers/config/utils/index.d.ts +39 -10
  88. package/build/plugins/highcharts/renderer/helpers/graph.css +4 -4
  89. package/build/plugins/highcharts/renderer/helpers/graph.d.ts +1 -1
  90. package/build/plugins/highcharts/renderer/helpers/graph.js +2 -2
  91. package/build/plugins/highcharts/renderer/helpers/highcharts/highcharts.js +2 -2
  92. package/build/plugins/highcharts/renderer/helpers/prepare-data.js +2 -2
  93. package/build/plugins/highcharts/renderer/helpers/tooltip/index.js +1 -1
  94. package/build/plugins/highcharts/renderer/helpers/tooltip/tooltip.css +6 -7
  95. package/build/plugins/highcharts/types/highcharts-extends.d.ts +1 -0
  96. package/build/plugins/highcharts/types/widget.d.ts +2 -2
  97. package/build/plugins/indicator/renderer/IndicatorWidget.css +1 -1
  98. package/build/plugins/indicator/renderer/IndicatorWidget.js +1 -1
  99. package/build/plugins/shared/format-number/format-number.d.ts +1 -1
  100. package/build/plugins/shared/format-number/format-number.js +2 -2
  101. package/build/plugins/shared/format-number/format-number.test.js +1 -1
  102. package/build/plugins/yagr/renderer/YagrWidget.css +1 -1
  103. package/build/plugins/yagr/renderer/YagrWidget.js +5 -3
  104. package/build/plugins/yagr/renderer/tooltip/tooltip.css +15 -16
  105. package/build/plugins/yagr/renderer/utils.d.ts +1 -1
  106. package/build/plugins/yagr/renderer/utils.js +1 -1
  107. package/build/types/index.d.ts +1 -1
  108. package/build/types/widget-data/area.d.ts +15 -0
  109. package/build/types/widget-data/bar-x.d.ts +3 -1
  110. package/build/types/widget-data/bar-y.d.ts +3 -1
  111. package/build/types/widget-data/chart.d.ts +6 -0
  112. package/build/types/widget-data/line.d.ts +10 -1
  113. package/build/types/widget-data/pie.d.ts +2 -0
  114. package/build/types/widget-data/scatter.d.ts +3 -0
  115. package/build/types/widget-data/series.d.ts +6 -6
  116. package/build/types/widget-data/tooltip.d.ts +3 -3
  117. package/build/types/widget.d.ts +2 -2
  118. 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 throttle from 'lodash/throttle';
9
+ import merge from 'lodash/merge';
10
+ import mergeWith from 'lodash/mergeWith';
10
11
  import pick from 'lodash/pick';
11
- import debounce from 'lodash/debounce';
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 { getCommentsOnLine, drawComments, hideComments, drawOnlyRendererComments, } from '../comments/drawing';
17
- import formatTooltip, { TOOLTIP_ROW_CLASS_NAME, SERIES_NAME_DATA_ATTRIBUTE, TOOLTIP_HEADER_CLASS_NAME, TOOLTIP_LIST_CLASS_NAME, TOOLTIP_FOOTER_CLASS_NAME, TOOLTIP_CONTAINER_CLASS_NAME, TOOLTIP_ROW_NAME_CLASS_NANE, } from '../tooltip';
18
- import defaultOptions from './options';
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(--yc-color-base-special)',
163
- inactiveColor: 'var(--yc-color-base-generic-accent-disabled)',
164
- style: { color: 'var(--yc-color-text-primary)' },
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(--yc-color-text-secondary)' },
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
- const zoomType: string;
5
- const backgroundColor: string;
6
- const className: string;
4
+ let zoomType: string;
5
+ let backgroundColor: string;
6
+ let className: string;
7
7
  }
8
8
  namespace title {
9
9
  namespace style {
10
- const color: string;
10
+ let color: string;
11
11
  }
12
12
  }
13
13
  namespace tooltip {
14
- const split: boolean;
15
- const shared: boolean;
16
- const outside: boolean;
17
- const followPointer: boolean;
14
+ let split: boolean;
15
+ let shared: boolean;
16
+ let outside: boolean;
17
+ let followPointer: boolean;
18
18
  namespace dateTimeLabelFormats {
19
- const millisecond: string;
20
- const second: string;
21
- const minute: string;
22
- const hour: string;
23
- const day: string;
24
- const week: string;
25
- const quarter: string;
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
- const color_1: string;
30
+ let color_1: string;
31
31
  export { color_1 as color };
32
32
  }
33
33
  namespace itemHoverStyle {
34
- const color_2: string;
34
+ let color_2: string;
35
35
  export { color_2 as color };
36
36
  }
37
37
  namespace itemHiddenStyle {
38
- const color_3: string;
38
+ let color_3: string;
39
39
  export { color_3 as color };
40
40
  }
41
41
  }
42
42
  namespace xAxis {
43
- export const crosshair: boolean;
44
- export const gridLineColor: string;
45
- export const lineColor: string;
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
- const color_4: string;
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 const tickPixelInterval: number;
54
- export const tickColor: string;
55
- export const tickmarkPlacement: string;
53
+ export let tickPixelInterval: number;
54
+ export let tickColor: string;
55
+ export let tickmarkPlacement: string;
56
56
  export namespace dateTimeLabelFormats_1 {
57
- const day_1: string;
57
+ let day_1: string;
58
58
  export { day_1 as day };
59
- const week_1: string;
59
+ let week_1: string;
60
60
  export { week_1 as week };
61
- const quarter_1: string;
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
- const gridLineColor_1: string;
67
+ let gridLineColor_1: string;
68
68
  export { gridLineColor_1 as gridLineColor };
69
- const lineColor_1: string;
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
- const color_5: string;
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
- const tickColor_1: string;
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 const textOutline: string;
84
- const color_6: string;
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
- const color_7: string;
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 const borderColor: string;
100
+ export let borderColor: string;
101
101
  export namespace label {
102
- const enabled: boolean;
102
+ let enabled: boolean;
103
103
  }
104
104
  export namespace tooltip_1 {
105
- const headerFormat: string;
106
- const pointFormat: string;
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
- const textOutline_1: string;
111
+ let textOutline_1: string;
112
112
  export { textOutline_1 as textOutline };
113
- const color_8: string;
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 const turboThreshold: number;
118
+ export let turboThreshold: number;
119
119
  }
120
- export const area: {
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 const bar: {
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 const column: {
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 const line: {
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 const arearange: {
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
- const headerFormat_1: string;
281
+ let headerFormat_1: string;
282
282
  export { headerFormat_1 as headerFormat };
283
- const pointFormat_1: string;
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
- const headerFormat_2: string;
290
+ let headerFormat_2: string;
291
291
  export { headerFormat_2 as headerFormat };
292
- const pointFormat_2: string;
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
- const headerFormat_3: string;
299
+ let headerFormat_3: string;
300
300
  export { headerFormat_3 as headerFormat };
301
- const pointFormat_3: string;
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
- const headerFormat_4: string;
308
+ let headerFormat_4: string;
309
309
  export { headerFormat_4 as headerFormat };
310
- const pointFormat_4: string;
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
- const headerFormat_5: null;
317
+ let headerFormat_5: null;
318
318
  export { headerFormat_5 as headerFormat };
319
- const pointFormat_5: string;
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
- const headerFormat_6: string;
326
+ let headerFormat_6: string;
327
327
  export { headerFormat_6 as headerFormat };
328
- const pointFormat_6: string;
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 const variwide: {};
334
- export const waterfall: {};
335
- export const pie: {
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
- const headerFormat_7: null;
357
+ let headerFormat_7: null;
358
358
  export { headerFormat_7 as headerFormat };
359
- const pointFormat_7: string;
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 const bellcurve: {};
365
- export const streamgraph: {};
364
+ export let bellcurve: {};
365
+ export let streamgraph: {};
366
366
  export namespace ohlc {
367
367
  export namespace tooltip_9 {
368
- const pointFormat_8: string;
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 const ema: {};
374
- export const sma: {};
373
+ export let ema: {};
374
+ export let sma: {};
375
375
  export namespace wordcloud {
376
376
  export namespace tooltip_10 {
377
- const pointFormat_9: string;
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
- const headerFormat_8: string;
384
+ let headerFormat_8: string;
385
385
  export { headerFormat_8 as headerFormat };
386
- const pointFormat_10: string;
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
- const pointFormat_11: string;
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
- const enabled_1: boolean;
404
+ let enabled_1: boolean;
405
405
  export { enabled_1 as enabled };
406
406
  }
407
407
  }
408
408
  }
409
409
  namespace rangeSelector {
410
- const enabled_2: boolean;
410
+ let enabled_2: boolean;
411
411
  export { enabled_2 as enabled };
412
- export const inputEnabled: boolean;
412
+ export let inputEnabled: boolean;
413
413
  }
414
414
  namespace scrollbar {
415
- const enabled_3: boolean;
415
+ let enabled_3: boolean;
416
416
  export { enabled_3 as enabled };
417
- export const barBackgroundColor: string;
418
- export const barBorderColor: string;
419
- export const buttonArrowColor: string;
420
- export const buttonBorderColor: string;
421
- export const buttonBackgroundColor: string;
422
- export const trackBackgroundColor: string;
423
- export const trackBorderColor: string;
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 const height: number;
427
- export const outlineColor: string;
426
+ export let height: number;
427
+ export let outlineColor: string;
428
428
  export namespace xAxis_1 {
429
- const gridLineColor_2: string;
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
- const backgroundColor_1: string;
434
+ let backgroundColor_1: string;
435
435
  export { backgroundColor_1 as backgroundColor };
436
- const borderColor_1: string;
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
- const lineWidthPlus: number;
444
+ let lineWidthPlus: number;
445
445
  }
446
446
  }
447
447
  namespace dataGrouping {
448
- const approximation: string;
448
+ let approximation: string;
449
449
  }
450
450
  namespace marker {
451
- const enabled_4: boolean;
451
+ let enabled_4: boolean;
452
452
  export { enabled_4 as enabled };
453
- export const radius: number;
453
+ export let radius: number;
454
454
  export namespace states_1 {
455
455
  export namespace hover_1 {
456
- const radiusPlus: number;
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
- const allowPointSelect: boolean;
465
- const slicedOffset: number;
466
- const cursor: string;
467
- const showInLegend: boolean;
464
+ let allowPointSelect: boolean;
465
+ let slicedOffset: number;
466
+ let cursor: string;
467
+ let showInLegend: boolean;
468
468
  }
@@ -163,7 +163,7 @@ const options = {
163
163
  },
164
164
  title: {
165
165
  style: {
166
- color: 'var(--yc-color-text-secondary)',
166
+ color: 'var(--g-color-text-secondary)',
167
167
  },
168
168
  },
169
169
  },
@@ -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
- copyWithin: boolean;
17
- entries: boolean;
18
- fill: boolean;
19
- find: boolean;
20
- findIndex: boolean;
21
- keys: boolean;
22
- values: boolean;
23
- }) | (() => string) | (() => string) | (() => T | undefined) | ((...items: T[]) => number) | {
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: (this: void, value: T, index: number, obj: T[]) => value is S_2, thisArg?: any): S_2 | undefined;
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(--yc-color-text-secondary) !important;
12
- color: var(--yc-color-text-secondary) !important;
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(--yc-color-base-background);
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(--yc-color-line-generic);
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 { Highcharts, HighchartsWidgetData, HighchartsComment, ExtendedHChart } from '../../types';
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 { addHolidays } from './add-holidays';
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 { hideFixedTooltip, getTooltipPositioner, handleScroll, synchronizeTooltipTablesCellsWidth, } from '../config/config';
6
- import { TOOLTIP_ROW_CLASS_NAME, TOOLTIP_LIST_CLASS_NAME, TOOLTIP_FOOTER_CLASS_NAME, TOOLTIP_CONTAINER_CLASS_NAME, TOOLTIP_ROW_NAME_CLASS_NANE, } from '../tooltip';
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 { ChartKitError, CHARTKIT_ERROR_CODE } from '../../../../libs';
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';