@primeui/vue-chart 0.0.1-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (277) hide show
  1. package/LICENSE +23 -0
  2. package/README.md +1 -0
  3. package/dist/Chart.parts.d.ts +39 -0
  4. package/dist/Chart.vue.d.ts +27 -0
  5. package/dist/ChartCanvas.mjs +14 -0
  6. package/dist/ChartCanvas.render.spec.d.ts +1 -0
  7. package/dist/ChartCanvas.vue.d.ts +23 -0
  8. package/dist/ChartStacked.spec.d.ts +1 -0
  9. package/dist/ChartSvg.axes.spec.d.ts +1 -0
  10. package/dist/ChartSvg.context.spec.d.ts +1 -0
  11. package/dist/ChartSvg.customizations.spec.d.ts +1 -0
  12. package/dist/ChartSvg.features.spec.d.ts +1 -0
  13. package/dist/ChartSvg.legend.spec.d.ts +1 -0
  14. package/dist/ChartSvg.mjs +14 -0
  15. package/dist/ChartSvg.registration.spec.d.ts +1 -0
  16. package/dist/ChartSvg.render.spec.d.ts +1 -0
  17. package/dist/ChartSvg.vue.d.ts +23 -0
  18. package/dist/_test/fixtures.d.ts +34 -0
  19. package/dist/bundle-discipline.spec.d.ts +1 -0
  20. package/dist/chunk-2D3PWFR2.mjs +214 -0
  21. package/dist/chunk-32XIRBZ7.mjs +87 -0
  22. package/dist/chunk-372K2BMN.mjs +1476 -0
  23. package/dist/chunk-42J32DPD.mjs +70 -0
  24. package/dist/chunk-44BAFHPK.mjs +51 -0
  25. package/dist/chunk-4CRHCZV3.mjs +142 -0
  26. package/dist/chunk-4NJ2PSHV.mjs +230 -0
  27. package/dist/chunk-4THCGGER.mjs +53 -0
  28. package/dist/chunk-4UVPCLJ7.mjs +70 -0
  29. package/dist/chunk-54DLUFIA.mjs +96 -0
  30. package/dist/chunk-56NMBNNX.mjs +52 -0
  31. package/dist/chunk-5DWO3G33.mjs +276 -0
  32. package/dist/chunk-5FTUGKPC.mjs +167 -0
  33. package/dist/chunk-5SRBQVU5.mjs +6 -0
  34. package/dist/chunk-62NGBLQ7.mjs +28 -0
  35. package/dist/chunk-644ROAHU.mjs +362 -0
  36. package/dist/chunk-6S4JMPKC.mjs +55 -0
  37. package/dist/chunk-72KINEJ6.mjs +52 -0
  38. package/dist/chunk-7P6ASYW6.mjs +7 -0
  39. package/dist/chunk-AAX7FOW3.mjs +210 -0
  40. package/dist/chunk-AUI5R4DA.mjs +84 -0
  41. package/dist/chunk-CDXF6ZTL.mjs +50 -0
  42. package/dist/chunk-CQHNYT2V.mjs +1692 -0
  43. package/dist/chunk-DLUFOM5K.mjs +218 -0
  44. package/dist/chunk-DOOXGOOB.mjs +123 -0
  45. package/dist/chunk-DYVFVVTO.mjs +97 -0
  46. package/dist/chunk-E2U4W5FW.mjs +288 -0
  47. package/dist/chunk-E4ROAOPT.mjs +291 -0
  48. package/dist/chunk-FFBK7Q3W.mjs +91 -0
  49. package/dist/chunk-FQTWLAVA.mjs +23 -0
  50. package/dist/chunk-FZ3PZ66C.mjs +12 -0
  51. package/dist/chunk-GA4VV5V4.mjs +21 -0
  52. package/dist/chunk-GFC24374.mjs +244 -0
  53. package/dist/chunk-GX2MK6VT.mjs +255 -0
  54. package/dist/chunk-HANSF33Z.mjs +169 -0
  55. package/dist/chunk-HTZVV6VV.mjs +550 -0
  56. package/dist/chunk-J2P5JBHC.mjs +26 -0
  57. package/dist/chunk-J43KLCZF.mjs +10 -0
  58. package/dist/chunk-JKK3D33U.mjs +64 -0
  59. package/dist/chunk-K326BBF7.mjs +276 -0
  60. package/dist/chunk-KOWFD2AE.mjs +72 -0
  61. package/dist/chunk-LD57I4SY.mjs +5 -0
  62. package/dist/chunk-MDA22SIZ.mjs +29 -0
  63. package/dist/chunk-NLXOJSKK.mjs +727 -0
  64. package/dist/chunk-O6L3PNFC.mjs +49 -0
  65. package/dist/chunk-PJVOZSPF.mjs +55 -0
  66. package/dist/chunk-PQV55JYI.mjs +38 -0
  67. package/dist/chunk-PSSXPTLQ.mjs +210 -0
  68. package/dist/chunk-RQURY2H3.mjs +40 -0
  69. package/dist/chunk-RRHYGSK6.mjs +29 -0
  70. package/dist/chunk-RSAZ7V5Z.mjs +42 -0
  71. package/dist/chunk-RSTIA3KM.mjs +41 -0
  72. package/dist/chunk-TEOO4OLV.mjs +6 -0
  73. package/dist/chunk-TIV2FI4S.mjs +53 -0
  74. package/dist/chunk-UO27BCRL.mjs +86 -0
  75. package/dist/chunk-VWABO23U.mjs +143 -0
  76. package/dist/chunk-W5M3BR6N.mjs +26 -0
  77. package/dist/chunk-WA735Y26.mjs +101 -0
  78. package/dist/chunk-WKSQR6L5.mjs +247 -0
  79. package/dist/chunk-WYV2MHP6.mjs +34 -0
  80. package/dist/chunk-XBDNMPF7.mjs +87 -0
  81. package/dist/chunk-YGHWUR7K.mjs +45 -0
  82. package/dist/chunk-YRKAI2R2.mjs +151 -0
  83. package/dist/chunk-ZHFL3RYO.mjs +228 -0
  84. package/dist/chunk-ZNINPVG7.mjs +30 -0
  85. package/dist/chunk-ZRCOVQQM.mjs +47 -0
  86. package/dist/components/charts/ChartBar.mjs +13 -0
  87. package/dist/components/charts/ChartBar.vue.d.ts +11 -0
  88. package/dist/components/charts/ChartCandlestick.mjs +11 -0
  89. package/dist/components/charts/ChartCandlestick.vue.d.ts +11 -0
  90. package/dist/components/charts/ChartHeatmap.mjs +11 -0
  91. package/dist/components/charts/ChartHeatmap.vue.d.ts +11 -0
  92. package/dist/components/charts/ChartLine.mjs +11 -0
  93. package/dist/components/charts/ChartLine.vue.d.ts +11 -0
  94. package/dist/components/charts/ChartPie.mjs +11 -0
  95. package/dist/components/charts/ChartPie.vue.d.ts +15 -0
  96. package/dist/components/charts/ChartPolar.mjs +11 -0
  97. package/dist/components/charts/ChartPolar.vue.d.ts +11 -0
  98. package/dist/components/charts/ChartRadar.mjs +11 -0
  99. package/dist/components/charts/ChartRadar.vue.d.ts +11 -0
  100. package/dist/components/charts/ChartScatter.mjs +11 -0
  101. package/dist/components/charts/ChartScatter.vue.d.ts +11 -0
  102. package/dist/components/charts/ChartTreemap.mjs +10 -0
  103. package/dist/components/charts/ChartTreemap.vue.d.ts +15 -0
  104. package/dist/components/charts/index.d.ts +2 -0
  105. package/dist/components/containers/ChartDecimation.mjs +6 -0
  106. package/dist/components/containers/ChartDecimation.vue.d.ts +29 -0
  107. package/dist/components/containers/ChartGroup.mjs +4 -0
  108. package/dist/components/containers/ChartGroup.vue.d.ts +13 -0
  109. package/dist/components/containers/ChartOverlap.mjs +5 -0
  110. package/dist/components/containers/ChartOverlap.vue.d.ts +13 -0
  111. package/dist/components/containers/ChartRange.mjs +6 -0
  112. package/dist/components/containers/ChartRange.vue.d.ts +13 -0
  113. package/dist/components/containers/ChartStacked.mjs +6 -0
  114. package/dist/components/containers/ChartStacked.vue.d.ts +21 -0
  115. package/dist/components/containers/ChartWaterfall.mjs +5 -0
  116. package/dist/components/containers/ChartWaterfall.vue.d.ts +17 -0
  117. package/dist/components/containers/keys.d.ts +5 -0
  118. package/dist/components/customizations/ChartAccessibility.mjs +9 -0
  119. package/dist/components/customizations/ChartAccessibility.vue.d.ts +28 -0
  120. package/dist/components/customizations/ChartAnnotation.mjs +5 -0
  121. package/dist/components/customizations/ChartAnnotation.vue.d.ts +8 -0
  122. package/dist/components/customizations/ChartAxisCategory.mjs +3 -0
  123. package/dist/components/customizations/ChartAxisCategory.vue.d.ts +4 -0
  124. package/dist/components/customizations/ChartAxisGroup.mjs +3 -0
  125. package/dist/components/customizations/ChartAxisGroup.vue.d.ts +14 -0
  126. package/dist/components/customizations/ChartBreadcrumb.mjs +6 -0
  127. package/dist/components/customizations/ChartBreadcrumb.vue.d.ts +15 -0
  128. package/dist/components/customizations/ChartCaption.mjs +9 -0
  129. package/dist/components/customizations/ChartCaption.vue.d.ts +4 -0
  130. package/dist/components/customizations/ChartColorLegend.mjs +9 -0
  131. package/dist/components/customizations/ChartColorLegend.vue.d.ts +47 -0
  132. package/dist/components/customizations/ChartDataLabels.mjs +9 -0
  133. package/dist/components/customizations/ChartDataLabels.vue.d.ts +53 -0
  134. package/dist/components/customizations/ChartExportMenu.mjs +9 -0
  135. package/dist/components/customizations/ChartExportMenu.vue.d.ts +29 -0
  136. package/dist/components/customizations/ChartHover.mjs +9 -0
  137. package/dist/components/customizations/ChartHover.vue.d.ts +4 -0
  138. package/dist/components/customizations/ChartLegend.mjs +9 -0
  139. package/dist/components/customizations/ChartLegend.vue.d.ts +7 -0
  140. package/dist/components/customizations/ChartNavigator.mjs +10 -0
  141. package/dist/components/customizations/ChartNavigator.vue.d.ts +4 -0
  142. package/dist/components/customizations/ChartReferenceBand.mjs +5 -0
  143. package/dist/components/customizations/ChartReferenceBand.vue.d.ts +4 -0
  144. package/dist/components/customizations/ChartReferenceLine.mjs +5 -0
  145. package/dist/components/customizations/ChartReferenceLine.vue.d.ts +4 -0
  146. package/dist/components/customizations/ChartResponsive.mjs +9 -0
  147. package/dist/components/customizations/ChartResponsive.vue.d.ts +12 -0
  148. package/dist/components/customizations/ChartTitle.mjs +9 -0
  149. package/dist/components/customizations/ChartTitle.vue.d.ts +4 -0
  150. package/dist/components/customizations/ChartTooltip.mjs +9 -0
  151. package/dist/components/customizations/ChartTooltip.vue.d.ts +6 -0
  152. package/dist/components/customizations/ChartXAxis.mjs +10 -0
  153. package/dist/components/customizations/ChartXAxis.vue.d.ts +24 -0
  154. package/dist/components/customizations/ChartYAxis.mjs +10 -0
  155. package/dist/components/customizations/ChartYAxis.vue.d.ts +23 -0
  156. package/dist/components/customizations/ChartZoom.mjs +9 -0
  157. package/dist/components/customizations/ChartZoom.vue.d.ts +4 -0
  158. package/dist/components/customizations/axisGroupKeys.d.ts +8 -0
  159. package/dist/components/customizations/index.d.ts +20 -0
  160. package/dist/components/items/ChartItem.mjs +3 -0
  161. package/dist/components/items/ChartItem.vue.d.ts +4 -0
  162. package/dist/components/items/ChartTreemapGroup.mjs +5 -0
  163. package/dist/components/items/ChartTreemapGroup.vue.d.ts +11 -0
  164. package/dist/components/items/index.d.ts +1 -0
  165. package/dist/components/renderers/CartesianRenderer.mjs +9 -0
  166. package/dist/components/renderers/CartesianRenderer.vue.d.ts +66 -0
  167. package/dist/components/renderers/ColorLegendRenderer.mjs +2 -0
  168. package/dist/components/renderers/ColorLegendRenderer.vue.d.ts +15 -0
  169. package/dist/components/renderers/LegendRenderer.mjs +3 -0
  170. package/dist/components/renderers/LegendRenderer.vue.d.ts +20 -0
  171. package/dist/components/renderers/NavigatorRenderer.mjs +5 -0
  172. package/dist/components/renderers/NavigatorRenderer.vue.d.ts +16 -0
  173. package/dist/components/renderers/RadialRenderer.mjs +9 -0
  174. package/dist/components/renderers/RadialRenderer.vue.d.ts +39 -0
  175. package/dist/components/renderers/RectRenderer.mjs +9 -0
  176. package/dist/components/renderers/RectRenderer.vue.d.ts +32 -0
  177. package/dist/components/renderers/TooltipRenderer.mjs +4 -0
  178. package/dist/components/renderers/TooltipRenderer.vue.d.ts +11 -0
  179. package/dist/components/renderers/layers/BarLayerCanvas.mjs +10 -0
  180. package/dist/components/renderers/layers/BarLayerCanvas.vue.d.ts +3 -0
  181. package/dist/components/renderers/layers/BarLayerSvg.mjs +10 -0
  182. package/dist/components/renderers/layers/BarLayerSvg.vue.d.ts +3 -0
  183. package/dist/components/renderers/layers/CandlestickLayer.mjs +9 -0
  184. package/dist/components/renderers/layers/CandlestickLayer.vue.d.ts +3 -0
  185. package/dist/components/renderers/layers/HeatmapLayer.mjs +9 -0
  186. package/dist/components/renderers/layers/HeatmapLayer.vue.d.ts +3 -0
  187. package/dist/components/renderers/layers/LineLayer.mjs +9 -0
  188. package/dist/components/renderers/layers/LineLayer.vue.d.ts +3 -0
  189. package/dist/components/renderers/layers/PieLayer.mjs +9 -0
  190. package/dist/components/renderers/layers/PieLayer.vue.d.ts +12 -0
  191. package/dist/components/renderers/layers/PolarLayer.mjs +9 -0
  192. package/dist/components/renderers/layers/PolarLayer.vue.d.ts +16 -0
  193. package/dist/components/renderers/layers/RadarLayer.mjs +9 -0
  194. package/dist/components/renderers/layers/RadarLayer.vue.d.ts +16 -0
  195. package/dist/components/renderers/layers/ScatterLayer.mjs +9 -0
  196. package/dist/components/renderers/layers/ScatterLayer.vue.d.ts +3 -0
  197. package/dist/composables/index.d.ts +35 -0
  198. package/dist/composables/useAnimationProps.d.ts +21 -0
  199. package/dist/composables/useAxisComponentBase.d.ts +11 -0
  200. package/dist/composables/useAxisRegistration.d.ts +7 -0
  201. package/dist/composables/useAxisTransition.d.ts +6 -0
  202. package/dist/composables/useBarLayer.d.ts +9 -0
  203. package/dist/composables/useBarRenderer.canvas.d.ts +2 -0
  204. package/dist/composables/useBarRenderer.svg.d.ts +2 -0
  205. package/dist/composables/useBarRendererBase.d.ts +3 -0
  206. package/dist/composables/useCandlestickRenderer.d.ts +2 -0
  207. package/dist/composables/useCartesianAnimation.d.ts +2 -0
  208. package/dist/composables/useCartesianFrame.d.ts +72 -0
  209. package/dist/composables/useCartesianLayout.d.ts +3 -0
  210. package/dist/composables/useChartContext.d.ts +40 -0
  211. package/dist/composables/useChartLayers.d.ts +31 -0
  212. package/dist/composables/useChartRefreshHook.d.ts +1 -0
  213. package/dist/composables/useChartSync.d.ts +2 -0
  214. package/dist/composables/useChartSyncCoordinator.d.ts +23 -0
  215. package/dist/composables/useControllerLifecycle.d.ts +18 -0
  216. package/dist/composables/useCustomizationRegistration.d.ts +18 -0
  217. package/dist/composables/useDatasetAnimationContext.d.ts +14 -0
  218. package/dist/composables/useDatasetRegistration.d.ts +6 -0
  219. package/dist/composables/useDrilldownState.d.ts +3 -0
  220. package/dist/composables/useFamilyRenderers.d.ts +10 -0
  221. package/dist/composables/useFamilyRenderers.spec.d.ts +1 -0
  222. package/dist/composables/useHeatmapRenderer.d.ts +2 -0
  223. package/dist/composables/useItemCollector.d.ts +2 -0
  224. package/dist/composables/useKeyboardController.d.ts +8 -0
  225. package/dist/composables/useKeyboardNavigation.d.ts +2 -0
  226. package/dist/composables/useLineRenderer.d.ts +2 -0
  227. package/dist/composables/useNavigatorRenderer.d.ts +7 -0
  228. package/dist/composables/usePieRenderer.d.ts +2 -0
  229. package/dist/composables/usePolarRenderer.d.ts +2 -0
  230. package/dist/composables/usePropertyAnimations.d.ts +4 -0
  231. package/dist/composables/useRadarRenderer.d.ts +2 -0
  232. package/dist/composables/useRadialFrame.d.ts +39 -0
  233. package/dist/composables/useResponsiveConfig.d.ts +8 -0
  234. package/dist/composables/useResponsiveDimensions.d.ts +2 -0
  235. package/dist/composables/useScatterRenderer.d.ts +2 -0
  236. package/dist/composables/useTreemapRenderer.d.ts +2 -0
  237. package/dist/composables/useZoomController.d.ts +9 -0
  238. package/dist/composables/useZoomPan.d.ts +2 -0
  239. package/dist/context/ChartContext.d.ts +21 -0
  240. package/dist/context/index.d.ts +4 -0
  241. package/dist/context/keys.d.ts +52 -0
  242. package/dist/context/syncKeys.d.ts +5 -0
  243. package/dist/index.d.ts +44 -0
  244. package/dist/index.mjs +67 -0
  245. package/dist/namespace.d.ts +1 -0
  246. package/dist/namespace.mjs +112 -0
  247. package/dist/release-date.d.ts +11 -0
  248. package/dist/types/animation.types.d.ts +38 -0
  249. package/dist/types/axes.types.d.ts +27 -0
  250. package/dist/types/axisComponentBase.types.d.ts +5 -0
  251. package/dist/types/axisGroup.types.d.ts +1 -0
  252. package/dist/types/bar.types.d.ts +42 -0
  253. package/dist/types/breadcrumb.types.d.ts +12 -0
  254. package/dist/types/candlestick.types.d.ts +41 -0
  255. package/dist/types/canvas.types.d.ts +5 -0
  256. package/dist/types/caption.types.d.ts +8 -0
  257. package/dist/types/cartesian.types.d.ts +22 -0
  258. package/dist/types/chart.types.d.ts +51 -0
  259. package/dist/types/heatmap.types.d.ts +58 -0
  260. package/dist/types/index.d.ts +27 -0
  261. package/dist/types/item.types.d.ts +25 -0
  262. package/dist/types/keyboard.types.d.ts +24 -0
  263. package/dist/types/layout.types.d.ts +35 -0
  264. package/dist/types/legend.types.d.ts +13 -0
  265. package/dist/types/line.types.d.ts +64 -0
  266. package/dist/types/pie.types.d.ts +49 -0
  267. package/dist/types/polar.types.d.ts +63 -0
  268. package/dist/types/radar.types.d.ts +56 -0
  269. package/dist/types/responsiveDimensions.types.d.ts +16 -0
  270. package/dist/types/scatter.types.d.ts +50 -0
  271. package/dist/types/svg.types.d.ts +44 -0
  272. package/dist/types/tooltip.types.d.ts +6 -0
  273. package/dist/types/treemap.types.d.ts +50 -0
  274. package/dist/types/zoom.types.d.ts +45 -0
  275. package/dist/utils/index.d.ts +3 -0
  276. package/dist/utils/styles.d.ts +10 -0
  277. package/package.json +63 -0
@@ -0,0 +1,70 @@
1
+ import { useChartMethods } from './chunk-HANSF33Z.mjs';
2
+ import { defineComponent, computed, onMounted, watch, onUnmounted } from 'vue';
3
+
4
+ var referenceLineIdCounter = 0;
5
+ var _sfc_main = /* @__PURE__ */ defineComponent({
6
+ __name: "ChartReferenceLine",
7
+ props: {
8
+ id: {},
9
+ render: { type: Function },
10
+ x: {},
11
+ y: {},
12
+ stroke: {},
13
+ lineStrokeWidth: {},
14
+ strokeDasharray: {},
15
+ label: {},
16
+ labelPosition: {},
17
+ labelAngle: {},
18
+ labelColor: {},
19
+ labelFontSize: {},
20
+ labelFontWeight: {},
21
+ labelBackground: {},
22
+ labelBackgroundOpacity: {},
23
+ labelPadding: {},
24
+ labelBorderRadius: {},
25
+ yAxisId: {},
26
+ placement: {}
27
+ },
28
+ setup(__props) {
29
+ const props = __props;
30
+ const methods = useChartMethods();
31
+ const lineId = props.id || `rl-vue-${++referenceLineIdCounter}`;
32
+ const featureKey = `referenceLine:${lineId}`;
33
+ const config = computed(() => ({
34
+ referenceLineId: lineId,
35
+ x: props.x,
36
+ y: props.y,
37
+ stroke: props.stroke,
38
+ lineStrokeWidth: props.lineStrokeWidth,
39
+ strokeDasharray: props.strokeDasharray,
40
+ label: props.label,
41
+ labelPosition: props.labelPosition,
42
+ labelAngle: props.labelAngle,
43
+ labelColor: props.labelColor,
44
+ labelFontSize: props.labelFontSize,
45
+ labelFontWeight: props.labelFontWeight,
46
+ labelBackground: props.labelBackground,
47
+ labelBackgroundOpacity: props.labelBackgroundOpacity,
48
+ labelPadding: props.labelPadding,
49
+ labelBorderRadius: props.labelBorderRadius,
50
+ yAxisId: props.yAxisId,
51
+ placement: props.placement,
52
+ render: props.render
53
+ }));
54
+ onMounted(() => {
55
+ methods.registerCustomization(featureKey, config.value);
56
+ });
57
+ watch(config, (cfg) => {
58
+ methods.registerCustomization(featureKey, cfg);
59
+ });
60
+ onUnmounted(() => {
61
+ methods.unregisterCustomization(featureKey);
62
+ });
63
+ return (_ctx, _cache) => {
64
+ return null;
65
+ };
66
+ }
67
+ });
68
+ var ChartReferenceLine_default = _sfc_main;
69
+
70
+ export { ChartReferenceLine_default };
@@ -0,0 +1,51 @@
1
+ import { Chart_default } from './chunk-372K2BMN.mjs';
2
+ import { defineComponent, ref, openBlock, createBlock, mergeProps, withCtx, renderSlot } from 'vue';
3
+
4
+ var _sfc_main = /* @__PURE__ */ defineComponent({
5
+ __name: "ChartSvg",
6
+ props: {
7
+ width: {},
8
+ height: {},
9
+ class: {},
10
+ style: {},
11
+ theme: {},
12
+ plugins: {},
13
+ responsive: {
14
+ type: Boolean,
15
+ default: true
16
+ },
17
+ aspectRatio: {},
18
+ debounceDelay: {},
19
+ sync: { type: [Boolean, Object] },
20
+ dir: {},
21
+ fontFamily: {},
22
+ fontSize: {},
23
+ locale: {},
24
+ animation: {
25
+ type: [Object, Boolean],
26
+ default: void 0
27
+ },
28
+ animations: {},
29
+ transitions: {}
30
+ },
31
+ emits: ["resize"],
32
+ setup(__props, { expose: __expose }) {
33
+ const chartRef = ref(null);
34
+ __expose({ redraw: () => chartRef.value?.redraw() });
35
+ return (_ctx, _cache) => {
36
+ return openBlock(), createBlock(Chart_default, mergeProps({
37
+ ref_key: "chartRef",
38
+ ref: chartRef
39
+ }, _ctx.$props, {
40
+ renderer: "svg",
41
+ onResize: _cache[0] || (_cache[0] = (w, h) => _ctx.$emit("resize", w, h))
42
+ }), {
43
+ default: withCtx(() => [renderSlot(_ctx.$slots, "default")]),
44
+ _: 3
45
+ }, 16);
46
+ };
47
+ }
48
+ });
49
+ var ChartSvg_default = _sfc_main;
50
+
51
+ export { ChartSvg_default };
@@ -0,0 +1,142 @@
1
+ import { useCartesianFrame, useLineRenderer, useCartesianFrameRegistration } from './chunk-CQHNYT2V.mjs';
2
+ import { useChartMethods, useChartState, useChartHover } from './chunk-HANSF33Z.mjs';
3
+ import { defineComponent, computed, h, unref, openBlock, createElementBlock, createCommentVNode } from 'vue';
4
+ import { resolvePointLabels } from '@primeui/chart-core';
5
+
6
+ var _hoisted_1 = ["clip-path"];
7
+ var _sfc_main = /* @__PURE__ */ defineComponent({
8
+ __name: "LineLayer",
9
+ setup(__props) {
10
+ const frame = useCartesianFrame();
11
+ const methods = useChartMethods();
12
+ const state = useChartState();
13
+ const hoverCtx = useChartHover();
14
+ const features = computed(() => state.value.features);
15
+ const line = useLineRenderer({
16
+ chartArea: frame.cartesianArea,
17
+ renderer: methods.renderer,
18
+ canvasEl: frame.canvasEl,
19
+ datasets: computed(() => state.value.datasets),
20
+ datasetVisibility: computed(() => state.value.datasetVisibility),
21
+ hover: computed(() => hoverCtx.value.hover),
22
+ hoverConfig: frame.hoverConfig,
23
+ chartId: methods.chartId,
24
+ width: frame.width,
25
+ height: frame.height,
26
+ categoryScale: computed(() => frame.layoutData.value?.sharedCategoryScale),
27
+ valueScales: computed(() => frame.layoutData.value?.valueScales),
28
+ firstValueAxisId: computed(() => frame.layoutData.value?.valueScales?.keys().next().value ?? "default"),
29
+ axisIdProp: computed(() => frame.layoutData.value?.orientation === "horizontal" ? "xAxisId" : "yAxisId"),
30
+ lineStackBasesMap: computed(() => frame.layoutData.value?.lineStackBasesMap),
31
+ lineTransformedValues: computed(() => frame.layoutData.value?.lineTransformedValues),
32
+ rangeGroups: computed(() => frame.layoutData.value?.rangeGroups),
33
+ features,
34
+ labelConfig: frame.labelConfig,
35
+ layoutData: frame.layoutData,
36
+ compositor: frame.compositor,
37
+ dir: computed(() => methods.dir),
38
+ theme: computed(() => methods.theme)
39
+ });
40
+ const dataLabelVNodes = computed(() => {
41
+ const lc = frame.labelConfig.value;
42
+ if (methods.renderer !== "svg" || !frame.layoutData.value || !lc?.render) return [];
43
+ const visibility = state.value.datasetVisibility;
44
+ const nodes = [];
45
+ for (const [dsId, lineLayout] of line.lineLayouts.value) {
46
+ if (visibility?.get(dsId) === false) continue;
47
+ const lineProps = line.lineRenderProps.value.get(dsId);
48
+ const seriesColor = typeof lineProps?.color === "string" ? lineProps.color : typeof lineLayout.lineColor === "string" ? lineLayout.lineColor : lc.color ?? "";
49
+ const dsTotal = lineLayout.visiblePoints.reduce((sum, pt) => sum + Math.abs(pt.value ?? 0), 0);
50
+ const resolved = resolvePointLabels(lineLayout.visiblePoints, seriesColor, dsTotal, lc, lineProps?.name);
51
+ for (const lbl of resolved) {
52
+ const result = lc.render({
53
+ index: lbl.dataIndex,
54
+ value: lbl.value,
55
+ percentage: lbl.percentage,
56
+ formattedText: lbl.text,
57
+ label: lbl.seriesName ?? lbl.category,
58
+ color: lbl.color,
59
+ x: lbl.x,
60
+ y: lbl.y
61
+ });
62
+ if (result != null) {
63
+ nodes.push(h("g", {
64
+ key: `line-${dsId}-${lbl.dataIndex}`,
65
+ transform: `translate(${lbl.x},${lbl.y})`,
66
+ "text-anchor": lbl.textAnchor,
67
+ "dominant-baseline": lbl.baseline
68
+ }, [result]));
69
+ }
70
+ }
71
+ }
72
+ return nodes;
73
+ });
74
+ useCartesianFrameRegistration({
75
+ type: "line",
76
+ hitTest: (x, y) => {
77
+ const lnHit = line.hitTest(x, y);
78
+ if (!lnHit) return null;
79
+ let fmtVal = String(lnHit.value);
80
+ const ld = frame.layoutData.value;
81
+ if (ld?.axisLayouts) {
82
+ for (const [key, info] of ld.axisLayouts) {
83
+ if (key.startsWith("y:")) {
84
+ const fmt = info.props?.tickFormat;
85
+ if (typeof fmt === "function") {
86
+ fmtVal = String(fmt(lnHit.value));
87
+ break;
88
+ }
89
+ }
90
+ }
91
+ }
92
+ return {
93
+ datasetId: lnHit.datasetId,
94
+ index: lnHit.index,
95
+ label: lnHit.label,
96
+ value: lnHit.value,
97
+ color: lnHit.color,
98
+ snapX: lnHit.x,
99
+ snapY: lnHit.y,
100
+ formattedValue: fmtVal,
101
+ cursorFormattedValue: ""
102
+ };
103
+ },
104
+ findAllNearest: (x, y) => line.findAllNearest(x, y),
105
+ applyPropertyAnimations: (store) => line.applyPropertyAnimations(store),
106
+ renderFrameCycle: () => line.renderFrameCycle(),
107
+ syncWithAnimatedScale: (categoryScale, valueScales) => line.syncWithAnimatedScale(categoryScale, valueScales),
108
+ dataLabelVNodes,
109
+ markerOverlays: line.markerOverlays,
110
+ getPointPosition: (datasetId, index) => {
111
+ const lineLayout = line.lineLayouts.value.get(datasetId);
112
+ if (lineLayout) {
113
+ const found = lineLayout.visiblePoints.find((p) => p.dataIndex === index);
114
+ if (found) {
115
+ const r = 6;
116
+ return {
117
+ x: found.x - r,
118
+ y: found.y - r,
119
+ width: r * 2,
120
+ height: r * 2,
121
+ shape: "circle"
122
+ };
123
+ }
124
+ }
125
+ return null;
126
+ }
127
+ });
128
+ return (_ctx, _cache) => {
129
+ return unref(methods).renderer === "svg" && unref(line).hasLineData.value ? (openBlock(), createElementBlock("g", {
130
+ key: 0,
131
+ ref: (el) => {
132
+ unref(line).groupRef.value = el;
133
+ },
134
+ class: "line-chart",
135
+ "clip-path": unref(frame).layoutData.value?.cartesianArea ? `url(#${unref(frame).plotClipId})` : void 0
136
+ }, null, 8, _hoisted_1)) : createCommentVNode("", true);
137
+ };
138
+ }
139
+ });
140
+ var LineLayer_default = _sfc_main;
141
+
142
+ export { LineLayer_default };
@@ -0,0 +1,230 @@
1
+ import { provideRadialFrame, useChartLayers, usePropertyAnimations } from './chunk-CQHNYT2V.mjs';
2
+ import { useChartMethods, useChartState } from './chunk-HANSF33Z.mjs';
3
+ import { defineComponent, computed, ref, watch, shallowRef, onUnmounted, openBlock, createElementBlock, Fragment, unref, createCommentVNode, renderList, createBlock, resolveDynamicComponent } from 'vue';
4
+ import { collectItems, computeRadialComboContext, materializeSvgGroup, renderRadialGridSvg, AnimatedPropertyStore, AnimationRegistry, buildRadialGridLayout, withReferenceFeatures, redrawRadialCanvas } from '@primeui/chart-core';
5
+
6
+ var _sfc_main = /* @__PURE__ */ defineComponent({
7
+ __name: "RadialRenderer",
8
+ props: {
9
+ chartArea: {},
10
+ width: {},
11
+ height: {},
12
+ canvasEl: {},
13
+ containerEl: {},
14
+ adaptiveDataLabelFontSize: {}
15
+ },
16
+ setup(__props, { expose: __expose }) {
17
+ const props = __props;
18
+ const methods = useChartMethods();
19
+ const state = useChartState();
20
+ const frame = provideRadialFrame();
21
+ const chartLayers = useChartLayers();
22
+ const gridLayers = computed(() => collectRadialLayers("grid"));
23
+ const framelessLayers = computed(() => collectRadialLayers(null));
24
+ function collectRadialLayers(frameKind) {
25
+ if (!chartLayers) return [];
26
+ const out = [];
27
+ for (const [type, entry] of chartLayers) {
28
+ if (entry.family === "radial" && entry.frameKind === frameKind && entry.layer) out.push({
29
+ type,
30
+ layer: entry.layer
31
+ });
32
+ }
33
+ return out;
34
+ }
35
+ const isCombo = computed(() => {
36
+ const vals = Array.from(state.value.datasets.values());
37
+ return vals.some((ds) => ds.type === "radar") && vals.some((ds) => ds.type === "polar");
38
+ });
39
+ const sharedContext = computed(() => {
40
+ if (!isCombo.value) return null;
41
+ const sortedDatasets = Array.from(state.value.datasets.entries()).sort(([, a], [, b]) => a.order - b.order);
42
+ const { radar: radarEntries, polar: polarEntries } = collectItems(sortedDatasets, state.value.datasetVisibility);
43
+ return computeRadialComboContext(radarEntries, polarEntries);
44
+ });
45
+ let _stickyGridLayout = null;
46
+ function buildGridLayout() {
47
+ const radarRaw = frame.handles.get("radar")?.layout?.value;
48
+ const polarRaw = frame.handles.get("polar")?.layout?.value;
49
+ const src = radarRaw ? {
50
+ ...radarRaw,
51
+ radius: radarRaw.radius
52
+ } : polarRaw ? {
53
+ ...polarRaw,
54
+ radius: polarRaw.maxRadius
55
+ } : null;
56
+ if (!src) return _stickyGridLayout ? withReferenceFeatures(_stickyGridLayout, state.value.features) : null;
57
+ const xAxisProps = [...state.value.axes.x.values()][0]?.props;
58
+ let defaultYAxisProps;
59
+ const yAxesByCategory = /* @__PURE__ */ new Map();
60
+ for (const axis of state.value.axes.y.values()) {
61
+ const yProps = axis.props;
62
+ const cat = yProps.category;
63
+ if (cat) yAxesByCategory.set(cat, yProps);
64
+ else if (!defaultYAxisProps) defaultYAxisProps = yProps;
65
+ }
66
+ const layout = buildRadialGridLayout(src, xAxisProps, defaultYAxisProps, yAxesByCategory.size > 0 ? yAxesByCategory : void 0, radarRaw ? "radar" : "polar");
67
+ _stickyGridLayout = layout;
68
+ return withReferenceFeatures(layout, state.value.features);
69
+ }
70
+ function redrawCanvas() {
71
+ if (methods.renderer !== "canvas") return;
72
+ const canvas = props.canvasEl;
73
+ if (!canvas) return;
74
+ const ctx = canvas.getContext("2d");
75
+ if (!ctx) return;
76
+ redrawRadialCanvas(ctx, canvas, buildGridLayout(), frame.handles.get("polar")?.renderCanvasContent ?? null, frame.handles.get("radar")?.renderCanvasContent ?? null, methods.theme);
77
+ }
78
+ const radialAxes = computed(() => ({
79
+ x: state.value.axes.x,
80
+ y: state.value.axes.y
81
+ }));
82
+ const gridLayerLayouts = computed(() => [frame.handles.get("radar")?.layout?.value ?? null, frame.handles.get("polar")?.layout?.value ?? null]);
83
+ const sharedGridGroupRef = ref(null);
84
+ watch([
85
+ gridLayerLayouts,
86
+ sharedGridGroupRef,
87
+ () => state.value.features,
88
+ radialAxes
89
+ ], () => {
90
+ const group = sharedGridGroupRef.value;
91
+ if (!group) return;
92
+ while (group.firstChild) {
93
+ group.removeChild(group.firstChild);
94
+ }
95
+ const gridLayout = buildGridLayout();
96
+ if (gridLayout) {
97
+ group.appendChild(materializeSvgGroup(renderRadialGridSvg(gridLayout, methods.theme)));
98
+ }
99
+ }, { flush: "post" });
100
+ function hitTest(x, y) {
101
+ return frame.handles.get("polar")?.hitTest(x, y) ?? frame.handles.get("radar")?.hitTest(x, y) ?? frame.handles.get("pie")?.hitTest(x, y) ?? null;
102
+ }
103
+ function findAllNearest(x, y) {
104
+ const polar = frame.handles.get("polar")?.findAllNearest?.(x, y) ?? null;
105
+ const radar = frame.handles.get("radar")?.findAllNearest?.(x, y) ?? null;
106
+ if (polar && radar) {
107
+ const c = getCenter();
108
+ const cursorR = Math.hypot(x - c.x, y - c.y);
109
+ const snapOf = (res) => res.allSeries.find((s) => s.datasetId === res.primary.datasetId)?.snapPixel ?? 0;
110
+ const primary = Math.abs(snapOf(polar) - cursorR) <= Math.abs(snapOf(radar) - cursorR) ? polar.primary : radar.primary;
111
+ return {
112
+ primary,
113
+ allSeries: [...polar.allSeries, ...radar.allSeries]
114
+ };
115
+ }
116
+ return polar ?? radar ?? null;
117
+ }
118
+ function getPointPosition(datasetId, index) {
119
+ return frame.handles.get("radar")?.getPointPosition(datasetId, index) ?? frame.handles.get("pie")?.getPointPosition(datasetId, index) ?? frame.handles.get("polar")?.getPointPosition(datasetId, index) ?? null;
120
+ }
121
+ function getCenter() {
122
+ const ca = props.chartArea;
123
+ return frame.handles.get("pie")?.getCenter?.() ?? frame.handles.get("radar")?.getCenter?.() ?? frame.handles.get("polar")?.getCenter?.() ?? {
124
+ x: ca.x + ca.width / 2,
125
+ y: ca.y + ca.height / 2
126
+ };
127
+ }
128
+ function handleDrilldownClick(_hit) {
129
+ return false;
130
+ }
131
+ function getPlotArea() {
132
+ return props.chartArea ?? null;
133
+ }
134
+ function getColorScaleInfo() {
135
+ return null;
136
+ }
137
+ const mergedPropertyAnimations = computed(() => {
138
+ const f = state.value.features;
139
+ const animProps = f.get("animation")?.props;
140
+ if (animProps?.enabled === false) {
141
+ return void 0;
142
+ }
143
+ const merged = [];
144
+ if (animProps?.propertyAnimations) merged.push(...animProps.propertyAnimations);
145
+ f.forEach((entry, key) => {
146
+ if (typeof key !== "string" || !key.startsWith("animation:")) return;
147
+ const p = entry.props;
148
+ if (p.propertyAnimations) merged.push(...p.propertyAnimations);
149
+ });
150
+ if (!merged.length) {
151
+ return void 0;
152
+ }
153
+ return merged;
154
+ });
155
+ const animStoreRef = shallowRef(new AnimatedPropertyStore());
156
+ const animRegistry = new AnimationRegistry();
157
+ animRegistry.setRepaintCallback(() => {
158
+ const store = animStoreRef.value;
159
+ if (!store) return;
160
+ for (const handle of frame.handles.values()) handle.applyPropertyAnimations?.(store);
161
+ });
162
+ function onPropertyComplete() {
163
+ for (const handle of frame.handles.values()) handle.renderFrameCycle?.();
164
+ }
165
+ usePropertyAnimations(mergedPropertyAnimations, animRegistry, animStoreRef.value, onPropertyComplete);
166
+ onUnmounted(() => {
167
+ animRegistry.destroy();
168
+ animStoreRef.value?.destroy();
169
+ animStoreRef.value = null;
170
+ });
171
+ __expose({
172
+ hitTest,
173
+ findAllNearest,
174
+ handleDrilldownClick,
175
+ getPointPosition,
176
+ getCenter,
177
+ getPlotArea,
178
+ getColorScaleInfo
179
+ });
180
+ return (_ctx, _cache) => {
181
+ return openBlock(), createElementBlock(Fragment, null, [
182
+ unref(methods).renderer === "svg" ? (openBlock(), createElementBlock("g", {
183
+ key: 0,
184
+ ref_key: "sharedGridGroupRef",
185
+ ref: sharedGridGroupRef
186
+ }, null, 512)) : createCommentVNode("", true),
187
+ (openBlock(true), createElementBlock(Fragment, null, renderList(gridLayers.value, (layer) => {
188
+ return openBlock(), createBlock(resolveDynamicComponent(layer.layer), {
189
+ key: layer.type,
190
+ "chart-area": __props.chartArea,
191
+ width: __props.width,
192
+ height: __props.height,
193
+ "canvas-el": __props.canvasEl,
194
+ "adaptive-data-label-font-size": __props.adaptiveDataLabelFontSize,
195
+ "shared-context": sharedContext.value,
196
+ "request-redraw": redrawCanvas
197
+ }, null, 8, [
198
+ "chart-area",
199
+ "width",
200
+ "height",
201
+ "canvas-el",
202
+ "adaptive-data-label-font-size",
203
+ "shared-context"
204
+ ]);
205
+ }), 128)),
206
+ (openBlock(true), createElementBlock(Fragment, null, renderList(framelessLayers.value, (layer) => {
207
+ return openBlock(), createBlock(resolveDynamicComponent(layer.layer), {
208
+ key: layer.type,
209
+ "chart-area": __props.chartArea,
210
+ width: __props.width,
211
+ height: __props.height,
212
+ "canvas-el": __props.canvasEl,
213
+ "container-el": __props.containerEl,
214
+ "adaptive-data-label-font-size": __props.adaptiveDataLabelFontSize
215
+ }, null, 8, [
216
+ "chart-area",
217
+ "width",
218
+ "height",
219
+ "canvas-el",
220
+ "container-el",
221
+ "adaptive-data-label-font-size"
222
+ ]);
223
+ }), 128))
224
+ ], 64);
225
+ };
226
+ }
227
+ });
228
+ var RadialRenderer_default = _sfc_main;
229
+
230
+ export { RadialRenderer_default };
@@ -0,0 +1,53 @@
1
+ import { useCustomizationRegistration } from './chunk-PQV55JYI.mjs';
2
+ import { CHART_METHODS_KEY, CHART_GROUP_TEXT_KEY } from './chunk-FZ3PZ66C.mjs';
3
+ import { defineComponent, inject, computed, onMounted, watch, onUnmounted } from 'vue';
4
+
5
+ var _sfc_main = /* @__PURE__ */ defineComponent({
6
+ __name: "ChartCaption",
7
+ props: {
8
+ fontWeight: {},
9
+ padding: {},
10
+ text: {},
11
+ position: {},
12
+ alignment: {},
13
+ offsetX: {},
14
+ offsetY: {},
15
+ fontSize: {},
16
+ fontFamily: {},
17
+ fontStyle: {},
18
+ lineHeight: {},
19
+ color: {}
20
+ },
21
+ setup(__props) {
22
+ const props = __props;
23
+ const chartMethods = inject(CHART_METHODS_KEY, null);
24
+ const groupText = inject(CHART_GROUP_TEXT_KEY, null);
25
+ if (chartMethods) {
26
+ const registrationProps = computed(() => ({
27
+ text: props.text,
28
+ position: props.position,
29
+ alignment: props.alignment,
30
+ offsetX: props.offsetX,
31
+ offsetY: props.offsetY,
32
+ fontSize: props.fontSize,
33
+ fontWeight: props.fontWeight,
34
+ fontFamily: props.fontFamily,
35
+ fontStyle: props.fontStyle,
36
+ lineHeight: props.lineHeight,
37
+ color: props.color,
38
+ padding: props.padding
39
+ }));
40
+ useCustomizationRegistration("caption", registrationProps);
41
+ } else if (groupText) {
42
+ onMounted(() => groupText.setCaption(props.text));
43
+ watch(() => props.text, (t) => groupText.setCaption(t));
44
+ onUnmounted(() => groupText.setCaption(void 0));
45
+ }
46
+ return (_ctx, _cache) => {
47
+ return null;
48
+ };
49
+ }
50
+ });
51
+ var ChartCaption_default = _sfc_main;
52
+
53
+ export { ChartCaption_default };
@@ -0,0 +1,70 @@
1
+ import { useChartMethods } from './chunk-HANSF33Z.mjs';
2
+ import { defineComponent, computed, onMounted, watch, onUnmounted } from 'vue';
3
+
4
+ var referenceBandIdCounter = 0;
5
+ var _sfc_main = /* @__PURE__ */ defineComponent({
6
+ __name: "ChartReferenceBand",
7
+ props: {
8
+ id: {},
9
+ render: { type: Function },
10
+ x1: {},
11
+ x2: {},
12
+ y1: {},
13
+ y2: {},
14
+ fill: {},
15
+ fillOpacity: {},
16
+ stroke: {},
17
+ label: {},
18
+ labelPosition: {},
19
+ labelAngle: {},
20
+ labelColor: {},
21
+ labelFontSize: {},
22
+ labelFontWeight: {},
23
+ bracket: { type: [Boolean, Object] },
24
+ separator: { type: [Boolean, Object] },
25
+ yAxisId: {},
26
+ placement: {}
27
+ },
28
+ setup(__props) {
29
+ const props = __props;
30
+ const methods = useChartMethods();
31
+ const bandId = props.id || `rb-vue-${++referenceBandIdCounter}`;
32
+ const featureKey = `referenceBand:${bandId}`;
33
+ const config = computed(() => ({
34
+ referenceBandId: bandId,
35
+ x1: props.x1,
36
+ x2: props.x2,
37
+ y1: props.y1,
38
+ y2: props.y2,
39
+ fill: props.fill,
40
+ fillOpacity: props.fillOpacity,
41
+ stroke: props.stroke,
42
+ label: props.label,
43
+ labelPosition: props.labelPosition,
44
+ labelAngle: props.labelAngle,
45
+ labelColor: props.labelColor,
46
+ labelFontSize: props.labelFontSize,
47
+ labelFontWeight: props.labelFontWeight,
48
+ bracket: props.bracket,
49
+ separator: props.separator,
50
+ yAxisId: props.yAxisId,
51
+ render: props.render,
52
+ placement: props.placement
53
+ }));
54
+ onMounted(() => {
55
+ methods.registerCustomization(featureKey, config.value);
56
+ });
57
+ watch(config, (cfg) => {
58
+ methods.registerCustomization(featureKey, cfg);
59
+ });
60
+ onUnmounted(() => {
61
+ methods.unregisterCustomization(featureKey);
62
+ });
63
+ return (_ctx, _cache) => {
64
+ return null;
65
+ };
66
+ }
67
+ });
68
+ var ChartReferenceBand_default = _sfc_main;
69
+
70
+ export { ChartReferenceBand_default };