vccs 0.0.1 → 0.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 (459) hide show
  1. package/LICENSE +21 -0
  2. package/dist/animation/Animate.d.ts +72 -0
  3. package/dist/cartesian/GraphicalItemClipPath.d.ts +31 -0
  4. package/dist/cartesian/area/ActivePoints.d.ts +77 -0
  5. package/dist/cartesian/area/Area.d.ts +17 -0
  6. package/dist/cartesian/area/ClipRect.d.ts +1 -0
  7. package/dist/cartesian/area/RenderArea.d.ts +16 -0
  8. package/dist/cartesian/area/__stories__/config.d.ts +31 -0
  9. package/dist/cartesian/area/hooks/useArea.d.ts +27 -0
  10. package/dist/cartesian/area/index.d.ts +2 -0
  11. package/dist/cartesian/area/type.d.ts +173 -0
  12. package/dist/cartesian/area/utils.d.ts +19 -0
  13. package/dist/cartesian/axis/XAxis.d.ts +189 -0
  14. package/dist/cartesian/axis/YAxis.d.ts +192 -0
  15. package/dist/cartesian/axis/index.d.ts +2 -0
  16. package/dist/cartesian/axis/type.d.ts +57 -0
  17. package/dist/cartesian/bar/Bar.d.ts +2 -0
  18. package/dist/cartesian/bar/components/BarBackground.d.ts +1 -0
  19. package/dist/cartesian/bar/components/BarRectangles.d.ts +1 -0
  20. package/dist/cartesian/bar/hooks/useBar.d.ts +23 -0
  21. package/dist/cartesian/bar/index.d.ts +1 -0
  22. package/dist/cartesian/bar/type.d.ts +166 -0
  23. package/dist/cartesian/bar/utils.d.ts +31 -0
  24. package/dist/cartesian/brush/Brush.d.ts +2 -0
  25. package/dist/cartesian/brush/components/Background.d.ts +15 -0
  26. package/dist/cartesian/brush/components/BrushText.d.ts +27 -0
  27. package/dist/cartesian/brush/components/Panorama.d.ts +65 -0
  28. package/dist/cartesian/brush/components/Slide.d.ts +20 -0
  29. package/dist/cartesian/brush/components/Traveller.d.ts +13 -0
  30. package/dist/cartesian/brush/components/TravellerLayer.d.ts +22 -0
  31. package/dist/cartesian/brush/hooks/useBrushHandlers.d.ts +25 -0
  32. package/dist/cartesian/brush/hooks/useBrushSetting.d.ts +6 -0
  33. package/dist/cartesian/brush/hooks/useBrushState.d.ts +29 -0
  34. package/dist/cartesian/brush/index.d.ts +2 -0
  35. package/dist/cartesian/brush/type.d.ts +103 -0
  36. package/dist/cartesian/brush/utils.d.ts +15 -0
  37. package/dist/cartesian/cartesian-axis/CartesianAxis.d.ts +209 -0
  38. package/dist/cartesian/cartesian-axis/const.d.ts +24 -0
  39. package/dist/cartesian/cartesian-axis/index.d.ts +1 -0
  40. package/dist/cartesian/cartesian-axis/use-axis-line.d.ts +7 -0
  41. package/dist/cartesian/cartesian-grid/Background.d.ts +18 -0
  42. package/dist/cartesian/cartesian-grid/CartesianGrid.d.ts +75 -0
  43. package/dist/cartesian/cartesian-grid/HorizontalGridLines.d.ts +37 -0
  44. package/dist/cartesian/cartesian-grid/HorizontalStripes.d.ts +20 -0
  45. package/dist/cartesian/cartesian-grid/VerticalGridLines.d.ts +26 -0
  46. package/dist/cartesian/cartesian-grid/VerticalStripes.d.ts +20 -0
  47. package/dist/cartesian/cartesian-grid/const.d.ts +6 -0
  48. package/dist/cartesian/cartesian-grid/index.d.ts +1 -0
  49. package/dist/cartesian/cartesian-grid/type.d.ts +145 -0
  50. package/dist/cartesian/cartesian-grid/utils.d.ts +5 -0
  51. package/dist/cartesian/error-bar/ErrorBar.d.ts +68 -0
  52. package/dist/cartesian/error-bar/ErrorBarContext.d.ts +27 -0
  53. package/dist/cartesian/error-bar/index.d.ts +2 -0
  54. package/dist/cartesian/funnel/index.d.ts +0 -0
  55. package/dist/cartesian/funnel/type.d.ts +37 -0
  56. package/dist/cartesian/funnel/utils.d.ts +12 -0
  57. package/dist/cartesian/index.d.ts +11 -0
  58. package/dist/cartesian/line/ActivePoints.d.ts +77 -0
  59. package/dist/cartesian/line/Line.d.ts +87 -0
  60. package/dist/cartesian/line/StaticLine.d.ts +16 -0
  61. package/dist/cartesian/line/hooks/useLine.d.ts +28 -0
  62. package/dist/cartesian/line/index.d.ts +3 -0
  63. package/dist/cartesian/line/type.d.ts +180 -0
  64. package/dist/cartesian/line/utils.d.ts +13 -0
  65. package/dist/cartesian/reference-area/ReferenceArea.d.ts +191 -0
  66. package/dist/cartesian/reference-area/index.d.ts +1 -0
  67. package/dist/cartesian/reference-line/ReferenceLine.d.ts +139 -0
  68. package/dist/cartesian/reference-line/index.d.ts +1 -0
  69. package/dist/cartesian/scatter/Scatter.d.ts +165 -0
  70. package/dist/cartesian/scatter/hooks/useScatter.d.ts +18 -0
  71. package/dist/cartesian/scatter/index.d.ts +1 -0
  72. package/dist/cartesian/type.d.ts +21 -0
  73. package/dist/cartesian/useNeedsClip.d.ts +6 -0
  74. package/dist/cartesian/utils/get-ticks.d.ts +16 -0
  75. package/dist/cartesian/z-axis/ZAxis.d.ts +81 -0
  76. package/dist/cartesian/z-axis/index.d.ts +1 -0
  77. package/dist/chart/AreaChart.d.ts +1 -0
  78. package/dist/chart/BarChart.d.ts +1 -0
  79. package/dist/chart/ComposedChart.d.ts +1 -0
  80. package/dist/chart/LegendPortalContext.d.ts +3 -0
  81. package/dist/chart/LineChart.d.ts +1 -0
  82. package/dist/chart/PieChart.d.ts +1 -0
  83. package/dist/chart/RadarChart.d.ts +1 -0
  84. package/dist/chart/RadialBarChart.d.ts +1 -0
  85. package/dist/chart/RechartsWrapper.d.ts +99 -0
  86. package/dist/chart/ScatterChart.d.ts +1 -0
  87. package/dist/chart/Surface.d.ts +40 -0
  88. package/dist/chart/TooltipPortalContext.d.ts +2 -0
  89. package/dist/chart/const.d.ts +6 -0
  90. package/dist/chart/generateCategoricalChart.d.ts +118 -0
  91. package/dist/chart/index.d.ts +8 -0
  92. package/dist/chart/provideClipPathId.d.ts +12 -0
  93. package/dist/components/Cell.d.ts +18 -0
  94. package/dist/components/DefaultLegendContent.d.ts +18 -0
  95. package/dist/components/Text.d.ts +149 -0
  96. package/dist/components/Tooltip.d.ts +250 -0
  97. package/dist/components/index.d.ts +4 -0
  98. package/dist/components/label/Label.d.ts +81 -0
  99. package/dist/components/label/LabelList.d.ts +63 -0
  100. package/dist/components/label/index.d.ts +2 -0
  101. package/dist/components/label/types.d.ts +88 -0
  102. package/dist/components/label/utils.d.ts +24 -0
  103. package/dist/components/legend/Legend.d.ts +4 -0
  104. package/dist/components/legend/LegendSymbol.d.ts +27 -0
  105. package/dist/components/legend/hooks/useLegend.d.ts +19 -0
  106. package/dist/components/legend/hooks/useLegendContent.d.ts +36 -0
  107. package/dist/components/legend/index.d.ts +2 -0
  108. package/dist/components/legend/type.d.ts +54 -0
  109. package/dist/components/legend/utils.d.ts +18 -0
  110. package/dist/components/types.d.ts +9 -0
  111. package/dist/components/utils.d.ts +4 -0
  112. package/dist/container/ClipPath.d.ts +12 -0
  113. package/dist/container/Layer.d.ts +2 -0
  114. package/dist/container/ResponsiveContainer.d.ts +50 -0
  115. package/dist/container/RootSurface.d.ts +17 -0
  116. package/dist/container/Surface.d.ts +25 -0
  117. package/dist/container/index.d.ts +1 -0
  118. package/dist/container/useSizeContext.d.ts +11 -0
  119. package/dist/context/ChartDataContextProvider.d.ts +17 -0
  120. package/dist/context/PanoramaContextProvider.d.ts +22 -0
  121. package/dist/context/accessibilityContext.d.ts +1 -0
  122. package/dist/context/cartesianLabelListContext.d.ts +3 -0
  123. package/dist/context/chartLayoutContext.d.ts +8 -0
  124. package/dist/context/cursorLayerContext.d.ts +2 -0
  125. package/dist/context/graphicalLayerContext.d.ts +2 -0
  126. package/dist/context/labelLayerContext.d.ts +2 -0
  127. package/dist/context/polarLabelViewBoxContext.d.ts +4 -0
  128. package/dist/context/useTooltipAxis.d.ts +2 -0
  129. package/dist/es/animation/Animate.mjs +63 -0
  130. package/dist/es/cartesian/GraphicalItemClipPath.mjs +36 -0
  131. package/dist/es/cartesian/area/ActivePoints.mjs +74 -0
  132. package/dist/es/cartesian/area/Area.mjs +41 -0
  133. package/dist/es/cartesian/area/ClipRect.mjs +104 -0
  134. package/dist/es/cartesian/area/RenderArea.mjs +151 -0
  135. package/dist/es/cartesian/area/hooks/useArea.mjs +57 -0
  136. package/dist/es/cartesian/area/type.mjs +136 -0
  137. package/dist/es/cartesian/area/utils.mjs +59 -0
  138. package/dist/es/cartesian/axis/XAxis.mjs +189 -0
  139. package/dist/es/cartesian/axis/YAxis.mjs +181 -0
  140. package/dist/es/cartesian/bar/Bar.mjs +89 -0
  141. package/dist/es/cartesian/bar/components/BarBackground.mjs +29 -0
  142. package/dist/es/cartesian/bar/components/BarRectangles.mjs +106 -0
  143. package/dist/es/cartesian/bar/hooks/useBar.mjs +41 -0
  144. package/dist/es/cartesian/bar/type.mjs +131 -0
  145. package/dist/es/cartesian/bar/utils.mjs +84 -0
  146. package/dist/es/cartesian/cartesian-axis/CartesianAxis.mjs +246 -0
  147. package/dist/es/cartesian/cartesian-grid/Background.mjs +30 -0
  148. package/dist/es/cartesian/cartesian-grid/CartesianGrid.mjs +155 -0
  149. package/dist/es/cartesian/cartesian-grid/HorizontalGridLines.mjs +49 -0
  150. package/dist/es/cartesian/cartesian-grid/HorizontalStripes.mjs +43 -0
  151. package/dist/es/cartesian/cartesian-grid/VerticalGridLines.mjs +44 -0
  152. package/dist/es/cartesian/cartesian-grid/VerticalStripes.mjs +43 -0
  153. package/dist/es/cartesian/cartesian-grid/const.mjs +29 -0
  154. package/dist/es/cartesian/cartesian-grid/utils.mjs +17 -0
  155. package/dist/es/cartesian/error-bar/ErrorBar.mjs +115 -0
  156. package/dist/es/cartesian/error-bar/ErrorBarContext.mjs +19 -0
  157. package/dist/es/cartesian/line/ActivePoints.mjs +75 -0
  158. package/dist/es/cartesian/line/Line.mjs +46 -0
  159. package/dist/es/cartesian/line/StaticLine.mjs +148 -0
  160. package/dist/es/cartesian/line/hooks/useLine.mjs +53 -0
  161. package/dist/es/cartesian/line/type.mjs +112 -0
  162. package/dist/es/cartesian/line/utils.mjs +33 -0
  163. package/dist/es/cartesian/reference-area/ReferenceArea.mjs +146 -0
  164. package/dist/es/cartesian/reference-line/ReferenceLine.mjs +143 -0
  165. package/dist/es/cartesian/scatter/Scatter.mjs +252 -0
  166. package/dist/es/cartesian/scatter/hooks/useScatter.mjs +19 -0
  167. package/dist/es/cartesian/useNeedsClip.mjs +14 -0
  168. package/dist/es/cartesian/utils/get-ticks.mjs +83 -0
  169. package/dist/es/cartesian/z-axis/ZAxis.mjs +70 -0
  170. package/dist/es/chart/AreaChart.mjs +9 -0
  171. package/dist/es/chart/BarChart.mjs +10 -0
  172. package/dist/es/chart/ComposedChart.mjs +10 -0
  173. package/dist/es/chart/LegendPortalContext.mjs +5 -0
  174. package/dist/es/chart/LineChart.mjs +10 -0
  175. package/dist/es/chart/PieChart.mjs +16 -0
  176. package/dist/es/chart/RadarChart.mjs +16 -0
  177. package/dist/es/chart/RadialBarChart.mjs +16 -0
  178. package/dist/es/chart/RechartsWrapper.mjs +137 -0
  179. package/dist/es/chart/ScatterChart.mjs +10 -0
  180. package/dist/es/chart/Surface.mjs +5 -0
  181. package/dist/es/chart/Surface.vue_vue_type_script_setup_true_lang.mjs +66 -0
  182. package/dist/es/chart/TooltipPortalContext.mjs +5 -0
  183. package/dist/es/chart/const.mjs +7 -0
  184. package/dist/es/chart/generateCategoricalChart.mjs +166 -0
  185. package/dist/es/chart/provideClipPathId.mjs +10 -0
  186. package/dist/es/components/Cell.mjs +11 -0
  187. package/dist/es/components/Text.mjs +5 -0
  188. package/dist/es/components/Text.vue_vue_type_script_setup_true_lang.mjs +154 -0
  189. package/dist/es/components/Tooltip.mjs +388 -0
  190. package/dist/es/components/label/Label.mjs +36 -0
  191. package/dist/es/components/label/LabelList.mjs +49 -0
  192. package/dist/es/components/label/types.mjs +35 -0
  193. package/dist/es/components/label/utils.mjs +233 -0
  194. package/dist/es/components/legend/Legend.mjs +82 -0
  195. package/dist/es/components/legend/LegendSymbol.mjs +60 -0
  196. package/dist/es/components/legend/hooks/useLegend.mjs +52 -0
  197. package/dist/es/components/legend/hooks/useLegendContent.mjs +47 -0
  198. package/dist/es/components/legend/type.mjs +41 -0
  199. package/dist/es/components/legend/utils.mjs +17 -0
  200. package/dist/es/components/utils.mjs +31 -0
  201. package/dist/es/container/ClipPath.mjs +25 -0
  202. package/dist/es/container/Layer.mjs +12 -0
  203. package/dist/es/container/ResponsiveContainer.mjs +5 -0
  204. package/dist/es/container/ResponsiveContainer.vue_vue_type_script_setup_true_lang.mjs +112 -0
  205. package/dist/es/container/Surface.mjs +58 -0
  206. package/dist/es/container/useSizeContext.mjs +5 -0
  207. package/dist/es/context/ChartDataContextProvider.mjs +21 -0
  208. package/dist/es/context/PanoramaContextProvider.mjs +19 -0
  209. package/dist/es/context/accessibilityContext.mjs +5 -0
  210. package/dist/es/context/cartesianLabelListContext.mjs +5 -0
  211. package/dist/es/context/chartLayoutContext.mjs +46 -0
  212. package/dist/es/context/cursorLayerContext.mjs +5 -0
  213. package/dist/es/context/graphicalLayerContext.mjs +5 -0
  214. package/dist/es/context/labelLayerContext.mjs +5 -0
  215. package/dist/es/context/polarLabelViewBoxContext.mjs +8 -0
  216. package/dist/es/context/useTooltipAxis.mjs +15 -0
  217. package/dist/es/events/useChartSynchronisation.mjs +88 -0
  218. package/dist/es/hooks/useSetupGraphicalItem.mjs +57 -0
  219. package/dist/es/index.mjs +42 -0
  220. package/dist/es/polar/pie/Pie.mjs +145 -0
  221. package/dist/es/polar/pie/type.mjs +97 -0
  222. package/dist/es/polar/radar/PolarAngleAxis.mjs +161 -0
  223. package/dist/es/polar/radar/PolarGrid.mjs +102 -0
  224. package/dist/es/polar/radar/PolarRadiusAxis.mjs +137 -0
  225. package/dist/es/polar/radar/Radar.mjs +248 -0
  226. package/dist/es/polar/radial-bar/RadialBar.mjs +176 -0
  227. package/dist/es/polar/radial-bar/type.mjs +97 -0
  228. package/dist/es/shape/Cross.mjs +15 -0
  229. package/dist/es/shape/Curve.mjs +60 -0
  230. package/dist/es/shape/Dot.mjs +23 -0
  231. package/dist/es/shape/Rectangle.mjs +68 -0
  232. package/dist/es/shape/Sector.mjs +128 -0
  233. package/dist/es/shape/Symbols.mjs +41 -0
  234. package/dist/es/state/ReportChartProps.mjs +63 -0
  235. package/dist/es/state/ReportMainChartProps.mjs +41 -0
  236. package/dist/es/state/ReportPolarOptions.mjs +55 -0
  237. package/dist/es/state/SetGraphicalItem.mjs +34 -0
  238. package/dist/es/state/SetLegendPayload.mjs +16 -0
  239. package/dist/es/state/SetTooltipEntrySettings.mjs +17 -0
  240. package/dist/es/state/brushSlice.mjs +22 -0
  241. package/dist/es/state/cartesianAxisSlice.mjs +33 -0
  242. package/dist/es/state/chartDataSlice.mjs +28 -0
  243. package/dist/es/state/externalEventsMiddleware.mjs +20 -0
  244. package/dist/es/state/graphicalItemsSlice.mjs +43 -0
  245. package/dist/es/state/hooks.mjs +5 -0
  246. package/dist/es/state/keyboardEventsMiddleware.mjs +55 -0
  247. package/dist/es/state/layoutSlice.mjs +33 -0
  248. package/dist/es/state/legendSlice.mjs +35 -0
  249. package/dist/es/state/mouseEventsMiddleware.mjs +34 -0
  250. package/dist/es/state/optionsSlice.mjs +22 -0
  251. package/dist/es/state/polarAxisSlice.mjs +26 -0
  252. package/dist/es/state/polarOptionsSlice.mjs +11 -0
  253. package/dist/es/state/reduxDevtoolsJsonStringifyReplacer.mjs +6 -0
  254. package/dist/es/state/referenceElementsSlice.mjs +34 -0
  255. package/dist/es/state/rootPropsSlice.mjs +21 -0
  256. package/dist/es/state/selectors/areaSelectors.mjs +67 -0
  257. package/dist/es/state/selectors/axisSelectors.mjs +693 -0
  258. package/dist/es/state/selectors/barSelectors.mjs +178 -0
  259. package/dist/es/state/selectors/brushSelectors.mjs +17 -0
  260. package/dist/es/state/selectors/combiners/combineActiveLabel.mjs +8 -0
  261. package/dist/es/state/selectors/combiners/combineActiveTooltipIndex.mjs +34 -0
  262. package/dist/es/state/selectors/combiners/combineAxisRangeWithReverse.mjs +6 -0
  263. package/dist/es/state/selectors/combiners/combineCoordinateForDefaultIndex.mjs +19 -0
  264. package/dist/es/state/selectors/combiners/combineTooltipInteractionState.mjs +32 -0
  265. package/dist/es/state/selectors/combiners/combineTooltipPayloadConfigurations.mjs +9 -0
  266. package/dist/es/state/selectors/common.mjs +4 -0
  267. package/dist/es/state/selectors/containerSelectors.mjs +4 -0
  268. package/dist/es/state/selectors/dataSelectors.mjs +16 -0
  269. package/dist/es/state/selectors/legendSelectors.mjs +9 -0
  270. package/dist/es/state/selectors/lineSelectors.mjs +57 -0
  271. package/dist/es/state/selectors/pickAxisId.mjs +4 -0
  272. package/dist/es/state/selectors/pickAxisType.mjs +4 -0
  273. package/dist/es/state/selectors/pieSelectors.mjs +97 -0
  274. package/dist/es/state/selectors/polarAxisSelectors.mjs +148 -0
  275. package/dist/es/state/selectors/polarGridSelectors.mjs +17 -0
  276. package/dist/es/state/selectors/polarScaleSelectors.mjs +52 -0
  277. package/dist/es/state/selectors/polarSelectors.mjs +64 -0
  278. package/dist/es/state/selectors/radarSelectors.mjs +113 -0
  279. package/dist/es/state/selectors/radialBarSelectors.mjs +212 -0
  280. package/dist/es/state/selectors/rootPropsSelectors.mjs +8 -0
  281. package/dist/es/state/selectors/scatterSelectors.mjs +118 -0
  282. package/dist/es/state/selectors/selectActivePropsFromChartPointer.mjs +18 -0
  283. package/dist/es/state/selectors/selectAllAxes.mjs +5 -0
  284. package/dist/es/state/selectors/selectChartOffset.mjs +60 -0
  285. package/dist/es/state/selectors/selectChartOffsetInternal.mjs +55 -0
  286. package/dist/es/state/selectors/selectTooltipEventType.mjs +21 -0
  287. package/dist/es/state/selectors/selectTooltipPayloadSearcher.mjs +6 -0
  288. package/dist/es/state/selectors/selectTooltipSettings.mjs +4 -0
  289. package/dist/es/state/selectors/selectTooltipState.mjs +4 -0
  290. package/dist/es/state/selectors/selectors.mjs +85 -0
  291. package/dist/es/state/selectors/tooltipSelectors.mjs +220 -0
  292. package/dist/es/state/selectors/touchSelectors.mjs +16 -0
  293. package/dist/es/state/store.mjs +55 -0
  294. package/dist/es/state/tooltipSlice.mjs +75 -0
  295. package/dist/es/state/touchEventsMiddleware.mjs +38 -0
  296. package/dist/es/state/utils/useReportScale.mjs +16 -0
  297. package/dist/es/synchronisation/syncSelectors.mjs +6 -0
  298. package/dist/es/synchronisation/useChartSynchronisation.mjs +24 -0
  299. package/dist/es/types/event.mjs +4 -0
  300. package/dist/es/utils/ReduceCSSCalc.mjs +82 -0
  301. package/dist/es/utils/VueUtils.mjs +18 -0
  302. package/dist/es/utils/attrs.mjs +52 -0
  303. package/dist/es/utils/cartesian.mjs +22 -0
  304. package/dist/es/utils/chart.mjs +265 -0
  305. package/dist/es/utils/const.mjs +4 -0
  306. package/dist/es/utils/createContext.mjs +12 -0
  307. package/dist/es/utils/data-utils.mjs +12 -0
  308. package/dist/es/utils/data.mjs +27 -0
  309. package/dist/es/utils/events.mjs +5 -0
  310. package/dist/es/utils/getLinearRegression.mjs +17 -0
  311. package/dist/es/utils/grid.mjs +8 -0
  312. package/dist/es/utils/isDomainSpecifiedByUser.mjs +65 -0
  313. package/dist/es/utils/legend.mjs +18 -0
  314. package/dist/es/utils/log.mjs +11 -0
  315. package/dist/es/utils/payload/getUniqPayload.mjs +7 -0
  316. package/dist/es/utils/polar.mjs +52 -0
  317. package/dist/es/utils/props.mjs +14 -0
  318. package/dist/es/utils/resolveDefaultProps.mjs +7 -0
  319. package/dist/es/utils/scale/getNiceTickValues.mjs +59 -0
  320. package/dist/es/utils/scale/utils/arithmetic.mjs +24 -0
  321. package/dist/es/utils/scale/utils/utils.mjs +34 -0
  322. package/dist/es/utils/style.mjs +19 -0
  323. package/dist/es/utils/tick.mjs +31 -0
  324. package/dist/es/utils/tooltip/translate.mjs +59 -0
  325. package/dist/es/utils/validate.mjs +31 -0
  326. package/dist/events/useChartSynchronisation.d.ts +8 -0
  327. package/dist/hooks/useSetupGraphicalItem.d.ts +7 -0
  328. package/dist/index.d.ts +6 -0
  329. package/dist/polar/index.d.ts +3 -0
  330. package/dist/polar/pie/Pie.d.ts +2 -0
  331. package/dist/polar/pie/index.d.ts +2 -0
  332. package/dist/polar/pie/type.d.ts +88 -0
  333. package/dist/polar/radar/PolarAngleAxis.d.ts +145 -0
  334. package/dist/polar/radar/PolarGrid.d.ts +77 -0
  335. package/dist/polar/radar/PolarRadiusAxis.d.ts +125 -0
  336. package/dist/polar/radar/Radar.d.ts +160 -0
  337. package/dist/polar/radar/index.d.ts +4 -0
  338. package/dist/polar/radial-bar/RadialBar.d.ts +2 -0
  339. package/dist/polar/radial-bar/index.d.ts +2 -0
  340. package/dist/polar/radial-bar/type.d.ts +96 -0
  341. package/dist/shape/Cross.d.ts +10 -0
  342. package/dist/shape/Curve.d.ts +42 -0
  343. package/dist/shape/Dot.d.ts +18 -0
  344. package/dist/shape/Rectangle.d.ts +33 -0
  345. package/dist/shape/Sector.d.ts +48 -0
  346. package/dist/shape/Symbols.d.ts +15 -0
  347. package/dist/shape/index.d.ts +8 -0
  348. package/dist/shape/types.d.ts +20 -0
  349. package/dist/state/ReportBar.d.ts +1 -0
  350. package/dist/state/ReportChartProps.d.ts +88 -0
  351. package/dist/state/ReportMainChartProps.d.ts +37 -0
  352. package/dist/state/ReportPolarOptions.d.ts +59 -0
  353. package/dist/state/SetGraphicalItem.d.ts +9 -0
  354. package/dist/state/SetLegendPayload.d.ts +3 -0
  355. package/dist/state/SetTooltipEntrySettings.d.ts +8 -0
  356. package/dist/state/brushSlice.d.ts +18 -0
  357. package/dist/state/cartesianAxisSlice.d.ts +88 -0
  358. package/dist/state/chartDataSlice.d.ts +44 -0
  359. package/dist/state/externalEventsMiddleware.d.ts +17 -0
  360. package/dist/state/graphicalItemsSlice.d.ts +108 -0
  361. package/dist/state/hooks.d.ts +54 -0
  362. package/dist/state/keyboardEventsMiddleware.d.ts +3 -0
  363. package/dist/state/layoutSlice.d.ts +15 -0
  364. package/dist/state/legendSlice.d.ts +26 -0
  365. package/dist/state/mouseEventsMiddleware.d.ts +5 -0
  366. package/dist/state/optionsSlice.d.ts +27 -0
  367. package/dist/state/polarAxisSlice.d.ts +10 -0
  368. package/dist/state/polarOptionsSlice.d.ts +10 -0
  369. package/dist/state/reduxDevtoolsJsonStringifyReplacer.d.ts +1 -0
  370. package/dist/state/referenceElementsSlice.d.ts +40 -0
  371. package/dist/state/rootPropsSlice.d.ts +26 -0
  372. package/dist/state/selectors/areaSelectors.d.ts +24 -0
  373. package/dist/state/selectors/axisSelectors.d.ts +1828 -0
  374. package/dist/state/selectors/barSelectors.d.ts +944 -0
  375. package/dist/state/selectors/brushSelectors.d.ts +10 -0
  376. package/dist/state/selectors/combiners/combineActiveLabel.d.ts +3 -0
  377. package/dist/state/selectors/combiners/combineActiveTooltipIndex.d.ts +5 -0
  378. package/dist/state/selectors/combiners/combineAxisRangeWithReverse.d.ts +3 -0
  379. package/dist/state/selectors/combiners/combineCoordinateForDefaultIndex.d.ts +3 -0
  380. package/dist/state/selectors/combiners/combineTooltipInteractionState.d.ts +3 -0
  381. package/dist/state/selectors/combiners/combineTooltipPayloadConfigurations.d.ts +3 -0
  382. package/dist/state/selectors/common.d.ts +2 -0
  383. package/dist/state/selectors/containerSelectors.d.ts +6 -0
  384. package/dist/state/selectors/dataSelectors.d.ts +23 -0
  385. package/dist/state/selectors/funnelSelectors.d.ts +69 -0
  386. package/dist/state/selectors/legendSelectors.d.ts +7 -0
  387. package/dist/state/selectors/lineSelectors.d.ts +123 -0
  388. package/dist/state/selectors/pickAxisId.d.ts +3 -0
  389. package/dist/state/selectors/pickAxisType.d.ts +2 -0
  390. package/dist/state/selectors/pieSelectors.d.ts +55 -0
  391. package/dist/state/selectors/polarAxisSelectors.d.ts +49 -0
  392. package/dist/state/selectors/polarGridSelectors.d.ts +118 -0
  393. package/dist/state/selectors/polarScaleSelectors.d.ts +9 -0
  394. package/dist/state/selectors/polarSelectors.d.ts +70 -0
  395. package/dist/state/selectors/radarSelectors.d.ts +76 -0
  396. package/dist/state/selectors/radialBarSelectors.d.ts +61 -0
  397. package/dist/state/selectors/rootPropsSelectors.d.ts +11 -0
  398. package/dist/state/selectors/scatterSelectors.d.ts +21 -0
  399. package/dist/state/selectors/selectActivePropsFromChartPointer.d.ts +382 -0
  400. package/dist/state/selectors/selectAllAxes.d.ts +4 -0
  401. package/dist/state/selectors/selectChartOffset.d.ts +116 -0
  402. package/dist/state/selectors/selectChartOffsetInternal.d.ts +9 -0
  403. package/dist/state/selectors/selectTooltipEventType.d.ts +8 -0
  404. package/dist/state/selectors/selectTooltipPayloadSearcher.d.ts +3 -0
  405. package/dist/state/selectors/selectTooltipSettings.d.ts +3 -0
  406. package/dist/state/selectors/selectTooltipState.d.ts +3 -0
  407. package/dist/state/selectors/selectors.d.ts +184 -0
  408. package/dist/state/selectors/tooltipSelectors.d.ts +581 -0
  409. package/dist/state/selectors/touchSelectors.d.ts +4 -0
  410. package/dist/state/store.d.ts +74 -0
  411. package/dist/state/tooltipSlice.d.ts +204 -0
  412. package/dist/state/touchEventsMiddleware.d.ts +2 -0
  413. package/dist/state/utils/useReportScale.d.ts +1 -0
  414. package/dist/synchronisation/syncSelectors.d.ts +3 -0
  415. package/dist/synchronisation/useChartSynchronisation.d.ts +11 -0
  416. package/dist/types/area.d.ts +8 -0
  417. package/dist/types/axis.d.ts +127 -0
  418. package/dist/types/bar.d.ts +51 -0
  419. package/dist/types/categorical.d.ts +36 -0
  420. package/dist/types/common.d.ts +129 -0
  421. package/dist/types/event.d.ts +16 -0
  422. package/dist/types/index.d.ts +4 -0
  423. package/dist/types/legend.d.ts +1 -0
  424. package/dist/types/offset.d.ts +8 -0
  425. package/dist/types/radar.d.ts +28 -0
  426. package/dist/types/scale.d.ts +11 -0
  427. package/dist/types/tick.d.ts +55 -0
  428. package/dist/types/tooltip.d.ts +33 -0
  429. package/dist/utils/ReduceCSSCalc.d.ts +2 -0
  430. package/dist/utils/VueUtils.d.ts +11 -0
  431. package/dist/utils/attrs.d.ts +46 -0
  432. package/dist/utils/cartesian.d.ts +20 -0
  433. package/dist/utils/chart.d.ts +99 -0
  434. package/dist/utils/const.d.ts +30 -0
  435. package/dist/utils/context.d.ts +8 -0
  436. package/dist/utils/createContext.d.ts +8 -0
  437. package/dist/utils/data-utils.d.ts +4 -0
  438. package/dist/utils/data.d.ts +13 -0
  439. package/dist/utils/events.d.ts +12 -0
  440. package/dist/utils/getLinearRegression.d.ts +15 -0
  441. package/dist/utils/getRelativeCoordinate.d.ts +11 -0
  442. package/dist/utils/grid.d.ts +37 -0
  443. package/dist/utils/index.d.ts +4 -0
  444. package/dist/utils/isDomainSpecifiedByUser.d.ts +47 -0
  445. package/dist/utils/legend.d.ts +3 -0
  446. package/dist/utils/log.d.ts +1 -0
  447. package/dist/utils/payload/getUniqPayload.d.ts +4 -0
  448. package/dist/utils/polar.d.ts +21 -0
  449. package/dist/utils/props.d.ts +15 -0
  450. package/dist/utils/resolveDefaultProps.d.ts +52 -0
  451. package/dist/utils/scale/getNiceTickValues.d.ts +61 -0
  452. package/dist/utils/scale/utils/arithmetic.d.ts +50 -0
  453. package/dist/utils/scale/utils/utils.d.ts +9 -0
  454. package/dist/utils/style.d.ts +12 -0
  455. package/dist/utils/tick.d.ts +19 -0
  456. package/dist/utils/tooltip/translate.d.ts +47 -0
  457. package/dist/utils/types.d.ts +14 -0
  458. package/dist/utils/validate.d.ts +25 -0
  459. package/package.json +27 -10
@@ -0,0 +1,178 @@
1
+ import { isNullish as e } from "../../utils/validate.mjs";
2
+ import { selectChartDataWithIndexesIfNotInPanorama as t } from "./dataSelectors.mjs";
3
+ import { selectChartOffset as n } from "./selectChartOffset.mjs";
4
+ import { selectBarCategoryGap as r, selectBarGap as i, selectRootBarSize as a, selectRootMaxBarSize as o } from "./rootPropsSelectors.mjs";
5
+ import { getPercentValue as s } from "../../utils/data.mjs";
6
+ import { selectChartLayout as c } from "./common.mjs";
7
+ import { getBandSizeOfAxis as l } from "../../utils/chart.mjs";
8
+ import { selectAxisWithScale as u, selectCartesianAxisSize as d, selectStackGroups as f, selectTicksOfGraphicalItem as p, selectUnfilteredCartesianItems as m } from "./axisSelectors.mjs";
9
+ import { computeBarRectangles as h } from "../../cartesian/bar/utils.mjs";
10
+ import { createSelector as g } from "@reduxjs/toolkit";
11
+ //#region src/state/selectors/barSelectors.ts
12
+ var _ = (e, t) => t, v = (e, t, n) => n;
13
+ function y(e, t, n, r) {
14
+ return r;
15
+ }
16
+ function b(e, t, n, r, i) {
17
+ return i;
18
+ }
19
+ function x(e, t, n, r, i) {
20
+ return i.maxBarSize;
21
+ }
22
+ function S(t, n, r) {
23
+ let i = r ?? t;
24
+ return e(i) ? void 0 : s(i, n, 0);
25
+ }
26
+ var C = g([
27
+ c,
28
+ m,
29
+ _,
30
+ v,
31
+ y
32
+ ], (e, t, n, r, i) => t.filter((t) => e === "horizontal" ? t.xAxisId === n : t.yAxisId === r).filter((e) => e.isPanorama === i).filter((e) => e.hide === !1).filter((e) => e.type === "bar"));
33
+ function w(e, t, n, r) {
34
+ return c(e) === "horizontal" ? f(e, "yAxis", n, r) : f(e, "xAxis", t, r);
35
+ }
36
+ function T(e, t, n) {
37
+ return c(e) === "horizontal" ? d(e, "xAxis", t) : d(e, "yAxis", n);
38
+ }
39
+ function E(e, t, n) {
40
+ let r = {}, i = e.filter((e) => e.stackId != null), a = e.filter((e) => e.stackId == null), o = i.reduce((e, t) => (e[t.stackId] || (e[t.stackId] = []), e[t.stackId].push(t), e), r), s = Object.entries(o).map(([e, r]) => ({
41
+ stackId: e,
42
+ dataKeys: r.map((e) => e.dataKey),
43
+ barSize: S(t, n, r[0].barSize)
44
+ })), c = a.map((e) => ({
45
+ stackId: void 0,
46
+ dataKeys: [e.dataKey],
47
+ barSize: S(t, n, e.barSize)
48
+ }));
49
+ return [...s, ...c];
50
+ }
51
+ var D = g([
52
+ C,
53
+ a,
54
+ T
55
+ ], E);
56
+ function O(t, n, r, i, a) {
57
+ let s = c(t), d = o(t), { maxBarSize: f } = a, m = e(f) ? d : f, h, g;
58
+ return s === "horizontal" ? (h = u(t, "xAxis", n, i), g = p(t, "xAxis", n, i)) : (h = u(t, "yAxis", r, i), g = p(t, "yAxis", r, i)), l(h, g, !0) ?? m ?? 0;
59
+ }
60
+ function k(e, t, n, r) {
61
+ let i = c(e), a, o;
62
+ return i === "horizontal" ? (a = u(e, "xAxis", t, r), o = p(e, "xAxis", t, r)) : (a = u(e, "yAxis", n, r), o = p(e, "yAxis", n, r)), l(a, o);
63
+ }
64
+ function A(e, t, n, r, i) {
65
+ let a = r.length;
66
+ if (a < 1) return null;
67
+ let o = s(e, n, 0, !0), c, l = [];
68
+ if (r[0].barSize === +r[0].barSize) {
69
+ let e = !1, t = n / a, i = r.reduce((e, t) => e + t.barSize || 0, 0);
70
+ i += (a - 1) * o, i >= n && (i -= (a - 1) * o, o = 0), i >= n && t > 0 && (e = !0, t *= .9, i = a * t);
71
+ let s = {
72
+ offset: ((n - i) / 2 >> 0) - o,
73
+ size: 0
74
+ };
75
+ c = r.reduce((n, r) => {
76
+ let i = {
77
+ stackId: r.stackId,
78
+ dataKeys: r.dataKeys,
79
+ position: {
80
+ offset: s.offset + s.size + o,
81
+ size: e ? t : r.barSize
82
+ }
83
+ }, a = [...n, i];
84
+ return s = a[a.length - 1].position, a;
85
+ }, l);
86
+ } else {
87
+ let e = s(t, n, 0, !0);
88
+ n - 2 * e - (a - 1) * o <= 0 && (o = 0);
89
+ let u = (n - 2 * e - (a - 1) * o) / a;
90
+ u > 1 && (u >>= 0);
91
+ let d = i === +i ? Math.min(u, i) : u;
92
+ c = r.reduce((t, n, r) => [...t, {
93
+ stackId: n.stackId,
94
+ dataKeys: n.dataKeys,
95
+ position: {
96
+ offset: e + (u + o) * r + (u - d) / 2,
97
+ size: d
98
+ }
99
+ }], l);
100
+ }
101
+ return c;
102
+ }
103
+ function j(t, n, r, i, a, o, s) {
104
+ let c = e(s) ? n : s, l = A(r, i, a === o ? o : a, t, c);
105
+ return a !== o && l != null && (l = l.map((e) => ({
106
+ ...e,
107
+ position: {
108
+ ...e.position,
109
+ offset: e.position.offset - a / 2
110
+ }
111
+ }))), l;
112
+ }
113
+ var M = g([
114
+ D,
115
+ o,
116
+ i,
117
+ r,
118
+ O,
119
+ k,
120
+ x
121
+ ], j);
122
+ function N(e, t, n, r) {
123
+ return u(e, "xAxis", t, r);
124
+ }
125
+ function P(e, t, n, r) {
126
+ return u(e, "yAxis", n, r);
127
+ }
128
+ function F(e, t, n, r) {
129
+ return p(e, "xAxis", t, r);
130
+ }
131
+ function I(e, t, n, r) {
132
+ return p(e, "yAxis", n, r);
133
+ }
134
+ var L = g([M, b], (e, t) => {
135
+ if (e == null) return;
136
+ let n = e.find((e) => e.stackId === t.stackId && e.dataKeys.includes(t.dataKey));
137
+ if (n != null) return n.position;
138
+ });
139
+ function R(e, t) {
140
+ if (!e || t?.dataKey == null) return;
141
+ let { stackId: n } = t, r = e[n];
142
+ if (!r) return;
143
+ let { stackedData: i } = r;
144
+ if (i) return i.find((e) => e.key === t.dataKey);
145
+ }
146
+ var z = g([m, b], (e, t) => {
147
+ if (e.some((e) => e.type === "bar" && t.dataKey === e.dataKey && t.stackId === e.stackId && t.stackId === e.stackId)) return t;
148
+ }), B = g([
149
+ n,
150
+ N,
151
+ P,
152
+ F,
153
+ I,
154
+ L,
155
+ c,
156
+ t,
157
+ k,
158
+ g([w, b], R),
159
+ z
160
+ ], (e, t, n, r, i, a, o, { chartData: s, dataStartIndex: c, dataEndIndex: l }, u, d, f) => {
161
+ if (f == null || a == null || o !== "horizontal" && o !== "vertical" || t == null || n == null || r == null || i == null) return;
162
+ let { data: p } = f, m;
163
+ if (m = (p?.length ?? 0) > 0 ? p : s?.slice(c, l + 1), m != null) return h({
164
+ layout: o,
165
+ barSettings: f,
166
+ pos: a,
167
+ bandSize: u,
168
+ xAxis: t,
169
+ yAxis: n,
170
+ xAxisTicks: r,
171
+ yAxisTicks: i,
172
+ stackedData: d,
173
+ displayedData: m,
174
+ offset: e
175
+ });
176
+ });
177
+ //#endregion
178
+ export { j as combineAllBarPositions, E as combineBarSizeList, R as combineStackedData, B as selectBarRectangles };
@@ -0,0 +1,17 @@
1
+ import { isNumber as e } from "../../utils/validate.mjs";
2
+ import { selectMargin as t } from "./containerSelectors.mjs";
3
+ import { selectChartOffset as n } from "./selectChartOffset.mjs";
4
+ import { createSelector as r } from "@reduxjs/toolkit";
5
+ //#region src/state/selectors/brushSelectors.ts
6
+ var i = (e) => e.brush, a = r([
7
+ i,
8
+ n,
9
+ t
10
+ ], (t, n, r) => ({
11
+ height: t.height,
12
+ x: e(t.x) ? t.x : n.left,
13
+ y: e(t.y) ? t.y : n.top + n.height + n.brushBottom - (r?.bottom || 0),
14
+ width: e(t.width) ? t.width : n.width
15
+ }));
16
+ //#endregion
17
+ export { a as selectBrushDimensions, i as selectBrushSettings };
@@ -0,0 +1,8 @@
1
+ import { isNan as e } from "../../../utils/validate.mjs";
2
+ //#region src/state/selectors/combiners/combineActiveLabel.ts
3
+ function t(t, n) {
4
+ let r = Number(n);
5
+ if (!(e(r) || n == null)) return r >= 0 ? t?.[r]?.value : void 0;
6
+ }
7
+ //#endregion
8
+ export { t as combineActiveLabel };
@@ -0,0 +1,34 @@
1
+ import { isWellBehavedNumber as e } from "../../../utils/validate.mjs";
2
+ import { getValueByDataKey as t } from "../../../utils/chart.mjs";
3
+ import { isWellFormedNumberDomain as n } from "../../../utils/isDomainSpecifiedByUser.mjs";
4
+ //#region src/state/selectors/combiners/combineActiveTooltipIndex.ts
5
+ function r(e) {
6
+ if (typeof e == "number") return Number.isFinite(e) ? e : void 0;
7
+ if (e instanceof Date) {
8
+ let t = e.valueOf();
9
+ return Number.isFinite(t) ? t : void 0;
10
+ }
11
+ let t = Number(e);
12
+ return Number.isFinite(t) ? t : void 0;
13
+ }
14
+ function i(e, t) {
15
+ let n = r(e), i = t[0], a = t[1];
16
+ return n === void 0 ? !1 : n >= Math.min(i, a) && n <= Math.max(i, a);
17
+ }
18
+ function a(e, r, a) {
19
+ if (a == null || r == null) return !0;
20
+ let o = t(e, r);
21
+ return o == null || !n(a) ? !0 : i(o, a);
22
+ }
23
+ function o(t, n, r, i) {
24
+ let o = t?.index;
25
+ if (o == null) return null;
26
+ let s = Number(o);
27
+ if (!e(s)) return o;
28
+ let c = Infinity;
29
+ n.length > 0 && (c = n.length - 1);
30
+ let l = Math.max(0, Math.min(s, c)), u = n[l];
31
+ return u == null || a(u, r, i) ? String(l) : null;
32
+ }
33
+ //#endregion
34
+ export { o as combineActiveTooltipIndex };
@@ -0,0 +1,6 @@
1
+ //#region src/state/selectors/combiners/combineAxisRangeWithReverse.ts
2
+ function e(e, t) {
3
+ if (!(!e || !t)) return e?.reversed ? [t[1], t[0]] : t;
4
+ }
5
+ //#endregion
6
+ export { e as combineAxisRangeWithReverse };
@@ -0,0 +1,19 @@
1
+ //#region src/state/selectors/combiners/combineCoordinateForDefaultIndex.ts
2
+ function e(e, t, n, r, i, a, o, s) {
3
+ if (a == null || r == null) return;
4
+ let c = o[0], l = c == null ? void 0 : s?.(c.positions, a);
5
+ if (l != null) return l;
6
+ let u = i?.[Number(a)];
7
+ if (u) switch (n) {
8
+ case "horizontal": return {
9
+ x: u.coordinate,
10
+ y: (r.top + t) / 2
11
+ };
12
+ default: return {
13
+ x: (r.left + e) / 2,
14
+ y: u.coordinate
15
+ };
16
+ }
17
+ }
18
+ //#endregion
19
+ export { e as combineCoordinateForDefaultIndex };
@@ -0,0 +1,32 @@
1
+ import { noInteraction as e } from "../../tooltipSlice.mjs";
2
+ //#region src/state/selectors/combiners/combineTooltipInteractionState.ts
3
+ function t(e, t, n) {
4
+ return t === "axis" ? n === "click" ? e.axisInteraction.click : e.axisInteraction.hover : n === "click" ? e.itemInteraction.click : e.itemInteraction.hover;
5
+ }
6
+ function n(e) {
7
+ return e.index != null;
8
+ }
9
+ function r(r, i, a, o) {
10
+ let s = t(r, i, a);
11
+ if (s?.active) return s;
12
+ if (r.keyboardInteraction.active) return r.keyboardInteraction;
13
+ if (r.syncInteraction.active && r.syncInteraction.index != null) return r.syncInteraction;
14
+ let c = r.settings.active === !0;
15
+ if (n(s)) {
16
+ if (c) return {
17
+ ...s,
18
+ active: !0
19
+ };
20
+ } else if (o != null) return {
21
+ active: !0,
22
+ coordinate: void 0,
23
+ dataKey: void 0,
24
+ index: o
25
+ };
26
+ return {
27
+ ...e,
28
+ coordinate: s?.coordinate
29
+ };
30
+ }
31
+ //#endregion
32
+ export { r as combineTooltipInteractionState };
@@ -0,0 +1,9 @@
1
+ //#region src/state/selectors/combiners/combineTooltipPayloadConfigurations.ts
2
+ function e(e, t, n, r) {
3
+ if (t === "axis") return e.tooltipItemPayloads;
4
+ if (e.tooltipItemPayloads.length === 0) return [];
5
+ let i;
6
+ return i = n === "hover" ? e.itemInteraction.hover.dataKey : e.itemInteraction.click.dataKey, e.syncInteraction.active && i == null ? e.tooltipItemPayloads : i == null && r != null ? [e.tooltipItemPayloads[0]] : e.tooltipItemPayloads.filter((e) => e.settings?.dataKey === i);
7
+ }
8
+ //#endregion
9
+ export { e as combineTooltipPayloadConfigurations };
@@ -0,0 +1,4 @@
1
+ //#region src/state/selectors/common.ts
2
+ var e = (e) => e.layout.layoutType;
3
+ //#endregion
4
+ export { e as selectChartLayout };
@@ -0,0 +1,4 @@
1
+ //#region src/state/selectors/containerSelectors.ts
2
+ var e = (e) => e.layout.width, t = (e) => e.layout.height, n = (e) => e.layout.scale, r = (e) => e.layout.margin;
3
+ //#endregion
4
+ export { t as selectChartHeight, e as selectChartWidth, n as selectContainerScale, r as selectMargin };
@@ -0,0 +1,16 @@
1
+ import { createSelector as e } from "@reduxjs/toolkit";
2
+ //#region src/state/selectors/dataSelectors.ts
3
+ var t = (e) => e.chartData, n = e([t], (e) => {
4
+ let t = e.chartData == null ? 0 : e.chartData.length - 1;
5
+ return {
6
+ chartData: e.chartData,
7
+ computedData: e.computedData,
8
+ dataEndIndex: t,
9
+ dataStartIndex: 0
10
+ };
11
+ });
12
+ function r(e, r, i, a) {
13
+ return a ? n(e) : t(e);
14
+ }
15
+ //#endregion
16
+ export { n as selectChartDataAndAlwaysIgnoreIndexes, t as selectChartDataWithIndexes, r as selectChartDataWithIndexesIfNotInPanorama };
@@ -0,0 +1,9 @@
1
+ import { createSelector as e } from "@reduxjs/toolkit";
2
+ //#region src/state/selectors/legendSelectors.ts
3
+ var t = (e) => e.legend.settings, n = (e) => e.legend.size;
4
+ function r(e) {
5
+ return e.legend.payload;
6
+ }
7
+ var i = e([r], (e) => e.flat(1));
8
+ //#endregion
9
+ export { i as selectLegendPayload, t as selectLegendSettings, n as selectLegendSize };
@@ -0,0 +1,57 @@
1
+ import { isCategoricalAxis as e } from "../../utils/validate.mjs";
2
+ import { selectChartDataWithIndexesIfNotInPanorama as t } from "./dataSelectors.mjs";
3
+ import { selectChartLayout as n } from "./common.mjs";
4
+ import { getBandSizeOfAxis as r } from "../../utils/chart.mjs";
5
+ import { selectAxisWithScale as i, selectTicksOfGraphicalItem as a, selectUnfilteredCartesianItems as o } from "./axisSelectors.mjs";
6
+ import { computeLinePoints as s } from "../../cartesian/line/utils.mjs";
7
+ import { createSelector as c } from "@reduxjs/toolkit";
8
+ //#region src/state/selectors/lineSelectors.ts
9
+ function l(e, t, n, r) {
10
+ return i(e, "xAxis", t, r);
11
+ }
12
+ function u(e, t, n, r) {
13
+ return a(e, "xAxis", t, r);
14
+ }
15
+ function d(e, t, n, r) {
16
+ return i(e, "yAxis", n, r);
17
+ }
18
+ function f(e, t, n, r) {
19
+ return a(e, "yAxis", n, r);
20
+ }
21
+ var p = c([
22
+ n,
23
+ l,
24
+ d,
25
+ u,
26
+ f
27
+ ], (t, n, i, a, o) => e(t, "xAxis") ? r(n, a, !1) : r(i, o, !1));
28
+ function m(e, t, n, r, i) {
29
+ return i;
30
+ }
31
+ var h = c([
32
+ n,
33
+ l,
34
+ d,
35
+ u,
36
+ f,
37
+ c([o, m], (e, t) => {
38
+ if (e.some((e) => e.type === "line" && t.dataKey === e.dataKey && t.data === e.data)) return t;
39
+ }),
40
+ p,
41
+ t
42
+ ], (e, t, n, r, i, a, o, { chartData: c, dataStartIndex: l, dataEndIndex: u }) => {
43
+ if (a == null || t == null || n == null || r == null || i == null || r.length === 0 || i.length === 0) return;
44
+ let { dataKey: d, data: f } = a, p;
45
+ if (p = f?.length > 0 ? f : c?.slice(l, u + 1), p != null) return s({
46
+ layout: e,
47
+ xAxis: t,
48
+ yAxis: n,
49
+ xAxisTicks: r,
50
+ yAxisTicks: i,
51
+ dataKey: d,
52
+ bandSize: o,
53
+ displayedData: p
54
+ });
55
+ });
56
+ //#endregion
57
+ export { h as selectLinePoints };
@@ -0,0 +1,4 @@
1
+ //#region src/state/selectors/pickAxisId.ts
2
+ var e = (e, t, n) => n;
3
+ //#endregion
4
+ export { e as pickAxisId };
@@ -0,0 +1,4 @@
1
+ //#region src/state/selectors/pickAxisType.ts
2
+ var e = (e, t) => t;
3
+ //#endregion
4
+ export { e as pickAxisType };
@@ -0,0 +1,97 @@
1
+ import { isNumber as e } from "../../utils/validate.mjs";
2
+ import { selectChartDataAndAlwaysIgnoreIndexes as t } from "./dataSelectors.mjs";
3
+ import { selectChartOffset as n } from "./selectChartOffset.mjs";
4
+ import { getMaxRadius as r, polarToCartesian as i } from "../../utils/polar.mjs";
5
+ import { getPercentValue as a, mathSign as o } from "../../utils/data.mjs";
6
+ import { getValueByDataKey as s } from "../../utils/chart.mjs";
7
+ import { selectUnfilteredPolarItems as c } from "./polarSelectors.mjs";
8
+ import { createSelector as l } from "@reduxjs/toolkit";
9
+ //#region src/state/selectors/pieSelectors.ts
10
+ var u = (e, t) => t, d = [];
11
+ function f(e, t) {
12
+ return d;
13
+ }
14
+ var p = l([
15
+ t,
16
+ u,
17
+ f
18
+ ], ({ chartData: e }, t, n) => {
19
+ let r;
20
+ if (r = t.data != null && t.data.length > 0 ? t.data : e, !r || r.length, r != null) return r;
21
+ }), m = l([p, u], (e, t) => {
22
+ if (e != null) return e.map((e, n) => {
23
+ let r = s(e, t.nameKey, t.name), i;
24
+ return i = typeof e == "object" && e && "fill" in e && typeof e.fill == "string" ? e.fill : t.fill, {
25
+ value: r ?? String(t.dataKey ?? n),
26
+ color: i,
27
+ payload: e,
28
+ type: t.legendType
29
+ };
30
+ });
31
+ }), h = l([c, u], (e, t) => {
32
+ if (e.some((e) => e.type === "pie" && t.dataKey === e.dataKey)) return t;
33
+ });
34
+ function g(e, t) {
35
+ return o(t - e) * Math.min(Math.abs(t - e), 360);
36
+ }
37
+ function _(e, t, n) {
38
+ return a(typeof t == "function" ? t(e) : t ?? n * .8, n, n * .8);
39
+ }
40
+ function v(e, t, n) {
41
+ let { top: i, left: o, width: s, height: c } = t, l = r(s, c);
42
+ return {
43
+ cx: o + a(e.cx ?? s / 2, s, s / 2),
44
+ cy: i + a(e.cy ?? c / 2, c, c / 2),
45
+ innerRadius: a(e.innerRadius ?? 0, l, 0),
46
+ outerRadius: _(n, e.outerRadius, l),
47
+ maxRadius: Math.sqrt(s * s + c * c) / 2
48
+ };
49
+ }
50
+ function y({ pieSettings: t, displayedData: n, offset: r }) {
51
+ if (!n || n.length === 0) return;
52
+ let { cornerRadius: a, dataKey: c, nameKey: l, tooltipType: u } = t, d = t.startAngle ?? 0, f = t.endAngle ?? 360, p = Math.abs(t.minAngle ?? 0), m = g(d, f), h = Math.abs(m), _ = n.length <= 1 ? 0 : t.paddingAngle ?? 0, y = n.filter((e) => s(e, c, 0) !== 0).length, b = (h >= 360 ? y : y - 1) * _, x = h - y * p - b, S = n.reduce((t, n) => {
53
+ let r = s(n, c, 0);
54
+ return t + (e(r) ? r : 0);
55
+ }, 0);
56
+ if (S <= 0) return;
57
+ let C;
58
+ return n.map((n, f) => {
59
+ let h = s(n, c, 0), g = s(n, l, f), y = v(t, r, n), b = (e(h) ? h : 0) / S, w = { ...n }, T = w != null && "fill" in w && typeof w.fill == "string" ? w.fill : t.fill, E;
60
+ E = f ? C.endAngle + o(m) * _ * (h === 0 ? 0 : 1) : d;
61
+ let D = E + o(m) * ((h === 0 ? 0 : p) + b * x), O = (E + D) / 2, k = (y.innerRadius + y.outerRadius) / 2, A = i(y.cx, y.cy, k, O);
62
+ return C = {
63
+ ...t.presentationProps,
64
+ percent: b,
65
+ cornerRadius: typeof a == "string" ? parseFloat(a) : a,
66
+ name: g,
67
+ midAngle: O,
68
+ middleRadius: k,
69
+ tooltipPosition: A,
70
+ ...w,
71
+ ...y,
72
+ value: h,
73
+ dataKey: c,
74
+ startAngle: E,
75
+ endAngle: D,
76
+ payload: w,
77
+ paddingAngle: o(m) * _,
78
+ fill: T,
79
+ nameKey: l,
80
+ tooltipType: u
81
+ }, C;
82
+ });
83
+ }
84
+ l([
85
+ p,
86
+ h,
87
+ f,
88
+ n
89
+ ], (e, t, n, r) => {
90
+ if (!(t == null || e == null)) return y({
91
+ offset: r,
92
+ pieSettings: t,
93
+ displayedData: e
94
+ });
95
+ });
96
+ //#endregion
97
+ export { y as computePieSectors, p as selectDisplayedData, m as selectPieLegend, h as selectSynchronisedPieSettings };
@@ -0,0 +1,148 @@
1
+ import { selectChartHeight as e, selectChartWidth as t } from "./containerSelectors.mjs";
2
+ import { selectChartOffset as n } from "./selectChartOffset.mjs";
3
+ import { combineAxisRangeWithReverse as r } from "./combiners/combineAxisRangeWithReverse.mjs";
4
+ import { getMaxRadius as i } from "../../utils/polar.mjs";
5
+ import { getPercentValue as a } from "../../utils/data.mjs";
6
+ import { selectChartLayout as o } from "./common.mjs";
7
+ import { createSelector as s } from "@reduxjs/toolkit";
8
+ //#region src/state/selectors/polarAxisSelectors.ts
9
+ var c = {
10
+ allowDuplicatedCategory: !0,
11
+ angleAxisId: 0,
12
+ axisLine: !0,
13
+ cx: 0,
14
+ cy: 0,
15
+ orientation: "outer",
16
+ reversed: !1,
17
+ scale: "auto",
18
+ tick: !0,
19
+ tickLine: !0,
20
+ tickSize: 8,
21
+ type: "category"
22
+ }, l = {
23
+ allowDataOverflow: !1,
24
+ allowDecimals: !1,
25
+ allowDuplicatedCategory: !1,
26
+ dataKey: void 0,
27
+ domain: void 0,
28
+ id: void 0,
29
+ includeHidden: !1,
30
+ name: void 0,
31
+ reversed: c.reversed,
32
+ scale: c.scale,
33
+ tick: c.tick,
34
+ tickCount: void 0,
35
+ ticks: void 0,
36
+ type: c.type,
37
+ unit: void 0
38
+ }, u = {
39
+ allowDataOverflow: !1,
40
+ allowDuplicatedCategory: !0,
41
+ angle: 0,
42
+ axisLine: !0,
43
+ cx: 0,
44
+ cy: 0,
45
+ orientation: "right",
46
+ radiusAxisId: 0,
47
+ scale: "auto",
48
+ stroke: "#ccc",
49
+ tick: !0,
50
+ tickCount: 5,
51
+ type: "number"
52
+ }, d = {
53
+ allowDataOverflow: u.allowDataOverflow,
54
+ allowDecimals: !1,
55
+ allowDuplicatedCategory: u.allowDuplicatedCategory,
56
+ dataKey: void 0,
57
+ domain: void 0,
58
+ id: void 0,
59
+ includeHidden: !1,
60
+ name: void 0,
61
+ reversed: !1,
62
+ scale: u.scale,
63
+ tick: u.tick,
64
+ tickCount: u.tickCount,
65
+ ticks: void 0,
66
+ type: u.type,
67
+ unit: void 0
68
+ }, f = {
69
+ allowDataOverflow: !1,
70
+ allowDecimals: !1,
71
+ allowDuplicatedCategory: c.allowDuplicatedCategory,
72
+ dataKey: void 0,
73
+ domain: void 0,
74
+ id: void 0,
75
+ includeHidden: !1,
76
+ name: void 0,
77
+ reversed: !1,
78
+ scale: c.scale,
79
+ tick: c.tick,
80
+ tickCount: void 0,
81
+ ticks: void 0,
82
+ type: "number",
83
+ unit: void 0
84
+ }, p = {
85
+ allowDataOverflow: u.allowDataOverflow,
86
+ allowDecimals: !1,
87
+ allowDuplicatedCategory: u.allowDuplicatedCategory,
88
+ dataKey: void 0,
89
+ domain: void 0,
90
+ id: void 0,
91
+ includeHidden: !1,
92
+ name: void 0,
93
+ reversed: !1,
94
+ scale: u.scale,
95
+ tick: u.tick,
96
+ tickCount: u.tickCount,
97
+ ticks: void 0,
98
+ type: "category",
99
+ unit: void 0
100
+ };
101
+ function m(e, t) {
102
+ return e.polarAxis.angleAxis[t] == null ? e.layout.layoutType === "radial" ? f : l : e.polarAxis.angleAxis[t];
103
+ }
104
+ function h(e, t) {
105
+ return e.polarAxis.radiusAxis[t] == null ? e.layout.layoutType === "radial" ? p : d : e.polarAxis.radiusAxis[t];
106
+ }
107
+ var g = (e) => e.polarOptions, _ = s([
108
+ t,
109
+ e,
110
+ n
111
+ ], i), v = s([g, _], (e, t) => {
112
+ if (e != null) return a(e.innerRadius, t, 0);
113
+ }), y = s([g, _], (e, t) => {
114
+ if (e != null) return a(e.outerRadius, t, t * .8);
115
+ });
116
+ function b(e) {
117
+ if (e == null) return [0, 0];
118
+ let { startAngle: t, endAngle: n } = e;
119
+ return [t, n];
120
+ }
121
+ var x = s([g], b), S = s([m, x], r), C = s([
122
+ _,
123
+ v,
124
+ y
125
+ ], (e, t, n) => {
126
+ if (!(e == null || t == null || n == null)) return [t, n];
127
+ }), w = s([h, C], r), T = s([
128
+ o,
129
+ g,
130
+ v,
131
+ y,
132
+ t,
133
+ e
134
+ ], (e, t, n, r, i, o) => {
135
+ if (e !== "centric" && e !== "radial" || t == null || n == null || r == null) return;
136
+ let { cx: s, cy: c, startAngle: l, endAngle: u } = t;
137
+ return {
138
+ cx: a(s, i, i / 2),
139
+ cy: a(c, o, o / 2),
140
+ innerRadius: n,
141
+ outerRadius: r,
142
+ startAngle: l,
143
+ endAngle: u,
144
+ clockWise: !1
145
+ };
146
+ });
147
+ //#endregion
148
+ export { m as selectAngleAxis, x as selectAngleAxisRange, S as selectAngleAxisRangeWithReversed, T as selectPolarViewBox, h as selectRadiusAxis, C as selectRadiusAxisRange, w as selectRadiusAxisRangeWithReversed };
@@ -0,0 +1,17 @@
1
+ import { selectPolarAxisTicks as e } from "./polarScaleSelectors.mjs";
2
+ import { createSelector as t } from "@reduxjs/toolkit";
3
+ //#region src/state/selectors/polarGridSelectors.ts
4
+ function n(t, n) {
5
+ return e(t, "angleAxis", n, !1);
6
+ }
7
+ var r = t([n], (e) => {
8
+ if (e) return e.map((e) => e.coordinate);
9
+ });
10
+ function i(t, n) {
11
+ return e(t, "radiusAxis", n, !1);
12
+ }
13
+ var a = t([i], (e) => {
14
+ if (e) return e.map((e) => e.coordinate);
15
+ });
16
+ //#endregion
17
+ export { r as selectPolarGridAngles, a as selectPolarGridRadii };