apexcharts 6.9.0 → 6.10.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 (159) hide show
  1. package/README.md +19 -1
  2. package/dist/apexcharts.common.js +2 -2
  3. package/dist/apexcharts.css +14 -3
  4. package/dist/apexcharts.esm.js +358 -80
  5. package/dist/apexcharts.js +358 -80
  6. package/dist/apexcharts.min.js +2 -2
  7. package/dist/apexcharts.ssr.common.js +2 -2
  8. package/dist/apexcharts.ssr.esm.js +358 -80
  9. package/dist/area.common.js +1 -1
  10. package/dist/area.esm.js +1 -1
  11. package/dist/bar.common.js +1 -1
  12. package/dist/bar.esm.js +1 -1
  13. package/dist/boxPlot.common.js +1 -1
  14. package/dist/boxPlot.esm.js +1 -1
  15. package/dist/bubble.common.js +1 -1
  16. package/dist/bubble.esm.js +1 -1
  17. package/dist/candlestick.common.js +1 -1
  18. package/dist/candlestick.esm.js +1 -1
  19. package/dist/column.common.js +1 -1
  20. package/dist/column.esm.js +1 -1
  21. package/dist/core.common.js +2 -2
  22. package/dist/core.esm.js +66 -7
  23. package/dist/donut.common.js +2 -2
  24. package/dist/donut.esm.js +87 -72
  25. package/dist/features/all.common.js +1 -1
  26. package/dist/features/all.esm.js +1 -1
  27. package/dist/features/annotations.common.js +1 -1
  28. package/dist/features/annotations.esm.js +1 -1
  29. package/dist/features/context-menu.common.js +1 -1
  30. package/dist/features/context-menu.esm.js +1 -1
  31. package/dist/features/drilldown.common.js +1 -1
  32. package/dist/features/drilldown.esm.js +1 -1
  33. package/dist/features/exports.common.js +1 -1
  34. package/dist/features/exports.esm.js +1 -1
  35. package/dist/features/facet.common.js +1 -1
  36. package/dist/features/facet.esm.js +1 -1
  37. package/dist/features/history.common.js +1 -1
  38. package/dist/features/history.esm.js +1 -1
  39. package/dist/features/ink.common.js +1 -1
  40. package/dist/features/ink.esm.js +1 -1
  41. package/dist/features/keyboard.common.js +1 -1
  42. package/dist/features/keyboard.esm.js +1 -1
  43. package/dist/features/legend.common.js +1 -1
  44. package/dist/features/legend.esm.js +1 -1
  45. package/dist/features/link.common.js +1 -1
  46. package/dist/features/link.esm.js +1 -1
  47. package/dist/features/marks.common.js +1 -1
  48. package/dist/features/marks.esm.js +1 -1
  49. package/dist/features/measure.common.js +1 -1
  50. package/dist/features/measure.esm.js +1 -1
  51. package/dist/features/morph.common.js +1 -1
  52. package/dist/features/morph.esm.js +1 -1
  53. package/dist/features/perspectives.common.js +1 -1
  54. package/dist/features/perspectives.esm.js +1 -1
  55. package/dist/features/renderer-canvas.common.js +1 -1
  56. package/dist/features/renderer-canvas.esm.js +1 -1
  57. package/dist/features/stats.common.js +1 -1
  58. package/dist/features/stats.esm.js +1 -1
  59. package/dist/features/storyboard.common.js +1 -1
  60. package/dist/features/storyboard.esm.js +1 -1
  61. package/dist/features/toolbar.common.js +1 -1
  62. package/dist/features/toolbar.esm.js +1 -1
  63. package/dist/features/weave.common.js +1 -1
  64. package/dist/features/weave.esm.js +1 -1
  65. package/dist/heatmap.common.js +1 -1
  66. package/dist/heatmap.esm.js +1 -1
  67. package/dist/histogram.common.js +1 -1
  68. package/dist/histogram.esm.js +1 -1
  69. package/dist/line.common.js +1 -1
  70. package/dist/line.esm.js +1 -1
  71. package/dist/pie.common.js +2 -2
  72. package/dist/pie.esm.js +87 -72
  73. package/dist/polarArea.common.js +2 -2
  74. package/dist/polarArea.esm.js +87 -72
  75. package/dist/radar.common.js +2 -2
  76. package/dist/radar.esm.js +61 -53
  77. package/dist/radialBar.common.js +2 -2
  78. package/dist/radialBar.esm.js +87 -72
  79. package/dist/rangeArea.common.js +1 -1
  80. package/dist/rangeArea.esm.js +1 -1
  81. package/dist/rangeBar.common.js +1 -1
  82. package/dist/rangeBar.esm.js +1 -1
  83. package/dist/scatter.common.js +1 -1
  84. package/dist/scatter.esm.js +1 -1
  85. package/dist/sunburst.common.js +1 -1
  86. package/dist/sunburst.esm.js +1 -1
  87. package/dist/treemap.common.js +1 -1
  88. package/dist/treemap.esm.js +1 -1
  89. package/dist/unit-shapes.common.js +5 -0
  90. package/dist/unit-shapes.esm.js +1544 -0
  91. package/dist/unit-shapes.js +5 -0
  92. package/dist/unit.common.js +5 -0
  93. package/dist/unit.esm.js +2566 -0
  94. package/dist/violin.common.js +1 -1
  95. package/dist/violin.esm.js +1 -1
  96. package/package.json +12 -1
  97. package/src/apexcharts.js +4 -3
  98. package/src/assets/apexcharts.css +14 -3
  99. package/src/charts/Pie.js +8 -29
  100. package/src/charts/Unit.js +258 -2
  101. package/src/charts/common/OuterLabels.js +182 -0
  102. package/src/charts/common/circle/Helpers.js +10 -61
  103. package/src/modules/Data.js +7 -2
  104. package/src/modules/settings/Options.js +28 -1
  105. package/src/unit-shapes/catalog.js +97 -0
  106. package/src/unit-shapes/cdn.js +25 -0
  107. package/src/unit-shapes/engine/digits.js +150 -0
  108. package/src/unit-shapes/engine/pack.js +234 -0
  109. package/src/unit-shapes/engine/path.js +413 -0
  110. package/src/unit-shapes/engine/preview.js +172 -0
  111. package/src/unit-shapes/engine/radial.js +369 -0
  112. package/src/unit-shapes/engine/region.js +313 -0
  113. package/src/unit-shapes/engine/shape.js +120 -0
  114. package/src/unit-shapes/engine/silhouette.js +111 -0
  115. package/src/unit-shapes/engine/stroke.js +167 -0
  116. package/src/unit-shapes/index.js +82 -0
  117. package/src/unit-shapes/registry.js +77 -0
  118. package/src/unit-shapes/shapes/arrow.js +17 -0
  119. package/src/unit-shapes/shapes/battery.js +18 -0
  120. package/src/unit-shapes/shapes/bolt.js +17 -0
  121. package/src/unit-shapes/shapes/bulb.js +20 -0
  122. package/src/unit-shapes/shapes/car.js +23 -0
  123. package/src/unit-shapes/shapes/check.js +18 -0
  124. package/src/unit-shapes/shapes/cross.js +19 -0
  125. package/src/unit-shapes/shapes/crown.js +18 -0
  126. package/src/unit-shapes/shapes/droplet.js +14 -0
  127. package/src/unit-shapes/shapes/fish.js +23 -0
  128. package/src/unit-shapes/shapes/flame.js +22 -0
  129. package/src/unit-shapes/shapes/flask.js +17 -0
  130. package/src/unit-shapes/shapes/funnel.js +19 -0
  131. package/src/unit-shapes/shapes/gear.js +34 -0
  132. package/src/unit-shapes/shapes/globe.js +19 -0
  133. package/src/unit-shapes/shapes/group.js +29 -0
  134. package/src/unit-shapes/shapes/heart.js +16 -0
  135. package/src/unit-shapes/shapes/house.js +20 -0
  136. package/src/unit-shapes/shapes/human.js +18 -0
  137. package/src/unit-shapes/shapes/leaf.js +24 -0
  138. package/src/unit-shapes/shapes/moneybag.js +22 -0
  139. package/src/unit-shapes/shapes/mountain.js +17 -0
  140. package/src/unit-shapes/shapes/percent.js +21 -0
  141. package/src/unit-shapes/shapes/pin.js +24 -0
  142. package/src/unit-shapes/shapes/plane.js +21 -0
  143. package/src/unit-shapes/shapes/pulse.js +19 -0
  144. package/src/unit-shapes/shapes/pyramid.js +17 -0
  145. package/src/unit-shapes/shapes/question.js +18 -0
  146. package/src/unit-shapes/shapes/robot.js +24 -0
  147. package/src/unit-shapes/shapes/rocket.js +20 -0
  148. package/src/unit-shapes/shapes/shield.js +16 -0
  149. package/src/unit-shapes/shapes/spiral.js +32 -0
  150. package/src/unit-shapes/shapes/star.js +19 -0
  151. package/src/unit-shapes/shapes/sun.js +24 -0
  152. package/src/unit-shapes/shapes/target.js +18 -0
  153. package/src/unit-shapes/shapes/tree.js +20 -0
  154. package/src/unit-shapes/shapes/trophy.js +20 -0
  155. package/src/unit-shapes/shapes/wifi.js +26 -0
  156. package/src/unit-shapes/shapes/xmark.js +19 -0
  157. package/src/utils/Utils.js +37 -0
  158. package/types/apexcharts.d.ts +32 -1
  159. package/types/unit-shapes.d.ts +224 -0
package/README.md CHANGED
@@ -89,7 +89,7 @@ Browse [100+ ready-to-use samples](https://apexcharts.com/javascript-chart-demos
89
89
  - [Pie](https://apexcharts.com/javascript-chart-demos/pie-charts/) · [Donut](https://apexcharts.com/javascript-chart-demos/pie-charts/) · [Polar Area](https://apexcharts.com/javascript-chart-demos/polar-area-charts/) · [Radial Bar / Gauge](https://apexcharts.com/javascript-chart-demos/radialbar-charts/)
90
90
  - [Radar](https://apexcharts.com/javascript-chart-demos/radar-charts/) · [Heatmap](https://apexcharts.com/javascript-chart-demos/heatmap-charts/) · [Treemap](https://apexcharts.com/javascript-chart-demos/treemap-charts/)
91
91
  - [Funnel](https://apexcharts.com/javascript-chart-demos/funnel-charts/)
92
- - [Unit / Pictogram / Beeswarm](samples/vanilla-js/unit/) · [Waffle](samples/vanilla-js/waffle/) (premium)
92
+ - [Unit / Pictogram / Beeswarm](samples/vanilla-js/unit/) · [Waffle](samples/vanilla-js/waffle/) (premium) · [shape kit](#shapes-for-the-unit-chart)
93
93
 
94
94
  Combine any of the above as [mixed/combo charts](https://apexcharts.com/javascript-chart-demos/mixed-charts/), [stacked variants](https://apexcharts.com/javascript-chart-demos/column-charts/stacked/), [sparklines](https://apexcharts.com/javascript-chart-demos/sparklines/), or [synchronized multi-chart layouts](https://apexcharts.com/javascript-chart-demos/line-charts/syncing-charts/).
95
95
 
@@ -175,6 +175,24 @@ import 'apexcharts/features/toolbar' // zoom/pan toolbar
175
175
 
176
176
  See the [tree-shaking guide](https://apexcharts.com/docs/tree-shaking/) for the complete list of entry points.
177
177
 
178
+ ### Shapes for the unit chart
179
+
180
+ `apexcharts/unit-shapes` is a companion kit: 39 shapes a unit chart can pack its dots into, as silhouettes (heart, house, globe, tree), stroked glyphs (checkmark, arrow, heartbeat trace) and a composer that draws a number in its own dots. Every shape is a plain function of the marks and the plot rectangle, so it repacks at any dot count and any size, and importing one costs about 4 KB gzipped with the rest shaken out.
181
+
182
+ ```js
183
+ import ApexCharts from 'apexcharts'
184
+ import { heart } from 'apexcharts/unit-shapes'
185
+
186
+ new ApexCharts(el, {
187
+ chart: { type: 'unit' },
188
+ series: [576, 168, 42, 34],
189
+ labels: ['Owned', 'Mortgaged', 'Renting', 'Other'],
190
+ plotOptions: { unit: { layout: 'custom', positions: heart } },
191
+ }).render()
192
+ ```
193
+
194
+ Shapes are composable (`outlined(heart)` traces it instead of filling it, `heart.with({ order: 'cols' })` changes where each series band lands), and `preview(heart, { series })` renders one to an SVG string with no chart and no DOM, for docs and build-time images. From a script tag, `dist/unit-shapes.js` exposes the same kit as `ApexUnitShapes` and registers every shape by name.
195
+
178
196
  ## Premium features & licensing
179
197
 
180
198
  Most of ApexCharts is free and open source. A small set of advanced features are **premium** and require a license key: