@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,96 @@
1
+ import { useCartesianFrame, useHeatmapRenderer, useCartesianFrameRegistration } from './chunk-CQHNYT2V.mjs';
2
+ import { useChartMethods, useChartState, useChartHover } from './chunk-HANSF33Z.mjs';
3
+ import { defineComponent, computed, unref, openBlock, createElementBlock, Fragment, createElementVNode, renderList, createBlock, createCommentVNode } from 'vue';
4
+
5
+ var _sfc_main = /* @__PURE__ */ defineComponent({
6
+ __name: "HeatmapLayer",
7
+ setup(__props) {
8
+ const VNodeRenderer = defineComponent({
9
+ props: { node: {
10
+ type: Object,
11
+ required: true
12
+ } },
13
+ render() {
14
+ return this.node;
15
+ }
16
+ });
17
+ const frame = useCartesianFrame();
18
+ const methods = useChartMethods();
19
+ const state = useChartState();
20
+ const hoverCtx = useChartHover();
21
+ const features = computed(() => state.value.features);
22
+ const heatmap = useHeatmapRenderer({
23
+ chartArea: frame.cartesianArea,
24
+ renderer: methods.renderer,
25
+ canvasEl: frame.canvasEl,
26
+ datasets: computed(() => state.value.datasets),
27
+ axes: computed(() => state.value.axes),
28
+ datasetVisibility: computed(() => state.value.datasetVisibility),
29
+ hover: computed(() => hoverCtx.value.hover),
30
+ hoverConfig: frame.hoverConfig,
31
+ chartId: methods.chartId,
32
+ width: frame.width,
33
+ height: frame.height,
34
+ features,
35
+ compositor: frame.compositor,
36
+ globalFont: methods.font,
37
+ locale: computed(() => methods.locale),
38
+ theme: computed(() => methods.theme)
39
+ });
40
+ useCartesianFrameRegistration({
41
+ type: "heatmap",
42
+ getColorScaleInfo: () => heatmap.getColorScaleInfo(),
43
+ scaleResult: heatmap.scaleResult,
44
+ getPointPosition: (datasetId, index) => heatmap.getPointPosition(datasetId, index),
45
+ applyPropertyAnimations: (store) => heatmap.applyPropertyAnimations(store),
46
+ renderFrameCycle: () => heatmap.renderFrameCycle(),
47
+ hitTest: (x, y) => {
48
+ const hmHit = heatmap.hitTest(x, y);
49
+ if (!hmHit) return null;
50
+ return {
51
+ datasetId: hmHit.datasetId,
52
+ index: hmHit.index,
53
+ col: hmHit.col,
54
+ label: `${hmHit.xLabel}, ${hmHit.yLabel}`,
55
+ value: hmHit.value ?? 0,
56
+ color: hmHit.color,
57
+ snapX: hmHit.x + hmHit.width / 2,
58
+ snapY: hmHit.y + hmHit.height / 2,
59
+ formattedValue: hmHit.value != null ? String(hmHit.value) : "",
60
+ cursorFormattedValue: ""
61
+ };
62
+ }
63
+ });
64
+ return (_ctx, _cache) => {
65
+ return unref(methods).renderer === "svg" && unref(heatmap).hasHeatmapData.value ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
66
+ createElementVNode("g", {
67
+ ref: (el) => {
68
+ unref(heatmap).gridGroupRef.value = el;
69
+ },
70
+ class: "heatmap-grid"
71
+ }, null, 512),
72
+ createElementVNode("g", {
73
+ ref: (el) => {
74
+ unref(heatmap).groupRef.value = el;
75
+ },
76
+ class: "heatmap-chart"
77
+ }, null, 512),
78
+ createElementVNode("g", {
79
+ ref: (el) => {
80
+ unref(heatmap).axisGroupRef.value = el;
81
+ },
82
+ class: "heatmap-axes"
83
+ }, null, 512),
84
+ (openBlock(true), createElementBlock(Fragment, null, renderList(unref(heatmap).svgContent.value, (el) => {
85
+ return openBlock(), createBlock(unref(VNodeRenderer), {
86
+ key: el.key ?? el.props?.key,
87
+ node: el
88
+ }, null, 8, ["node"]);
89
+ }), 128))
90
+ ], 64)) : createCommentVNode("", true);
91
+ };
92
+ }
93
+ });
94
+ var HeatmapLayer_default = _sfc_main;
95
+
96
+ export { HeatmapLayer_default };
@@ -0,0 +1,52 @@
1
+ import { registerNavigatorRenderer } from './chunk-CQHNYT2V.mjs';
2
+ import { useCustomizationRegistration } from './chunk-PQV55JYI.mjs';
3
+ import { NavigatorRenderer_default } from './chunk-NLXOJSKK.mjs';
4
+ import { defineComponent, getCurrentInstance, computed } from 'vue';
5
+
6
+ var _sfc_main = /* @__PURE__ */ defineComponent({
7
+ __name: "ChartNavigator",
8
+ props: {
9
+ height: {},
10
+ series: {},
11
+ color: {},
12
+ opacity: {},
13
+ selectionColor: {},
14
+ selectionFill: {},
15
+ maskColor: {},
16
+ enabled: { type: Boolean },
17
+ gap: {},
18
+ backgroundColor: {},
19
+ gridColor: {},
20
+ labelColor: {},
21
+ handleWidth: {},
22
+ gripLineGap: {},
23
+ padding: {},
24
+ animation: { type: [Boolean, Object] }
25
+ },
26
+ setup(__props) {
27
+ const props = __props;
28
+ registerNavigatorRenderer(NavigatorRenderer_default);
29
+ const vnodeProps = getCurrentInstance()?.vnode.props || {};
30
+ const registrationProps = computed(() => ({
31
+ height: props.height,
32
+ gap: props.gap,
33
+ series: props.series,
34
+ color: props.color,
35
+ opacity: props.opacity,
36
+ enabled: "enabled" in vnodeProps ? props.enabled : void 0,
37
+ selectionColor: props.selectionColor,
38
+ selectionFill: props.selectionFill,
39
+ maskColor: props.maskColor,
40
+ backgroundColor: props.backgroundColor,
41
+ gridColor: props.gridColor,
42
+ labelColor: props.labelColor
43
+ }));
44
+ useCustomizationRegistration("navigator", registrationProps);
45
+ return (_ctx, _cache) => {
46
+ return null;
47
+ };
48
+ }
49
+ });
50
+ var ChartNavigator_default = _sfc_main;
51
+
52
+ export { ChartNavigator_default };
@@ -0,0 +1,276 @@
1
+ import { CartesianRenderer_default } from './chunk-HTZVV6VV.mjs';
2
+ import { ScatterLayer_default } from './chunk-DYVFVVTO.mjs';
3
+ import { registerFamilyRenderer, registerChartLayer, useDatasetAnimationRegistration, useDatasetRegistration, useItemCollector } from './chunk-CQHNYT2V.mjs';
4
+ import { useRendererHint, useChartMethods } from './chunk-HANSF33Z.mjs';
5
+ import { defineComponent, useSlots, computed, onMounted, watch, onUnmounted, renderSlot, createCommentVNode } from 'vue';
6
+ import { scatterRenderer, resolveAccessor } from '@primeui/chart-core';
7
+
8
+ var scatterIdCounter = 0;
9
+ var _sfc_main = /* @__PURE__ */ defineComponent({
10
+ __name: "ChartScatter",
11
+ props: {
12
+ id: {},
13
+ data: {},
14
+ categoryField: { type: [
15
+ String,
16
+ Function,
17
+ Array
18
+ ] },
19
+ valueField: { type: [
20
+ String,
21
+ Function,
22
+ Number,
23
+ null,
24
+ Array
25
+ ] },
26
+ name: {},
27
+ color: { type: [
28
+ String,
29
+ Function,
30
+ Array
31
+ ] },
32
+ xAxisId: {},
33
+ yAxisId: {},
34
+ order: {},
35
+ stackId: {},
36
+ xField: { type: [
37
+ String,
38
+ Function,
39
+ Number,
40
+ Array
41
+ ] },
42
+ yField: { type: [
43
+ String,
44
+ Function,
45
+ Number,
46
+ Array
47
+ ] },
48
+ sizeField: { type: [
49
+ String,
50
+ Function,
51
+ Number,
52
+ Array
53
+ ] },
54
+ markerSize: { type: [
55
+ String,
56
+ Function,
57
+ Number,
58
+ Array
59
+ ] },
60
+ markerShape: { type: [
61
+ String,
62
+ Function,
63
+ Array
64
+ ] },
65
+ minSize: {},
66
+ maxSize: {},
67
+ connectNulls: { type: [Boolean, String] },
68
+ opacity: { type: [
69
+ String,
70
+ Function,
71
+ Number,
72
+ Array
73
+ ] },
74
+ pointFillOpacity: {},
75
+ pointHitRadius: {},
76
+ hoverPointRadius: {},
77
+ pointHoverBackgroundColor: { type: [
78
+ String,
79
+ Function,
80
+ Array
81
+ ] },
82
+ pointHoverBorderColor: { type: [
83
+ String,
84
+ Function,
85
+ Array
86
+ ] },
87
+ pointHoverBorderStrokeWidth: { type: [
88
+ String,
89
+ Function,
90
+ Number,
91
+ Array
92
+ ] },
93
+ hoverColor: {},
94
+ hoverBorderColor: {},
95
+ renderMarker: { type: Function },
96
+ keyField: {},
97
+ pointRadius: {},
98
+ pointBackgroundColor: { type: [
99
+ String,
100
+ Function,
101
+ Array
102
+ ] },
103
+ pointBorderColor: { type: [
104
+ String,
105
+ Function,
106
+ Array
107
+ ] },
108
+ pointBorderStrokeWidth: { type: [
109
+ String,
110
+ Function,
111
+ Number,
112
+ Array
113
+ ] },
114
+ pointBorderDash: { type: [
115
+ Array,
116
+ String,
117
+ Function
118
+ ] },
119
+ pointBorderDashOffset: { type: [
120
+ String,
121
+ Function,
122
+ Number,
123
+ Array
124
+ ] },
125
+ pointBorderJoinStyle: {},
126
+ pointBorderRadius: { type: [
127
+ String,
128
+ Function,
129
+ Number,
130
+ Array
131
+ ] },
132
+ pointRotation: { type: [
133
+ String,
134
+ Function,
135
+ Number,
136
+ Array
137
+ ] },
138
+ animations: {}
139
+ },
140
+ setup(__props) {
141
+ useRendererHint("cartesian");
142
+ registerFamilyRenderer("cartesian", CartesianRenderer_default);
143
+ registerChartLayer("scatter", {
144
+ family: "cartesian",
145
+ frameKind: "grid",
146
+ layer: ScatterLayer_default,
147
+ axisHints: scatterRenderer
148
+ });
149
+ const props = __props;
150
+ function generateScatterId() {
151
+ return `scatter-auto-${++scatterIdCounter}`;
152
+ }
153
+ const slots = useSlots();
154
+ const hasChildren = computed(() => !!slots.default);
155
+ const autoId = props.id || generateScatterId();
156
+ useDatasetAnimationRegistration(() => autoId, () => props.animations);
157
+ if (!hasChildren.value) {
158
+ const datasetId = computed(() => autoId);
159
+ const datasetProps = computed(() => ({
160
+ id: autoId,
161
+ data: props.data,
162
+ xField: props.xField,
163
+ yField: props.yField,
164
+ sizeField: props.sizeField,
165
+ color: props.color,
166
+ name: props.name,
167
+ order: props.order,
168
+ markerSize: props.markerSize,
169
+ markerShape: props.markerShape,
170
+ minSize: props.minSize,
171
+ maxSize: props.maxSize,
172
+ pointBorderColor: props.pointBorderColor,
173
+ pointBorderStrokeWidth: props.pointBorderStrokeWidth,
174
+ pointBorderDash: props.pointBorderDash,
175
+ pointBorderDashOffset: props.pointBorderDashOffset,
176
+ pointBorderJoinStyle: props.pointBorderJoinStyle,
177
+ pointBorderRadius: props.pointBorderRadius,
178
+ pointRotation: props.pointRotation,
179
+ pointHitRadius: props.pointHitRadius,
180
+ hoverPointRadius: props.hoverPointRadius,
181
+ pointHoverBackgroundColor: props.pointHoverBackgroundColor,
182
+ pointHoverBorderColor: props.pointHoverBorderColor,
183
+ pointHoverBorderStrokeWidth: props.pointHoverBorderStrokeWidth,
184
+ hoverColor: props.hoverColor,
185
+ hoverBorderColor: props.hoverBorderColor,
186
+ xAxisId: props.xAxisId,
187
+ yAxisId: props.yAxisId,
188
+ connectNulls: props.connectNulls,
189
+ renderMarker: props.renderMarker
190
+ }));
191
+ useDatasetRegistration({
192
+ id: datasetId,
193
+ type: "scatter",
194
+ props: datasetProps
195
+ });
196
+ }
197
+ if (hasChildren.value) {
198
+ let buildSynthesizedProps2 = function() {
199
+ const items = getItems();
200
+ return {
201
+ id: autoId,
202
+ data: items,
203
+ xField: (ctx) => ctx.datum.x ?? 0,
204
+ yField: (ctx) => ctx.datum.y ?? 0,
205
+ color: ((ctx) => ctx.datum.color ?? resolveAccessor(props.color, ctx)),
206
+ name: props.name,
207
+ markerSize: props.markerSize,
208
+ markerShape: props.markerShape,
209
+ minSize: props.minSize,
210
+ maxSize: props.maxSize,
211
+ pointBorderColor: props.pointBorderColor,
212
+ pointBorderStrokeWidth: props.pointBorderStrokeWidth,
213
+ pointBorderDash: props.pointBorderDash,
214
+ pointBorderDashOffset: props.pointBorderDashOffset,
215
+ pointBorderJoinStyle: props.pointBorderJoinStyle,
216
+ pointBorderRadius: props.pointBorderRadius,
217
+ pointRotation: props.pointRotation,
218
+ pointHitRadius: props.pointHitRadius,
219
+ hoverPointRadius: props.hoverPointRadius,
220
+ pointHoverBackgroundColor: props.pointHoverBackgroundColor,
221
+ pointHoverBorderColor: props.pointHoverBorderColor,
222
+ pointHoverBorderStrokeWidth: props.pointHoverBorderStrokeWidth,
223
+ hoverColor: props.hoverColor,
224
+ hoverBorderColor: props.hoverBorderColor,
225
+ xAxisId: props.xAxisId,
226
+ yAxisId: props.yAxisId,
227
+ order: props.order,
228
+ sizeField: (ctx) => ctx.datum.size,
229
+ connectNulls: props.connectNulls,
230
+ renderMarker: props.renderMarker
231
+ };
232
+ };
233
+ const methods = useChartMethods();
234
+ const { getItems } = useItemCollector();
235
+ let isRegistered = false;
236
+ onMounted(() => {
237
+ methods.registerDataset(autoId, "scatter", buildSynthesizedProps2());
238
+ isRegistered = true;
239
+ });
240
+ watch([
241
+ () => props.name,
242
+ () => props.color,
243
+ () => props.markerSize,
244
+ () => props.markerShape,
245
+ () => props.order,
246
+ () => props.pointBorderColor,
247
+ () => props.pointBorderStrokeWidth,
248
+ () => props.pointBorderDash,
249
+ () => props.pointBorderDashOffset,
250
+ () => props.pointBorderJoinStyle,
251
+ () => props.pointBorderRadius,
252
+ () => props.pointRotation,
253
+ () => props.pointHitRadius,
254
+ () => props.hoverPointRadius,
255
+ () => props.pointHoverBackgroundColor,
256
+ () => props.pointHoverBorderColor,
257
+ () => props.pointHoverBorderStrokeWidth,
258
+ () => props.connectNulls,
259
+ () => props.renderMarker
260
+ ], () => {
261
+ if (!isRegistered) return;
262
+ methods.updateDataset(autoId, buildSynthesizedProps2());
263
+ }, { flush: "post" });
264
+ onUnmounted(() => {
265
+ methods.unregisterDataset(autoId);
266
+ isRegistered = false;
267
+ });
268
+ }
269
+ return (_ctx, _cache) => {
270
+ return hasChildren.value ? renderSlot(_ctx.$slots, "default", { key: 0 }) : createCommentVNode("", true);
271
+ };
272
+ }
273
+ });
274
+ var ChartScatter_default = _sfc_main;
275
+
276
+ export { ChartScatter_default };
@@ -0,0 +1,167 @@
1
+ import { LEGEND_ITEM_BASE_STYLE, LEGEND_SWATCH_STYLE } from './chunk-J43KLCZF.mjs';
2
+ import { defineComponent, ref, computed, openBlock, createElementBlock, normalizeStyle, Fragment, renderList, createBlock, resolveDynamicComponent, createCommentVNode, createElementVNode, toDisplayString, nextTick } from 'vue';
3
+ import { computeLegendStyle, gradientToCssBackground } from '@primeui/chart-core';
4
+
5
+ var _hoisted_1 = ["dir"];
6
+ var _hoisted_2 = {
7
+ key: 0,
8
+ style: { "display": "contents" }
9
+ };
10
+ var _hoisted_3 = [
11
+ "role",
12
+ "aria-checked",
13
+ "aria-label",
14
+ "onClick",
15
+ "onMouseenter"
16
+ ];
17
+ var _hoisted_4 = ["data-chart-gradient"];
18
+ var _sfc_main = /* @__PURE__ */ defineComponent({
19
+ __name: "LegendRenderer",
20
+ props: {
21
+ legendConfig: {},
22
+ legendArea: {},
23
+ legendItems: {},
24
+ onLegendClick: { type: Function },
25
+ onLegendHover: { type: Function },
26
+ adaptiveFontSize: {},
27
+ effectivePosition: {},
28
+ globalFontFamily: {},
29
+ dir: {}
30
+ },
31
+ setup(__props) {
32
+ const props = __props;
33
+ const hoveredItem = ref(null);
34
+ const UNITLESS = /* @__PURE__ */ new Set([
35
+ "opacity",
36
+ "zIndex",
37
+ "fontWeight",
38
+ "lineHeight",
39
+ "order",
40
+ "flex",
41
+ "flexGrow",
42
+ "flexShrink",
43
+ "transform"
44
+ ]);
45
+ function toCssStyle(raw) {
46
+ const out = {};
47
+ for (const [k, v] of Object.entries(raw)) {
48
+ out[k] = typeof v === "number" && !UNITLESS.has(k) ? `${v}px` : String(v);
49
+ }
50
+ return out;
51
+ }
52
+ const legendStyle = computed(() => {
53
+ if (!props.legendConfig || !props.legendArea) return {};
54
+ const lc = props.legendConfig;
55
+ const result = computeLegendStyle({
56
+ position: props.effectivePosition ?? lc.position,
57
+ layout: lc.layout,
58
+ align: lc.align,
59
+ verticalAlign: lc.verticalAlign,
60
+ width: lc.width,
61
+ height: lc.height,
62
+ maxWidth: lc.maxWidth,
63
+ maxHeight: lc.maxHeight,
64
+ itemGap: lc.itemGap
65
+ }, props.legendArea);
66
+ return toCssStyle(result);
67
+ });
68
+ function handleHover(item) {
69
+ hoveredItem.value = item;
70
+ props.onLegendHover(item);
71
+ }
72
+ function handleClick(item) {
73
+ if (!props.legendConfig.interactive) return;
74
+ props.onLegendClick(item);
75
+ nextTick(() => {
76
+ if (hoveredItem.value === null) return;
77
+ const fresh = props.legendItems.find((i) => i.datasetId === hoveredItem.value?.datasetId && i.index === hoveredItem.value?.index);
78
+ handleHover(fresh?.visible ? fresh : null);
79
+ });
80
+ }
81
+ function itemKey(item, idx) {
82
+ return `${item.datasetId}-${item.index ?? "header"}-${idx}`;
83
+ }
84
+ function getItemStyle(item) {
85
+ const isHovered = hoveredItem.value === item;
86
+ const lc = props.legendConfig;
87
+ const baseFontSize = item.type === "dataset" ? (props.adaptiveFontSize ?? 12) + 1 : props.adaptiveFontSize ?? 12;
88
+ return {
89
+ ...LEGEND_ITEM_BASE_STYLE,
90
+ background: "none",
91
+ border: "none",
92
+ font: "inherit",
93
+ padding: "0",
94
+ cursor: lc.interactive ? "pointer" : "default",
95
+ opacity: item.visible ? "1" : "0.4",
96
+ fontWeight: lc.fontWeight !== void 0 ? String(lc.fontWeight) : item.type === "dataset" ? "600" : "400",
97
+ fontSize: `${lc.fontSize ?? baseFontSize}px`,
98
+ fontFamily: lc.fontFamily ?? props.globalFontFamily ?? void 0,
99
+ ...lc.color ? { color: lc.color } : {},
100
+ backgroundColor: isHovered ? "var(--p-chart-legend-hover-background, rgba(0,0,0,0.05))" : "transparent"
101
+ };
102
+ }
103
+ function getSwatchStyle(item) {
104
+ const lc = props.legendConfig;
105
+ const iconSize = lc.iconSize ?? 12;
106
+ const iconShape = lc.iconShape;
107
+ const base = {
108
+ ...LEGEND_SWATCH_STYLE,
109
+ width: `${iconSize}px`,
110
+ height: iconShape === "line" ? "2px" : `${iconSize}px`,
111
+ borderRadius: iconShape === "circle" ? "50%" : iconShape === "line" ? "1px" : "2px",
112
+ backgroundColor: item.color,
113
+ ...item.colorGradient ? { backgroundImage: gradientToCssBackground(item.colorGradient) } : {}
114
+ };
115
+ if (item.hasBorder && item.borderColor) {
116
+ base.border = `2px solid ${item.borderColor}`;
117
+ base.boxSizing = "border-box";
118
+ }
119
+ if (item.borderRadius !== void 0) {
120
+ base.borderRadius = `${Math.min(item.borderRadius, 6)}px`;
121
+ }
122
+ return base;
123
+ }
124
+ return (_ctx, _cache) => {
125
+ return __props.legendConfig && __props.legendArea && __props.legendItems.length > 0 ? (openBlock(), createElementBlock("div", {
126
+ key: 0,
127
+ style: normalizeStyle(legendStyle.value),
128
+ class: "chart-legend",
129
+ dir: __props.dir ?? "ltr"
130
+ }, [(openBlock(true), createElementBlock(Fragment, null, renderList(__props.legendItems, (item, idx) => {
131
+ return openBlock(), createElementBlock(Fragment, { key: itemKey(item, idx) }, [__props.legendConfig.render ? (openBlock(), createElementBlock("div", _hoisted_2, [(openBlock(), createBlock(resolveDynamicComponent(() => __props.legendConfig.render({
132
+ type: item.type,
133
+ datasetId: item.datasetId,
134
+ index: item.index,
135
+ label: item.label,
136
+ color: item.color,
137
+ colorGradient: item.colorGradient,
138
+ visible: item.visible,
139
+ borderColor: item.borderColor,
140
+ hasBorder: item.hasBorder,
141
+ borderRadius: item.borderRadius,
142
+ isHovered: hoveredItem.value === item,
143
+ onClick: () => handleClick(item),
144
+ onMouseEnter: () => handleHover(item),
145
+ onMouseLeave: () => handleHover(null)
146
+ }))))])) : (openBlock(), createElementBlock("button", {
147
+ key: 1,
148
+ type: "button",
149
+ role: __props.legendConfig.interactive ? "switch" : void 0,
150
+ "aria-checked": __props.legendConfig.interactive ? item.visible : void 0,
151
+ "aria-label": `${item.label}. ${item.visible ? "Shown" : "Hidden"}.${__props.legendConfig.interactive ? " Click to toggle." : ""}`,
152
+ style: normalizeStyle(getItemStyle(item)),
153
+ onClick: () => handleClick(item),
154
+ onMouseenter: ($event) => handleHover(item),
155
+ onMouseleave: _cache[0] || (_cache[0] = ($event) => handleHover(null))
156
+ }, [item.color ? (openBlock(), createElementBlock("span", {
157
+ key: 0,
158
+ style: normalizeStyle(getSwatchStyle(item)),
159
+ "data-chart-gradient": item.colorGradient ? JSON.stringify(item.colorGradient) : void 0
160
+ }, null, 12, _hoisted_4)) : createCommentVNode("", true), createElementVNode("span", null, toDisplayString(item.label), 1)], 44, _hoisted_3))], 64);
161
+ }), 128))], 12, _hoisted_1)) : createCommentVNode("", true);
162
+ };
163
+ }
164
+ });
165
+ var LegendRenderer_default = _sfc_main;
166
+
167
+ export { LegendRenderer_default };
@@ -0,0 +1,6 @@
1
+ // src/components/customizations/axisGroupKeys.ts
2
+ var AXIS_GROUP_COLLECTOR_KEY = /* @__PURE__ */ Symbol.for("axis-category-collector");
3
+ var AXIS_GROUP_REGISTRY_KEY = /* @__PURE__ */ Symbol.for("axis-group-registry");
4
+ var AXIS_GROUP_DEPTH_KEY = /* @__PURE__ */ Symbol.for("axis-group-depth");
5
+
6
+ export { AXIS_GROUP_COLLECTOR_KEY, AXIS_GROUP_DEPTH_KEY, AXIS_GROUP_REGISTRY_KEY };
@@ -0,0 +1,28 @@
1
+ import { useCustomizationRegistration } from './chunk-PQV55JYI.mjs';
2
+ import { defineComponent, computed } from 'vue';
3
+
4
+ var _sfc_main = /* @__PURE__ */ defineComponent({
5
+ __name: "ChartBreadcrumb",
6
+ props: {
7
+ separator: {},
8
+ renderItem: { type: Function },
9
+ class: {},
10
+ style: {}
11
+ },
12
+ setup(__props) {
13
+ const props = __props;
14
+ const registrationProps = computed(() => ({
15
+ separator: props.separator,
16
+ renderItem: props.renderItem,
17
+ class: props.class,
18
+ style: props.style
19
+ }));
20
+ useCustomizationRegistration("breadcrumb", registrationProps);
21
+ return (_ctx, _cache) => {
22
+ return null;
23
+ };
24
+ }
25
+ });
26
+ var ChartBreadcrumb_default = _sfc_main;
27
+
28
+ export { ChartBreadcrumb_default };