vue-data-ui 2.4.1 → 2.4.2

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 (201) hide show
  1. package/README.md +44 -44
  2. package/dist/{Arrow-DpMf3yPs.cjs → Arrow-DLTRnzcG.cjs} +1 -1
  3. package/dist/{Arrow-BIs_9yK8.js → Arrow-JuK2z9IB.js} +1 -1
  4. package/dist/BaseIcon-BGExhz6v.cjs +1 -0
  5. package/dist/{BaseIcon-CXDdkPfN.js → BaseIcon-rRli6Sfv.js} +7 -4
  6. package/dist/{DataTable-BTgMVOwp.cjs → DataTable-DJzhv96s.cjs} +1 -1
  7. package/dist/{DataTable-DL2agEJ3.js → DataTable-DTk7C4Pr.js} +2 -2
  8. package/dist/{Legend-DXLiSLHd.js → Legend-CYF2gpXG.js} +1 -1
  9. package/dist/{Legend-Dj9KiaLv.cjs → Legend-YZ7Hz3o1.cjs} +1 -1
  10. package/dist/{PackageVersion-DtnhR89q.js → PackageVersion-CvCRsT5_.js} +1 -1
  11. package/dist/{PackageVersion-D4D0WicU.cjs → PackageVersion-DVZtsuy4.cjs} +1 -1
  12. package/dist/PenAndPaper-CyXm-yVL.cjs +1 -0
  13. package/dist/PenAndPaper-Jb0pLt3G.js +269 -0
  14. package/dist/{Shape-CO_Ak9Zm.js → Shape-BpPn4eWR.js} +1 -1
  15. package/dist/{Shape-7EC2UKDK.cjs → Shape-X2F-QV_B.cjs} +1 -1
  16. package/dist/{Slicer-CLAVjSQP.cjs → Slicer-CL0tP5a5.cjs} +1 -1
  17. package/dist/{Slicer-BZfUZr1J.js → Slicer-CU7dRZR0.js} +2 -2
  18. package/dist/{Title-DYNLqCCT.js → Title-5VmBwT4i.js} +1 -1
  19. package/dist/{Title-C-lm3Mkl.cjs → Title-Co5jI5ed.cjs} +1 -1
  20. package/dist/{Tooltip-t-3mVhcz.cjs → Tooltip-Bl6W8Zn7.cjs} +1 -1
  21. package/dist/{Tooltip-CICAYyQj.js → Tooltip-Cj4EF7v1.js} +1 -1
  22. package/dist/{index-DDXisDKy.js → index-DnVHQ2xI.js} +880 -842
  23. package/dist/index-FfZRtJ6A.cjs +9 -0
  24. package/dist/style.css +1 -1
  25. package/dist/types/vue-data-ui.d.cts +18 -16
  26. package/dist/types/vue-data-ui.d.ts +18 -16
  27. package/dist/{useNestedProp-S1UXxUgm.js → useNestedProp-Cox0K0Y5.js} +1 -1
  28. package/dist/{useNestedProp-CC9zGr7C.cjs → useNestedProp-q7byAAIJ.cjs} +1 -1
  29. package/dist/usePrinter-BCAFeO_J.cjs +1 -0
  30. package/dist/{usePrinter-8ofTb2MJ.js → usePrinter-BEeNAqS5.js} +230 -185
  31. package/dist/vue-data-ui-CRLLZpt0.cjs +9 -0
  32. package/dist/vue-data-ui-W7nnqn0v.js +261 -0
  33. package/dist/vue-data-ui.cjs +1 -1
  34. package/dist/vue-data-ui.js +1 -1
  35. package/dist/{vue-ui-3d-bar-DcF1nyGW.js → vue-ui-3d-bar-BwBrUabe.js} +414 -390
  36. package/dist/vue-ui-3d-bar-bD_n6qL_.cjs +19 -0
  37. package/dist/{vue-ui-accordion-D_1fE5EF.js → vue-ui-accordion-DspS4q3f.js} +3 -3
  38. package/dist/{vue-ui-accordion-Cc9958th.cjs → vue-ui-accordion-xXgqfR2l.cjs} +1 -1
  39. package/dist/vue-ui-age-pyramid-BZcAwcVQ.cjs +1 -0
  40. package/dist/{vue-ui-age-pyramid-Oe_yHDL0.js → vue-ui-age-pyramid-CxBvm3uM.js} +218 -194
  41. package/dist/{vue-ui-annotator-Dix6_Gm6.js → vue-ui-annotator-BOofWpzv.js} +1 -1
  42. package/dist/{vue-ui-annotator-Dbp6cWMr.cjs → vue-ui-annotator-C6T5_7ZV.cjs} +1 -1
  43. package/dist/vue-ui-bullet-ChaEgXvR.cjs +23 -0
  44. package/dist/vue-ui-bullet-DraC-oFu.js +433 -0
  45. package/dist/vue-ui-candlestick--hPCfMFH.cjs +2 -0
  46. package/dist/{vue-ui-candlestick-CRwzWF6j.js → vue-ui-candlestick-DQZ5eT1f.js} +267 -243
  47. package/dist/{vue-ui-carousel-table-C0GDDSW9.cjs → vue-ui-carousel-table-DpRQklDZ.cjs} +1 -1
  48. package/dist/{vue-ui-carousel-table-BHeEbRKY.js → vue-ui-carousel-table-PdLjpH1p.js} +4 -4
  49. package/dist/{vue-ui-chestnut-CRk0RCB9.js → vue-ui-chestnut-ByI_O5hB.js} +293 -269
  50. package/dist/vue-ui-chestnut-ae6x87wl.cjs +6 -0
  51. package/dist/{vue-ui-cursor-y0kdr0uA.js → vue-ui-cursor-BM74l93B.js} +2 -2
  52. package/dist/{vue-ui-cursor-lU1rts1B.cjs → vue-ui-cursor-BvadpA2m.cjs} +1 -1
  53. package/dist/{vue-ui-dashboard-OyihaKdu.js → vue-ui-dashboard-CoANBhAM.js} +2 -2
  54. package/dist/{vue-ui-dashboard-BfC0jS-X.cjs → vue-ui-dashboard-OP51Gs8I.cjs} +1 -1
  55. package/dist/{vue-ui-digits-BJfcAiq_.cjs → vue-ui-digits-C7jJJg9k.cjs} +1 -1
  56. package/dist/{vue-ui-digits-IKt4qT2-.js → vue-ui-digits-DioaBnkB.js} +2 -2
  57. package/dist/vue-ui-donut-CplNylps.cjs +1 -0
  58. package/dist/vue-ui-donut-evolution-CQpr-6IS.cjs +1 -0
  59. package/dist/{vue-ui-donut-evolution-Dd4o37RP.js → vue-ui-donut-evolution-DAb1xzNd.js} +330 -306
  60. package/dist/{vue-ui-donut-DFaGk4fI.js → vue-ui-donut-ldqSm_JV.js} +345 -321
  61. package/dist/{vue-ui-dumbbell-B7j1_JoQ.js → vue-ui-dumbbell-Dg7PkiKJ.js} +265 -241
  62. package/dist/vue-ui-dumbbell-_ijaYr8W.cjs +9 -0
  63. package/dist/vue-ui-flow-BPt35d5K.cjs +1 -0
  64. package/dist/vue-ui-flow-DKT7ZEnr.js +508 -0
  65. package/dist/vue-ui-galaxy-e06PkTmp.cjs +1 -0
  66. package/dist/{vue-ui-galaxy-CH1BDtWl.js → vue-ui-galaxy-qAA9be3S.js} +193 -169
  67. package/dist/vue-ui-gauge-D8yVTIgP.js +518 -0
  68. package/dist/vue-ui-gauge-DiZVIU0D.cjs +1 -0
  69. package/dist/{vue-ui-gizmo-CKQcbe_7.js → vue-ui-gizmo-DC0uUwI3.js} +3 -3
  70. package/dist/{vue-ui-gizmo-DVwQaEH1.cjs → vue-ui-gizmo-W6bTkg59.cjs} +1 -1
  71. package/dist/vue-ui-heatmap-CbZcv_2I.cjs +1 -0
  72. package/dist/{vue-ui-heatmap-B-zWMk0Y.js → vue-ui-heatmap-u1raIzBQ.js} +252 -228
  73. package/dist/{vue-ui-kpi-CghbfSdM.js → vue-ui-kpi-C-iTxMD2.js} +3 -3
  74. package/dist/{vue-ui-kpi-CuY3xlVq.cjs → vue-ui-kpi-DY_2WF7U.cjs} +1 -1
  75. package/dist/{vue-ui-mini-loader-CH_PfeDc.cjs → vue-ui-mini-loader-Bfq2MNWu.cjs} +1 -1
  76. package/dist/{vue-ui-mini-loader-C7roqZ4p.js → vue-ui-mini-loader-C7x7S0hi.js} +2 -2
  77. package/dist/vue-ui-molecule-BFnOIxxs.js +798 -0
  78. package/dist/vue-ui-molecule-CbKMLrDT.cjs +1 -0
  79. package/dist/vue-ui-mood-radar-6LmFXuiw.cjs +1 -0
  80. package/dist/{vue-ui-mood-radar-DSznHxLS.js → vue-ui-mood-radar-CR1v5v2x.js} +263 -239
  81. package/dist/{vue-ui-nested-donuts-CiE4DdEQ.js → vue-ui-nested-donuts-DEiloQzq.js} +342 -318
  82. package/dist/vue-ui-nested-donuts-DS0fjiLi.cjs +17 -0
  83. package/dist/vue-ui-onion-CLvvu4Ku.cjs +5 -0
  84. package/dist/{vue-ui-onion-D9o6Rcgu.js → vue-ui-onion-LsEhBe4x.js} +226 -202
  85. package/dist/vue-ui-parallel-coordinate-plot-BWg8OFqH.cjs +8 -0
  86. package/dist/{vue-ui-parallel-coordinate-plot-BcYrYXhG.js → vue-ui-parallel-coordinate-plot-CTlIjJqG.js} +243 -219
  87. package/dist/{vue-ui-quadrant-Cs3A77us.js → vue-ui-quadrant-DKVVFufb.js} +350 -326
  88. package/dist/vue-ui-quadrant-OM5J1mG3.cjs +1 -0
  89. package/dist/{vue-ui-quick-chart-CiiSUexi.js → vue-ui-quick-chart-8vJikiGH.js} +505 -481
  90. package/dist/vue-ui-quick-chart-gG5Ar8-i.cjs +15 -0
  91. package/dist/{vue-ui-radar-CNSpiNrM.js → vue-ui-radar-20QhOUer.js} +255 -231
  92. package/dist/vue-ui-radar-CAaHjDO7.cjs +1 -0
  93. package/dist/{vue-ui-rating-GoUNDOdZ.cjs → vue-ui-rating-Bbzm5nUK.cjs} +1 -1
  94. package/dist/{vue-ui-rating-b_iYZWF8.js → vue-ui-rating-DRWJsve1.js} +2 -2
  95. package/dist/vue-ui-relation-circle-BoGAFXuS.cjs +1 -0
  96. package/dist/vue-ui-relation-circle-I45_Sk5l.js +349 -0
  97. package/dist/vue-ui-rings-B9WQ7S5m.cjs +2 -0
  98. package/dist/vue-ui-rings-DG8GCi3y.js +593 -0
  99. package/dist/vue-ui-scatter-BZfg1YIN.cjs +1 -0
  100. package/dist/{vue-ui-scatter-CVuoW-cD.js → vue-ui-scatter-Hqu5-F2H.js} +369 -345
  101. package/dist/{vue-ui-screenshot-Co2o48d6.cjs → vue-ui-screenshot-D8nxd5RV.cjs} +1 -1
  102. package/dist/{vue-ui-screenshot-Csc0dQL9.js → vue-ui-screenshot-cjiqbtLK.js} +1 -1
  103. package/dist/{vue-ui-skeleton-CGV1dEUD.cjs → vue-ui-skeleton-Djv08J67.cjs} +1 -1
  104. package/dist/{vue-ui-skeleton-B2sRnIXX.js → vue-ui-skeleton-aZmkNzAe.js} +3 -3
  105. package/dist/{vue-ui-smiley-Ci3uMgVh.cjs → vue-ui-smiley-B1TA19Hv.cjs} +1 -1
  106. package/dist/{vue-ui-smiley-D4s-AdIE.js → vue-ui-smiley-ChNvxygm.js} +2 -2
  107. package/dist/{vue-ui-spark-trend-BfoEoJEy.cjs → vue-ui-spark-trend-BqrPr63O.cjs} +1 -1
  108. package/dist/{vue-ui-spark-trend-CHKQGMLs.js → vue-ui-spark-trend-CQxELQcf.js} +5 -5
  109. package/dist/{vue-ui-sparkbar-Bb1fq2GR.js → vue-ui-sparkbar-0ixbKZzf.js} +4 -4
  110. package/dist/{vue-ui-sparkbar-DB2DeXti.cjs → vue-ui-sparkbar-CrTEPTU5.cjs} +1 -1
  111. package/dist/{vue-ui-sparkgauge-CJepIY2u.cjs → vue-ui-sparkgauge-BYxpe_WV.cjs} +1 -1
  112. package/dist/{vue-ui-sparkgauge-DWuaAQbo.js → vue-ui-sparkgauge-pdYb7OwH.js} +4 -4
  113. package/dist/{vue-ui-sparkhistogram-B7B36LLT.cjs → vue-ui-sparkhistogram-D21XDUH2.cjs} +1 -1
  114. package/dist/{vue-ui-sparkhistogram-CjeJ3ch1.js → vue-ui-sparkhistogram-N69h2q0U.js} +5 -5
  115. package/dist/{vue-ui-sparkline-DGJDBArr.js → vue-ui-sparkline-2BKYZMOb.js} +4 -4
  116. package/dist/{vue-ui-sparkline-BcqmwDAb.cjs → vue-ui-sparkline-Cf4m-Fxo.cjs} +1 -1
  117. package/dist/{vue-ui-sparkstackbar-DT3aKNeV.cjs → vue-ui-sparkstackbar-dAS8XoJs.cjs} +1 -1
  118. package/dist/{vue-ui-sparkstackbar-B3ul3qUZ.js → vue-ui-sparkstackbar-sh03cuOU.js} +4 -4
  119. package/dist/vue-ui-stackbar-B1si-1RM.js +938 -0
  120. package/dist/vue-ui-stackbar-Dy_saeSe.cjs +6 -0
  121. package/dist/{vue-ui-strip-plot-CIb2LSV8.js → vue-ui-strip-plot-BYn-QrTQ.js} +274 -250
  122. package/dist/vue-ui-strip-plot-D53LABpZ.cjs +1 -0
  123. package/dist/{vue-ui-table-B_sFrAO9.cjs → vue-ui-table-Ce4waJaj.cjs} +1 -1
  124. package/dist/{vue-ui-table-CmVi0nv2.js → vue-ui-table-DQORPCDJ.js} +1 -1
  125. package/dist/{vue-ui-table-heatmap-CgFr38QT.js → vue-ui-table-heatmap-Csp7Tx8N.js} +4 -4
  126. package/dist/{vue-ui-table-heatmap-Chvdf2Gi.cjs → vue-ui-table-heatmap-EqHt-O7Y.cjs} +1 -1
  127. package/dist/{vue-ui-table-sparkline-DUUYQ5dH.cjs → vue-ui-table-sparkline-DONmVOMh.cjs} +1 -1
  128. package/dist/{vue-ui-table-sparkline-eg2Qd8ws.js → vue-ui-table-sparkline-DdwVrfUj.js} +5 -5
  129. package/dist/vue-ui-thermometer-I6ZnlfAv.js +440 -0
  130. package/dist/vue-ui-thermometer-hQBkMa7u.cjs +1 -0
  131. package/dist/{vue-ui-timer-DM1IStj1.cjs → vue-ui-timer-COOXcn14.cjs} +1 -1
  132. package/dist/{vue-ui-timer-COSI3Q5T.js → vue-ui-timer-pi1SazTU.js} +5 -5
  133. package/dist/vue-ui-tiremarks-hdNqoGyd.cjs +1 -0
  134. package/dist/vue-ui-tiremarks-vdPQYiDp.js +303 -0
  135. package/dist/vue-ui-treemap-3FNUlKxL.js +816 -0
  136. package/dist/vue-ui-treemap-Cv0TSFQa.cjs +1 -0
  137. package/dist/vue-ui-vertical-bar-C--Ma0Dw.cjs +4 -0
  138. package/dist/{vue-ui-vertical-bar-CieqHVD5.js → vue-ui-vertical-bar-DwxpB46q.js} +312 -288
  139. package/dist/vue-ui-waffle-CKM0QyJN.cjs +1 -0
  140. package/dist/vue-ui-waffle-XecHJIc-.js +782 -0
  141. package/dist/vue-ui-wheel-Bbih5sSL.js +282 -0
  142. package/dist/vue-ui-wheel-C0dJrzOJ.cjs +1 -0
  143. package/dist/vue-ui-word-cloud-Cfd2wxsT.cjs +1 -0
  144. package/dist/vue-ui-word-cloud-DnhXUn5x.js +598 -0
  145. package/dist/vue-ui-xy-BDpqVzAq.cjs +3 -0
  146. package/dist/{vue-ui-xy-x8KEsGV-.js → vue-ui-xy-CqlRuFMc.js} +775 -751
  147. package/dist/{vue-ui-xy-canvas-BYdTxzi6.js → vue-ui-xy-canvas-C8c2X5fk.js} +409 -385
  148. package/dist/vue-ui-xy-canvas-Cansjd3L.cjs +9 -0
  149. package/package.json +1 -1
  150. package/dist/BaseIcon-E7FmzMcY.cjs +0 -1
  151. package/dist/index-C7_6YjWN.cjs +0 -9
  152. package/dist/usePrinter-8EP4iaGm.cjs +0 -1
  153. package/dist/vue-data-ui-4Yd255Ia.cjs +0 -9
  154. package/dist/vue-data-ui-Cp7bO_tj.js +0 -258
  155. package/dist/vue-ui-3d-bar-BeR2aBgQ.cjs +0 -19
  156. package/dist/vue-ui-age-pyramid-R-C4P4mI.cjs +0 -1
  157. package/dist/vue-ui-bullet-CQKaC4wG.js +0 -409
  158. package/dist/vue-ui-bullet-DSZox236.cjs +0 -23
  159. package/dist/vue-ui-candlestick-Dilozp3V.cjs +0 -2
  160. package/dist/vue-ui-chestnut-DdEcEI04.cjs +0 -6
  161. package/dist/vue-ui-donut-DTSVlGMg.cjs +0 -1
  162. package/dist/vue-ui-donut-evolution-BuUafabD.cjs +0 -1
  163. package/dist/vue-ui-dumbbell-CVfgnyKi.cjs +0 -9
  164. package/dist/vue-ui-flow-C45dODaB.cjs +0 -1
  165. package/dist/vue-ui-flow-DkPTzNv9.js +0 -484
  166. package/dist/vue-ui-galaxy-DlPavMK0.cjs +0 -1
  167. package/dist/vue-ui-gauge-BXiy515T.js +0 -494
  168. package/dist/vue-ui-gauge-vMFUYHYH.cjs +0 -1
  169. package/dist/vue-ui-heatmap-CMQqQnxc.cjs +0 -1
  170. package/dist/vue-ui-molecule-BwmkMEVN.js +0 -774
  171. package/dist/vue-ui-molecule-nOuD0hR5.cjs +0 -1
  172. package/dist/vue-ui-mood-radar-Bof_C9Ae.cjs +0 -1
  173. package/dist/vue-ui-nested-donuts-DIb6YyWv.cjs +0 -17
  174. package/dist/vue-ui-onion-N3tRNc4u.cjs +0 -5
  175. package/dist/vue-ui-parallel-coordinate-plot-qKGk2bX6.cjs +0 -8
  176. package/dist/vue-ui-quadrant-Do48rGrX.cjs +0 -1
  177. package/dist/vue-ui-quick-chart-BxU4d-sJ.cjs +0 -15
  178. package/dist/vue-ui-radar-CooAvwPA.cjs +0 -1
  179. package/dist/vue-ui-relation-circle-nRf1pvD0.js +0 -325
  180. package/dist/vue-ui-relation-circle-uNgJni4x.cjs +0 -1
  181. package/dist/vue-ui-rings-BgRc1o4_.js +0 -569
  182. package/dist/vue-ui-rings-iIgQI9Ws.cjs +0 -2
  183. package/dist/vue-ui-scatter-CkrpmLxP.cjs +0 -1
  184. package/dist/vue-ui-stackbar-CRcUugkl.cjs +0 -6
  185. package/dist/vue-ui-stackbar-DNROvZII.js +0 -915
  186. package/dist/vue-ui-strip-plot-Ck9Fmt_b.cjs +0 -1
  187. package/dist/vue-ui-thermometer-BFfN4aat.cjs +0 -1
  188. package/dist/vue-ui-thermometer-BePmFiwy.js +0 -416
  189. package/dist/vue-ui-tiremarks-BkYXzU3R.cjs +0 -1
  190. package/dist/vue-ui-tiremarks-d6TmSHY7.js +0 -279
  191. package/dist/vue-ui-treemap-BgeZnbl3.cjs +0 -1
  192. package/dist/vue-ui-treemap-Qg0858o6.js +0 -792
  193. package/dist/vue-ui-vertical-bar-D3atbdvl.cjs +0 -4
  194. package/dist/vue-ui-waffle-CD7C9Lu4.cjs +0 -1
  195. package/dist/vue-ui-waffle-CjNhM-mV.js +0 -758
  196. package/dist/vue-ui-wheel-B8mbO6ht.js +0 -258
  197. package/dist/vue-ui-wheel-CYmM7J61.cjs +0 -1
  198. package/dist/vue-ui-word-cloud-DMXrUmX5.js +0 -574
  199. package/dist/vue-ui-word-cloud-Dm9yZ1zQ.cjs +0 -1
  200. package/dist/vue-ui-xy-DoWnidom.cjs +0 -3
  201. package/dist/vue-ui-xy-canvas-DHs5sb3t.cjs +0 -9
@@ -1,409 +0,0 @@
1
- import { ref as d, computed as g, onMounted as ue, watch as R, onBeforeUnmount as ne, openBlock as r, createElementBlock as u, normalizeClass as D, normalizeStyle as G, createBlock as F, createCommentVNode as c, unref as h, createSlots as ie, withCtx as w, renderSlot as m, normalizeProps as j, guardReactiveProps as V, createVNode as ce, Fragment as I, renderList as P, createElementVNode as b, toDisplayString as x } from "vue";
2
- import { u as he, o as ve, e as q, g as de, c as ge, l as fe, C as me, d as ye, i as _, f as L, X as pe, t as be } from "./index-DDXisDKy.js";
3
- import { u as X } from "./useNestedProp-S1UXxUgm.js";
4
- import { _ as ke } from "./Title-DYNLqCCT.js";
5
- import { L as we } from "./Legend-DXLiSLHd.js";
6
- import { u as xe, U as _e } from "./usePrinter-8ofTb2MJ.js";
7
- import { _ as Le } from "./PackageVersion-DtnhR89q.js";
8
- import { _ as Ce } from "./_plugin-vue_export-helper-CHgC5LLL.js";
9
- const $e = ["id"], Be = ["xmlns", "viewBox"], Fe = { key: 0 }, Ie = ["x", "y", "height", "width", "fill", "stroke"], Pe = ["x", "y", "height", "width", "rx", "fill", "stroke", "stroke-width"], Se = ["x", "y", "height", "width", "fill", "stroke", "stroke-width"], He = ["x", "y", "font-size", "font-weight", "fill"], ze = ["x", "y", "height", "width", "rx", "fill", "stroke", "stroke-width"], Me = { key: 3 }, Ne = ["x", "y", "fill", "font-size", "font-weight"], Oe = { key: 4 }, Ae = ["x1", "x2", "y1", "y2", "stroke"], Te = {
10
- key: 3,
11
- class: "vue-data-ui-watermark"
12
- }, Ue = {
13
- class: "vue-ui-bullet-legend-item",
14
- dir: "auto"
15
- }, We = { style: { "margin-right": "2px" } }, Ee = {
16
- __name: "vue-ui-bullet",
17
- props: {
18
- config: {
19
- type: Object,
20
- default() {
21
- return {};
22
- }
23
- },
24
- dataset: {
25
- type: Object,
26
- default() {
27
- return {};
28
- }
29
- }
30
- },
31
- setup(Y, { expose: J }) {
32
- const o = Y, { vue_ui_bullet: K } = he(), S = d(null), Q = d(null), H = d(0), Z = d(null), ee = d(0), C = g({
33
- get: () => !0,
34
- set: (t) => t
35
- }), y = g(() => o.dataset.segments ? Array.isArray(o.dataset.segments) ? o.dataset.segments.length ? !0 : (console.warn(`VueUiBullet: dataset segments is empty. Provide segments with this datastructure:
36
-
37
- segments: [
38
- {
39
- name: string;
40
- from: number;
41
- to: number;
42
- color?: string;
43
- },
44
- {...}
45
- ]
46
- `), !1) : (console.warn(`VueUiBullet: dataset segments must be an array of objects with this datastructure:
47
-
48
- segments: [
49
- {
50
- name: string;
51
- from: number;
52
- to: number;
53
- color?: string;
54
- },
55
- {...}
56
- ]
57
- `), !1) : !1);
58
- ue(z);
59
- function z() {
60
- ve(o.dataset) ? q({
61
- componentName: "VueUiBullet",
62
- type: "dataset"
63
- }) : y.value && o.dataset.segments.forEach((t, s) => {
64
- de({
65
- datasetObject: t,
66
- requiredAttributes: ["name", "from", "to"]
67
- }).forEach((l) => {
68
- C.value = !1, q({
69
- componentName: "VueUiBullet segment",
70
- type: "datasetSerieAttribute",
71
- property: l,
72
- index: s
73
- });
74
- });
75
- }), e.value.style.chart.animation.show && O(o.dataset.value || 0);
76
- }
77
- const $ = d(ge());
78
- function M() {
79
- const t = X({
80
- userConfig: o.config,
81
- defaultConfig: K
82
- });
83
- return t.theme ? {
84
- ...X({
85
- userConfig: be.vue_ui_bullet[t.theme] || o.config,
86
- defaultConfig: t
87
- })
88
- } : t;
89
- }
90
- const e = g({
91
- get: () => M(),
92
- set: (t) => t
93
- });
94
- R(() => o.config, (t) => {
95
- e.value = M(), z(), H.value += 1;
96
- }, { deep: !0 });
97
- const a = g(() => {
98
- const t = e.value.style.chart.height, s = e.value.style.chart.width, l = e.value.style.chart.padding.left, f = s - e.value.style.chart.padding.right, k = e.value.style.chart.padding.top, i = t - e.value.style.chart.padding.bottom;
99
- return {
100
- height: t,
101
- width: s,
102
- left: l,
103
- right: f,
104
- top: k,
105
- bottom: i,
106
- chartWidth: f - l,
107
- chartHeight: i - k
108
- };
109
- }), te = g(() => {
110
- if (!y.value) return [];
111
- const t = [];
112
- for (let s = 0; s < o.dataset.segments.length; s += 1)
113
- t.push(fe(e.value.style.chart.segments.baseColor, s / o.dataset.segments.length));
114
- return t;
115
- }), B = g(() => y.value ? {
116
- min: Math.min(...o.dataset.segments.map((t) => t.from)),
117
- max: Math.max(...o.dataset.segments.map((t) => t.to))
118
- } : { min: 0, max: 1 }), n = d(ae());
119
- R(() => o.dataset, (t) => {
120
- e.value.style.chart.animation.show ? O(t.value || 0) : n.value = t.value || 0;
121
- }, { deep: !0 });
122
- function ae() {
123
- return e.value.style.chart.animation.show ? B.value.min : o.dataset.value || 0;
124
- }
125
- const N = d(null);
126
- function O(t) {
127
- const s = Math.abs(t - n.value) / e.value.style.chart.animation.animationFrames;
128
- function l() {
129
- n.value < t ? n.value = Math.min(n.value + s, t) : n.value > t && (n.value = Math.max(n.value - s, t)), n.value !== t && (N.value = requestAnimationFrame(l));
130
- }
131
- l();
132
- }
133
- ne(() => {
134
- cancelAnimationFrame(N.value);
135
- });
136
- const v = g(() => {
137
- if (!y.value)
138
- return [];
139
- const t = me(B.value.min, B.value.max, e.value.style.chart.segments.ticks.divisions), s = t.min >= 0 ? 0 : Math.abs(t.min), l = {
140
- x: a.value.left + (o.dataset.target + s) / (t.max + s) * a.value.chartWidth - e.value.style.chart.target.width / 2
141
- }, f = {
142
- width: (n.value + s) / (t.max + s) * a.value.chartWidth
143
- }, k = t.ticks.map((i) => ({
144
- value: i,
145
- y: a.value.bottom + e.value.style.chart.segments.dataLabels.fontSize + 3 + e.value.style.chart.segments.dataLabels.offsetY,
146
- x: a.value.left + (i + s) / (t.max + s) * a.value.chartWidth
147
- }));
148
- return {
149
- scale: t,
150
- target: l,
151
- value: f,
152
- ticks: k,
153
- chunks: o.dataset.segments.map((i, oe) => ({
154
- ...i,
155
- color: i.color ? ye(i.color) : te.value[oe],
156
- x: a.value.left + a.value.chartWidth * ((i.from + s) / (t.max + s)),
157
- y: a.value.top,
158
- height: a.value.chartHeight,
159
- width: a.value.chartWidth * (Math.abs(i.to - i.from) / (t.max + s))
160
- }))
161
- };
162
- }), A = g(() => v.value.chunks.map((t) => {
163
- const s = _(
164
- e.value.style.chart.segments.dataLabels.formatter,
165
- t.from,
166
- L({
167
- p: e.value.style.chart.segments.dataLabels.prefix,
168
- v: t.from,
169
- s: e.value.style.chart.segments.dataLabels.suffix,
170
- r: e.value.style.chart.segments.dataLabels.rounding
171
- })
172
- ), l = _(
173
- e.value.style.chart.segments.dataLabels.formatter,
174
- t.to,
175
- L({
176
- p: e.value.style.chart.segments.dataLabels.prefix,
177
- v: t.to,
178
- s: e.value.style.chart.segments.dataLabels.suffix,
179
- r: e.value.style.chart.segments.dataLabels.rounding
180
- })
181
- );
182
- return {
183
- ...t,
184
- shape: "square",
185
- value: `${s} - ${l}`
186
- };
187
- })), le = g(() => ({
188
- cy: "bullet-div-legend",
189
- backgroundColor: "transparent",
190
- color: e.value.style.chart.legend.color,
191
- fontSize: e.value.style.chart.legend.fontSize,
192
- paddingBottom: 6,
193
- fontWeight: e.value.style.chart.legend.bold ? "bold" : ""
194
- })), { isPrinting: T, isImaging: U, generatePdf: W, generateImage: E } = xe({
195
- elementId: `bullet_${$.value}`,
196
- fileName: e.value.style.chart.title.text || "vue-ui-bullet"
197
- }), p = d(!1);
198
- function se(t) {
199
- p.value = t, ee.value += 1;
200
- }
201
- function re() {
202
- return v.value;
203
- }
204
- return J({
205
- generatePdf: W,
206
- generateImage: E,
207
- getData: re
208
- }), (t, s) => (r(), u("div", {
209
- ref_key: "bulletChart",
210
- ref: S,
211
- class: D(`vue-ui-bullet ${p.value ? "vue-data-ui-wrapper-fullscreen" : ""}`),
212
- style: G(`font-family:${e.value.style.fontFamily};width:100%;background:${e.value.style.chart.backgroundColor}`),
213
- id: `bullet_${$.value}`
214
- }, [
215
- e.value.style.chart.title.text ? (r(), u("div", {
216
- key: 0,
217
- ref_key: "chartTitle",
218
- ref: Q,
219
- style: "width:100%;background:transparent;"
220
- }, [
221
- (r(), F(ke, {
222
- lineHeight: "1.3rem",
223
- key: `title_${H.value}`,
224
- config: {
225
- title: {
226
- cy: "bullet-div-title",
227
- ...e.value.style.chart.title
228
- },
229
- subtitle: {
230
- cy: "bullet-div-subtitle",
231
- ...e.value.style.chart.title.subtitle
232
- }
233
- }
234
- }, null, 8, ["config"]))
235
- ], 512)) : c("", !0),
236
- e.value.userOptions.show && C.value ? (r(), F(_e, {
237
- key: 1,
238
- ref: "details",
239
- backgroundColor: e.value.style.chart.backgroundColor,
240
- color: e.value.style.chart.color,
241
- isPrinting: h(T),
242
- isImaging: h(U),
243
- uid: $.value,
244
- hasTooltip: !1,
245
- hasPdf: e.value.userOptions.buttons.pdf,
246
- hasImg: e.value.userOptions.buttons.img,
247
- hasXls: !1,
248
- hasTable: !1,
249
- hasLabel: !1,
250
- hasFullscreen: e.value.userOptions.buttons.fullscreen,
251
- isFullscreen: p.value,
252
- chartElement: S.value,
253
- position: e.value.userOptions.position,
254
- titles: { ...e.value.userOptions.buttonTitles },
255
- onToggleFullscreen: se,
256
- onGeneratePdf: h(W),
257
- onGenerateImage: h(E)
258
- }, ie({ _: 2 }, [
259
- t.$slots.optionPdf ? {
260
- name: "optionPdf",
261
- fn: w(() => [
262
- m(t.$slots, "optionPdf", {}, void 0, !0)
263
- ]),
264
- key: "0"
265
- } : void 0,
266
- t.$slots.optionImg ? {
267
- name: "optionImg",
268
- fn: w(() => [
269
- m(t.$slots, "optionImg", {}, void 0, !0)
270
- ]),
271
- key: "1"
272
- } : void 0,
273
- t.$slots.optionFullscreen ? {
274
- name: "optionFullscreen",
275
- fn: w(({ toggleFullscreen: l, isFullscreen: f }) => [
276
- m(t.$slots, "optionFullscreen", j(V({ toggleFullscreen: l, isFullscreen: f })), void 0, !0)
277
- ]),
278
- key: "2"
279
- } : void 0
280
- ]), 1032, ["backgroundColor", "color", "isPrinting", "isImaging", "uid", "hasPdf", "hasImg", "hasFullscreen", "isFullscreen", "chartElement", "position", "titles", "onGeneratePdf", "onGenerateImage"])) : c("", !0),
281
- C.value ? (r(), u("svg", {
282
- key: 2,
283
- xmlns: h(pe),
284
- class: D({ "vue-data-ui-fullscreen--on": p.value, "vue-data-ui-fulscreen--off": !p.value, "vue-ui-bullet-svg": !0 }),
285
- viewBox: `0 0 ${a.value.width} ${a.value.height}`,
286
- style: G(`width: 100%; overflow: visible; background:transparent;color:${e.value.style.chart.color}`)
287
- }, [
288
- ce(Le),
289
- y.value ? (r(), u("g", Fe, [
290
- (r(!0), u(I, null, P(v.value.chunks, (l) => (r(), u("rect", {
291
- x: l.x,
292
- y: l.y,
293
- height: l.height,
294
- width: l.width,
295
- fill: l.color,
296
- "stroke-width": 1,
297
- stroke: e.value.style.chart.backgroundColor
298
- }, null, 8, Ie))), 256)),
299
- e.value.style.chart.target.onTop ? c("", !0) : (r(), u("rect", {
300
- key: 0,
301
- x: v.value.target.x,
302
- y: a.value.top + (a.value.chartHeight - a.value.chartHeight * e.value.style.chart.target.heightRatio) / 2,
303
- height: a.value.chartHeight * e.value.style.chart.target.heightRatio,
304
- width: e.value.style.chart.target.width,
305
- rx: e.value.style.chart.target.rounded ? e.value.style.chart.target.width / 2 : 0,
306
- fill: e.value.style.chart.target.color,
307
- stroke: e.value.style.chart.target.stroke,
308
- "stroke-width": e.value.style.chart.target.strokeWidth
309
- }, null, 8, Pe)),
310
- b("rect", {
311
- x: a.value.left,
312
- y: a.value.top + (a.value.chartHeight - a.value.chartHeight * e.value.style.chart.valueBar.heightRatio) / 2,
313
- height: a.value.chartHeight * e.value.style.chart.valueBar.heightRatio,
314
- width: v.value.value.width,
315
- fill: e.value.style.chart.valueBar.color,
316
- stroke: e.value.style.chart.valueBar.stroke,
317
- "stroke-width": e.value.style.chart.valueBar.strokeWidth
318
- }, null, 8, Se),
319
- e.value.style.chart.valueBar.label.show ? (r(), u("text", {
320
- key: 1,
321
- x: a.value.left + v.value.value.width,
322
- y: a.value.top - 6 + e.value.style.chart.valueBar.label.offsetY,
323
- "font-size": e.value.style.chart.valueBar.label.fontSize,
324
- "font-weight": e.value.style.chart.valueBar.label.bold ? "bold" : "normal",
325
- fill: e.value.style.chart.valueBar.label.color,
326
- "text-anchor": "middle"
327
- }, x(h(_)(
328
- e.value.style.chart.segments.dataLabels.formatter,
329
- n.value,
330
- h(L)({
331
- p: e.value.style.chart.segments.dataLabels.prefix,
332
- v: n.value,
333
- s: e.value.style.chart.segments.dataLabels.suffix,
334
- r: e.value.style.chart.segments.dataLabels.rounding
335
- })
336
- )), 9, He)) : c("", !0),
337
- e.value.style.chart.target.onTop ? (r(), u("rect", {
338
- key: 2,
339
- x: v.value.target.x,
340
- y: a.value.top + (a.value.chartHeight - a.value.chartHeight * e.value.style.chart.target.heightRatio) / 2,
341
- height: a.value.chartHeight * e.value.style.chart.target.heightRatio,
342
- width: e.value.style.chart.target.width,
343
- rx: e.value.style.chart.target.rounded ? e.value.style.chart.target.width / 2 : 0,
344
- fill: e.value.style.chart.target.color,
345
- stroke: e.value.style.chart.target.stroke,
346
- "stroke-width": e.value.style.chart.target.strokeWidth
347
- }, null, 8, ze)) : c("", !0),
348
- e.value.style.chart.segments.dataLabels.show ? (r(), u("g", Me, [
349
- (r(!0), u(I, null, P(v.value.ticks, (l) => (r(), u("text", {
350
- x: l.x,
351
- y: l.y,
352
- "text-anchor": "middle",
353
- fill: e.value.style.chart.segments.dataLabels.color,
354
- "font-size": e.value.style.chart.segments.dataLabels.fontSize + "px",
355
- "font-weight": e.value.style.chart.segments.dataLabels.bold ? "bold" : "normal"
356
- }, x(h(_)(
357
- e.value.style.chart.segments.dataLabels.formatter,
358
- l.value,
359
- h(L)({
360
- p: e.value.style.chart.segments.dataLabels.prefix,
361
- v: l.value,
362
- s: e.value.style.chart.segments.dataLabels.suffix,
363
- r: e.value.style.chart.segments.dataLabels.rounding
364
- })
365
- )), 9, Ne))), 256))
366
- ])) : c("", !0),
367
- e.value.style.chart.segments.dataLabels.show && e.value.style.chart.segments.ticks.show ? (r(), u("g", Oe, [
368
- (r(!0), u(I, null, P(v.value.ticks, (l) => (r(), u("line", {
369
- x1: l.x,
370
- x2: l.x,
371
- y1: a.value.bottom,
372
- y2: a.value.bottom + 3,
373
- stroke: e.value.style.chart.segments.ticks.stroke,
374
- "stroke-width": 1,
375
- "stroke-linecap": "round"
376
- }, null, 8, Ae))), 256))
377
- ])) : c("", !0)
378
- ])) : c("", !0),
379
- m(t.$slots, "svg", { svg: a.value }, void 0, !0)
380
- ], 14, Be)) : c("", !0),
381
- t.$slots.watermark ? (r(), u("div", Te, [
382
- m(t.$slots, "watermark", j(V({ isPrinting: h(T) || h(U) })), void 0, !0)
383
- ])) : c("", !0),
384
- b("div", {
385
- ref_key: "chartLegend",
386
- ref: Z
387
- }, [
388
- e.value.style.chart.legend.show ? (r(), F(we, {
389
- key: 0,
390
- clickable: !1,
391
- legendSet: A.value,
392
- config: le.value
393
- }, {
394
- item: w(({ legend: l }) => [
395
- b("div", Ue, [
396
- b("span", We, x(l.name) + ":", 1),
397
- b("span", null, x(l.value), 1)
398
- ])
399
- ]),
400
- _: 1
401
- }, 8, ["legendSet", "config"])) : c("", !0),
402
- m(t.$slots, "legend", { legend: A.value }, void 0, !0)
403
- ], 512)
404
- ], 14, $e));
405
- }
406
- }, Je = /* @__PURE__ */ Ce(Ee, [["__scopeId", "data-v-8f9b47b1"]]);
407
- export {
408
- Je as default
409
- };
@@ -1,23 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-C7_6YjWN.cjs"),E=require("./useNestedProp-CC9zGr7C.cjs"),W=require("./Title-C-lm3Mkl.cjs"),U=require("./Legend-Dj9KiaLv.cjs"),P=require("./usePrinter-8EP4iaGm.cjs"),R=require("./PackageVersion-D4D0WicU.cjs"),j=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),G=["id"],X=["xmlns","viewBox"],Y={key:0},J=["x","y","height","width","fill","stroke"],K=["x","y","height","width","rx","fill","stroke","stroke-width"],Q=["x","y","height","width","fill","stroke","stroke-width"],Z=["x","y","font-size","font-weight","fill"],ee=["x","y","height","width","rx","fill","stroke","stroke-width"],te={key:3},ae=["x","y","fill","font-size","font-weight"],le={key:4},re=["x1","x2","y1","y2","stroke"],se={key:3,class:"vue-data-ui-watermark"},oe={class:"vue-ui-bullet-legend-item",dir:"auto"},ne={style:{"margin-right":"2px"}},ue={__name:"vue-ui-bullet",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(F,{expose:$}){const n=F,{vue_ui_bullet:V}=o.useConfig(),p=e.ref(null),I=e.ref(null),b=e.ref(0),z=e.ref(null),H=e.ref(0),g=e.computed({get:()=>!0,set:a=>a}),d=e.computed(()=>n.dataset.segments?Array.isArray(n.dataset.segments)?n.dataset.segments.length?!0:(console.warn(`VueUiBullet: dataset segments is empty. Provide segments with this datastructure:
2
-
3
- segments: [
4
- {
5
- name: string;
6
- from: number;
7
- to: number;
8
- color?: string;
9
- },
10
- {...}
11
- ]
12
- `),!1):(console.warn(`VueUiBullet: dataset segments must be an array of objects with this datastructure:
13
-
14
- segments: [
15
- {
16
- name: string;
17
- from: number;
18
- to: number;
19
- color?: string;
20
- },
21
- {...}
22
- ]
23
- `),!1):!1);e.onMounted(k);function k(){o.objectIsEmpty(n.dataset)?o.error({componentName:"VueUiBullet",type:"dataset"}):d.value&&n.dataset.segments.forEach((a,s)=>{o.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","from","to"]}).forEach(r=>{g.value=!1,o.error({componentName:"VueUiBullet segment",type:"datasetSerieAttribute",property:r,index:s})})}),t.value.style.chart.animation.show&&B(n.dataset.value||0)}const f=e.ref(o.createUid());function w(){const a=E.useNestedProp({userConfig:n.config,defaultConfig:V});return a.theme?{...E.useNestedProp({userConfig:o.themes.vue_ui_bullet[a.theme]||n.config,defaultConfig:a})}:a}const t=e.computed({get:()=>w(),set:a=>a});e.watch(()=>n.config,a=>{t.value=w(),k(),b.value+=1},{deep:!0});const l=e.computed(()=>{const a=t.value.style.chart.height,s=t.value.style.chart.width,r=t.value.style.chart.padding.left,h=s-t.value.style.chart.padding.right,m=t.value.style.chart.padding.top,i=a-t.value.style.chart.padding.bottom;return{height:a,width:s,left:r,right:h,top:m,bottom:i,chartWidth:h-r,chartHeight:i-m}}),M=e.computed(()=>{if(!d.value)return[];const a=[];for(let s=0;s<n.dataset.segments.length;s+=1)a.push(o.lightenHexColor(t.value.style.chart.segments.baseColor,s/n.dataset.segments.length));return a}),y=e.computed(()=>d.value?{min:Math.min(...n.dataset.segments.map(a=>a.from)),max:Math.max(...n.dataset.segments.map(a=>a.to))}:{min:0,max:1}),u=e.ref(O());e.watch(()=>n.dataset,a=>{t.value.style.chart.animation.show?B(a.value||0):u.value=a.value||0},{deep:!0});function O(){return t.value.style.chart.animation.show?y.value.min:n.dataset.value||0}const x=e.ref(null);function B(a){const s=Math.abs(a-u.value)/t.value.style.chart.animation.animationFrames;function r(){u.value<a?u.value=Math.min(u.value+s,a):u.value>a&&(u.value=Math.max(u.value-s,a)),u.value!==a&&(x.value=requestAnimationFrame(r))}r()}e.onBeforeUnmount(()=>{cancelAnimationFrame(x.value)});const c=e.computed(()=>{if(!d.value)return[];const a=o.calculateNiceScale(y.value.min,y.value.max,t.value.style.chart.segments.ticks.divisions),s=a.min>=0?0:Math.abs(a.min),r={x:l.value.left+(n.dataset.target+s)/(a.max+s)*l.value.chartWidth-t.value.style.chart.target.width/2},h={width:(u.value+s)/(a.max+s)*l.value.chartWidth},m=a.ticks.map(i=>({value:i,y:l.value.bottom+t.value.style.chart.segments.dataLabels.fontSize+3+t.value.style.chart.segments.dataLabels.offsetY,x:l.value.left+(i+s)/(a.max+s)*l.value.chartWidth}));return{scale:a,target:r,value:h,ticks:m,chunks:n.dataset.segments.map((i,A)=>({...i,color:i.color?o.convertColorToHex(i.color):M.value[A],x:l.value.left+l.value.chartWidth*((i.from+s)/(a.max+s)),y:l.value.top,height:l.value.chartHeight,width:l.value.chartWidth*(Math.abs(i.to-i.from)/(a.max+s))}))}}),_=e.computed(()=>c.value.chunks.map(a=>{const s=o.applyDataLabel(t.value.style.chart.segments.dataLabels.formatter,a.from,o.dataLabel({p:t.value.style.chart.segments.dataLabels.prefix,v:a.from,s:t.value.style.chart.segments.dataLabels.suffix,r:t.value.style.chart.segments.dataLabels.rounding})),r=o.applyDataLabel(t.value.style.chart.segments.dataLabels.formatter,a.to,o.dataLabel({p:t.value.style.chart.segments.dataLabels.prefix,v:a.to,s:t.value.style.chart.segments.dataLabels.suffix,r:t.value.style.chart.segments.dataLabels.rounding}));return{...a,shape:"square",value:`${s} - ${r}`}})),T=e.computed(()=>({cy:"bullet-div-legend",backgroundColor:"transparent",color:t.value.style.chart.legend.color,fontSize:t.value.style.chart.legend.fontSize,paddingBottom:6,fontWeight:t.value.style.chart.legend.bold?"bold":""})),{isPrinting:L,isImaging:C,generatePdf:N,generateImage:S}=P.usePrinter({elementId:`bullet_${f.value}`,fileName:t.value.style.chart.title.text||"vue-ui-bullet"}),v=e.ref(!1);function D(a){v.value=a,H.value+=1}function q(){return c.value}return $({generatePdf:N,generateImage:S,getData:q}),(a,s)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"bulletChart",ref:p,class:e.normalizeClass(`vue-ui-bullet ${v.value?"vue-data-ui-wrapper-fullscreen":""}`),style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%;background:${t.value.style.chart.backgroundColor}`),id:`bullet_${f.value}`},[t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:I,style:"width:100%;background:transparent;"},[(e.openBlock(),e.createBlock(W._sfc_main,{lineHeight:"1.3rem",key:`title_${b.value}`,config:{title:{cy:"bullet-div-title",...t.value.style.chart.title},subtitle:{cy:"bullet-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&g.value?(e.openBlock(),e.createBlock(P.UserOptions,{key:1,ref:"details",backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(L),isImaging:e.unref(C),uid:f.value,hasTooltip:!1,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:!1,hasTable:!1,hasLabel:!1,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:v.value,chartElement:p.value,position:t.value.userOptions.position,titles:{...t.value.userOptions.buttonTitles},onToggleFullscreen:D,onGeneratePdf:e.unref(N),onGenerateImage:e.unref(S)},e.createSlots({_:2},[a.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,a.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionImg",{},void 0,!0)]),key:"1"}:void 0,a.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:r,isFullscreen:h})=>[e.renderSlot(a.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:r,isFullscreen:h})),void 0,!0)]),key:"2"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasImg","hasFullscreen","isFullscreen","chartElement","position","titles","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(o.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":v.value,"vue-data-ui-fulscreen--off":!v.value,"vue-ui-bullet-svg":!0}),viewBox:`0 0 ${l.value.width} ${l.value.height}`,style:e.normalizeStyle(`width: 100%; overflow: visible; background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(R._sfc_main),d.value?(e.openBlock(),e.createElementBlock("g",Y,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value.chunks,r=>(e.openBlock(),e.createElementBlock("rect",{x:r.x,y:r.y,height:r.height,width:r.width,fill:r.color,"stroke-width":1,stroke:t.value.style.chart.backgroundColor},null,8,J))),256)),t.value.style.chart.target.onTop?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("rect",{key:0,x:c.value.target.x,y:l.value.top+(l.value.chartHeight-l.value.chartHeight*t.value.style.chart.target.heightRatio)/2,height:l.value.chartHeight*t.value.style.chart.target.heightRatio,width:t.value.style.chart.target.width,rx:t.value.style.chart.target.rounded?t.value.style.chart.target.width/2:0,fill:t.value.style.chart.target.color,stroke:t.value.style.chart.target.stroke,"stroke-width":t.value.style.chart.target.strokeWidth},null,8,K)),e.createElementVNode("rect",{x:l.value.left,y:l.value.top+(l.value.chartHeight-l.value.chartHeight*t.value.style.chart.valueBar.heightRatio)/2,height:l.value.chartHeight*t.value.style.chart.valueBar.heightRatio,width:c.value.value.width,fill:t.value.style.chart.valueBar.color,stroke:t.value.style.chart.valueBar.stroke,"stroke-width":t.value.style.chart.valueBar.strokeWidth},null,8,Q),t.value.style.chart.valueBar.label.show?(e.openBlock(),e.createElementBlock("text",{key:1,x:l.value.left+c.value.value.width,y:l.value.top-6+t.value.style.chart.valueBar.label.offsetY,"font-size":t.value.style.chart.valueBar.label.fontSize,"font-weight":t.value.style.chart.valueBar.label.bold?"bold":"normal",fill:t.value.style.chart.valueBar.label.color,"text-anchor":"middle"},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.segments.dataLabels.formatter,u.value,e.unref(o.dataLabel)({p:t.value.style.chart.segments.dataLabels.prefix,v:u.value,s:t.value.style.chart.segments.dataLabels.suffix,r:t.value.style.chart.segments.dataLabels.rounding}))),9,Z)):e.createCommentVNode("",!0),t.value.style.chart.target.onTop?(e.openBlock(),e.createElementBlock("rect",{key:2,x:c.value.target.x,y:l.value.top+(l.value.chartHeight-l.value.chartHeight*t.value.style.chart.target.heightRatio)/2,height:l.value.chartHeight*t.value.style.chart.target.heightRatio,width:t.value.style.chart.target.width,rx:t.value.style.chart.target.rounded?t.value.style.chart.target.width/2:0,fill:t.value.style.chart.target.color,stroke:t.value.style.chart.target.stroke,"stroke-width":t.value.style.chart.target.strokeWidth},null,8,ee)):e.createCommentVNode("",!0),t.value.style.chart.segments.dataLabels.show?(e.openBlock(),e.createElementBlock("g",te,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value.ticks,r=>(e.openBlock(),e.createElementBlock("text",{x:r.x,y:r.y,"text-anchor":"middle",fill:t.value.style.chart.segments.dataLabels.color,"font-size":t.value.style.chart.segments.dataLabels.fontSize+"px","font-weight":t.value.style.chart.segments.dataLabels.bold?"bold":"normal"},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.segments.dataLabels.formatter,r.value,e.unref(o.dataLabel)({p:t.value.style.chart.segments.dataLabels.prefix,v:r.value,s:t.value.style.chart.segments.dataLabels.suffix,r:t.value.style.chart.segments.dataLabels.rounding}))),9,ae))),256))])):e.createCommentVNode("",!0),t.value.style.chart.segments.dataLabels.show&&t.value.style.chart.segments.ticks.show?(e.openBlock(),e.createElementBlock("g",le,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value.ticks,r=>(e.openBlock(),e.createElementBlock("line",{x1:r.x,x2:r.x,y1:l.value.bottom,y2:l.value.bottom+3,stroke:t.value.style.chart.segments.ticks.stroke,"stroke-width":1,"stroke-linecap":"round"},null,8,re))),256))])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.renderSlot(a.$slots,"svg",{svg:l.value},void 0,!0)],14,X)):e.createCommentVNode("",!0),a.$slots.watermark?(e.openBlock(),e.createElementBlock("div",se,[e.renderSlot(a.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(L)||e.unref(C)})),void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"chartLegend",ref:z},[t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(U.Legend,{key:0,clickable:!1,legendSet:_.value,config:T.value},{item:e.withCtx(({legend:r})=>[e.createElementVNode("div",oe,[e.createElementVNode("span",ne,e.toDisplayString(r.name)+":",1),e.createElementVNode("span",null,e.toDisplayString(r.value),1)])]),_:1},8,["legendSet","config"])):e.createCommentVNode("",!0),e.renderSlot(a.$slots,"legend",{legend:_.value},void 0,!0)],512)],14,G))}},ie=j._export_sfc(ue,[["__scopeId","data-v-8f9b47b1"]]);exports.default=ie;
@@ -1,2 +0,0 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),i=require("./index-C7_6YjWN.cjs"),ee=require("./useResponsive-B3TrDDIG.cjs"),ge=require("./Title-C-lm3Mkl.cjs"),te=require("./usePrinter-8EP4iaGm.cjs"),me=require("./Tooltip-t-3mVhcz.cjs"),ke=require("./DataTable-BTgMVOwp.cjs"),xe=require("./vue-ui-skeleton-CGV1dEUD.cjs"),be=require("./Slicer-CLAVjSQP.cjs"),we=require("./vue-ui-accordion-Cc9958th.cjs"),le=require("./useNestedProp-CC9zGr7C.cjs"),Ce=require("./PackageVersion-D4D0WicU.cjs"),Ne=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),$e=["id"],_e=["xmlns","viewBox"],Be={key:0},Se=["id"],Ve=["stop-color"],Ee=["stop-color"],ze=["stop-color"],Te=["id"],Fe=["stop-color"],Ae=["stop-color"],Le=["stop-color"],Re={key:0},Pe=["x1","x2","y1","y2","stroke","stroke-width"],Ie=["x1","x2","y1","y2","stroke","stroke-width"],Oe={key:1},Me=["x1","x2","y1","y2","stroke","stroke-width"],Ue=["x","y","font-size","fill","font-weight"],De={key:2},qe=["transform","text-anchor","font-size","fill","font-weight"],We=["x1","x2","y1","y2","stroke","stroke-width"],Ge={key:0},He=["cx","cy","r","fill"],je=["cx","cy","r","fill"],Xe={key:1},Ye=["x1","x2","y1","y2","stroke","stroke-width"],Je=["x1","x2","y1","y2","stroke","stroke-width"],Ke=["x","y","height","width","fill","rx"],Qe=["x","y","height","width","fill","rx","stroke","stroke-width"],Ze=["x","y","height","width","fill","onMouseover"],et={key:3,class:"vue-data-ui-watermark"},tt=["innerHTML"],lt={__name:"vue-ui-candlestick",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},setup(f,{expose:oe}){const h=f,{vue_ui_candlestick:ae}=i.useConfig(),m=e.computed(()=>!!h.dataset&&h.dataset.length),y=e.ref(i.createUid()),ue=e.ref(null),B=e.ref(!1),S=e.ref(""),V=e.ref(void 0),F=e.ref(0),k=e.ref(null),A=e.ref(null),L=e.ref(null),R=e.ref(null),b=e.ref(0),P=e.ref(0),I=e.ref(0),t=e.computed({get:()=>O(),set:l=>l});function O(){const l=le.useNestedProp({userConfig:h.config,defaultConfig:ae});return l.theme?{...le.useNestedProp({userConfig:i.themes.vue_ui_candlestick[l.theme]||h.config,defaultConfig:l})}:l}e.watch(()=>h.config,l=>{t.value=O(),M(),b.value+=1,I.value+=1,P.value+=1},{deep:!0}),e.watch(()=>h.dataset,l=>{d.value.start=0,d.value.end=l.length,b.value+=1},{deep:!0});const r=e.ref({height:t.value.style.height,width:t.value.style.width,xAxisFontSize:t.value.style.layout.grid.xAxis.dataLabels.fontSize,yAxisFontSize:t.value.style.layout.grid.yAxis.dataLabels.fontSize}),w=e.ref(null);e.onMounted(()=>{M()});function M(){if(i.objectIsEmpty(h.dataset)&&i.error({componentName:"VueUiCandlestick",type:"dataset"}),t.value.responsive){const l=ee.throttle(()=>{const{width:u,height:o}=ee.useResponsive({chart:k.value,title:t.value.style.title.text?A.value:null,slicer:R.value,legend:L.value});r.value.width=u,r.value.height=o,r.value.xAxisFontSize=i.translateSize({relator:Math.min(u,o),adjuster:t.value.style.width,source:t.value.style.layout.grid.xAxis.dataLabels.fontSize,threshold:6,fallback:6}),r.value.yAxisFontSize=i.translateSize({relator:Math.min(u,o),adjuster:t.value.style.width,source:t.value.style.layout.grid.yAxis.dataLabels.fontSize,threshold:6,fallback:6})});w.value=new ResizeObserver(l),w.value.observe(k.value.parentNode)}}e.onBeforeUnmount(()=>{w.value&&w.value.disconnect()});const{isPrinting:U,isImaging:D,generatePdf:q,generateImage:W}=te.usePrinter({elementId:`vue-ui-candlestick_${y.value}`,fileName:t.value.style.title.text||"vue-ui-candlestick"}),p=e.ref({showTable:t.value.table.show,showTooltip:t.value.style.tooltip.show}),s=e.computed(()=>{const{top:l,right:u,bottom:o,left:a}=t.value.style.layout.padding;return{top:l,right:r.value.width-u,left:a,bottom:r.value.height-o,width:r.value.width-a-u,height:r.value.height-l-o}}),E=e.computed(()=>h.dataset.length),d=e.ref({start:0,end:E.value}),G=e.computed(()=>h.dataset.slice(d.value.start,d.value.end)),z=e.computed(()=>(h.dataset.forEach((l,u)=>{[null,void 0].includes(l[0])&&i.error({componentName:"VueUiCandlestick",type:"datasetAttribute",property:"period (index 0)",index:u}),[null,void 0].includes(l[1])&&i.error({componentName:"VueUiCandlestick",type:"datasetAttribute",property:"open (index 1)",index:u}),[null,void 0].includes(l[2])&&i.error({componentName:"VueUiCandlestick",type:"datasetAttribute",property:"high (index 2)",index:u}),[null,void 0].includes(l[3])&&i.error({componentName:"VueUiCandlestick",type:"datasetAttribute",property:"low (index 3)",index:u}),[null,void 0].includes(l[4])&&i.error({componentName:"VueUiCandlestick",type:"datasetAttribute",property:"last (index 4)",index:u}),[null,void 0].includes(l[5])&&i.error({componentName:"VueUiCandlestick",type:"datasetAttribute",property:"volume (index 5)",index:u})}),G.value.map(l=>({period:l[0],open:l[1],high:l[2],low:l[3],last:l[4],volume:l[5]})))),n=e.computed(()=>s.value.width/G.value.length),H=e.computed(()=>({max:Math.max(...z.value.map(l=>l.high)),min:0})),g=e.computed(()=>i.calculateNiceScale(H.value.min,H.value.max,t.value.style.layout.grid.yAxis.dataLabels.steps));function C(l,u){return{...l,x:i.checkNaN(s.value.left+u*n.value+n.value/2),y:i.checkNaN(s.value.top+(1-l/g.value.max)*s.value.height),value:i.checkNaN(l)}}const c=e.computed(()=>z.value.map((l,u)=>{const o=C(l.open,u),a=C(l.high,u),v=C(l.low,u),$=C(l.last,u),_=l.last>l.open;return{period:l.period,open:o,high:a,low:v,last:$,volume:l.volume,isBullish:_}}));function ie(l){return i.checkNaN(l/g.value.max)}const se=e.computed(()=>g.value.ticks.map(l=>({y:s.value.bottom-s.value.height*ie(l),value:i.checkNaN(l)}))),ne=e.computed(()=>z.value.map(l=>l.period)),T=e.ref(null);function re(l,u){V.value=l,T.value={datapoint:u,seriesIndex:l,series:c.value,config:t.value};const o=t.value.style.tooltip.customFormat;if(i.isFunction(o)&&i.functionReturnsString(()=>o({seriesIndex:l,datapoint:u,series:c.value,config:t.value})))S.value=o({seriesIndex:l,datapoint:u,series:c.value,config:t.value});else if(t.value.style.tooltip.show){let a="";const{period:v,open:$,high:_,low:J,last:K,volume:Q,isBullish:Z}=c.value[l],{period:at,open:ve,high:ye,low:he,last:pe,volume:fe}=t.value.translations;a+=`<div><svg style="margin-right:6px" viewBox="0 0 12 12" height="12" width="12"><rect x="0" y="0" height="12" width="12" rx="${t.value.style.layout.candle.borderRadius*3}" stroke="${t.value.style.layout.candle.stroke}" stroke-width="${t.value.style.layout.candle.strokeWidth}"
2
- fill="${t.value.style.layout.candle.gradient.show?Z?`url(#bullish_gradient_${y.value})`:`url(#bearish_gradient_${y.value})`:Z?t.value.style.layout.candle.colors.bullish:t.value.style.layout.candle.colors.bearish}"/></svg>${v}</div>`,a+=`${fe} : <b>${isNaN(Q)?"-":Number(Q.toFixed(t.value.style.tooltip.roundingValue)).toLocaleString()}</b>`,a+=`<div style="margin-top:6px;padding-top:6px;border-top:1px solid ${t.value.style.tooltip.borderColor}">`,a+=`<div>${ve}: <b>${t.value.style.tooltip.prefix} ${isNaN($.value)?"-":Number($.value.toFixed(t.value.style.tooltip.roundingValue)).toLocaleString()} ${t.value.style.tooltip.suffix}</b></div>`,a+=`<div>${ye}: <b>${t.value.style.tooltip.prefix} ${isNaN(_.value)?"-":Number(_.value.toFixed(t.value.style.tooltip.roundingValue)).toLocaleString()} ${t.value.style.tooltip.suffix}</b></div>`,a+=`<div>${he}: <b>${t.value.style.tooltip.prefix} ${isNaN(J.value)?"-":Number(J.value.toFixed(t.value.style.tooltip.roundingValue)).toLocaleString()} ${t.value.style.tooltip.suffix}</b></div>`,a+=`<div>${pe}: <b>${t.value.style.tooltip.prefix} ${isNaN(K.value)?"-":Number(K.value.toFixed(t.value.style.tooltip.roundingValue)).toLocaleString()} ${t.value.style.tooltip.suffix}</b></div>`,a+="</div>",S.value=`<div style="text-align:right">${a}</div>`}B.value=!0}function de(){d.value={start:0,end:E.value},b.value+=1}function j(){e.nextTick(()=>{const l=[t.value.translations.period,t.value.translations.open,t.value.translations.high,t.value.translations.low,t.value.translations.last,t.value.translations.volume],u=c.value.map(v=>[v.period,v.open.value,v.high.value,v.low.value,v.last.value,v.volume]),o=[[t.value.style.title.text],[t.value.style.title.subtitle.text],[[""],[""],[""]]].concat([l]).concat(u),a=i.createCsvContent(o);i.downloadCsv({csvContent:a,title:t.value.style.title.text||"vue-ui-candlestick"})})}const N=e.computed(()=>{const l=c.value.map(a=>[`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12" height="12" width="12" style="margin-right: 6px"><rect x="0" y="0" height="12" width="12" :rx="${t.value.style.layout.candle.borderRadius*3}" fill="${t.value.style.layout.candle.gradient.show?a.isBullish?`url(#bullish_gradient_${y.value}`:`url(#bearish_gradient_${y.value})`:a.isBullish?t.value.style.layout.candle.colors.bullish:t.value.style.layout.candle.colors.bearish}"/></svg> ${a.period}`,`${t.value.table.td.prefix} ${isNaN(a.open.value)?"-":Number(a.open.value.toFixed(t.value.table.td.roundingValue)).toLocaleString()} ${t.value.table.td.suffix}`,`${t.value.table.td.prefix} ${isNaN(a.high.value)?"-":Number(a.high.value.toFixed(t.value.table.td.roundingValue)).toLocaleString()} ${t.value.table.td.suffix}`,`${t.value.table.td.prefix} ${isNaN(a.low.value)?"-":Number(a.low.value.toFixed(t.value.table.td.roundingValue)).toLocaleString()} ${t.value.table.td.suffix}`,`${t.value.table.td.prefix} ${isNaN(a.last.value)?"-":Number(a.last.value.toFixed(t.value.table.td.roundingValue)).toLocaleString()} ${t.value.table.td.suffix}`,`${isNaN(a.volume)?"-":a.volume.toLocaleString()}`]),u={th:{backgroundColor:t.value.table.th.backgroundColor,color:t.value.table.th.color,outline:t.value.table.th.outline},td:{backgroundColor:t.value.table.td.backgroundColor,color:t.value.table.td.color,outline:t.value.table.td.outline},breakpoint:t.value.table.responsiveBreakpoint},o=[t.value.translations.period,t.value.translations.open,t.value.translations.high,t.value.translations.low,t.value.translations.last,t.value.translations.volume];return{head:o,body:l,config:u,colNames:o}}),x=e.ref(!1);function ce(l){x.value=l,F.value+=1}function X(){p.value.showTable=!p.value.showTable}function Y(){p.value.showTooltip=!p.value.showTooltip}return oe({generatePdf:q,generateCsv:j,generateImage:W,toggleTable:X,toggleTooltip:Y}),(l,u)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"candlestickChart",ref:k,class:e.normalizeClass(`vue-ui-candlestick ${x.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),style:e.normalizeStyle(`position:relative;font-family:${t.value.style.fontFamily}; text-align:center;${t.value.style.title.text?"":"padding-top:36px"};background:${t.value.style.backgroundColor}; ${t.value.responsive?"height: 100%":""}`),id:`vue-ui-candlestick_${y.value}`},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"chartTitle",ref:A,style:"width:100%;background:transparent"},[(e.openBlock(),e.createBlock(ge._sfc_main,{key:`title_${I.value}`,config:{title:{cy:"candlestick-div-title",...t.value.style.title},subtitle:{cy:"candlestick-div-subtitle",...t.value.style.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&m.value?(e.openBlock(),e.createBlock(te.UserOptions,{ref_key:"details",ref:ue,key:`user_options_${F.value}`,backgroundColor:t.value.style.backgroundColor,color:t.value.style.color,isImaging:e.unref(D),isPrinting:e.unref(U),uid:y.value,hasTooltip:t.value.userOptions.buttons.tooltip&&t.value.style.tooltip.show,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:t.value.userOptions.buttons.csv,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:x.value,isTooltip:p.value.showTooltip,titles:{...t.value.userOptions.buttonTitles},chartElement:k.value,position:t.value.userOptions.position,onToggleFullscreen:ce,onGeneratePdf:e.unref(q),onGenerateCsv:j,onGenerateImage:e.unref(W),onToggleTable:X,onToggleTooltip:Y},e.createSlots({_:2},[l.$slots.optionTooltip?{name:"optionTooltip",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:o,isFullscreen:a})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:a})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasTooltip","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","isTooltip","titles","chartElement","position","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("svg",{key:2,xmlns:e.unref(i.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":x.value,"vue-data-ui-fulscreen--off":!x.value}),viewBox:`0 0 ${r.value.width<=0?10:r.value.width} ${r.value.height<=0?10:r.value.height}`,style:e.normalizeStyle(`max-width:100%;overflow:visible;background:transparent;color:${t.value.style.color}`)},[e.createVNode(Ce._sfc_main),c.value.length>0?(e.openBlock(),e.createElementBlock("g",Be,[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`bearish_gradient_${y.value}`,x2:"0%",y2:"100%"},[e.createElementVNode("stop",{offset:"0%","stop-color":t.value.style.layout.candle.colors.bearish},null,8,Ve),e.createElementVNode("stop",{offset:"50%","stop-color":`${e.unref(i.shiftHue)(t.value.style.layout.candle.colors.bearish,.02)}DE`},null,8,Ee),e.createElementVNode("stop",{offset:"100%","stop-color":`${e.unref(i.shiftHue)(t.value.style.layout.candle.colors.bearish,.05)}66`},null,8,ze)],8,Se),e.createElementVNode("linearGradient",{id:`bullish_gradient_${y.value}`,x2:"0%",y2:"100%"},[e.createElementVNode("stop",{offset:"0%","stop-color":t.value.style.layout.candle.colors.bullish},null,8,Fe),e.createElementVNode("stop",{offset:"50%","stop-color":`${e.unref(i.shiftHue)(t.value.style.layout.candle.colors.bullish,.02)}DE`},null,8,Ae),e.createElementVNode("stop",{offset:"100%","stop-color":`${e.unref(i.shiftHue)(t.value.style.layout.candle.colors.bullish,.05)}66`},null,8,Le)],8,Te)]),t.value.style.layout.grid.show?(e.openBlock(),e.createElementBlock("g",Re,[e.createElementVNode("line",{x1:s.value.left,x2:s.value.left,y1:s.value.top,y2:s.value.bottom,stroke:t.value.style.layout.grid.stroke,"stroke-width":t.value.style.layout.grid.strokeWidth,"stroke-linecap":"round"},null,8,Pe),e.createElementVNode("line",{x1:s.value.left,x2:s.value.right,y1:s.value.bottom,y2:s.value.bottom,stroke:t.value.style.layout.grid.stroke,"stroke-width":t.value.style.layout.grid.strokeWidth,"stroke-linecap":"round"},null,8,Ie)])):e.createCommentVNode("",!0),t.value.style.layout.grid.yAxis.dataLabels.show?(e.openBlock(),e.createElementBlock("g",Oe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(se.value,(o,a)=>(e.openBlock(),e.createElementBlock("g",null,[o.value>=g.value.min&&o.value<=g.value.max?(e.openBlock(),e.createElementBlock("line",{key:0,x1:s.value.left,x2:s.value.left-5,y1:o.y,y2:o.y,stroke:t.value.style.layout.grid.stroke,"stroke-width":t.value.style.layout.grid.strokeWidth,"stroke-linecap":"round"},null,8,Me)):e.createCommentVNode("",!0),o.value>=g.value.min&&o.value<=g.value.max?(e.openBlock(),e.createElementBlock("text",{key:1,x:s.value.left-8+t.value.style.layout.grid.yAxis.dataLabels.offsetX,y:o.y+r.value.yAxisFontSize/3,"font-size":r.value.yAxisFontSize,"text-anchor":"end",fill:t.value.style.layout.grid.yAxis.dataLabels.color,"font-weight":t.value.style.layout.grid.yAxis.dataLabels.bold?"bold":"normal"},e.toDisplayString(t.value.style.layout.grid.yAxis.dataLabels.prefix)+" "+e.toDisplayString(e.unref(i.canShowValue)(o.value)?o.value.toFixed(t.value.style.layout.grid.yAxis.dataLabels.roundingValue):"")+" "+e.toDisplayString(t.value.style.layout.grid.yAxis.dataLabels.suffix),9,Ue)):e.createCommentVNode("",!0)]))),256))])):e.createCommentVNode("",!0),t.value.style.layout.grid.xAxis.dataLabels.show?(e.openBlock(),e.createElementBlock("g",De,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ne.value,(o,a)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("text",{transform:`translate(${s.value.left+n.value*a+n.value/2}, ${s.value.bottom+r.value.xAxisFontSize*2+t.value.style.layout.grid.xAxis.dataLabels.offsetY}), rotate(${t.value.style.layout.grid.xAxis.dataLabels.rotation})`,"text-anchor":t.value.style.layout.grid.xAxis.dataLabels.rotation>0?"start":t.value.style.layout.grid.xAxis.dataLabels.rotation<0?"end":"middle","font-size":r.value.xAxisFontSize,fill:t.value.style.layout.grid.xAxis.dataLabels.color,"font-weight":t.value.style.layout.grid.xAxis.dataLabels.bold?"bold":"normal"},e.toDisplayString(o),9,qe)]))),256))])):e.createCommentVNode("",!0),e.createElementVNode("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(o,a)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("line",{x1:o.open.x,x2:o.open.x,y1:o.high.y,y2:o.low.y,stroke:t.value.style.layout.wick.stroke,"stroke-width":t.value.style.layout.wick.strokeWidth,"stroke-linecap":"round"},null,8,We),t.value.style.layout.wick.extremity.shape==="circle"?(e.openBlock(),e.createElementBlock("g",Ge,[e.createElementVNode("circle",{cx:o.high.x,cy:o.high.y,r:t.value.style.layout.wick.extremity.size==="auto"?n.value/20:t.value.style.layout.wick.extremity.size,fill:t.value.style.layout.wick.extremity.color},null,8,He),e.createElementVNode("circle",{cx:o.low.x,cy:o.low.y,r:t.value.style.layout.wick.extremity.size==="auto"?n.value/20:t.value.style.layout.wick.extremity.size,fill:t.value.style.layout.wick.extremity.color},null,8,je)])):e.createCommentVNode("",!0),t.value.style.layout.wick.extremity.shape==="line"?(e.openBlock(),e.createElementBlock("g",Xe,[e.createElementVNode("line",{x1:o.high.x-(t.value.style.layout.wick.extremity.size==="auto"?n.value*t.value.style.layout.candle.widthRatio:t.value.style.layout.wick.extremity.size)/2,x2:o.high.x+(t.value.style.layout.wick.extremity.size==="auto"?n.value*t.value.style.layout.candle.widthRatio:t.value.style.layout.wick.extremity.size)/2,y1:o.high.y,y2:o.high.y,stroke:t.value.style.layout.wick.extremity.color,"stroke-width":t.value.style.layout.wick.strokeWidth,"stroke-linecap":"round"},null,8,Ye),e.createElementVNode("line",{x1:o.low.x-(t.value.style.layout.wick.extremity.size==="auto"?n.value*t.value.style.layout.candle.widthRatio:t.value.style.layout.wick.extremity.size)/2,x2:o.low.x+(t.value.style.layout.wick.extremity.size==="auto"?n.value*t.value.style.layout.candle.widthRatio:t.value.style.layout.wick.extremity.size)/2,y1:o.low.y,y2:o.low.y,stroke:t.value.style.layout.wick.extremity.color,"stroke-width":t.value.style.layout.wick.strokeWidth,"stroke-linecap":"round"},null,8,Je)])):e.createCommentVNode("",!0)]))),256))]),e.createElementVNode("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(o,a)=>(e.openBlock(),e.createElementBlock("rect",{x:o.open.x-n.value/2+n.value*(1-t.value.style.layout.candle.widthRatio)/2,y:o.isBullish?o.last.y:o.open.y,height:Math.abs(o.last.y-o.open.y)<=0?1e-4:Math.abs(o.last.y-o.open.y),width:n.value*t.value.style.layout.candle.widthRatio<=0?1e-4:n.value*t.value.style.layout.candle.widthRatio,fill:t.value.style.layout.candle.gradient.underlayer,rx:t.value.style.layout.candle.borderRadius,stroke:"none"},null,8,Ke))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(o,a)=>(e.openBlock(),e.createElementBlock("rect",{x:o.open.x-n.value/2+n.value*(1-t.value.style.layout.candle.widthRatio)/2,y:o.isBullish?o.last.y:o.open.y,height:Math.abs(o.last.y-o.open.y)<=0?1e-4:Math.abs(o.last.y-o.open.y),width:n.value*t.value.style.layout.candle.widthRatio<=0?1e-4:n.value*t.value.style.layout.candle.widthRatio,fill:o.isBullish?t.value.style.layout.candle.gradient.show?`url(#bullish_gradient_${y.value})`:t.value.style.layout.candle.colors.bullish:t.value.style.layout.candle.gradient.show?`url(#bearish_gradient_${y.value})`:t.value.style.layout.candle.colors.bearish,rx:t.value.style.layout.candle.borderRadius,stroke:t.value.style.layout.candle.stroke,"stroke-width":t.value.style.layout.candle.strokeWidth,"stroke-linecap":"round","stroke-linejoin":"round"},null,8,Qe))),256))]),e.createElementVNode("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(o,a)=>(e.openBlock(),e.createElementBlock("rect",{x:s.value.left+a*n.value,y:s.value.top,height:s.value.height<=0?1e-4:s.value.height,width:n.value<=0?1e-4:n.value,fill:V.value===a?e.unref(i.setOpacity)(t.value.style.layout.selector.color,t.value.style.layout.selector.opacity):"transparent",onMouseover:v=>re(a,o),onMouseleave:u[0]||(u[0]=v=>{V.value=void 0,B.value=!1})},null,40,Ze))),256))])])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"svg",{svg:r.value},void 0,!0)],14,_e)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",et,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(U)||e.unref(D)})),void 0,!0)])):e.createCommentVNode("",!0),m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(xe.default,{key:4,config:{type:"candlesticks",style:{backgroundColor:t.value.style.backgroundColor,candlesticks:{axis:{color:"#CCCCCC"},candle:{color:"#CCCCCC"}}}}},null,8,["config"])),t.value.style.zoom.show&&m.value?(e.openBlock(),e.createElementBlock("div",{key:5,ref_key:"chartSlicer",ref:R},[(e.openBlock(),e.createBlock(be.Slicer,{key:`slicer_${b.value}`,background:t.value.style.zoom.color,borderColor:t.value.style.backgroundColor,fontSize:t.value.style.zoom.fontSize,useResetSlot:t.value.style.zoom.useResetSlot,labelLeft:f.dataset[d.value.start]?f.dataset[d.value.start][0]:f.dataset[0][0],labelRight:f.dataset[d.value.end-1]?f.dataset[d.value.end-1][0]:f.dataset.at(-1)[0],textColor:t.value.style.color,inputColor:t.value.style.zoom.color,selectColor:t.value.style.zoom.highlightColor,max:E.value,min:0,valueStart:d.value.start,valueEnd:d.value.end,start:d.value.start,"onUpdate:start":u[1]||(u[1]=o=>d.value.start=o),end:d.value.end,"onUpdate:end":u[2]||(u[2]=o=>d.value.end=o),onReset:de},{"reset-action":e.withCtx(({reset:o})=>[e.renderSlot(l.$slots,"reset-action",e.normalizeProps(e.guardReactiveProps({reset:o})),void 0,!0)]),_:3},8,["background","borderColor","fontSize","useResetSlot","labelLeft","labelRight","textColor","inputColor","selectColor","max","valueStart","valueEnd","start","end"]))],512)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"chartLegend",ref:L},[e.renderSlot(l.$slots,"legend",{legend:c.value},void 0,!0)],512),e.createVNode(me._sfc_main,{show:p.value.showTooltip&&B.value,backgroundColor:t.value.style.tooltip.backgroundColor,color:t.value.style.tooltip.color,borderRadius:t.value.style.tooltip.borderRadius,borderColor:t.value.style.tooltip.borderColor,borderWidth:t.value.style.tooltip.borderWidth,fontSize:t.value.style.tooltip.fontSize,backgroundOpacity:t.value.style.tooltip.backgroundOpacity,position:t.value.style.tooltip.position,offsetY:t.value.style.tooltip.offsetY,parent:k.value,content:S.value,isCustom:t.value.style.tooltip.customFormat&&typeof t.value.style.tooltip.customFormat=="function"},{"tooltip-before":e.withCtx(()=>[e.renderSlot(l.$slots,"tooltip-before",e.normalizeProps(e.guardReactiveProps({...T.value})),void 0,!0)]),"tooltip-after":e.withCtx(()=>[e.renderSlot(l.$slots,"tooltip-after",e.normalizeProps(e.guardReactiveProps({...T.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","borderRadius","borderColor","borderWidth","fontSize","backgroundOpacity","position","offsetY","parent","content","isCustom"]),m.value?(e.openBlock(),e.createBlock(we.default,{key:6,hideDetails:"",config:{open:p.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.backgroundColor,color:t.value.style.color},head:{backgroundColor:t.value.style.backgroundColor,color:t.value.style.color}}},{content:e.withCtx(()=>[(e.openBlock(),e.createBlock(ke.DataTable,{key:`table_${P.value}`,colNames:N.value.colNames,head:N.value.head,body:N.value.body,config:N.value.config,title:`${t.value.style.title.text}${t.value.style.title.subtitle.text?` : ${t.value.style.title.subtitle.text}`:""}`,onClose:u[3]||(u[3]=o=>p.value.showTable=!1)},{th:e.withCtx(({th:o})=>[e.createTextVNode(e.toDisplayString(o),1)]),td:e.withCtx(({td:o})=>[e.createElementVNode("div",{innerHTML:o},null,8,tt)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],14,$e))}},ot=Ne._export_sfc(lt,[["__scopeId","data-v-51dc0cb1"]]);exports.default=ot;