@gravity-ui/chartkit 5.17.1 → 5.18.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 (298) hide show
  1. package/build/components/ChartKit.css +0 -1
  2. package/build/components/SplitPane/Pane.d.ts +14 -0
  3. package/build/components/SplitPane/Pane.js +26 -0
  4. package/build/components/SplitPane/Resizer.d.ts +18 -0
  5. package/build/components/SplitPane/Resizer.js +26 -0
  6. package/build/components/SplitPane/SplitPane.d.ts +59 -0
  7. package/build/components/SplitPane/SplitPane.js +235 -0
  8. package/build/{plugins/highcharts/renderer/components/StyledSplitPane → components/SplitPane}/StyledSplitPane.css +0 -1
  9. package/build/{plugins/highcharts/renderer/components/StyledSplitPane → components/SplitPane}/StyledSplitPane.d.ts +1 -1
  10. package/build/{plugins/highcharts/renderer/components/StyledSplitPane → components/SplitPane}/StyledSplitPane.js +3 -3
  11. package/build/components/SplitPane/constants.d.ts +4 -0
  12. package/build/components/SplitPane/constants.js +4 -0
  13. package/build/components/SplitPane/index.d.ts +8 -0
  14. package/build/components/SplitPane/index.js +18 -0
  15. package/build/components/SplitPane/types.d.ts +2 -0
  16. package/build/constants/index.d.ts +1 -0
  17. package/build/constants/index.js +1 -0
  18. package/build/constants/misc.d.ts +10 -0
  19. package/build/constants/misc.js +19 -0
  20. package/build/hooks/index.d.ts +1 -0
  21. package/build/hooks/index.js +1 -0
  22. package/build/hooks/misc.d.ts +1 -0
  23. package/build/hooks/misc.js +8 -0
  24. package/build/plugins/d3/index.d.ts +1 -1
  25. package/build/plugins/d3/index.js +2 -1
  26. package/build/plugins/d3/renderer/D3Widget.d.ts +5 -1
  27. package/build/plugins/d3/renderer/D3Widget.js +31 -66
  28. package/build/plugins/d3/renderer/withSplitPane/TooltipContent.d.ts +8 -0
  29. package/build/plugins/d3/renderer/withSplitPane/TooltipContent.js +12 -0
  30. package/build/plugins/d3/renderer/withSplitPane/useWithSplitPaneState.d.ts +19 -0
  31. package/build/plugins/d3/renderer/withSplitPane/useWithSplitPaneState.js +46 -0
  32. package/build/plugins/d3/renderer/withSplitPane/withSplitPane.d.ts +4 -0
  33. package/build/plugins/d3/renderer/withSplitPane/withSplitPane.js +100 -0
  34. package/build/plugins/d3/types.d.ts +2 -2
  35. package/build/plugins/highcharts/renderer/HighchartsWidget.d.ts +2 -2
  36. package/build/plugins/highcharts/renderer/components/withSplitPane/withSplitPane.js +1 -1
  37. package/build/types/index.js +1 -0
  38. package/build/types/widget-data/pie.d.ts +1 -1
  39. package/build/types/widget.d.ts +6 -3
  40. package/build/utils/index.d.ts +1 -0
  41. package/build/utils/index.js +1 -0
  42. package/build/utils/misc.d.ts +2 -0
  43. package/build/utils/misc.js +7 -0
  44. package/package.json +4 -4
  45. package/build/plugins/d3/examples/ExampleWrapper.d.ts +0 -7
  46. package/build/plugins/d3/examples/ExampleWrapper.js +0 -5
  47. package/build/plugins/d3/examples/area/Basic.d.ts +0 -2
  48. package/build/plugins/d3/examples/area/Basic.js +0 -34
  49. package/build/plugins/d3/examples/area/NegativeValues.d.ts +0 -2
  50. package/build/plugins/d3/examples/area/NegativeValues.js +0 -24
  51. package/build/plugins/d3/examples/area/PercentStacking.d.ts +0 -2
  52. package/build/plugins/d3/examples/area/PercentStacking.js +0 -47
  53. package/build/plugins/d3/examples/area/StackedArea.d.ts +0 -2
  54. package/build/plugins/d3/examples/area/StackedArea.js +0 -47
  55. package/build/plugins/d3/examples/area/TwoYAxis.d.ts +0 -2
  56. package/build/plugins/d3/examples/area/TwoYAxis.js +0 -58
  57. package/build/plugins/d3/examples/bar-x/Basic.d.ts +0 -4
  58. package/build/plugins/d3/examples/bar-x/Basic.js +0 -88
  59. package/build/plugins/d3/examples/bar-x/DataLabels.d.ts +0 -2
  60. package/build/plugins/d3/examples/bar-x/DataLabels.js +0 -48
  61. package/build/plugins/d3/examples/bar-x/GroupedColumns.d.ts +0 -2
  62. package/build/plugins/d3/examples/bar-x/GroupedColumns.js +0 -48
  63. package/build/plugins/d3/examples/bar-x/NegativeValues.d.ts +0 -2
  64. package/build/plugins/d3/examples/bar-x/NegativeValues.js +0 -41
  65. package/build/plugins/d3/examples/bar-x/PercentStack.d.ts +0 -2
  66. package/build/plugins/d3/examples/bar-x/PercentStack.js +0 -47
  67. package/build/plugins/d3/examples/bar-x/StackedColumns.d.ts +0 -2
  68. package/build/plugins/d3/examples/bar-x/StackedColumns.js +0 -47
  69. package/build/plugins/d3/examples/bar-x/TwoYAxis.d.ts +0 -2
  70. package/build/plugins/d3/examples/bar-x/TwoYAxis.js +0 -58
  71. package/build/plugins/d3/examples/bar-y/Basic.d.ts +0 -2
  72. package/build/plugins/d3/examples/bar-y/Basic.js +0 -45
  73. package/build/plugins/d3/examples/bar-y/GroupedColumns.d.ts +0 -2
  74. package/build/plugins/d3/examples/bar-y/GroupedColumns.js +0 -50
  75. package/build/plugins/d3/examples/bar-y/NegativeValues.d.ts +0 -2
  76. package/build/plugins/d3/examples/bar-y/NegativeValues.js +0 -40
  77. package/build/plugins/d3/examples/bar-y/PercentStacking.d.ts +0 -2
  78. package/build/plugins/d3/examples/bar-y/PercentStacking.js +0 -49
  79. package/build/plugins/d3/examples/bar-y/StackedColumns.d.ts +0 -2
  80. package/build/plugins/d3/examples/bar-y/StackedColumns.js +0 -49
  81. package/build/plugins/d3/examples/combined/LineAndBarX.d.ts +0 -2
  82. package/build/plugins/d3/examples/combined/LineAndBarX.js +0 -63
  83. package/build/plugins/d3/examples/line/Basic.d.ts +0 -2
  84. package/build/plugins/d3/examples/line/Basic.js +0 -68
  85. package/build/plugins/d3/examples/line/DataLabels.d.ts +0 -2
  86. package/build/plugins/d3/examples/line/DataLabels.js +0 -91
  87. package/build/plugins/d3/examples/line/LineWithMarkers.d.ts +0 -2
  88. package/build/plugins/d3/examples/line/LineWithMarkers.js +0 -69
  89. package/build/plugins/d3/examples/line/LogarithmicAxis.d.ts +0 -2
  90. package/build/plugins/d3/examples/line/LogarithmicAxis.js +0 -38
  91. package/build/plugins/d3/examples/line/Shapes.d.ts +0 -2
  92. package/build/plugins/d3/examples/line/Shapes.js +0 -93
  93. package/build/plugins/d3/examples/line/TwoYAxis.d.ts +0 -2
  94. package/build/plugins/d3/examples/line/TwoYAxis.js +0 -58
  95. package/build/plugins/d3/examples/mars-weather.d.ts +0 -13
  96. package/build/plugins/d3/examples/mars-weather.js +0 -1203
  97. package/build/plugins/d3/examples/nintendoGames.d.ts +0 -92
  98. package/build/plugins/d3/examples/nintendoGames.js +0 -12264
  99. package/build/plugins/d3/examples/pie/Basic.d.ts +0 -2
  100. package/build/plugins/d3/examples/pie/Basic.js +0 -32
  101. package/build/plugins/d3/examples/pie/Donut.d.ts +0 -2
  102. package/build/plugins/d3/examples/pie/Donut.js +0 -33
  103. package/build/plugins/d3/examples/pie/DonutWithTotals.d.ts +0 -2
  104. package/build/plugins/d3/examples/pie/DonutWithTotals.js +0 -36
  105. package/build/plugins/d3/examples/scatter/Basic.d.ts +0 -2
  106. package/build/plugins/d3/examples/scatter/Basic.js +0 -47
  107. package/build/plugins/d3/examples/scatter/TwoYAxis.d.ts +0 -2
  108. package/build/plugins/d3/examples/scatter/TwoYAxis.js +0 -58
  109. package/build/plugins/d3/renderer/components/AxisX.d.ts +0 -19
  110. package/build/plugins/d3/renderer/components/AxisX.js +0 -108
  111. package/build/plugins/d3/renderer/components/AxisY.d.ts +0 -11
  112. package/build/plugins/d3/renderer/components/AxisY.js +0 -199
  113. package/build/plugins/d3/renderer/components/Chart.d.ts +0 -10
  114. package/build/plugins/d3/renderer/components/Chart.js +0 -145
  115. package/build/plugins/d3/renderer/components/Legend.d.ts +0 -12
  116. package/build/plugins/d3/renderer/components/Legend.js +0 -278
  117. package/build/plugins/d3/renderer/components/PlotTitle.d.ts +0 -7
  118. package/build/plugins/d3/renderer/components/PlotTitle.js +0 -12
  119. package/build/plugins/d3/renderer/components/Title.d.ts +0 -7
  120. package/build/plugins/d3/renderer/components/Title.js +0 -8
  121. package/build/plugins/d3/renderer/components/Tooltip/DefaultContent.d.ts +0 -10
  122. package/build/plugins/d3/renderer/components/Tooltip/DefaultContent.js +0 -102
  123. package/build/plugins/d3/renderer/components/Tooltip/index.d.ts +0 -12
  124. package/build/plugins/d3/renderer/components/Tooltip/index.js +0 -28
  125. package/build/plugins/d3/renderer/components/index.d.ts +0 -1
  126. package/build/plugins/d3/renderer/components/index.js +0 -1
  127. package/build/plugins/d3/renderer/components/styles.css +0 -140
  128. package/build/plugins/d3/renderer/constants/defaults/axis.d.ts +0 -14
  129. package/build/plugins/d3/renderer/constants/defaults/axis.js +0 -18
  130. package/build/plugins/d3/renderer/constants/defaults/index.d.ts +0 -3
  131. package/build/plugins/d3/renderer/constants/defaults/index.js +0 -3
  132. package/build/plugins/d3/renderer/constants/defaults/legend.d.ts +0 -12
  133. package/build/plugins/d3/renderer/constants/defaults/legend.js +0 -12
  134. package/build/plugins/d3/renderer/constants/defaults/series-options.d.ts +0 -24
  135. package/build/plugins/d3/renderer/constants/defaults/series-options.js +0 -106
  136. package/build/plugins/d3/renderer/constants/index.d.ts +0 -3
  137. package/build/plugins/d3/renderer/constants/index.js +0 -24
  138. package/build/plugins/d3/renderer/d3-dispatcher.d.ts +0 -1
  139. package/build/plugins/d3/renderer/d3-dispatcher.js +0 -4
  140. package/build/plugins/d3/renderer/hooks/index.d.ts +0 -10
  141. package/build/plugins/d3/renderer/hooks/index.js +0 -10
  142. package/build/plugins/d3/renderer/hooks/useAxisScales/index.d.ts +0 -25
  143. package/build/plugins/d3/renderer/hooks/useAxisScales/index.js +0 -183
  144. package/build/plugins/d3/renderer/hooks/useChartDimensions/index.d.ts +0 -16
  145. package/build/plugins/d3/renderer/hooks/useChartDimensions/index.js +0 -34
  146. package/build/plugins/d3/renderer/hooks/useChartDimensions/utils.d.ts +0 -10
  147. package/build/plugins/d3/renderer/hooks/useChartDimensions/utils.js +0 -32
  148. package/build/plugins/d3/renderer/hooks/useChartOptions/chart.d.ts +0 -6
  149. package/build/plugins/d3/renderer/hooks/useChartOptions/chart.js +0 -28
  150. package/build/plugins/d3/renderer/hooks/useChartOptions/index.d.ts +0 -7
  151. package/build/plugins/d3/renderer/hooks/useChartOptions/index.js +0 -21
  152. package/build/plugins/d3/renderer/hooks/useChartOptions/title.d.ts +0 -5
  153. package/build/plugins/d3/renderer/hooks/useChartOptions/title.js +0 -18
  154. package/build/plugins/d3/renderer/hooks/useChartOptions/tooltip.d.ts +0 -5
  155. package/build/plugins/d3/renderer/hooks/useChartOptions/tooltip.js +0 -5
  156. package/build/plugins/d3/renderer/hooks/useChartOptions/types.d.ts +0 -47
  157. package/build/plugins/d3/renderer/hooks/useChartOptions/x-axis.d.ts +0 -7
  158. package/build/plugins/d3/renderer/hooks/useChartOptions/x-axis.js +0 -114
  159. package/build/plugins/d3/renderer/hooks/useChartOptions/y-axis.d.ts +0 -7
  160. package/build/plugins/d3/renderer/hooks/useChartOptions/y-axis.js +0 -116
  161. package/build/plugins/d3/renderer/hooks/useSeries/constants.d.ts +0 -8
  162. package/build/plugins/d3/renderer/hooks/useSeries/constants.js +0 -19
  163. package/build/plugins/d3/renderer/hooks/useSeries/index.d.ts +0 -29
  164. package/build/plugins/d3/renderer/hooks/useSeries/index.js +0 -82
  165. package/build/plugins/d3/renderer/hooks/useSeries/prepare-area.d.ts +0 -19
  166. package/build/plugins/d3/renderer/hooks/useSeries/prepare-area.js +0 -63
  167. package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-x.d.ts +0 -10
  168. package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-x.js +0 -38
  169. package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-y.d.ts +0 -10
  170. package/build/plugins/d3/renderer/hooks/useSeries/prepare-bar-y.js +0 -49
  171. package/build/plugins/d3/renderer/hooks/useSeries/prepare-legend.d.ts +0 -27
  172. package/build/plugins/d3/renderer/hooks/useSeries/prepare-legend.js +0 -144
  173. package/build/plugins/d3/renderer/hooks/useSeries/prepare-line.d.ts +0 -22
  174. package/build/plugins/d3/renderer/hooks/useSeries/prepare-line.js +0 -82
  175. package/build/plugins/d3/renderer/hooks/useSeries/prepare-options.d.ts +0 -3
  176. package/build/plugins/d3/renderer/hooks/useSeries/prepare-options.js +0 -5
  177. package/build/plugins/d3/renderer/hooks/useSeries/prepare-pie.d.ts +0 -9
  178. package/build/plugins/d3/renderer/hooks/useSeries/prepare-pie.js +0 -62
  179. package/build/plugins/d3/renderer/hooks/useSeries/prepare-scatter.d.ts +0 -11
  180. package/build/plugins/d3/renderer/hooks/useSeries/prepare-scatter.js +0 -47
  181. package/build/plugins/d3/renderer/hooks/useSeries/prepare-treemap.d.ts +0 -11
  182. package/build/plugins/d3/renderer/hooks/useSeries/prepare-treemap.js +0 -38
  183. package/build/plugins/d3/renderer/hooks/useSeries/prepare-waterfall.d.ts +0 -10
  184. package/build/plugins/d3/renderer/hooks/useSeries/prepare-waterfall.js +0 -37
  185. package/build/plugins/d3/renderer/hooks/useSeries/prepareSeries.d.ts +0 -10
  186. package/build/plugins/d3/renderer/hooks/useSeries/prepareSeries.js +0 -65
  187. package/build/plugins/d3/renderer/hooks/useSeries/types.d.ts +0 -254
  188. package/build/plugins/d3/renderer/hooks/useSeries/types.js +0 -1
  189. package/build/plugins/d3/renderer/hooks/useSeries/utils.d.ts +0 -7
  190. package/build/plugins/d3/renderer/hooks/useSeries/utils.js +0 -33
  191. package/build/plugins/d3/renderer/hooks/useShapes/HtmlLayer.d.ts +0 -8
  192. package/build/plugins/d3/renderer/hooks/useShapes/HtmlLayer.js +0 -22
  193. package/build/plugins/d3/renderer/hooks/useShapes/area/index.d.ts +0 -12
  194. package/build/plugins/d3/renderer/hooks/useShapes/area/index.js +0 -144
  195. package/build/plugins/d3/renderer/hooks/useShapes/area/prepare-data.d.ts +0 -12
  196. package/build/plugins/d3/renderer/hooks/useShapes/area/prepare-data.js +0 -158
  197. package/build/plugins/d3/renderer/hooks/useShapes/area/types.d.ts +0 -28
  198. package/build/plugins/d3/renderer/hooks/useShapes/area/types.js +0 -1
  199. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/index.d.ts +0 -13
  200. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/index.js +0 -96
  201. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/prepare-data.d.ts +0 -13
  202. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/prepare-data.js +0 -160
  203. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/types.d.ts +0 -13
  204. package/build/plugins/d3/renderer/hooks/useShapes/bar-x/types.js +0 -1
  205. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/index.d.ts +0 -12
  206. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/index.js +0 -84
  207. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/prepare-data.d.ts +0 -12
  208. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/prepare-data.js +0 -169
  209. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/types.d.ts +0 -14
  210. package/build/plugins/d3/renderer/hooks/useShapes/bar-y/types.js +0 -1
  211. package/build/plugins/d3/renderer/hooks/useShapes/constants.d.ts +0 -3
  212. package/build/plugins/d3/renderer/hooks/useShapes/constants.js +0 -3
  213. package/build/plugins/d3/renderer/hooks/useShapes/index.d.ts +0 -33
  214. package/build/plugins/d3/renderer/hooks/useShapes/index.js +0 -153
  215. package/build/plugins/d3/renderer/hooks/useShapes/line/index.d.ts +0 -12
  216. package/build/plugins/d3/renderer/hooks/useShapes/line/index.js +0 -131
  217. package/build/plugins/d3/renderer/hooks/useShapes/line/prepare-data.d.ts +0 -13
  218. package/build/plugins/d3/renderer/hooks/useShapes/line/prepare-data.js +0 -91
  219. package/build/plugins/d3/renderer/hooks/useShapes/line/types.d.ts +0 -30
  220. package/build/plugins/d3/renderer/hooks/useShapes/line/types.js +0 -1
  221. package/build/plugins/d3/renderer/hooks/useShapes/marker.d.ts +0 -13
  222. package/build/plugins/d3/renderer/hooks/useShapes/marker.js +0 -76
  223. package/build/plugins/d3/renderer/hooks/useShapes/pie/index.d.ts +0 -13
  224. package/build/plugins/d3/renderer/hooks/useShapes/pie/index.js +0 -172
  225. package/build/plugins/d3/renderer/hooks/useShapes/pie/prepare-data.d.ts +0 -9
  226. package/build/plugins/d3/renderer/hooks/useShapes/pie/prepare-data.js +0 -186
  227. package/build/plugins/d3/renderer/hooks/useShapes/pie/types.d.ts +0 -42
  228. package/build/plugins/d3/renderer/hooks/useShapes/pie/types.js +0 -1
  229. package/build/plugins/d3/renderer/hooks/useShapes/pie/utils.d.ts +0 -4
  230. package/build/plugins/d3/renderer/hooks/useShapes/pie/utils.js +0 -15
  231. package/build/plugins/d3/renderer/hooks/useShapes/scatter/index.d.ts +0 -12
  232. package/build/plugins/d3/renderer/hooks/useShapes/scatter/index.js +0 -69
  233. package/build/plugins/d3/renderer/hooks/useShapes/scatter/prepare-data.d.ts +0 -11
  234. package/build/plugins/d3/renderer/hooks/useShapes/scatter/prepare-data.js +0 -31
  235. package/build/plugins/d3/renderer/hooks/useShapes/scatter/types.d.ts +0 -18
  236. package/build/plugins/d3/renderer/hooks/useShapes/scatter/types.js +0 -1
  237. package/build/plugins/d3/renderer/hooks/useShapes/styles.css +0 -36
  238. package/build/plugins/d3/renderer/hooks/useShapes/treemap/index.d.ts +0 -12
  239. package/build/plugins/d3/renderer/hooks/useShapes/treemap/index.js +0 -99
  240. package/build/plugins/d3/renderer/hooks/useShapes/treemap/prepare-data.d.ts +0 -7
  241. package/build/plugins/d3/renderer/hooks/useShapes/treemap/prepare-data.js +0 -114
  242. package/build/plugins/d3/renderer/hooks/useShapes/treemap/types.d.ts +0 -17
  243. package/build/plugins/d3/renderer/hooks/useShapes/treemap/types.js +0 -1
  244. package/build/plugins/d3/renderer/hooks/useShapes/utils.d.ts +0 -29
  245. package/build/plugins/d3/renderer/hooks/useShapes/utils.js +0 -53
  246. package/build/plugins/d3/renderer/hooks/useShapes/waterfall/index.d.ts +0 -13
  247. package/build/plugins/d3/renderer/hooks/useShapes/waterfall/index.js +0 -128
  248. package/build/plugins/d3/renderer/hooks/useShapes/waterfall/prepare-data.d.ts +0 -12
  249. package/build/plugins/d3/renderer/hooks/useShapes/waterfall/prepare-data.js +0 -133
  250. package/build/plugins/d3/renderer/hooks/useShapes/waterfall/types.d.ts +0 -15
  251. package/build/plugins/d3/renderer/hooks/useShapes/waterfall/types.js +0 -1
  252. package/build/plugins/d3/renderer/hooks/useSplit/index.d.ts +0 -14
  253. package/build/plugins/d3/renderer/hooks/useSplit/index.js +0 -57
  254. package/build/plugins/d3/renderer/hooks/useSplit/types.d.ts +0 -17
  255. package/build/plugins/d3/renderer/hooks/useSplit/types.js +0 -1
  256. package/build/plugins/d3/renderer/hooks/useTooltip/index.d.ts +0 -13
  257. package/build/plugins/d3/renderer/hooks/useTooltip/index.js +0 -17
  258. package/build/plugins/d3/renderer/hooks/useTooltip/types.d.ts +0 -1
  259. package/build/plugins/d3/renderer/hooks/useTooltip/types.js +0 -1
  260. package/build/plugins/d3/renderer/types/index.d.ts +0 -24
  261. package/build/plugins/d3/renderer/types/index.js +0 -1
  262. package/build/plugins/d3/renderer/utils/axis-generators/bottom.d.ts +0 -24
  263. package/build/plugins/d3/renderer/utils/axis-generators/bottom.js +0 -126
  264. package/build/plugins/d3/renderer/utils/axis-generators/index.d.ts +0 -1
  265. package/build/plugins/d3/renderer/utils/axis-generators/index.js +0 -1
  266. package/build/plugins/d3/renderer/utils/axis.d.ts +0 -31
  267. package/build/plugins/d3/renderer/utils/axis.js +0 -71
  268. package/build/plugins/d3/renderer/utils/color.d.ts +0 -10
  269. package/build/plugins/d3/renderer/utils/color.js +0 -43
  270. package/build/plugins/d3/renderer/utils/get-closest-data.d.ts +0 -15
  271. package/build/plugins/d3/renderer/utils/get-closest-data.js +0 -172
  272. package/build/plugins/d3/renderer/utils/index.d.ts +0 -78
  273. package/build/plugins/d3/renderer/utils/index.js +0 -211
  274. package/build/plugins/d3/renderer/utils/labels.d.ts +0 -6
  275. package/build/plugins/d3/renderer/utils/labels.js +0 -44
  276. package/build/plugins/d3/renderer/utils/legend.d.ts +0 -8
  277. package/build/plugins/d3/renderer/utils/legend.js +0 -23
  278. package/build/plugins/d3/renderer/utils/math.d.ts +0 -25
  279. package/build/plugins/d3/renderer/utils/math.js +0 -51
  280. package/build/plugins/d3/renderer/utils/series/index.d.ts +0 -1
  281. package/build/plugins/d3/renderer/utils/series/index.js +0 -1
  282. package/build/plugins/d3/renderer/utils/series/waterfall.d.ts +0 -4
  283. package/build/plugins/d3/renderer/utils/series/waterfall.js +0 -25
  284. package/build/plugins/d3/renderer/utils/symbol.d.ts +0 -3
  285. package/build/plugins/d3/renderer/utils/symbol.js +0 -36
  286. package/build/plugins/d3/renderer/utils/text.d.ts +0 -29
  287. package/build/plugins/d3/renderer/utils/text.js +0 -139
  288. package/build/plugins/d3/renderer/utils/time.d.ts +0 -3
  289. package/build/plugins/d3/renderer/utils/time.js +0 -34
  290. package/build/plugins/d3/renderer/validation/__mocks__/index.d.ts +0 -3
  291. package/build/plugins/d3/renderer/validation/__mocks__/index.js +0 -44
  292. package/build/plugins/d3/renderer/validation/index.d.ts +0 -2
  293. package/build/plugins/d3/renderer/validation/index.js +0 -221
  294. package/build/plugins/d3/utils/index.d.ts +0 -4
  295. package/build/plugins/d3/utils/index.js +0 -4
  296. package/build/plugins/d3/utils/pie-center-text.d.ts +0 -7
  297. package/build/plugins/d3/utils/pie-center-text.js +0 -23
  298. /package/build/{plugins/d3/renderer/hooks/useChartOptions → components/SplitPane}/types.js +0 -0
@@ -1,58 +0,0 @@
1
- import React from 'react';
2
- import { dateTime } from '@gravity-ui/date-utils';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import marsWeatherData from '../mars-weather';
6
- export const TwoYAxis = () => {
7
- const data = marsWeatherData;
8
- const pressureData = data.map((d) => ({
9
- x: dateTime({ input: d.terrestrial_date, format: 'YYYY-MM-DD' }).valueOf(),
10
- y: d.pressure,
11
- }));
12
- const tempData = data.map((d) => ({
13
- x: dateTime({ input: d.terrestrial_date, format: 'YYYY-MM-DD' }).valueOf(),
14
- y: d.max_temp - d.min_temp,
15
- }));
16
- const widgetData = {
17
- series: {
18
- data: [
19
- {
20
- type: 'area',
21
- data: pressureData,
22
- name: 'Pressure',
23
- yAxis: 0,
24
- },
25
- {
26
- type: 'area',
27
- data: tempData,
28
- name: 'Temperature range',
29
- yAxis: 1,
30
- },
31
- ],
32
- },
33
- yAxis: [
34
- {
35
- title: {
36
- text: 'Pressure',
37
- },
38
- },
39
- {
40
- title: {
41
- text: 'Temperature range',
42
- },
43
- },
44
- ],
45
- xAxis: {
46
- type: 'datetime',
47
- title: {
48
- text: 'Terrestrial date',
49
- },
50
- ticks: { pixelInterval: 200 },
51
- },
52
- title: {
53
- text: 'Mars weather',
54
- },
55
- };
56
- return (React.createElement(ExampleWrapper, null,
57
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
58
- };
@@ -1,4 +0,0 @@
1
- import React from 'react';
2
- export declare const BasicBarXChart: () => React.JSX.Element;
3
- export declare const BasicLinearBarXChart: () => React.JSX.Element;
4
- export declare const BasicDateTimeBarXChart: () => React.JSX.Element;
@@ -1,88 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData({ field, filterNulls } = {
7
- field: 'platform',
8
- }) {
9
- const gamesByPlatform = groups(nintendoGames, (item) => item[field]);
10
- let resultData = gamesByPlatform;
11
- if (filterNulls) {
12
- resultData = gamesByPlatform.filter(([value]) => typeof value === 'number');
13
- }
14
- const data = resultData.map(([value, games]) => ({
15
- x: value,
16
- y: games.length,
17
- }));
18
- return {
19
- categories: resultData.map(([key]) => key),
20
- series: [
21
- {
22
- data,
23
- name: 'Games released',
24
- },
25
- ],
26
- };
27
- }
28
- export const BasicBarXChart = () => {
29
- const { categories, series } = prepareData();
30
- const widgetData = {
31
- series: {
32
- data: series.map((s) => ({
33
- type: 'bar-x',
34
- data: s.data,
35
- name: s.name,
36
- })),
37
- },
38
- xAxis: {
39
- type: 'category',
40
- categories: categories.map(String),
41
- title: {
42
- text: 'Game Platforms',
43
- },
44
- },
45
- yAxis: [{ title: { text: 'Number of games released' } }],
46
- };
47
- return (React.createElement(ExampleWrapper, null,
48
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
49
- };
50
- export const BasicLinearBarXChart = () => {
51
- const { series } = prepareData({ field: 'meta_score' });
52
- const widgetData = {
53
- series: {
54
- data: series.map((s) => ({
55
- type: 'bar-x',
56
- data: s.data,
57
- name: s.name,
58
- })),
59
- },
60
- xAxis: {
61
- title: {
62
- text: 'Meta scores',
63
- },
64
- },
65
- };
66
- return (React.createElement(ExampleWrapper, null,
67
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
68
- };
69
- export const BasicDateTimeBarXChart = () => {
70
- const { series } = prepareData({ field: 'date', filterNulls: true });
71
- const widgetData = {
72
- series: {
73
- data: series.map((s) => ({
74
- type: 'bar-x',
75
- data: s.data,
76
- name: s.name,
77
- })),
78
- },
79
- xAxis: {
80
- type: 'datetime',
81
- title: {
82
- text: 'Release date',
83
- },
84
- },
85
- };
86
- return (React.createElement(ExampleWrapper, null,
87
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
88
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const DataLabels: () => React.JSX.Element;
@@ -1,48 +0,0 @@
1
- import React from 'react';
2
- import { groups, sort } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- const years = Array.from(new Set(nintendoGames.map((g) => g.date ? new Date(g.date).getFullYear().toString() : 'unknown')));
7
- function prepareData() {
8
- const games = sort(nintendoGames.filter((d) => {
9
- return d.date && d.user_score;
10
- }), (d) => d.date);
11
- const groupByYear = (d) => (d.date ? new Date(d.date).getFullYear() : 'unknown');
12
- const byGenre = (genre) => {
13
- const data = groups(games.filter((d) => d.genres.includes(genre)), groupByYear).map(([year, items]) => {
14
- return {
15
- x: years.indexOf(String(year)),
16
- y: items.length,
17
- };
18
- });
19
- return {
20
- type: 'bar-x',
21
- name: genre,
22
- dataLabels: {
23
- enabled: true,
24
- },
25
- stacking: 'normal',
26
- data,
27
- };
28
- };
29
- return [byGenre('Strategy'), byGenre('Shooter'), byGenre('Puzzle'), byGenre('Action')];
30
- }
31
- export const DataLabels = () => {
32
- const series = prepareData();
33
- const widgetData = {
34
- series: {
35
- data: series,
36
- },
37
- xAxis: {
38
- categories: years,
39
- type: 'category',
40
- title: {
41
- text: 'Release year',
42
- },
43
- ticks: { pixelInterval: 200 },
44
- },
45
- };
46
- return (React.createElement(ExampleWrapper, null,
47
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
48
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const GroupedColumns: () => React.JSX.Element;
@@ -1,48 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData() {
7
- const displayedYears = [2015, 2016, 2017, 2018, 2019];
8
- const games = nintendoGames.filter((ng) => displayedYears.includes(new Date(ng.date).getFullYear()));
9
- const grouped = groups(games, (d) => d.platform, (d) => (d.date ? new Date(d.date).getFullYear() : 'unknown'));
10
- const categories = [];
11
- const series = grouped.map(([platform, years]) => {
12
- return {
13
- name: platform,
14
- data: years.map(([year, list]) => {
15
- categories.push(String(year));
16
- return {
17
- x: String(year),
18
- y: list.length,
19
- };
20
- }),
21
- };
22
- });
23
- return { categories, series };
24
- }
25
- export const GroupedColumns = () => {
26
- const { series, categories } = prepareData();
27
- const data = series.map((s) => {
28
- return {
29
- type: 'bar-x',
30
- name: s.name,
31
- data: s.data,
32
- };
33
- });
34
- const widgetData = {
35
- series: {
36
- data,
37
- },
38
- xAxis: {
39
- type: 'category',
40
- categories: categories.sort(),
41
- title: {
42
- text: 'Release year',
43
- },
44
- },
45
- };
46
- return (React.createElement(ExampleWrapper, null,
47
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
48
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const NegativeValues: () => React.JSX.Element;
@@ -1,41 +0,0 @@
1
- import React from 'react';
2
- import { dateTime } from '@gravity-ui/date-utils';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import marsWeatherData from '../mars-weather';
6
- export const NegativeValues = () => {
7
- const data = marsWeatherData.map((d) => ({
8
- x: dateTime({ input: d.terrestrial_date, format: 'YYYY-MM-DD' }).valueOf(),
9
- y: d.min_temp,
10
- }));
11
- const widgetData = {
12
- series: {
13
- data: [
14
- {
15
- type: 'bar-x',
16
- data: data,
17
- name: 'Min temperature',
18
- },
19
- ],
20
- },
21
- yAxis: [
22
- {
23
- title: {
24
- text: 'Min temperature',
25
- },
26
- },
27
- ],
28
- xAxis: {
29
- type: 'datetime',
30
- title: {
31
- text: 'Terrestrial date',
32
- },
33
- ticks: { pixelInterval: 200 },
34
- },
35
- title: {
36
- text: 'Mars weather',
37
- },
38
- };
39
- return (React.createElement(ExampleWrapper, null,
40
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
41
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const PercentStackColumns: () => React.JSX.Element;
@@ -1,47 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData() {
7
- const grouped = groups(nintendoGames, (d) => d.platform, (d) => (d.date ? new Date(d.date).getFullYear() : 'unknown'));
8
- const categories = [];
9
- const series = grouped.map(([platform, years]) => {
10
- return {
11
- name: platform,
12
- data: years.map(([year, list]) => {
13
- categories.push(String(year));
14
- return {
15
- x: String(year),
16
- y: list.length,
17
- };
18
- }),
19
- };
20
- });
21
- return { categories, series };
22
- }
23
- export const PercentStackColumns = () => {
24
- const { series, categories } = prepareData();
25
- const data = series.map((s) => {
26
- return {
27
- type: 'bar-x',
28
- stacking: 'percent',
29
- name: s.name,
30
- data: s.data,
31
- };
32
- });
33
- const widgetData = {
34
- series: {
35
- data: data,
36
- },
37
- xAxis: {
38
- type: 'category',
39
- categories: categories.sort(),
40
- title: {
41
- text: 'Release year',
42
- },
43
- },
44
- };
45
- return (React.createElement(ExampleWrapper, null,
46
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
47
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const StackedColumns: () => React.JSX.Element;
@@ -1,47 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData() {
7
- const grouped = groups(nintendoGames, (d) => d.platform, (d) => (d.date ? new Date(d.date).getFullYear() : 'unknown'));
8
- const categories = [];
9
- const series = grouped.map(([platform, years]) => {
10
- return {
11
- name: platform,
12
- data: years.map(([year, list]) => {
13
- categories.push(String(year));
14
- return {
15
- x: String(year),
16
- y: list.length,
17
- };
18
- }),
19
- };
20
- });
21
- return { categories, series };
22
- }
23
- export const StackedColumns = () => {
24
- const { series, categories } = prepareData();
25
- const data = series.map((s) => {
26
- return {
27
- type: 'bar-x',
28
- stacking: 'normal',
29
- name: s.name,
30
- data: s.data,
31
- };
32
- });
33
- const widgetData = {
34
- series: {
35
- data: data,
36
- },
37
- xAxis: {
38
- type: 'category',
39
- categories: categories.sort(),
40
- title: {
41
- text: 'Release year',
42
- },
43
- },
44
- };
45
- return (React.createElement(ExampleWrapper, null,
46
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
47
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const TwoYAxis: () => React.JSX.Element;
@@ -1,58 +0,0 @@
1
- import React from 'react';
2
- import { dateTime } from '@gravity-ui/date-utils';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import marsWeatherData from '../mars-weather';
6
- export const TwoYAxis = () => {
7
- const data = marsWeatherData;
8
- const pressureData = data.map((d) => ({
9
- x: dateTime({ input: d.terrestrial_date, format: 'YYYY-MM-DD' }).valueOf(),
10
- y: d.pressure,
11
- }));
12
- const tempData = data.map((d) => ({
13
- x: dateTime({ input: d.terrestrial_date, format: 'YYYY-MM-DD' }).valueOf(),
14
- y: d.max_temp - d.min_temp,
15
- }));
16
- const widgetData = {
17
- series: {
18
- data: [
19
- {
20
- type: 'bar-x',
21
- data: pressureData,
22
- name: 'Pressure',
23
- yAxis: 0,
24
- },
25
- {
26
- type: 'bar-x',
27
- data: tempData,
28
- name: 'Temperature range',
29
- yAxis: 1,
30
- },
31
- ],
32
- },
33
- yAxis: [
34
- {
35
- title: {
36
- text: 'Pressure',
37
- },
38
- },
39
- {
40
- title: {
41
- text: 'Temperature range',
42
- },
43
- },
44
- ],
45
- xAxis: {
46
- type: 'datetime',
47
- title: {
48
- text: 'Terrestrial date',
49
- },
50
- ticks: { pixelInterval: 200 },
51
- },
52
- title: {
53
- text: 'Mars weather',
54
- },
55
- };
56
- return (React.createElement(ExampleWrapper, null,
57
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
58
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const Basic: () => React.JSX.Element;
@@ -1,45 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData(field = 'platform') {
7
- const gamesByPlatform = groups(nintendoGames, (item) => item[field]);
8
- const data = gamesByPlatform.map(([value, games]) => ({
9
- y: value,
10
- x: games.length,
11
- }));
12
- return {
13
- categories: gamesByPlatform.map(([key]) => key),
14
- series: [
15
- {
16
- data,
17
- name: 'Games released',
18
- },
19
- ],
20
- };
21
- }
22
- export const Basic = () => {
23
- const { categories, series } = prepareData();
24
- const widgetData = {
25
- series: {
26
- data: series.map((s) => ({
27
- type: 'bar-y',
28
- data: s.data,
29
- name: s.name,
30
- })),
31
- },
32
- xAxis: { title: { text: 'Number of games released' } },
33
- yAxis: [
34
- {
35
- type: 'category',
36
- categories: categories.map(String),
37
- title: {
38
- text: 'Game Platforms',
39
- },
40
- },
41
- ],
42
- };
43
- return (React.createElement(ExampleWrapper, null,
44
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
45
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const GroupedColumns: () => React.JSX.Element;
@@ -1,50 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData() {
7
- const displayedYears = [2015, 2016, 2017, 2018, 2019];
8
- const games = nintendoGames.filter((ng) => displayedYears.includes(new Date(ng.date).getFullYear()));
9
- const grouped = groups(games, (d) => d.platform, (d) => (d.date ? new Date(d.date).getFullYear() : 'unknown'));
10
- const categories = [];
11
- const series = grouped.map(([platform, years]) => {
12
- return {
13
- name: platform,
14
- data: years.map(([year, list]) => {
15
- categories.push(String(year));
16
- return {
17
- y: String(year),
18
- x: list.length,
19
- };
20
- }),
21
- };
22
- });
23
- return { categories, series };
24
- }
25
- export const GroupedColumns = () => {
26
- const { series, categories } = prepareData();
27
- const data = series.map((s) => {
28
- return {
29
- type: 'bar-y',
30
- name: s.name,
31
- data: s.data,
32
- };
33
- });
34
- const widgetData = {
35
- series: {
36
- data: data,
37
- },
38
- yAxis: [
39
- {
40
- type: 'category',
41
- categories: categories.sort(),
42
- title: {
43
- text: 'Release year',
44
- },
45
- },
46
- ],
47
- };
48
- return (React.createElement(ExampleWrapper, null,
49
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
50
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const NegativeValues: () => React.JSX.Element;
@@ -1,40 +0,0 @@
1
- import React from 'react';
2
- import { dateTime } from '@gravity-ui/date-utils';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import marsWeatherData from '../mars-weather';
6
- export const NegativeValues = () => {
7
- const data = marsWeatherData.map((d) => ({
8
- y: dateTime({ input: d.terrestrial_date, format: 'YYYY-MM-DD' }).valueOf(),
9
- x: d.min_temp,
10
- }));
11
- const widgetData = {
12
- series: {
13
- data: [
14
- {
15
- type: 'bar-y',
16
- data: data,
17
- name: 'Min temperature',
18
- },
19
- ],
20
- },
21
- xAxis: {
22
- title: {
23
- text: 'Min temperature',
24
- },
25
- },
26
- yAxis: [
27
- {
28
- type: 'datetime',
29
- title: {
30
- text: 'Terrestrial date',
31
- },
32
- },
33
- ],
34
- title: {
35
- text: 'Mars weather',
36
- },
37
- };
38
- return (React.createElement(ExampleWrapper, null,
39
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
40
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const PercentStackingBars: () => React.JSX.Element;
@@ -1,49 +0,0 @@
1
- import React from 'react';
2
- import { groups } from 'd3';
3
- import { ChartKit } from '../../../../components/ChartKit';
4
- import { ExampleWrapper } from '../ExampleWrapper';
5
- import nintendoGames from '../nintendoGames';
6
- function prepareData() {
7
- const grouped = groups(nintendoGames, (d) => d.platform, (d) => (d.date ? new Date(d.date).getFullYear() : 'unknown'));
8
- const categories = [];
9
- const series = grouped.map(([platform, years]) => {
10
- return {
11
- name: platform,
12
- data: years.map(([year, list]) => {
13
- categories.push(String(year));
14
- return {
15
- y: String(year),
16
- x: list.length,
17
- };
18
- }),
19
- };
20
- });
21
- return { categories, series };
22
- }
23
- export const PercentStackingBars = () => {
24
- const { series, categories } = prepareData();
25
- const data = series.map((s) => {
26
- return {
27
- type: 'bar-y',
28
- stacking: 'percent',
29
- name: s.name,
30
- data: s.data,
31
- };
32
- });
33
- const widgetData = {
34
- series: {
35
- data: data,
36
- },
37
- yAxis: [
38
- {
39
- type: 'category',
40
- categories: categories.sort(),
41
- title: {
42
- text: 'Release year',
43
- },
44
- },
45
- ],
46
- };
47
- return (React.createElement(ExampleWrapper, null,
48
- React.createElement(ChartKit, { type: "d3", data: widgetData })));
49
- };
@@ -1,2 +0,0 @@
1
- import React from 'react';
2
- export declare const StackedColumns: () => React.JSX.Element;