vue-data-ui 2.6.4 → 2.6.6

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 (162) hide show
  1. package/dist/{Arrow-CJeP3IfV.cjs → Arrow-BYqxz6UG.cjs} +1 -1
  2. package/dist/{Arrow-BNRsG_PK.js → Arrow-DFWjAvCY.js} +1 -1
  3. package/dist/{BaseIcon-BOR1UXkg.cjs → BaseIcon-COe_H-UB.cjs} +1 -1
  4. package/dist/{BaseIcon-DAD8bWYx.js → BaseIcon-t20JEZNG.js} +1 -1
  5. package/dist/{DataTable-Bg0b_pVK.js → DataTable-CJN0sipt.js} +2 -2
  6. package/dist/{DataTable-C1LMti1U.cjs → DataTable-Du7nJ0TM.cjs} +1 -1
  7. package/dist/{Legend-Ba6qRAqc.js → Legend-BDyPoYfp.js} +2 -2
  8. package/dist/{Legend-CMzKRWtT.cjs → Legend-CM7IGBC3.cjs} +1 -1
  9. package/dist/{PackageVersion-C5hOoj_p.js → PackageVersion-DqmHcoqz.js} +1 -1
  10. package/dist/{PackageVersion-2gojTmrp.cjs → PackageVersion-qeLvq6l8.cjs} +1 -1
  11. package/dist/{PenAndPaper-BJLUyj-s.js → PenAndPaper-6UYizrkQ.js} +3 -3
  12. package/dist/{PenAndPaper-Bwxr_PKm.cjs → PenAndPaper-BYqaxOpk.cjs} +1 -1
  13. package/dist/{Shape-DTKetM4N.cjs → Shape-BN3-_2DI.cjs} +1 -1
  14. package/dist/{Shape-BXfC7I_g.js → Shape-C_qIhG3J.js} +1 -1
  15. package/dist/{Slicer-bCt9Cx4y.js → Slicer-BQP3UIW-.js} +2 -2
  16. package/dist/{Slicer-Park25Rm.cjs → Slicer-DPae3p1M.cjs} +1 -1
  17. package/dist/{Title-vXH_7MPz.cjs → Title-BGiQdt7J.cjs} +1 -1
  18. package/dist/{Title-AFFkNb_h.js → Title-D6h1gTvZ.js} +1 -1
  19. package/dist/{Tooltip-C6qF6AOJ.js → Tooltip-BonEVaob.js} +1 -1
  20. package/dist/{Tooltip-C7eukp_Y.cjs → Tooltip-DSPKrQcQ.cjs} +1 -1
  21. package/dist/{index-y7ebFPbO.js → index-B9qF6XbP.js} +12 -7
  22. package/dist/index-kZKcQZM_.cjs +9 -0
  23. package/dist/style.css +1 -1
  24. package/dist/types/vue-data-ui.d.cts +89 -62
  25. package/dist/types/vue-data-ui.d.ts +89 -62
  26. package/dist/{useNestedProp-BzGIy5aD.cjs → useNestedProp-D4Jn2Oxr.cjs} +1 -1
  27. package/dist/{useNestedProp-BWzyGJZ8.js → useNestedProp-g5oKzlVy.js} +1 -1
  28. package/dist/{usePrinter-DY6H-UkT.cjs → usePrinter-DR42gTOS.cjs} +1 -1
  29. package/dist/{usePrinter-xz0bcBPM.js → usePrinter-DsiBLAy1.js} +1 -1
  30. package/dist/{vue-data-ui-lvrlgytd.js → vue-data-ui-DB2kdhYH.js} +61 -61
  31. package/dist/{vue-data-ui-DI586Tl5.cjs → vue-data-ui-DbhVASfn.cjs} +1 -1
  32. package/dist/vue-data-ui.cjs +1 -1
  33. package/dist/vue-data-ui.js +1 -1
  34. package/dist/{vue-ui-3d-bar-BZgGJ_4E.cjs → vue-ui-3d-bar-DEu24HHj.cjs} +1 -1
  35. package/dist/{vue-ui-3d-bar-7ciIKlHS.js → vue-ui-3d-bar-DHeSFJ5z.js} +9 -9
  36. package/dist/{vue-ui-accordion-D3UeWj9q.cjs → vue-ui-accordion-BfDu7hTY.cjs} +1 -1
  37. package/dist/{vue-ui-accordion-DxSGI7GJ.js → vue-ui-accordion-DBmchkva.js} +3 -3
  38. package/dist/{vue-ui-age-pyramid-C-3bEzow.cjs → vue-ui-age-pyramid-CRYYDXFo.cjs} +1 -1
  39. package/dist/{vue-ui-age-pyramid-D8CKdfwE.js → vue-ui-age-pyramid-CvUCPqxa.js} +10 -10
  40. package/dist/{vue-ui-annotator-B4_flLm1.cjs → vue-ui-annotator-BV9t6ro7.cjs} +1 -1
  41. package/dist/{vue-ui-annotator-Cu9TPyUl.js → vue-ui-annotator-Dr5PLrJx.js} +1 -1
  42. package/dist/{vue-ui-bullet-BEssjqEW.js → vue-ui-bullet-D7Uw9tez.js} +8 -8
  43. package/dist/{vue-ui-bullet-CS48Jn1m.cjs → vue-ui-bullet-Dy71N3Jf.cjs} +1 -1
  44. package/dist/{vue-ui-candlestick-DW7NHW5L.js → vue-ui-candlestick-BFmh-zx1.js} +11 -11
  45. package/dist/{vue-ui-candlestick-B85sWqPO.cjs → vue-ui-candlestick-aZ1YN4hh.cjs} +1 -1
  46. package/dist/{vue-ui-carousel-table--yu4e9Dn.cjs → vue-ui-carousel-table-C30Gvanv.cjs} +1 -1
  47. package/dist/{vue-ui-carousel-table-BDgIKnZ6.js → vue-ui-carousel-table-CUhkylz_.js} +4 -4
  48. package/dist/{vue-ui-chestnut-wiZb3STX.js → vue-ui-chestnut-C53wdHmR.js} +8 -8
  49. package/dist/{vue-ui-chestnut-CohERgOT.cjs → vue-ui-chestnut-DuycsDaB.cjs} +1 -1
  50. package/dist/{vue-ui-circle-pack-D0DnGODv.cjs → vue-ui-circle-pack-BFF5_9Sm.cjs} +1 -1
  51. package/dist/{vue-ui-circle-pack-CCbFwcZq.js → vue-ui-circle-pack-Bj3sA7RV.js} +9 -9
  52. package/dist/{vue-ui-cursor-DqFQ-PMZ.js → vue-ui-cursor-0GY46Ywr.js} +2 -2
  53. package/dist/{vue-ui-cursor-Br93sq6V.cjs → vue-ui-cursor-ZBrt-jTo.cjs} +1 -1
  54. package/dist/{vue-ui-dashboard-lSSaetgV.js → vue-ui-dashboard-BX787_or.js} +2 -2
  55. package/dist/{vue-ui-dashboard-BwnE3PnW.cjs → vue-ui-dashboard-pzZD8J2y.cjs} +1 -1
  56. package/dist/{vue-ui-digits-DyMxtXim.cjs → vue-ui-digits-Blb8fghV.cjs} +1 -1
  57. package/dist/{vue-ui-digits-BbKoWo0v.js → vue-ui-digits-BvCMwL0L.js} +2 -2
  58. package/dist/{vue-ui-donut-BFdOEkVv.cjs → vue-ui-donut-BO6RWqZ6.cjs} +1 -1
  59. package/dist/{vue-ui-donut-evolution-572FJh5z.cjs → vue-ui-donut-evolution-BgJMw_a4.cjs} +1 -1
  60. package/dist/{vue-ui-donut-evolution-WWwGlSFZ.js → vue-ui-donut-evolution-DRfJVMrP.js} +12 -12
  61. package/dist/{vue-ui-donut-BPY9X0nr.js → vue-ui-donut-yBjSgsTz.js} +13 -15
  62. package/dist/{vue-ui-dumbbell-otpZLJRb.js → vue-ui-dumbbell-4-hWZn-o.js} +10 -10
  63. package/dist/{vue-ui-dumbbell-CTCUgGKD.cjs → vue-ui-dumbbell-BSXxNjyK.cjs} +1 -1
  64. package/dist/{vue-ui-flow-BcqEMc_I.cjs → vue-ui-flow-LNlNIRfb.cjs} +1 -1
  65. package/dist/{vue-ui-flow-Dr2lzUkJ.js → vue-ui-flow-aH6xSdwn.js} +9 -9
  66. package/dist/{vue-ui-funnel-DhAgAXS7.js → vue-ui-funnel-BZy4SvlW.js} +9 -9
  67. package/dist/{vue-ui-funnel-D3WFS9UV.cjs → vue-ui-funnel-BhDmLkFj.cjs} +1 -1
  68. package/dist/{vue-ui-galaxy-wA-JkujS.cjs → vue-ui-galaxy-BcwAAgUh.cjs} +1 -1
  69. package/dist/{vue-ui-galaxy-Com-d71M.js → vue-ui-galaxy-GDXdZqjm.js} +11 -11
  70. package/dist/{vue-ui-gauge-DseS2Wjw.cjs → vue-ui-gauge-BCf-2H4T.cjs} +1 -1
  71. package/dist/{vue-ui-gauge-D5cWSaYs.js → vue-ui-gauge-CeyHdkuS.js} +8 -8
  72. package/dist/{vue-ui-gizmo-C4hyVlqo.cjs → vue-ui-gizmo-CRTzb1J_.cjs} +1 -1
  73. package/dist/{vue-ui-gizmo-D7Y4R-bm.js → vue-ui-gizmo-veFxjktw.js} +3 -3
  74. package/dist/{vue-ui-heatmap-B60uAj5d.js → vue-ui-heatmap-BizLgjJ8.js} +13 -13
  75. package/dist/{vue-ui-heatmap-rlqRMQeh.cjs → vue-ui-heatmap-Bxhy4dCf.cjs} +1 -1
  76. package/dist/{vue-ui-history-plot-CC4-ii7H.cjs → vue-ui-history-plot-CTBCFIG0.cjs} +1 -1
  77. package/dist/{vue-ui-history-plot-CmOEQx8n.js → vue-ui-history-plot-gzx5uGyY.js} +11 -11
  78. package/dist/{vue-ui-kpi-uxIO9tVc.cjs → vue-ui-kpi-CP08PB51.cjs} +1 -1
  79. package/dist/{vue-ui-kpi-B9SmpjuD.js → vue-ui-kpi-MdyAQjdJ.js} +3 -3
  80. package/dist/{vue-ui-mini-loader-B8n-qGUz.cjs → vue-ui-mini-loader-BRmtJ6az.cjs} +1 -1
  81. package/dist/{vue-ui-mini-loader-Bpp9yfiB.js → vue-ui-mini-loader-CYVr1K6S.js} +2 -2
  82. package/dist/{vue-ui-molecule-9de6y3_R.js → vue-ui-molecule-CJ05ddhf.js} +11 -11
  83. package/dist/{vue-ui-molecule-D5DCX4SJ.cjs → vue-ui-molecule-pTMJG_3k.cjs} +1 -1
  84. package/dist/{vue-ui-mood-radar-D2pdih9T.js → vue-ui-mood-radar-DG1pF6Ii.js} +11 -11
  85. package/dist/{vue-ui-mood-radar-uHW_8xE-.cjs → vue-ui-mood-radar-DXLYUXbX.cjs} +1 -1
  86. package/dist/{vue-ui-nested-donuts-wLxqfAFm.js → vue-ui-nested-donuts-CDjZ6KfI.js} +11 -11
  87. package/dist/{vue-ui-nested-donuts-BCtAAmdG.cjs → vue-ui-nested-donuts-yztsnsjM.cjs} +1 -1
  88. package/dist/{vue-ui-onion-CK_xa2M4.cjs → vue-ui-onion-BgbKMVNe.cjs} +1 -1
  89. package/dist/{vue-ui-onion-Vz2j7gWm.js → vue-ui-onion-DsskQUiP.js} +11 -11
  90. package/dist/{vue-ui-parallel-coordinate-plot-CZRX2Hss.cjs → vue-ui-parallel-coordinate-plot-Cha1Em8k.cjs} +1 -1
  91. package/dist/{vue-ui-parallel-coordinate-plot-BQdLDI5B.js → vue-ui-parallel-coordinate-plot-D7r71vdp.js} +12 -12
  92. package/dist/{vue-ui-quadrant-CalJqNte.cjs → vue-ui-quadrant-BzYnR_Hc.cjs} +1 -1
  93. package/dist/{vue-ui-quadrant-iPPHj_cd.js → vue-ui-quadrant-DCHEhvMX.js} +15 -16
  94. package/dist/{vue-ui-quick-chart-CV1VBbY1.js → vue-ui-quick-chart-BB5b4AQ1.js} +9 -9
  95. package/dist/{vue-ui-quick-chart-CFUOFUU_.cjs → vue-ui-quick-chart-BcW7URue.cjs} +1 -1
  96. package/dist/{vue-ui-radar-DsialWJl.js → vue-ui-radar-CNEXWSEx.js} +53 -56
  97. package/dist/{vue-ui-radar-B2gn7R-V.cjs → vue-ui-radar-D-XPVXa9.cjs} +1 -1
  98. package/dist/{vue-ui-rating-B3W6ZWnp.cjs → vue-ui-rating-ClvF4LPg.cjs} +1 -1
  99. package/dist/{vue-ui-rating-4gM1AlYy.js → vue-ui-rating-DJLSl0-4.js} +2 -2
  100. package/dist/{vue-ui-relation-circle-YEAFQh-9.cjs → vue-ui-relation-circle-DfxnHEqR.cjs} +1 -1
  101. package/dist/{vue-ui-relation-circle-D6ZiupHh.js → vue-ui-relation-circle-Hdzt7fOS.js} +7 -7
  102. package/dist/{vue-ui-rings-CbIo_ZYH.js → vue-ui-rings-BAFkqjcL.js} +13 -15
  103. package/dist/{vue-ui-rings-B9BPvha3.cjs → vue-ui-rings-C9NFME3F.cjs} +2 -2
  104. package/dist/{vue-ui-scatter-CQ-Vdmeu.js → vue-ui-scatter-Ca67EOrI.js} +13 -13
  105. package/dist/{vue-ui-scatter-BqSstAAz.cjs → vue-ui-scatter-D0UloS1C.cjs} +1 -1
  106. package/dist/{vue-ui-screenshot-0RZZXp_S.cjs → vue-ui-screenshot-CFcvBOJm.cjs} +1 -1
  107. package/dist/{vue-ui-screenshot-BEV-kvIS.js → vue-ui-screenshot-CsdnwhSO.js} +1 -1
  108. package/dist/{vue-ui-skeleton-DkW8eWHI.cjs → vue-ui-skeleton-BBNX7lud.cjs} +1 -1
  109. package/dist/{vue-ui-skeleton-DOahsJXV.js → vue-ui-skeleton-CHEZlRpn.js} +3 -3
  110. package/dist/{vue-ui-smiley-DY8lN1W3.js → vue-ui-smiley-Dth6gRqg.js} +2 -2
  111. package/dist/{vue-ui-smiley-B9xk5OKe.cjs → vue-ui-smiley-EngC6Vc4.cjs} +1 -1
  112. package/dist/{vue-ui-spark-trend-XDdEKIe6.js → vue-ui-spark-trend-33sBlF-n.js} +5 -5
  113. package/dist/{vue-ui-spark-trend-CGoCmXa9.cjs → vue-ui-spark-trend-DJ8yhFMx.cjs} +1 -1
  114. package/dist/{vue-ui-sparkbar-QikBTVyy.cjs → vue-ui-sparkbar-D9QLpB7G.cjs} +1 -1
  115. package/dist/{vue-ui-sparkbar-CGpwWIBE.js → vue-ui-sparkbar-mJu95295.js} +4 -4
  116. package/dist/{vue-ui-sparkgauge-ZDhKN9Pz.cjs → vue-ui-sparkgauge-CBCbyOG2.cjs} +1 -1
  117. package/dist/{vue-ui-sparkgauge-CeNuuLof.js → vue-ui-sparkgauge-nFFf8h-x.js} +4 -4
  118. package/dist/{vue-ui-sparkhistogram-DLEumotF.js → vue-ui-sparkhistogram-Bh6R737O.js} +21 -21
  119. package/dist/vue-ui-sparkhistogram-BstSpbti.cjs +1 -0
  120. package/dist/{vue-ui-sparkline-b9FXu2wY.js → vue-ui-sparkline-BfBiA1O5.js} +136 -140
  121. package/dist/vue-ui-sparkline-DTRZ-_Qw.cjs +1 -0
  122. package/dist/{vue-ui-sparkstackbar-CQFec5Ni.js → vue-ui-sparkstackbar-BNTFNUIA.js} +8 -6
  123. package/dist/vue-ui-sparkstackbar-CuU8Vpcv.cjs +1 -0
  124. package/dist/{vue-ui-stackbar-B24Xho-6.cjs → vue-ui-stackbar-B5uNBkxp.cjs} +1 -1
  125. package/dist/{vue-ui-stackbar-B50_Zmpe.js → vue-ui-stackbar-BbFUifMU.js} +13 -13
  126. package/dist/{vue-ui-strip-plot-DzTWLY9k.cjs → vue-ui-strip-plot-7G7BAGQM.cjs} +1 -1
  127. package/dist/{vue-ui-strip-plot-DBEKI4DJ.js → vue-ui-strip-plot-wsxpyqrw.js} +11 -11
  128. package/dist/{vue-ui-table-CiJBrzOj.js → vue-ui-table-CQYM4uPf.js} +1 -1
  129. package/dist/{vue-ui-table-DeQeB-f6.cjs → vue-ui-table-DUokotBj.cjs} +1 -1
  130. package/dist/{vue-ui-table-heatmap-DQMdZaE0.cjs → vue-ui-table-heatmap-Brk58nK_.cjs} +1 -1
  131. package/dist/{vue-ui-table-heatmap-CjnQNUKw.js → vue-ui-table-heatmap-OYQ9OOzo.js} +4 -4
  132. package/dist/{vue-ui-table-sparkline-Bu6vSST9.cjs → vue-ui-table-sparkline-C9dOsIAB.cjs} +1 -1
  133. package/dist/{vue-ui-table-sparkline-DqBjtjvu.js → vue-ui-table-sparkline-DUjDhg8A.js} +5 -5
  134. package/dist/vue-ui-thermometer-VnlcJh4G.cjs +1 -0
  135. package/dist/{vue-ui-thermometer-DQr-b2tS.js → vue-ui-thermometer-WSMSVcM_.js} +11 -11
  136. package/dist/{vue-ui-timer-B18HFp7S.cjs → vue-ui-timer-Bh8RpM2u.cjs} +1 -1
  137. package/dist/{vue-ui-timer-lsgsV998.js → vue-ui-timer-DBP_fRcm.js} +5 -5
  138. package/dist/{vue-ui-tiremarks-D1A57_oK.cjs → vue-ui-tiremarks-Ct96o_fd.cjs} +1 -1
  139. package/dist/{vue-ui-tiremarks-C7Dw9KnQ.js → vue-ui-tiremarks-WWgS2mqw.js} +7 -7
  140. package/dist/{vue-ui-treemap-DurUVYzG.cjs → vue-ui-treemap-BfDk53pM.cjs} +1 -1
  141. package/dist/{vue-ui-treemap-qSvP_IHI.js → vue-ui-treemap-CXoXEuSA.js} +11 -11
  142. package/dist/{vue-ui-vertical-bar-D9eDAZF3.js → vue-ui-vertical-bar-COaAa4nz.js} +15 -17
  143. package/dist/vue-ui-vertical-bar-EIy7A0dV.cjs +4 -0
  144. package/dist/{vue-ui-waffle-CaGazi4R.cjs → vue-ui-waffle-BB3l0zZU.cjs} +1 -1
  145. package/dist/{vue-ui-waffle-CFzcClhK.js → vue-ui-waffle-DD8pT7JN.js} +13 -13
  146. package/dist/vue-ui-wheel-BLlKekiu.js +327 -0
  147. package/dist/vue-ui-wheel-DfpXZJ8A.cjs +1 -0
  148. package/dist/{vue-ui-word-cloud-CelTdM-N.js → vue-ui-word-cloud-CcYtTXW6.js} +10 -10
  149. package/dist/{vue-ui-word-cloud-BxEfdctG.cjs → vue-ui-word-cloud-DdaMzF2e.cjs} +1 -1
  150. package/dist/{vue-ui-xy-BMTIOJmU.cjs → vue-ui-xy-B4Mzyy81.cjs} +2 -2
  151. package/dist/{vue-ui-xy-CaEGEO6l.js → vue-ui-xy-DYzfiZnJ.js} +15 -16
  152. package/dist/{vue-ui-xy-canvas-CrU_aS7K.cjs → vue-ui-xy-canvas-CkB7VDhF.cjs} +1 -1
  153. package/dist/{vue-ui-xy-canvas-DBWb4s2q.js → vue-ui-xy-canvas-DqnK_i0Q.js} +11 -11
  154. package/package.json +1 -1
  155. package/dist/index-Cww7pocd.cjs +0 -9
  156. package/dist/vue-ui-sparkhistogram-BN2N7qor.cjs +0 -1
  157. package/dist/vue-ui-sparkline-BmaYIS-1.cjs +0 -1
  158. package/dist/vue-ui-sparkstackbar-hxwlugf0.cjs +0 -1
  159. package/dist/vue-ui-thermometer-DCv2Gvg0.cjs +0 -1
  160. package/dist/vue-ui-vertical-bar-C-liaL8N.cjs +0 -4
  161. package/dist/vue-ui-wheel-CIHLvNK5.cjs +0 -1
  162. package/dist/vue-ui-wheel-tsJlAaV1.js +0 -319
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-Cww7pocd.cjs"),Z=require("./usePrinter-DY6H-UkT.cjs"),be=require("./vue-ui-skeleton-DkW8eWHI.cjs"),ge=require("./BaseIcon-BOR1UXkg.cjs"),ke=require("./vue-ui-accordion-D3UeWj9q.cjs"),ee=require("./useNestedProp-BzGIy5aD.cjs"),_e=require("./PackageVersion-2gojTmrp.cjs"),xe=require("./PenAndPaper-Bwxr_PKm.cjs"),Be=require("./useUserOptionState-BgepsfED.cjs"),Ee=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ne=["id"],Se={key:1,ref:"noTitle",class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},Ce=["xmlns","viewBox"],we=["width","height"],ze={key:1},Ve=["fill","font-weight","font-size","x","y"],$e=["fill","font-weight","font-size","x","y"],Te=["id"],Fe=["stop-color"],Le=["stop-color"],De=["id"],Oe=["stop-color"],Pe=["stop-color"],Me=["id"],Ie=["stop-color"],Re=["stop-color"],Xe=["stop-color"],Ae=["id"],je=["stop-color"],Ge=["stop-color"],Ue=["stop-color"],qe=["id"],Ye=["stop-color"],He=["stop-color"],We=["stop-color"],Ke={key:2},Je=["x","y","font-size","font-weight","fill"],Qe=["x","y","font-size","font-weight","fill"],Ze=["d","stroke"],et=["cx","cy","r","fill"],tt=["cx","cy","r","fill","stroke","stroke-width","onClick"],lt={key:3},at=["x","y","font-size","fill","onClick"],ot={key:0},nt=["x","y","fill","font-size","font-weight"],rt=["x","y","height","width","fill","rx","onClick"],st=["x","y","height","width","fill","rx","stroke","stroke-width","onClick"],ut={key:4},ct=["x","y","fill","font-size","onClick"],it=["d","stroke"],dt=["fill","cx","cy","r","onClick"],yt={key:5},vt=["x","y","font-size","font-weight","fill"],ht=["x1","x2","y1","y2","stroke","stroke-width"],pt=["y","height","width"],ft={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},mt={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},bt={viewBox:"0 0 20 20",height:"16",width:"16"},gt=["fill"],kt={key:7},_t=["y","height","width"],xt={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},Bt={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},Et={viewBox:"0 0 20 20",height:"16",width:"16"},Nt=["fill"],St=["cx","cy","fill"],Ct=["d","stroke"],wt=["cx","cy","fill"],zt=["d","stroke"],Vt=["cx","cy","fill"],$t=["cx","cy","fill"],Tt=["x","y","fill","font-size","font-weight"],Ft=["x","y","fill","font-size","font-weight"],Lt=["x","text-anchor","y","fill","font-size"],Dt=["x","text-anchor","y","fill","font-size"],Ot=["x","text-anchor","y","fill","font-size"],Pt=["x","text-anchor","y","fill","font-size"],Mt=["x","text-anchor","y","fill","font-size"],It=["x","y","font-size","fill"],Rt=["x","y","font-size","fill"],Xt=["x","y","font-size","fill"],At={key:4,class:"vue-data-ui-watermark"},jt={key:6,ref:"source",dir:"auto"},Gt={style:{"padding-top":"36px",position:"relative"}},Ut={class:"vue-ui-data-table"},qt={key:0},Yt=["data-cell"],Ht={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Wt={key:0},Kt={key:1},Jt=["data-cell"],Qt={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Zt={key:0},el={key:1},tl=["data-cell"],ll={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},al={key:0},ol={key:1},nl=["data-cell"],rl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},sl={key:0},ul={key:1},cl=["data-cell"],il={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},dl={key:0},yl={key:1},vl=["data-cell"],hl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},pl={key:0},fl={key:1},ml=["data-cell"],bl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},gl={key:0},kl={key:1},_l=["data-cell"],xl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Bl=["data-cell"],El={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Nl=["data-cell"],Sl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Cl=["data-cell"],wl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},zl=["data-cell"],Vl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},$l={__name:"vue-ui-chestnut",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectRoot","selectBranch","selectNut"],setup(te,{expose:le,emit:ae}){e.useCssVars(a=>({a946cfe6:a.tdo}));const{vue_ui_chestnut:oe}=o.useConfig(),k=te,z=e.computed(()=>!!k.dataset&&k.dataset.length),h=e.ref(o.createUid()),T=e.ref(null),ne=e.ref(null),I=e.ref(0),t=e.computed({get:()=>A(),set:a=>a}),{userOptionsVisible:F,setUserOptionsVisibility:R,keepUserOptionState:X}=Be.useUserOptionState({config:t.value});function A(){const a=ee.useNestedProp({userConfig:k.config,defaultConfig:oe});return a.theme?{...ee.useNestedProp({userConfig:o.themes.vue_ui_chestnut[a.theme]||k.config,defaultConfig:a}),customPalette:o.themePalettes[a.theme]||o.palette}:a}e.watch(()=>k.config,a=>{t.value=A(),F.value=!t.value.userOptions.showOnChartHover,S.value.showTable=t.value.table.show,K()},{deep:!0});const{isPrinting:j,isImaging:G,generatePdf:U,generateImage:q}=Z.usePrinter({elementId:`vue-ui-chestnut_${h.value}`,fileName:t.value.style.chart.layout.title.text||"vue-ui-chestnut"}),re=e.computed(()=>t.value.userOptions.show),L=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),S=e.ref({showTable:t.value.table.show}),D=e.ref(null),Y=e.ref(!1),se=e.computed(()=>t.value.table.responsiveBreakpoint),r=e.ref({gap:6,padding:{top:102,left:12,right:12,bottom:96},width:1024,height:0,branchSize:32,branchStart:128}),f=e.computed(()=>({left:r.value.padding.left,top:r.value.padding.top,right:r.value.width-r.value.padding.right,bottom:r.value.height-r.value.padding.bottom,width:r.value.width-(r.value.padding.left+r.value.padding.right),height:r.value.height-(r.value.padding.top+r.value.padding.bottom),seedX:r.value.padding.left+64})),_=e.computed(()=>z.value?k.dataset.flatMap(a=>(a.branches||[]).map(s=>s.value||0)).reduce((a,s)=>a+s,0):0),m=e.computed(()=>(k.dataset.forEach((a,s)=>{o.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","branches"]}).forEach(l=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:l,index:s})}),a.branches&&a.branches.forEach((l,n)=>{o.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","value"]}).forEach(d=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:d,index:`${s} - ${n}`})}),l.breakdown&&l.breakdown.forEach((d,i)=>{o.getMissingDatasetAttributes({datasetObject:d,requiredAttributes:["name","value"]}).forEach(y=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:y,index:`${s} - ${n} - ${i}`})})})})}),k.dataset.map((a,s)=>{const l=(a.branches||[]).map(n=>n.value||0).reduce((n,d)=>n+d,0);return{...a,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],id:a.id||`root_${s}_${h.value}`,type:"root",total:l,rootIndex:s,branches:(a.branches||[]).map((n,d)=>({...n,rootName:a.name,rootIndex:s,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],value:n.value>=0?n.value:0,id:n.id||`branch_${s}_${d}_${h.value}`,proportionToRoot:n.value/l,type:"branch",breakdown:(n.breakdown||[]).map((i,y)=>({table:{rootName:a.name,rootValue:l,rootToTotal:l/_.value,branchName:n.name,branchValue:n.value,branchToTotal:n.value/_.value,branchToRoot:n.value/l,nutName:i.name,nutValue:i.value,nutToTotal:i.value/_.value,nutToRoot:i.value/l,nutToBranch:i.value/n.value},...i,type:"nut",branchName:n.name,rootName:a.name,branchTotal:n.value>=0?n.value:0,proportionToBranch:i.value/n.value,proportionToRoot:i.value/l,proportionToTree:i.value/_.value,rootIndex:s,id:i.id||`nut_${s}_${d}_${y}_${h.value}`,color:o.convertColorToHex(i.color)||L.value[y]||o.palette[y]||o.palette[y%o.palette.length],value:i.value>=0?i.value:0}))}))}})));function ue(){return m.value}const C=ae,ce=e.computed(()=>m.value.flatMap(a=>a.branches).length),ie=e.computed(()=>Math.max(...m.value.map(a=>a.branches.map(s=>s.value).reduce((s,l)=>s+l,0)))),de=e.computed(()=>Math.max(...m.value.flatMap(a=>a.branches.map(s=>s.value)))),H=e.computed(()=>256+r.value.padding.left),B=e.computed(()=>m.value.sort((a,s)=>s.total-a.total).map((a,s)=>{const l=f.value.height/m.value.length/2,n=a.total/ie.value*(l>64?64:l);return{...a,x:f.value.seedX,y:f.value.top+f.value.height/m.value.length*(s+1)-(f.value.height/m.value.length/2+r.value.gap/2),r:n<r.value.branchSize/2?r.value.branchSize/2:n}})),ye=e.computed(()=>t.value.style.chart.layout.branches.widthRatio<=0?.1:t.value.style.chart.layout.branches.widthRatio>1.8?1.8:t.value.style.chart.layout.branches.widthRatio),ve=e.computed(()=>B.value.flatMap(a=>a.branches)),E=e.computed(()=>ve.value.sort((a,s)=>s.value-a.value).map((a,s)=>({...a,y1:s*r.value.branchSize+f.value.top+s*r.value.gap,y2:s*r.value.branchSize+r.value.branchSize,x1:H.value,x2:384*a.value/de.value*ye.value+H.value})));function O(a){const s=B.value.find(l=>l.rootIndex===a.rootIndex);return{x:s.x,y:s.y,r:s.r}}const u=e.ref(null),x=e.ref(null),v=e.ref(null),b=e.ref(null);function p(){u.value=null,v.value=null,b.value=null}function g(a){return b.value?b.value===null?!0:a.type==="root"?a.id===b.value.id:a.rootIndex===b.value.rootIndex:u.value===null&&v.value===null?!0:a.type==="nut"?u.value.id===a.id:a.type==="branch"?v.value.id===a.id:a.type==="root"?v.value&&v.value.rootIndex===a.rootIndex||u.value&&u.value.rootIndex===a.rootIndex:!1}function he(a){p(),e.nextTick(()=>{u.value=a,v.value=a,x.value=o.makeDonut({series:a.breakdown,base:1},a.x2+24+t.value.style.chart.layout.nuts.offsetX,a.y1+r.value.branchSize/2,80,80),C("selectNut",a.breakdown)})}function N(){u.value=null,x.value=null,C("selectNut",null)}function P(a){v.value&&v.value.id===a.id?(v.value=null,p(),C("selectBranch",null)):(p(),v.value=a,C("selectBranch",a))}function W(a){b.value&&b.value.id===a.id?(p(),C("selectRoot",null)):(p(),b.value=a,C("selectRoot",a))}function pe(){return f.value.bottom-(u.value.y1+180)<0?0:f.value.bottom}function w(a){return a.proportion*100>t.value.style.chart.layout.nuts.selected.labels.dataLabels.hideUnderValue}function fe(){const a=new ResizeObserver(s=>{s.forEach(l=>{Y.value=l.contentRect.width<se.value})});D.value&&a.observe(D.value)}e.onMounted(()=>{K()});function K(){o.objectIsEmpty(k.dataset)&&o.error({componentName:"VueUiChestnut",type:"dataset"});const a=ce.value*(r.value.branchSize+r.value.gap)+r.value.padding.top+r.value.padding.bottom;r.value.height=a,fe()}const c=e.computed(()=>{const a=[t.value.table.th.translations.rootName,t.value.table.th.translations.rootValue,t.value.table.th.translations.rootToTotal,t.value.table.th.translations.branchName,t.value.table.th.translations.branchValue,t.value.table.th.translations.branchToRoot,t.value.table.th.translations.branchToTotal,t.value.table.th.translations.nutName,t.value.table.th.translations.nutValue,t.value.table.th.translations.nutToBranch,t.value.table.th.translations.nutToRoot,t.value.table.th.translations.nutToTotal],s=m.value.flatMap((l,n)=>l.branches.flatMap((d,i)=>d.breakdown.flatMap((y,Fl)=>y.table)));return{head:a,body:s}});function J(){e.nextTick(()=>{const a=[[t.value.style.chart.layout.title.text],[t.value.style.chart.layout.title.subtitle.text],[""],["Grand total",_.value],[""]],s=c.value.head,l=c.value.body.map((i,y)=>[c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootName,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootValue,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootToTotal,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchName,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchValue,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToRoot,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToTotal,i.nutName,i.nutValue,i.nutToBranch,i.nutToRoot,i.nutToTotal]),n=a.concat([s]).concat(l),d=o.createCsvContent(n);o.downloadCsv({csvContent:d,title:t.value.style.chart.layout.title.text||"vue-ui-chestnut"})})}const V=e.ref(!1);function me(a){V.value=a,I.value+=1}function Q(){S.value.showTable=!S.value.showTable}const $=e.ref(!1);function M(){$.value=!$.value}return le({getData:ue,generatePdf:U,generateCsv:J,generateImage:q,toggleTable:Q,toggleAnnotator:M}),(a,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-chestnut ${V.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"chestnutChart",ref:T,id:`vue-ui-chestnut_${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:s[2]||(s[2]=()=>e.unref(R)(!0)),onMouseleave:s[3]||(s[3]=()=>e.unref(R)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(xe.PenAndPaper,{key:0,parent:T.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:$.value,onClose:M},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),re.value?(e.openBlock(),e.createElementBlock("div",Se,null,512)):e.createCommentVNode("",!0),t.value.userOptions.show&&z.value&&(e.unref(X)||e.unref(F))?(e.openBlock(),e.createBlock(Z.UserOptions,{ref_key:"details",ref:ne,key:`user_options_${I.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(G),isPrinting:e.unref(j),uid:h.value,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:V.value,titles:{...t.value.userOptions.buttonTitles},chartElement:T.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:$.value,onToggleFullscreen:me,onGeneratePdf:e.unref(U),onGenerateCsv:J,onGenerateImage:e.unref(q),onToggleTable:Q,onToggleAnnotator:M,style:e.normalizeStyle({visibility:e.unref(X)?e.unref(F)?"visible":"hidden":"visible"})},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.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,a.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,a.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,a.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:n})=>[e.renderSlot(a.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:n})),void 0,!0)]),key:"4"}:void 0,a.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:l,isAnnotator:n})=>[e.renderSlot(a.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:l,isAnnotator:n})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),r.value.height>0&&z.value?(e.openBlock(),e.createElementBlock("svg",{key:3,xmlns:e.unref(o.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":V.value,"vue-data-ui-fulscreen--off":!V.value}),viewBox:`0 0 ${r.value.width<=0?10:r.value.width} ${r.value.height<=0?10:r.value.height}`,style:e.normalizeStyle(`overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(_e._sfc_main),a.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:r.value.width<=0?10:r.value.width,height:r.value.height<=0?10:r.value.height,style:{pointerEvents:"none"}},[e.renderSlot(a.$slots,"chart-background",{},void 0,!0)],8,we)):e.createCommentVNode("",!0),u.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("g",ze,[t.value.style.chart.layout.title.text?(e.openBlock(),e.createElementBlock("text",{key:0,"text-anchor":"middle",fill:t.value.style.chart.layout.title.color,"font-weight":t.value.style.chart.layout.title.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.fontSize,x:r.value.width/2,y:12+t.value.style.chart.layout.title.fontSize+t.value.style.chart.layout.title.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.text),9,Ve)):e.createCommentVNode("",!0),t.value.style.chart.layout.title.subtitle.text?(e.openBlock(),e.createElementBlock("text",{key:1,"text-anchor":"middle",fill:t.value.style.chart.layout.title.subtitle.color,"font-weight":t.value.style.chart.layout.title.subtitle.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.subtitle.fontSize,x:r.value.width/2,y:48+t.value.style.chart.layout.title.subtitle.fontSize+t.value.style.chart.layout.title.subtitle.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.subtitle.text),9,$e)):e.createCommentVNode("",!0)])),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(l,n)=>(e.openBlock(),e.createElementBlock("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`root_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.05),100-t.value.style.chart.layout.roots.gradientIntensity)},null,8,Fe),e.createElementVNode("stop",{offset:"100%","stop-color":l.color},null,8,Le)],8,Te))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,l=>(e.openBlock(),e.createElementBlock("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`branch_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":l.color},null,8,Oe),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.02),100-t.value.style.chart.layout.branches.gradientIntensity)},null,8,Pe)],8,De))),256)),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nutpick_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ie),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.selected.gradientIntensity)},null,8,Re),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Xe)],8,Me),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,je),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.gradientIntensity)},null,8,Ge),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ue)],8,Ae),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_underlayer_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,100)},null,8,Ye),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,60)},null,8,He),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,0)},null,8,We)],8,qe)]),t.value.style.chart.layout.grandTotal.show?(e.openBlock(),e.createElementBlock("g",Ke,[e.createElementVNode("text",{x:f.value.seedX,y:32+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(t.value.style.chart.layout.grandTotal.text),9,Je),e.createElementVNode("text",{x:f.value.seedX,y:38+t.value.style.chart.layout.grandTotal.fontSize+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.layout.grandTotal.formatter,_.value,e.unref(o.dataLabel)({p:t.value.style.chart.layout.grandTotal.prefix,v:_.value,s:t.value.style.chart.layout.grandTotal.suffix,r:t.value.style.chart.layout.grandTotal.roundingValue}))),9,Qe)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,l=>(e.openBlock(),e.createElementBlock("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value.branchSize,(n,d)=>(e.openBlock(),e.createElementBlock("path",{d:`M
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-kZKcQZM_.cjs"),Z=require("./usePrinter-DR42gTOS.cjs"),be=require("./vue-ui-skeleton-BBNX7lud.cjs"),ge=require("./BaseIcon-COe_H-UB.cjs"),ke=require("./vue-ui-accordion-BfDu7hTY.cjs"),ee=require("./useNestedProp-D4Jn2Oxr.cjs"),_e=require("./PackageVersion-qeLvq6l8.cjs"),xe=require("./PenAndPaper-BYqaxOpk.cjs"),Be=require("./useUserOptionState-BgepsfED.cjs"),Ee=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ne=["id"],Se={key:1,ref:"noTitle",class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},Ce=["xmlns","viewBox"],we=["width","height"],ze={key:1},Ve=["fill","font-weight","font-size","x","y"],$e=["fill","font-weight","font-size","x","y"],Te=["id"],Fe=["stop-color"],Le=["stop-color"],De=["id"],Oe=["stop-color"],Pe=["stop-color"],Me=["id"],Ie=["stop-color"],Re=["stop-color"],Xe=["stop-color"],Ae=["id"],je=["stop-color"],Ge=["stop-color"],Ue=["stop-color"],qe=["id"],Ye=["stop-color"],He=["stop-color"],We=["stop-color"],Ke={key:2},Je=["x","y","font-size","font-weight","fill"],Qe=["x","y","font-size","font-weight","fill"],Ze=["d","stroke"],et=["cx","cy","r","fill"],tt=["cx","cy","r","fill","stroke","stroke-width","onClick"],lt={key:3},at=["x","y","font-size","fill","onClick"],ot={key:0},nt=["x","y","fill","font-size","font-weight"],rt=["x","y","height","width","fill","rx","onClick"],st=["x","y","height","width","fill","rx","stroke","stroke-width","onClick"],ut={key:4},ct=["x","y","fill","font-size","onClick"],it=["d","stroke"],dt=["fill","cx","cy","r","onClick"],yt={key:5},vt=["x","y","font-size","font-weight","fill"],ht=["x1","x2","y1","y2","stroke","stroke-width"],pt=["y","height","width"],ft={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},mt={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},bt={viewBox:"0 0 20 20",height:"16",width:"16"},gt=["fill"],kt={key:7},_t=["y","height","width"],xt={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},Bt={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},Et={viewBox:"0 0 20 20",height:"16",width:"16"},Nt=["fill"],St=["cx","cy","fill"],Ct=["d","stroke"],wt=["cx","cy","fill"],zt=["d","stroke"],Vt=["cx","cy","fill"],$t=["cx","cy","fill"],Tt=["x","y","fill","font-size","font-weight"],Ft=["x","y","fill","font-size","font-weight"],Lt=["x","text-anchor","y","fill","font-size"],Dt=["x","text-anchor","y","fill","font-size"],Ot=["x","text-anchor","y","fill","font-size"],Pt=["x","text-anchor","y","fill","font-size"],Mt=["x","text-anchor","y","fill","font-size"],It=["x","y","font-size","fill"],Rt=["x","y","font-size","fill"],Xt=["x","y","font-size","fill"],At={key:4,class:"vue-data-ui-watermark"},jt={key:6,ref:"source",dir:"auto"},Gt={style:{"padding-top":"36px",position:"relative"}},Ut={class:"vue-ui-data-table"},qt={key:0},Yt=["data-cell"],Ht={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Wt={key:0},Kt={key:1},Jt=["data-cell"],Qt={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Zt={key:0},el={key:1},tl=["data-cell"],ll={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},al={key:0},ol={key:1},nl=["data-cell"],rl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},sl={key:0},ul={key:1},cl=["data-cell"],il={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},dl={key:0},yl={key:1},vl=["data-cell"],hl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},pl={key:0},fl={key:1},ml=["data-cell"],bl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},gl={key:0},kl={key:1},_l=["data-cell"],xl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Bl=["data-cell"],El={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Nl=["data-cell"],Sl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Cl=["data-cell"],wl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},zl=["data-cell"],Vl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},$l={__name:"vue-ui-chestnut",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectRoot","selectBranch","selectNut"],setup(te,{expose:le,emit:ae}){e.useCssVars(a=>({a946cfe6:a.tdo}));const{vue_ui_chestnut:oe}=o.useConfig(),k=te,z=e.computed(()=>!!k.dataset&&k.dataset.length),h=e.ref(o.createUid()),T=e.ref(null),ne=e.ref(null),I=e.ref(0),t=e.computed({get:()=>A(),set:a=>a}),{userOptionsVisible:F,setUserOptionsVisibility:R,keepUserOptionState:X}=Be.useUserOptionState({config:t.value});function A(){const a=ee.useNestedProp({userConfig:k.config,defaultConfig:oe});return a.theme?{...ee.useNestedProp({userConfig:o.themes.vue_ui_chestnut[a.theme]||k.config,defaultConfig:a}),customPalette:o.themePalettes[a.theme]||o.palette}:a}e.watch(()=>k.config,a=>{t.value=A(),F.value=!t.value.userOptions.showOnChartHover,S.value.showTable=t.value.table.show,K()},{deep:!0});const{isPrinting:j,isImaging:G,generatePdf:U,generateImage:q}=Z.usePrinter({elementId:`vue-ui-chestnut_${h.value}`,fileName:t.value.style.chart.layout.title.text||"vue-ui-chestnut"}),re=e.computed(()=>t.value.userOptions.show),L=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),S=e.ref({showTable:t.value.table.show}),D=e.ref(null),Y=e.ref(!1),se=e.computed(()=>t.value.table.responsiveBreakpoint),r=e.ref({gap:6,padding:{top:102,left:12,right:12,bottom:96},width:1024,height:0,branchSize:32,branchStart:128}),f=e.computed(()=>({left:r.value.padding.left,top:r.value.padding.top,right:r.value.width-r.value.padding.right,bottom:r.value.height-r.value.padding.bottom,width:r.value.width-(r.value.padding.left+r.value.padding.right),height:r.value.height-(r.value.padding.top+r.value.padding.bottom),seedX:r.value.padding.left+64})),_=e.computed(()=>z.value?k.dataset.flatMap(a=>(a.branches||[]).map(s=>s.value||0)).reduce((a,s)=>a+s,0):0),m=e.computed(()=>(k.dataset.forEach((a,s)=>{o.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","branches"]}).forEach(l=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:l,index:s})}),a.branches&&a.branches.forEach((l,n)=>{o.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","value"]}).forEach(d=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:d,index:`${s} - ${n}`})}),l.breakdown&&l.breakdown.forEach((d,i)=>{o.getMissingDatasetAttributes({datasetObject:d,requiredAttributes:["name","value"]}).forEach(y=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:y,index:`${s} - ${n} - ${i}`})})})})}),k.dataset.map((a,s)=>{const l=(a.branches||[]).map(n=>n.value||0).reduce((n,d)=>n+d,0);return{...a,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],id:a.id||`root_${s}_${h.value}`,type:"root",total:l,rootIndex:s,branches:(a.branches||[]).map((n,d)=>({...n,rootName:a.name,rootIndex:s,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],value:n.value>=0?n.value:0,id:n.id||`branch_${s}_${d}_${h.value}`,proportionToRoot:n.value/l,type:"branch",breakdown:(n.breakdown||[]).map((i,y)=>({table:{rootName:a.name,rootValue:l,rootToTotal:l/_.value,branchName:n.name,branchValue:n.value,branchToTotal:n.value/_.value,branchToRoot:n.value/l,nutName:i.name,nutValue:i.value,nutToTotal:i.value/_.value,nutToRoot:i.value/l,nutToBranch:i.value/n.value},...i,type:"nut",branchName:n.name,rootName:a.name,branchTotal:n.value>=0?n.value:0,proportionToBranch:i.value/n.value,proportionToRoot:i.value/l,proportionToTree:i.value/_.value,rootIndex:s,id:i.id||`nut_${s}_${d}_${y}_${h.value}`,color:o.convertColorToHex(i.color)||L.value[y]||o.palette[y]||o.palette[y%o.palette.length],value:i.value>=0?i.value:0}))}))}})));function ue(){return m.value}const C=ae,ce=e.computed(()=>m.value.flatMap(a=>a.branches).length),ie=e.computed(()=>Math.max(...m.value.map(a=>a.branches.map(s=>s.value).reduce((s,l)=>s+l,0)))),de=e.computed(()=>Math.max(...m.value.flatMap(a=>a.branches.map(s=>s.value)))),H=e.computed(()=>256+r.value.padding.left),B=e.computed(()=>m.value.sort((a,s)=>s.total-a.total).map((a,s)=>{const l=f.value.height/m.value.length/2,n=a.total/ie.value*(l>64?64:l);return{...a,x:f.value.seedX,y:f.value.top+f.value.height/m.value.length*(s+1)-(f.value.height/m.value.length/2+r.value.gap/2),r:n<r.value.branchSize/2?r.value.branchSize/2:n}})),ye=e.computed(()=>t.value.style.chart.layout.branches.widthRatio<=0?.1:t.value.style.chart.layout.branches.widthRatio>1.8?1.8:t.value.style.chart.layout.branches.widthRatio),ve=e.computed(()=>B.value.flatMap(a=>a.branches)),E=e.computed(()=>ve.value.sort((a,s)=>s.value-a.value).map((a,s)=>({...a,y1:s*r.value.branchSize+f.value.top+s*r.value.gap,y2:s*r.value.branchSize+r.value.branchSize,x1:H.value,x2:384*a.value/de.value*ye.value+H.value})));function O(a){const s=B.value.find(l=>l.rootIndex===a.rootIndex);return{x:s.x,y:s.y,r:s.r}}const u=e.ref(null),x=e.ref(null),v=e.ref(null),b=e.ref(null);function p(){u.value=null,v.value=null,b.value=null}function g(a){return b.value?b.value===null?!0:a.type==="root"?a.id===b.value.id:a.rootIndex===b.value.rootIndex:u.value===null&&v.value===null?!0:a.type==="nut"?u.value.id===a.id:a.type==="branch"?v.value.id===a.id:a.type==="root"?v.value&&v.value.rootIndex===a.rootIndex||u.value&&u.value.rootIndex===a.rootIndex:!1}function he(a){p(),e.nextTick(()=>{u.value=a,v.value=a,x.value=o.makeDonut({series:a.breakdown,base:1},a.x2+24+t.value.style.chart.layout.nuts.offsetX,a.y1+r.value.branchSize/2,80,80),C("selectNut",a.breakdown)})}function N(){u.value=null,x.value=null,C("selectNut",null)}function P(a){v.value&&v.value.id===a.id?(v.value=null,p(),C("selectBranch",null)):(p(),v.value=a,C("selectBranch",a))}function W(a){b.value&&b.value.id===a.id?(p(),C("selectRoot",null)):(p(),b.value=a,C("selectRoot",a))}function pe(){return f.value.bottom-(u.value.y1+180)<0?0:f.value.bottom}function w(a){return a.proportion*100>t.value.style.chart.layout.nuts.selected.labels.dataLabels.hideUnderValue}function fe(){const a=new ResizeObserver(s=>{s.forEach(l=>{Y.value=l.contentRect.width<se.value})});D.value&&a.observe(D.value)}e.onMounted(()=>{K()});function K(){o.objectIsEmpty(k.dataset)&&o.error({componentName:"VueUiChestnut",type:"dataset"});const a=ce.value*(r.value.branchSize+r.value.gap)+r.value.padding.top+r.value.padding.bottom;r.value.height=a,fe()}const c=e.computed(()=>{const a=[t.value.table.th.translations.rootName,t.value.table.th.translations.rootValue,t.value.table.th.translations.rootToTotal,t.value.table.th.translations.branchName,t.value.table.th.translations.branchValue,t.value.table.th.translations.branchToRoot,t.value.table.th.translations.branchToTotal,t.value.table.th.translations.nutName,t.value.table.th.translations.nutValue,t.value.table.th.translations.nutToBranch,t.value.table.th.translations.nutToRoot,t.value.table.th.translations.nutToTotal],s=m.value.flatMap((l,n)=>l.branches.flatMap((d,i)=>d.breakdown.flatMap((y,Fl)=>y.table)));return{head:a,body:s}});function J(){e.nextTick(()=>{const a=[[t.value.style.chart.layout.title.text],[t.value.style.chart.layout.title.subtitle.text],[""],["Grand total",_.value],[""]],s=c.value.head,l=c.value.body.map((i,y)=>[c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootName,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootValue,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootToTotal,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchName,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchValue,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToRoot,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToTotal,i.nutName,i.nutValue,i.nutToBranch,i.nutToRoot,i.nutToTotal]),n=a.concat([s]).concat(l),d=o.createCsvContent(n);o.downloadCsv({csvContent:d,title:t.value.style.chart.layout.title.text||"vue-ui-chestnut"})})}const V=e.ref(!1);function me(a){V.value=a,I.value+=1}function Q(){S.value.showTable=!S.value.showTable}const $=e.ref(!1);function M(){$.value=!$.value}return le({getData:ue,generatePdf:U,generateCsv:J,generateImage:q,toggleTable:Q,toggleAnnotator:M}),(a,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-chestnut ${V.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"chestnutChart",ref:T,id:`vue-ui-chestnut_${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:s[2]||(s[2]=()=>e.unref(R)(!0)),onMouseleave:s[3]||(s[3]=()=>e.unref(R)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(xe.PenAndPaper,{key:0,parent:T.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:$.value,onClose:M},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),re.value?(e.openBlock(),e.createElementBlock("div",Se,null,512)):e.createCommentVNode("",!0),t.value.userOptions.show&&z.value&&(e.unref(X)||e.unref(F))?(e.openBlock(),e.createBlock(Z.UserOptions,{ref_key:"details",ref:ne,key:`user_options_${I.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(G),isPrinting:e.unref(j),uid:h.value,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:V.value,titles:{...t.value.userOptions.buttonTitles},chartElement:T.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:$.value,onToggleFullscreen:me,onGeneratePdf:e.unref(U),onGenerateCsv:J,onGenerateImage:e.unref(q),onToggleTable:Q,onToggleAnnotator:M,style:e.normalizeStyle({visibility:e.unref(X)?e.unref(F)?"visible":"hidden":"visible"})},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.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,a.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,a.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,a.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:n})=>[e.renderSlot(a.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:n})),void 0,!0)]),key:"4"}:void 0,a.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:l,isAnnotator:n})=>[e.renderSlot(a.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:l,isAnnotator:n})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),r.value.height>0&&z.value?(e.openBlock(),e.createElementBlock("svg",{key:3,xmlns:e.unref(o.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":V.value,"vue-data-ui-fulscreen--off":!V.value}),viewBox:`0 0 ${r.value.width<=0?10:r.value.width} ${r.value.height<=0?10:r.value.height}`,style:e.normalizeStyle(`overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(_e._sfc_main),a.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:r.value.width<=0?10:r.value.width,height:r.value.height<=0?10:r.value.height,style:{pointerEvents:"none"}},[e.renderSlot(a.$slots,"chart-background",{},void 0,!0)],8,we)):e.createCommentVNode("",!0),u.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("g",ze,[t.value.style.chart.layout.title.text?(e.openBlock(),e.createElementBlock("text",{key:0,"text-anchor":"middle",fill:t.value.style.chart.layout.title.color,"font-weight":t.value.style.chart.layout.title.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.fontSize,x:r.value.width/2,y:12+t.value.style.chart.layout.title.fontSize+t.value.style.chart.layout.title.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.text),9,Ve)):e.createCommentVNode("",!0),t.value.style.chart.layout.title.subtitle.text?(e.openBlock(),e.createElementBlock("text",{key:1,"text-anchor":"middle",fill:t.value.style.chart.layout.title.subtitle.color,"font-weight":t.value.style.chart.layout.title.subtitle.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.subtitle.fontSize,x:r.value.width/2,y:48+t.value.style.chart.layout.title.subtitle.fontSize+t.value.style.chart.layout.title.subtitle.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.subtitle.text),9,$e)):e.createCommentVNode("",!0)])),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(l,n)=>(e.openBlock(),e.createElementBlock("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`root_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.05),100-t.value.style.chart.layout.roots.gradientIntensity)},null,8,Fe),e.createElementVNode("stop",{offset:"100%","stop-color":l.color},null,8,Le)],8,Te))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,l=>(e.openBlock(),e.createElementBlock("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`branch_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":l.color},null,8,Oe),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.02),100-t.value.style.chart.layout.branches.gradientIntensity)},null,8,Pe)],8,De))),256)),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nutpick_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ie),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.selected.gradientIntensity)},null,8,Re),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Xe)],8,Me),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,je),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.gradientIntensity)},null,8,Ge),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ue)],8,Ae),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_underlayer_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,100)},null,8,Ye),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,60)},null,8,He),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,0)},null,8,We)],8,qe)]),t.value.style.chart.layout.grandTotal.show?(e.openBlock(),e.createElementBlock("g",Ke,[e.createElementVNode("text",{x:f.value.seedX,y:32+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(t.value.style.chart.layout.grandTotal.text),9,Je),e.createElementVNode("text",{x:f.value.seedX,y:38+t.value.style.chart.layout.grandTotal.fontSize+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.layout.grandTotal.formatter,_.value,e.unref(o.dataLabel)({p:t.value.style.chart.layout.grandTotal.prefix,v:_.value,s:t.value.style.chart.layout.grandTotal.suffix,r:t.value.style.chart.layout.grandTotal.roundingValue}))),9,Qe)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,l=>(e.openBlock(),e.createElementBlock("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value.branchSize,(n,d)=>(e.openBlock(),e.createElementBlock("path",{d:`M
2
2
  ${l.x1},${l.y1+d}
3
3
  C${l.x1-20},${l.y1+d}
4
4
  ${l.x1-80},${l.y1+d}
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-Cww7pocd.cjs"),fe=require("./useNestedProp-BzGIy5aD.cjs"),me=require("./usePrinter-DY6H-UkT.cjs"),Ie=require("./Title-vXH_7MPz.cjs"),Me=require("./PenAndPaper-Bwxr_PKm.cjs"),De=require("./useUserOptionState-BgepsfED.cjs"),_e=require("./PackageVersion-2gojTmrp.cjs"),Ae=require("./vue-ui-accordion-D3UeWj9q.cjs"),Le=require("./DataTable-C1LMti1U.cjs"),Re=require("./vue-ui-skeleton-DkW8eWHI.cjs"),qe=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ue=["id"],He=["xmlns","viewBox"],Ge=["x","y","width","height"],Ye=["id"],We=["stop-color"],Xe=["stop-color"],je=["stop-color"],Ze={key:0},Je=["x","y","width","height","stroke","stroke-width","fill","rx","onMouseenter","onClick"],Ke=["x","y","width","height","stroke","stroke-width","fill","rx"],Qe=["opacity","x","y","font-size","fill","font-weight"],et=["opacity","x","y","font-size","fill","font-weight"],tt=["d","fill"],lt=["cx","cy","r","opacity","stroke","fill"],at={key:0,style:{pointerEvents:"none"}},ot={key:1},rt=["opacity","x","y","font-size","fill","font-weight"],nt=["opacity","x","y","font-size","fill","font-weight"],st={key:6,class:"vue-data-ui-watermark"},ut=["innerHTML"],it={__name:"vue-ui-circle-pack",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectDatapoint"],setup(he,{expose:pe,emit:ye}){e.useCssVars(l=>({"6a0cf3f2":C.value,"5a6a5c6b":M.value}));const y=he,ke=ye,{vue_ui_circle_pack:ge}=r.useConfig(),$=e.computed(()=>!!y.dataset&&y.dataset.length),g=e.ref(r.createUid()),V=e.ref(null),be=e.ref(null),Ce=e.ref(null),H=e.ref(0),G=e.ref(0),Y=e.ref(0),xe=e.ref(null),t=e.computed({get:()=>j(),set:l=>l}),{userOptionsVisible:O,setUserOptionsVisibility:W,keepUserOptionState:X}=De.useUserOptionState({config:t.value});function j(){const l=fe.useNestedProp({userConfig:y.config,defaultConfig:ge});return l.theme?{...fe.useNestedProp({userConfig:r.themes.vue_ui_circle_pack[l.theme]||y.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>y.config,l=>{t.value=j(),O.value=!t.value.userOptions.showOnChartHover,F(),H.value+=1,G.value+=1,b.value.showTable=t.value.table.show},{deep:!0});const{isPrinting:Z,isImaging:J,generatePdf:K,generateImage:Q}=me.usePrinter({elementId:`vue-ui-circle-pack_${g.value}`,fileName:t.value.style.chart.title.text||"vue-ui-circle-pack"}),we=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),b=e.ref({showTable:t.value.table.show});async function F(){r.objectIsEmpty(y.dataset)&&r.error({componentName:"VueUiCirclePack",type:"dataset"}),await Se()}e.onMounted(F),e.watch(()=>y.dataset,async l=>{await F()},{deep:!0});const ee=e.computed(()=>r.convertCustomPalette(t.value.customPalette));function te(l,o){return Math.hypot(o.x-l.x,o.y-l.y)}function le(l,o){return o.some(a=>te(l,a)<l.radius+a.radius)}function Be(l,o,a,s){const c=o*2;for(let h of l)for(let p=0;p<360;p+=1){let z=p*Math.PI/180,i=h.x+c*Math.cos(z),n=h.y-c*Math.sin(z),m={x:i,y:n,radius:o};if(i-o>=0&&i+o<=a&&n-o>=0&&n+o<=s&&!le(m,l))return{x:i,y:n}}return null}function ze({datapoints:l,width:o,height:a,maxRadius:s,offsetX:c=0,offsetY:h=0}){const p=Math.max(...l.map(m=>m.value)),i=l.map((m,d)=>({...m,radius:m.value/p*s,index:d})).map((m,d)=>({...m,index:d})).toSorted((m,d)=>d.radius-m.radius);let n=[];n.push({...i[0],x:o/2+c,y:a/2+h});for(let m of i.slice(1)){let{radius:d,...ue}=m,A=Be(n,d,o,a);if(A)n.push({...ue,x:A.x,y:A.y,radius:d});else{let L=null,ie=1/0;for(let E of n)for(let R=0;R<360;R+=15){let ce=R*Math.PI/180,q=E.x+(d+E.radius)*Math.cos(ce),U=E.y+(d+E.radius)*Math.sin(ce),T={...ue,x:q,y:U,radius:d};if(q-d>=0&&q+d<=o&&U-d>=0&&U+d<=a&&!le(T,n)){let de=n.reduce((Fe,ve)=>Fe+(te(T,ve)<T.radius+ve.radius?1:0),0);de<ie&&(ie=de,L=T)}}L&&n.push(L)}}return n}const I=e.computed(()=>y.dataset.map((l,o)=>{const a=r.convertColorToHex(l.color)||ee.value[o]||r.themePalettes[t.value.theme||"default"][o%r.themePalettes[t.value.theme||"default"].length]||r.palette[o]||r.palette[o%r.palette.length];return{...l,id:r.createUid(),color:a}}).filter(l=>![null,void 0,1/0,-1/0].includes(l.value))),f=e.ref([]),$e=e.computed(()=>Math.max(...f.value.map(l=>l.radius)));function ae(l,o){return o/$e.value*l}async function Se(){f.value=ze({datapoints:I.value,width:1e4,height:1e4,maxRadius:32})}const oe=e.computed(()=>({width:100,height:100})),v=e.computed(()=>{const l=f.value.reduce((i,n)=>n.x-n.radius<i.x-i.radius?n:i,f.value[0]),o=f.value.reduce((i,n)=>n.y-n.radius<i.y-i.radius?n:i,f.value[0]),a=f.value.reduce((i,n)=>n.x+n.radius>i.x+i.radius?n:i,f.value[0]),s=f.value.reduce((i,n)=>n.y+n.radius>i.y+i.radius?n:i,f.value[0]),c=(l==null?void 0:l.x)||0,h=(a==null?void 0:a.x)||oe.value.width,p=(o==null?void 0:o.y)||0,z=(s==null?void 0:s.y)||oe.value.height;return{maxX:h,minX:c,width:Math.abs(h-c)+(l?l.radius:0)+(a?a.radius:0)+t.value.style.chart.circles.strokeWidth*4,height:Math.abs(z-p)+(o?o.radius:0)+(s?s.radius:0)+t.value.style.chart.circles.strokeWidth*4,x:l?(l==null?void 0:l.x)-(l==null?void 0:l.radius)-t.value.style.chart.circles.strokeWidth*2:0,y:o?(o==null?void 0:o.y)-(o==null?void 0:o.radius)-t.value.style.chart.circles.strokeWidth*2:0}}),Pe=e.computed(()=>f.value.map(l=>{if(l.breakdown)return r.makeDonut({series:l.breakdown.map((o,a)=>({...o,color:r.convertColorToHex(o.color)||ee.value[a]||r.palette[a]||r.palette[a%r.palette.length]}))},l.x,l.y,l.radius,l.radius,1.99999,2,1,360,105.25,l.radius/2)})),u=e.ref(null);function Ne(l){t.value.style.chart.circles.zoom.show&&(u.value=l)}const C=e.computed(()=>u.value?u.value.radius:0),M=e.computed(()=>u.value?u.value.radius>v.value.width/6*t.value.style.chart.circles.zoom.zoomRatio?u.value.radius:v.value.width/6*t.value.style.chart.circles.zoom.zoomRatio:0),k=e.ref(0),Ee=e.computed(()=>({pointerEvents:"none",opacity:k.value,filter:`drop-shadow(0px 0px 6px ${r.darkenHexColor(u.value.color,t.value.style.chart.circles.zoom.shadowForce)})`})),x=e.ref(C.value);e.watchEffect(()=>{x.value=C.value,k.value=0;let l=null;function o(a){l||(l=a);const s=(a-l)/t.value.style.chart.circles.zoom.animationFrameMs;s<1?(x.value=C.value+(M.value-C.value)*s,k.value=0+t.value.style.chart.circles.zoom.opacity*s,requestAnimationFrame(o)):(x.value=M.value,k.value=t.value.style.chart.circles.zoom.opacity)}requestAnimationFrame(o)});const w=e.computed(()=>({name:t.value.style.chart.circles.zoom.label.name.fontSize*v.value.width/300,value:t.value.style.chart.circles.zoom.label.value.fontSize*v.value.width/300}));function D(l){return r.applyDataLabel(t.value.style.chart.circles.labels.value.formatter,l.value,r.dataLabel({p:t.value.style.chart.circles.labels.value.prefix,v:l.value,s:t.value.style.chart.circles.labels.value.suffix,r:t.value.style.chart.circles.labels.value.rounding}))}function Te(){return r.applyDataLabel(t.value.style.chart.circles.zoom.label.value.formatter,u.value.value,r.dataLabel({p:t.value.style.chart.circles.zoom.label.value.prefix,v:u.value.value,s:t.value.style.chart.circles.zoom.label.value.suffix,r:t.value.style.chart.circles.zoom.label.value.rounding}))}function re(l){if(!l)return 0;const o=l.radius/D(l).length*(D(l).length===1?1:2);return Math.min(l.radius/2.5,o)}const B=e.ref(!1);function Ve(l){B.value=l,Y.value+=1}const S=e.ref(!1);function _(){S.value=!S.value}const P=e.computed(()=>{const l=I.value.map(a=>({name:a.name,value:a.value,color:a.color})).toSorted((a,s)=>s.value-a.value),o=l.map(a=>a.value);return{head:l,body:o}});function ne(){e.nextTick(()=>{const l=P.value.head.map((s,c)=>[[s.name],[P.value.body[c]]]),o=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],[t.value.table.columnNames.value]]].concat(l),a=r.createCsvContent(o);r.downloadCsv({csvContent:a,title:t.value.style.chart.title.text||"vue-ui-circle-pack"})})}const N=e.computed(()=>{const l=[t.value.table.columnNames.datapoint,t.value.table.columnNames.value],o=P.value.head.map((c,h)=>{const p=r.dataLabel({p:t.value.style.chart.circles.labels.value.prefix,v:P.value.body[h],s:t.value.style.chart.circles.labels.value.suffix,r:t.value.style.chart.circles.labels.value.rounding});return[{color:c.color,name:c.name},p]}),a={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};return{colNames:[t.value.table.columnNames.datapoint,t.value.table.columnNames.value],head:l,body:o,config:a}});function se(){b.value.showTable=!b.value.showTable}function Oe(){return I.value}return pe({getData:Oe,generateCsv:ne,generatePdf:K,generateImage:Q,toggleTable:se,toggleAnnotator:_}),(l,o)=>(e.openBlock(),e.createElementBlock("div",{id:`vue-ui-circle-pack_${g.value}`,class:e.normalizeClass(`vue-ui-circle-pack ${B.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"circlePackChart",ref:V,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:o[2]||(o[2]=()=>e.unref(W)(!0)),onMouseleave:o[3]||(o[3]=()=>e.unref(W)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(Me.PenAndPaper,{key:0,parent:V.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:S.value,onClose:_},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"userConfig",{},void 0,!0),we.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:Ce,class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},null,512)):e.createCommentVNode("",!0),t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:2,ref_key:"chartTitle",ref:be,style:"width:100%;background:transparent;padding-bottom:12px"},[(e.openBlock(),e.createBlock(Ie._sfc_main,{key:`title_${H.value}`,config:{title:{cy:"donut-div-title",...t.value.style.chart.title},subtitle:{cy:"donut-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&$.value&&(e.unref(X)||e.unref(O))?(e.openBlock(),e.createBlock(me.UserOptions,{ref:"details",key:`user_option_${Y.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(Z),isImaging:e.unref(J),uid:g.value,hasTooltip:!1,hasLabel:!1,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:B.value,chartElement:V.value,position:t.value.userOptions.position,titles:{...t.value.userOptions.buttonTitles},hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:S.value,onToggleFullscreen:Ve,onGeneratePdf:e.unref(K),onGenerateCsv:ne,onGenerateImage:e.unref(Q),onToggleTable:se,onToggleAnnotator:_,style:e.normalizeStyle({visibility:e.unref(X)?e.unref(O)?"visible":"hidden":"visible"})},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:a,isFullscreen:s})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:a,isFullscreen:s})),void 0,!0)]),key:"4"}:void 0,l.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:a,isAnnotator:s})=>[e.renderSlot(l.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:a,isAnnotator:s})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","chartElement","position","titles","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),$.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(r.XMLNS),viewBox:`${v.value.x} ${v.value.y} ${v.value.width} ${v.value.height}`,width:"100%",class:e.normalizeClass({"vue-data-ui-fullscreen--on":B.value,"vue-data-ui-fulscreen--off":!B.value}),style:e.normalizeStyle(`max-width:100%;overflow:visible;background:transparent;color:${t.value.style.chart.color};`)},[e.createVNode(_e._sfc_main),l.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:v.value.x,y:v.value.y,width:v.value.width,height:v.value.height,style:{pointerEvents:"none"}},[e.renderSlot(l.$slots,"chart-background",{},void 0,!0)],8,Ge)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,a=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{id:a.id,fy:"30%"},[e.createElementVNode("stop",{offset:"10%","stop-color":e.unref(r.lightenHexColor)(a.color,t.value.style.chart.circles.gradient.intensity/100)},null,8,We),e.createElementVNode("stop",{offset:"90%","stop-color":e.unref(r.darkenHexColor)(a.color,.1)},null,8,Xe),e.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,je)],8,Ye)]),l.$slots.pattern?(e.openBlock(),e.createElementBlock("g",Ze,[e.createElementVNode("defs",null,[e.renderSlot(l.$slots,"pattern",e.mergeProps({ref_for:!0},{...a,patternId:`pattern_${g.value}_${a.id}`}),void 0,!0)])])):e.createCommentVNode("",!0),e.createElementVNode("rect",{x:a.x-a.radius,y:a.y-a.radius,width:a.radius*2,height:a.radius*2,stroke:t.value.style.chart.circles.stroke,"stroke-width":t.value.style.chart.circles.strokeWidth,fill:t.value.style.chart.circles.gradient.show?`url(#${a.id})`:a.color,rx:a.radius,onMouseenter:()=>Ne(a),onMouseout:o[0]||(o[0]=s=>u.value=null),onClick:s=>ke("selectDatapoint",a)},null,40,Je),l.$slots.pattern?(e.openBlock(),e.createElementBlock("rect",{key:1,x:a.x-a.radius,y:a.y-a.radius,width:a.radius*2,height:a.radius*2,stroke:t.value.style.chart.circles.stroke,"stroke-width":t.value.style.chart.circles.strokeWidth,fill:`url(#pattern_${g.value}_${a.id})`,rx:a.radius,style:{pointerEvents:"none"}},null,8,Ke)):e.createCommentVNode("",!0),l.$slots["data-label"]?e.renderSlot(l.$slots,"data-label",e.mergeProps({key:2,ref_for:!0},{...a,createTSpans:e.unref(r.createTSpans),fontSize:{name:a.radius/3*t.value.style.chart.circles.labels.name.fontSizeRatio,value:re(a)*t.value.style.chart.circles.labels.value.fontSizeRatio},color:t.value.style.chart.circles.labels.name.color?t.value.style.chart.circles.labels.name.color:e.unref(r.adaptColorToBackground)(a.color)}),void 0,!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[t.value.style.chart.circles.labels.name.show&&a.name?(e.openBlock(),e.createElementBlock("text",{key:0,style:{pointerEvents:"none",transition:"opacity 0.2s ease-in-out"},opacity:u.value?.2:1,x:a.x,y:a.y+ae(a.radius,t.value.style.chart.circles.labels.name.offsetY)-a.radius/6,"font-size":a.radius/3*t.value.style.chart.circles.labels.name.fontSizeRatio,fill:t.value.style.chart.circles.labels.name.color?t.value.style.chart.circles.labels.name.color:e.unref(r.adaptColorToBackground)(a.color),"font-weight":t.value.style.chart.circles.labels.name.bold?"bold":"normal","text-anchor":"middle"},e.toDisplayString(a.name),9,Qe)):e.createCommentVNode("",!0),t.value.style.chart.circles.labels.value.show?(e.openBlock(),e.createElementBlock("text",{key:1,style:{pointerEvents:"none",transition:"opacity 0.2s ease-in-out"},opacity:u.value?.2:1,x:a.x,y:a.y+ae(a.radius,t.value.style.chart.circles.labels.value.offsetY)+a.radius/3,"font-size":re(a)*t.value.style.chart.circles.labels.value.fontSizeRatio,fill:t.value.style.chart.circles.labels.value.color?t.value.style.chart.circles.labels.value.color:e.unref(r.adaptColorToBackground)(a.color),"font-weight":t.value.style.chart.circles.labels.value.bold?"bold":"normal","text-anchor":"middle"},e.toDisplayString(D(a)),9,et)):e.createCommentVNode("",!0)],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Pe.value,s=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s,c=>(e.openBlock(),e.createElementBlock("path",{d:c.arcSlice,fill:c.color,stroke:"black"},null,8,tt))),256))],64))),256))],64))),256)),u.value&&t.value.style.chart.circles.zoom.show?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("circle",{style:e.normalizeStyle(Ee.value),cx:u.value.x,cy:u.value.y,r:x.value,opacity:k.value,stroke:t.value.style.chart.circles.stroke,fill:t.value.style.chart.circles.gradient.show?`url(#${u.value.id})`:u.value.color},null,12,lt),l.$slots["zoom-label"]?(e.openBlock(),e.createElementBlock("g",at,[e.renderSlot(l.$slots,"zoom-label",e.normalizeProps(e.guardReactiveProps({...u.value,zoomOpacity:k.value,currentRadius:x.value,fontSize:w.value})),void 0,!0)])):(e.openBlock(),e.createElementBlock("g",ot,[e.createElementVNode("text",{style:{pointerEvents:"none"},opacity:k.value,x:u.value.x,y:u.value.y+t.value.style.chart.circles.zoom.label.name.offsetY-w.value.name/4,"text-anchor":"middle","font-size":w.value.name,fill:t.value.style.chart.circles.zoom.label.name.color?t.value.style.chart.circles.zoom.label.name.color:e.unref(r.adaptColorToBackground)(u.value.color),"font-weight":t.value.style.chart.circles.zoom.label.name.bold?"bold":"normal"},e.toDisplayString(u.value.name),9,rt),e.createElementVNode("text",{style:{pointerEvents:"none"},opacity:k.value,x:u.value.x,y:u.value.y+w.value.value+t.value.style.chart.circles.zoom.label.value.offsetY,"text-anchor":"middle","font-size":w.value.value,fill:t.value.style.chart.circles.zoom.label.value.color?t.value.style.chart.circles.zoom.label.value.color:e.unref(r.adaptColorToBackground)(u.value.color),"font-weight":t.value.style.chart.circles.zoom.label.value.bold?"bold":"normal"},e.toDisplayString(Te()),9,nt)]))],64)):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"svg",{svg:{...v.value}},void 0,!0)],14,He)):e.createCommentVNode("",!0),$.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(Re.default,{key:5,config:{type:"circlePack",style:{color:"#CCCCCC"}}})),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",st,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(Z)||e.unref(J)})),void 0,!0)])):e.createCommentVNode("",!0),l.$slots.source?(e.openBlock(),e.createElementBlock("div",{key:7,ref_key:"source",ref:xe,dir:"auto"},[e.renderSlot(l.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),$.value?(e.openBlock(),e.createBlock(Ae.default,{key:8,hideDetails:"",config:{open:b.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:e.withCtx(()=>[(e.openBlock(),e.createBlock(Le.DataTable,{key:`table_${G.value}`,colNames:N.value.colNames,head:N.value.head,body:N.value.body,config:N.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:o[1]||(o[1]=a=>b.value.showTable=!1)},{th:e.withCtx(({th:a})=>[e.createElementVNode("div",{innerHTML:a,style:{display:"flex","align-items":"center"}},null,8,ut)]),td:e.withCtx(({td:a})=>[e.createTextVNode(e.toDisplayString(a.name||a),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],46,Ue))}},ct=qe._export_sfc(it,[["__scopeId","data-v-cbf5c72e"]]);exports.default=ct;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-kZKcQZM_.cjs"),fe=require("./useNestedProp-D4Jn2Oxr.cjs"),me=require("./usePrinter-DR42gTOS.cjs"),Ie=require("./Title-BGiQdt7J.cjs"),Me=require("./PenAndPaper-BYqaxOpk.cjs"),De=require("./useUserOptionState-BgepsfED.cjs"),_e=require("./PackageVersion-qeLvq6l8.cjs"),Ae=require("./vue-ui-accordion-BfDu7hTY.cjs"),Le=require("./DataTable-Du7nJ0TM.cjs"),Re=require("./vue-ui-skeleton-BBNX7lud.cjs"),qe=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ue=["id"],He=["xmlns","viewBox"],Ge=["x","y","width","height"],Ye=["id"],We=["stop-color"],Xe=["stop-color"],je=["stop-color"],Ze={key:0},Je=["x","y","width","height","stroke","stroke-width","fill","rx","onMouseenter","onClick"],Ke=["x","y","width","height","stroke","stroke-width","fill","rx"],Qe=["opacity","x","y","font-size","fill","font-weight"],et=["opacity","x","y","font-size","fill","font-weight"],tt=["d","fill"],lt=["cx","cy","r","opacity","stroke","fill"],at={key:0,style:{pointerEvents:"none"}},ot={key:1},rt=["opacity","x","y","font-size","fill","font-weight"],nt=["opacity","x","y","font-size","fill","font-weight"],st={key:6,class:"vue-data-ui-watermark"},ut=["innerHTML"],it={__name:"vue-ui-circle-pack",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectDatapoint"],setup(he,{expose:pe,emit:ye}){e.useCssVars(l=>({"6a0cf3f2":C.value,"5a6a5c6b":M.value}));const y=he,ke=ye,{vue_ui_circle_pack:ge}=r.useConfig(),$=e.computed(()=>!!y.dataset&&y.dataset.length),g=e.ref(r.createUid()),V=e.ref(null),be=e.ref(null),Ce=e.ref(null),H=e.ref(0),G=e.ref(0),Y=e.ref(0),xe=e.ref(null),t=e.computed({get:()=>j(),set:l=>l}),{userOptionsVisible:O,setUserOptionsVisibility:W,keepUserOptionState:X}=De.useUserOptionState({config:t.value});function j(){const l=fe.useNestedProp({userConfig:y.config,defaultConfig:ge});return l.theme?{...fe.useNestedProp({userConfig:r.themes.vue_ui_circle_pack[l.theme]||y.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>y.config,l=>{t.value=j(),O.value=!t.value.userOptions.showOnChartHover,F(),H.value+=1,G.value+=1,b.value.showTable=t.value.table.show},{deep:!0});const{isPrinting:Z,isImaging:J,generatePdf:K,generateImage:Q}=me.usePrinter({elementId:`vue-ui-circle-pack_${g.value}`,fileName:t.value.style.chart.title.text||"vue-ui-circle-pack"}),we=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),b=e.ref({showTable:t.value.table.show});async function F(){r.objectIsEmpty(y.dataset)&&r.error({componentName:"VueUiCirclePack",type:"dataset"}),await Se()}e.onMounted(F),e.watch(()=>y.dataset,async l=>{await F()},{deep:!0});const ee=e.computed(()=>r.convertCustomPalette(t.value.customPalette));function te(l,o){return Math.hypot(o.x-l.x,o.y-l.y)}function le(l,o){return o.some(a=>te(l,a)<l.radius+a.radius)}function Be(l,o,a,s){const c=o*2;for(let h of l)for(let p=0;p<360;p+=1){let z=p*Math.PI/180,i=h.x+c*Math.cos(z),n=h.y-c*Math.sin(z),m={x:i,y:n,radius:o};if(i-o>=0&&i+o<=a&&n-o>=0&&n+o<=s&&!le(m,l))return{x:i,y:n}}return null}function ze({datapoints:l,width:o,height:a,maxRadius:s,offsetX:c=0,offsetY:h=0}){const p=Math.max(...l.map(m=>m.value)),i=l.map((m,d)=>({...m,radius:m.value/p*s,index:d})).map((m,d)=>({...m,index:d})).toSorted((m,d)=>d.radius-m.radius);let n=[];n.push({...i[0],x:o/2+c,y:a/2+h});for(let m of i.slice(1)){let{radius:d,...ue}=m,A=Be(n,d,o,a);if(A)n.push({...ue,x:A.x,y:A.y,radius:d});else{let L=null,ie=1/0;for(let E of n)for(let R=0;R<360;R+=15){let ce=R*Math.PI/180,q=E.x+(d+E.radius)*Math.cos(ce),U=E.y+(d+E.radius)*Math.sin(ce),T={...ue,x:q,y:U,radius:d};if(q-d>=0&&q+d<=o&&U-d>=0&&U+d<=a&&!le(T,n)){let de=n.reduce((Fe,ve)=>Fe+(te(T,ve)<T.radius+ve.radius?1:0),0);de<ie&&(ie=de,L=T)}}L&&n.push(L)}}return n}const I=e.computed(()=>y.dataset.map((l,o)=>{const a=r.convertColorToHex(l.color)||ee.value[o]||r.themePalettes[t.value.theme||"default"][o%r.themePalettes[t.value.theme||"default"].length]||r.palette[o]||r.palette[o%r.palette.length];return{...l,id:r.createUid(),color:a}}).filter(l=>![null,void 0,1/0,-1/0].includes(l.value))),f=e.ref([]),$e=e.computed(()=>Math.max(...f.value.map(l=>l.radius)));function ae(l,o){return o/$e.value*l}async function Se(){f.value=ze({datapoints:I.value,width:1e4,height:1e4,maxRadius:32})}const oe=e.computed(()=>({width:100,height:100})),v=e.computed(()=>{const l=f.value.reduce((i,n)=>n.x-n.radius<i.x-i.radius?n:i,f.value[0]),o=f.value.reduce((i,n)=>n.y-n.radius<i.y-i.radius?n:i,f.value[0]),a=f.value.reduce((i,n)=>n.x+n.radius>i.x+i.radius?n:i,f.value[0]),s=f.value.reduce((i,n)=>n.y+n.radius>i.y+i.radius?n:i,f.value[0]),c=(l==null?void 0:l.x)||0,h=(a==null?void 0:a.x)||oe.value.width,p=(o==null?void 0:o.y)||0,z=(s==null?void 0:s.y)||oe.value.height;return{maxX:h,minX:c,width:Math.abs(h-c)+(l?l.radius:0)+(a?a.radius:0)+t.value.style.chart.circles.strokeWidth*4,height:Math.abs(z-p)+(o?o.radius:0)+(s?s.radius:0)+t.value.style.chart.circles.strokeWidth*4,x:l?(l==null?void 0:l.x)-(l==null?void 0:l.radius)-t.value.style.chart.circles.strokeWidth*2:0,y:o?(o==null?void 0:o.y)-(o==null?void 0:o.radius)-t.value.style.chart.circles.strokeWidth*2:0}}),Pe=e.computed(()=>f.value.map(l=>{if(l.breakdown)return r.makeDonut({series:l.breakdown.map((o,a)=>({...o,color:r.convertColorToHex(o.color)||ee.value[a]||r.palette[a]||r.palette[a%r.palette.length]}))},l.x,l.y,l.radius,l.radius,1.99999,2,1,360,105.25,l.radius/2)})),u=e.ref(null);function Ne(l){t.value.style.chart.circles.zoom.show&&(u.value=l)}const C=e.computed(()=>u.value?u.value.radius:0),M=e.computed(()=>u.value?u.value.radius>v.value.width/6*t.value.style.chart.circles.zoom.zoomRatio?u.value.radius:v.value.width/6*t.value.style.chart.circles.zoom.zoomRatio:0),k=e.ref(0),Ee=e.computed(()=>({pointerEvents:"none",opacity:k.value,filter:`drop-shadow(0px 0px 6px ${r.darkenHexColor(u.value.color,t.value.style.chart.circles.zoom.shadowForce)})`})),x=e.ref(C.value);e.watchEffect(()=>{x.value=C.value,k.value=0;let l=null;function o(a){l||(l=a);const s=(a-l)/t.value.style.chart.circles.zoom.animationFrameMs;s<1?(x.value=C.value+(M.value-C.value)*s,k.value=0+t.value.style.chart.circles.zoom.opacity*s,requestAnimationFrame(o)):(x.value=M.value,k.value=t.value.style.chart.circles.zoom.opacity)}requestAnimationFrame(o)});const w=e.computed(()=>({name:t.value.style.chart.circles.zoom.label.name.fontSize*v.value.width/300,value:t.value.style.chart.circles.zoom.label.value.fontSize*v.value.width/300}));function D(l){return r.applyDataLabel(t.value.style.chart.circles.labels.value.formatter,l.value,r.dataLabel({p:t.value.style.chart.circles.labels.value.prefix,v:l.value,s:t.value.style.chart.circles.labels.value.suffix,r:t.value.style.chart.circles.labels.value.rounding}))}function Te(){return r.applyDataLabel(t.value.style.chart.circles.zoom.label.value.formatter,u.value.value,r.dataLabel({p:t.value.style.chart.circles.zoom.label.value.prefix,v:u.value.value,s:t.value.style.chart.circles.zoom.label.value.suffix,r:t.value.style.chart.circles.zoom.label.value.rounding}))}function re(l){if(!l)return 0;const o=l.radius/D(l).length*(D(l).length===1?1:2);return Math.min(l.radius/2.5,o)}const B=e.ref(!1);function Ve(l){B.value=l,Y.value+=1}const S=e.ref(!1);function _(){S.value=!S.value}const P=e.computed(()=>{const l=I.value.map(a=>({name:a.name,value:a.value,color:a.color})).toSorted((a,s)=>s.value-a.value),o=l.map(a=>a.value);return{head:l,body:o}});function ne(){e.nextTick(()=>{const l=P.value.head.map((s,c)=>[[s.name],[P.value.body[c]]]),o=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],[t.value.table.columnNames.value]]].concat(l),a=r.createCsvContent(o);r.downloadCsv({csvContent:a,title:t.value.style.chart.title.text||"vue-ui-circle-pack"})})}const N=e.computed(()=>{const l=[t.value.table.columnNames.datapoint,t.value.table.columnNames.value],o=P.value.head.map((c,h)=>{const p=r.dataLabel({p:t.value.style.chart.circles.labels.value.prefix,v:P.value.body[h],s:t.value.style.chart.circles.labels.value.suffix,r:t.value.style.chart.circles.labels.value.rounding});return[{color:c.color,name:c.name},p]}),a={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};return{colNames:[t.value.table.columnNames.datapoint,t.value.table.columnNames.value],head:l,body:o,config:a}});function se(){b.value.showTable=!b.value.showTable}function Oe(){return I.value}return pe({getData:Oe,generateCsv:ne,generatePdf:K,generateImage:Q,toggleTable:se,toggleAnnotator:_}),(l,o)=>(e.openBlock(),e.createElementBlock("div",{id:`vue-ui-circle-pack_${g.value}`,class:e.normalizeClass(`vue-ui-circle-pack ${B.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"circlePackChart",ref:V,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:o[2]||(o[2]=()=>e.unref(W)(!0)),onMouseleave:o[3]||(o[3]=()=>e.unref(W)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(Me.PenAndPaper,{key:0,parent:V.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:S.value,onClose:_},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"userConfig",{},void 0,!0),we.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:Ce,class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},null,512)):e.createCommentVNode("",!0),t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:2,ref_key:"chartTitle",ref:be,style:"width:100%;background:transparent;padding-bottom:12px"},[(e.openBlock(),e.createBlock(Ie._sfc_main,{key:`title_${H.value}`,config:{title:{cy:"donut-div-title",...t.value.style.chart.title},subtitle:{cy:"donut-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&$.value&&(e.unref(X)||e.unref(O))?(e.openBlock(),e.createBlock(me.UserOptions,{ref:"details",key:`user_option_${Y.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(Z),isImaging:e.unref(J),uid:g.value,hasTooltip:!1,hasLabel:!1,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:B.value,chartElement:V.value,position:t.value.userOptions.position,titles:{...t.value.userOptions.buttonTitles},hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:S.value,onToggleFullscreen:Ve,onGeneratePdf:e.unref(K),onGenerateCsv:ne,onGenerateImage:e.unref(Q),onToggleTable:se,onToggleAnnotator:_,style:e.normalizeStyle({visibility:e.unref(X)?e.unref(O)?"visible":"hidden":"visible"})},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:a,isFullscreen:s})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:a,isFullscreen:s})),void 0,!0)]),key:"4"}:void 0,l.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:a,isAnnotator:s})=>[e.renderSlot(l.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:a,isAnnotator:s})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","chartElement","position","titles","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),$.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(r.XMLNS),viewBox:`${v.value.x} ${v.value.y} ${v.value.width} ${v.value.height}`,width:"100%",class:e.normalizeClass({"vue-data-ui-fullscreen--on":B.value,"vue-data-ui-fulscreen--off":!B.value}),style:e.normalizeStyle(`max-width:100%;overflow:visible;background:transparent;color:${t.value.style.chart.color};`)},[e.createVNode(_e._sfc_main),l.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:v.value.x,y:v.value.y,width:v.value.width,height:v.value.height,style:{pointerEvents:"none"}},[e.renderSlot(l.$slots,"chart-background",{},void 0,!0)],8,Ge)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,a=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{id:a.id,fy:"30%"},[e.createElementVNode("stop",{offset:"10%","stop-color":e.unref(r.lightenHexColor)(a.color,t.value.style.chart.circles.gradient.intensity/100)},null,8,We),e.createElementVNode("stop",{offset:"90%","stop-color":e.unref(r.darkenHexColor)(a.color,.1)},null,8,Xe),e.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,je)],8,Ye)]),l.$slots.pattern?(e.openBlock(),e.createElementBlock("g",Ze,[e.createElementVNode("defs",null,[e.renderSlot(l.$slots,"pattern",e.mergeProps({ref_for:!0},{...a,patternId:`pattern_${g.value}_${a.id}`}),void 0,!0)])])):e.createCommentVNode("",!0),e.createElementVNode("rect",{x:a.x-a.radius,y:a.y-a.radius,width:a.radius*2,height:a.radius*2,stroke:t.value.style.chart.circles.stroke,"stroke-width":t.value.style.chart.circles.strokeWidth,fill:t.value.style.chart.circles.gradient.show?`url(#${a.id})`:a.color,rx:a.radius,onMouseenter:()=>Ne(a),onMouseout:o[0]||(o[0]=s=>u.value=null),onClick:s=>ke("selectDatapoint",a)},null,40,Je),l.$slots.pattern?(e.openBlock(),e.createElementBlock("rect",{key:1,x:a.x-a.radius,y:a.y-a.radius,width:a.radius*2,height:a.radius*2,stroke:t.value.style.chart.circles.stroke,"stroke-width":t.value.style.chart.circles.strokeWidth,fill:`url(#pattern_${g.value}_${a.id})`,rx:a.radius,style:{pointerEvents:"none"}},null,8,Ke)):e.createCommentVNode("",!0),l.$slots["data-label"]?e.renderSlot(l.$slots,"data-label",e.mergeProps({key:2,ref_for:!0},{...a,createTSpans:e.unref(r.createTSpans),fontSize:{name:a.radius/3*t.value.style.chart.circles.labels.name.fontSizeRatio,value:re(a)*t.value.style.chart.circles.labels.value.fontSizeRatio},color:t.value.style.chart.circles.labels.name.color?t.value.style.chart.circles.labels.name.color:e.unref(r.adaptColorToBackground)(a.color)}),void 0,!0):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[t.value.style.chart.circles.labels.name.show&&a.name?(e.openBlock(),e.createElementBlock("text",{key:0,style:{pointerEvents:"none",transition:"opacity 0.2s ease-in-out"},opacity:u.value?.2:1,x:a.x,y:a.y+ae(a.radius,t.value.style.chart.circles.labels.name.offsetY)-a.radius/6,"font-size":a.radius/3*t.value.style.chart.circles.labels.name.fontSizeRatio,fill:t.value.style.chart.circles.labels.name.color?t.value.style.chart.circles.labels.name.color:e.unref(r.adaptColorToBackground)(a.color),"font-weight":t.value.style.chart.circles.labels.name.bold?"bold":"normal","text-anchor":"middle"},e.toDisplayString(a.name),9,Qe)):e.createCommentVNode("",!0),t.value.style.chart.circles.labels.value.show?(e.openBlock(),e.createElementBlock("text",{key:1,style:{pointerEvents:"none",transition:"opacity 0.2s ease-in-out"},opacity:u.value?.2:1,x:a.x,y:a.y+ae(a.radius,t.value.style.chart.circles.labels.value.offsetY)+a.radius/3,"font-size":re(a)*t.value.style.chart.circles.labels.value.fontSizeRatio,fill:t.value.style.chart.circles.labels.value.color?t.value.style.chart.circles.labels.value.color:e.unref(r.adaptColorToBackground)(a.color),"font-weight":t.value.style.chart.circles.labels.value.bold?"bold":"normal","text-anchor":"middle"},e.toDisplayString(D(a)),9,et)):e.createCommentVNode("",!0)],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Pe.value,s=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s,c=>(e.openBlock(),e.createElementBlock("path",{d:c.arcSlice,fill:c.color,stroke:"black"},null,8,tt))),256))],64))),256))],64))),256)),u.value&&t.value.style.chart.circles.zoom.show?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("circle",{style:e.normalizeStyle(Ee.value),cx:u.value.x,cy:u.value.y,r:x.value,opacity:k.value,stroke:t.value.style.chart.circles.stroke,fill:t.value.style.chart.circles.gradient.show?`url(#${u.value.id})`:u.value.color},null,12,lt),l.$slots["zoom-label"]?(e.openBlock(),e.createElementBlock("g",at,[e.renderSlot(l.$slots,"zoom-label",e.normalizeProps(e.guardReactiveProps({...u.value,zoomOpacity:k.value,currentRadius:x.value,fontSize:w.value})),void 0,!0)])):(e.openBlock(),e.createElementBlock("g",ot,[e.createElementVNode("text",{style:{pointerEvents:"none"},opacity:k.value,x:u.value.x,y:u.value.y+t.value.style.chart.circles.zoom.label.name.offsetY-w.value.name/4,"text-anchor":"middle","font-size":w.value.name,fill:t.value.style.chart.circles.zoom.label.name.color?t.value.style.chart.circles.zoom.label.name.color:e.unref(r.adaptColorToBackground)(u.value.color),"font-weight":t.value.style.chart.circles.zoom.label.name.bold?"bold":"normal"},e.toDisplayString(u.value.name),9,rt),e.createElementVNode("text",{style:{pointerEvents:"none"},opacity:k.value,x:u.value.x,y:u.value.y+w.value.value+t.value.style.chart.circles.zoom.label.value.offsetY,"text-anchor":"middle","font-size":w.value.value,fill:t.value.style.chart.circles.zoom.label.value.color?t.value.style.chart.circles.zoom.label.value.color:e.unref(r.adaptColorToBackground)(u.value.color),"font-weight":t.value.style.chart.circles.zoom.label.value.bold?"bold":"normal"},e.toDisplayString(Te()),9,nt)]))],64)):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"svg",{svg:{...v.value}},void 0,!0)],14,He)):e.createCommentVNode("",!0),$.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(Re.default,{key:5,config:{type:"circlePack",style:{color:"#CCCCCC"}}})),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",st,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(Z)||e.unref(J)})),void 0,!0)])):e.createCommentVNode("",!0),l.$slots.source?(e.openBlock(),e.createElementBlock("div",{key:7,ref_key:"source",ref:xe,dir:"auto"},[e.renderSlot(l.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),$.value?(e.openBlock(),e.createBlock(Ae.default,{key:8,hideDetails:"",config:{open:b.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:e.withCtx(()=>[(e.openBlock(),e.createBlock(Le.DataTable,{key:`table_${G.value}`,colNames:N.value.colNames,head:N.value.head,body:N.value.body,config:N.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:o[1]||(o[1]=a=>b.value.showTable=!1)},{th:e.withCtx(({th:a})=>[e.createElementVNode("div",{innerHTML:a,style:{display:"flex","align-items":"center"}},null,8,ut)]),td:e.withCtx(({td:a})=>[e.createTextVNode(e.toDisplayString(a.name||a),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],46,Ue))}},ct=qe._export_sfc(it,[["__scopeId","data-v-cbf5c72e"]]);exports.default=ct;
@@ -1,14 +1,14 @@
1
1
  import { useCssVars as st, computed as h, ref as f, watch as Fe, onMounted as rt, watchEffect as nt, createElementBlock as i, openBlock as s, unref as c, normalizeStyle as H, normalizeClass as Me, createBlock as S, createCommentVNode as y, renderSlot as m, createSlots as ut, withCtx as C, normalizeProps as X, guardReactiveProps as Y, createVNode as it, Fragment as T, renderList as se, createElementVNode as k, mergeProps as Ne, toDisplayString as E, createTextVNode as ct, nextTick as vt } from "vue";
2
- import { u as dt, c as _e, t as re, p as P, a as ht, o as ft, e as yt, b as mt, d as Ae, m as pt, h as Ee, f as ne, X as bt, l as gt, G as D, a6 as kt, q as xt, r as wt, i as De } from "./index-y7ebFPbO.js";
3
- import { u as Re } from "./useNestedProp-BWzyGJZ8.js";
4
- import { u as Ct, U as zt } from "./usePrinter-xz0bcBPM.js";
5
- import { _ as $t } from "./Title-AFFkNb_h.js";
6
- import { P as Tt } from "./PenAndPaper-BJLUyj-s.js";
2
+ import { u as dt, c as _e, t as re, p as P, a as ht, o as ft, e as yt, b as mt, d as Ae, m as pt, h as Ee, f as ne, X as bt, l as gt, G as D, a6 as kt, q as xt, r as wt, i as De } from "./index-B9qF6XbP.js";
3
+ import { u as Re } from "./useNestedProp-g5oKzlVy.js";
4
+ import { u as Ct, U as zt } from "./usePrinter-DsiBLAy1.js";
5
+ import { _ as $t } from "./Title-D6h1gTvZ.js";
6
+ import { P as Tt } from "./PenAndPaper-6UYizrkQ.js";
7
7
  import { u as Pt } from "./useUserOptionState-BIvW1Kz7.js";
8
- import { _ as St } from "./PackageVersion-C5hOoj_p.js";
9
- import Ot from "./vue-ui-accordion-DxSGI7GJ.js";
10
- import { D as It } from "./DataTable-Bg0b_pVK.js";
11
- import Ft from "./vue-ui-skeleton-DOahsJXV.js";
8
+ import { _ as St } from "./PackageVersion-DqmHcoqz.js";
9
+ import Ot from "./vue-ui-accordion-DBmchkva.js";
10
+ import { D as It } from "./DataTable-CJN0sipt.js";
11
+ import Ft from "./vue-ui-skeleton-CHEZlRpn.js";
12
12
  import { _ as Mt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
13
13
  const Nt = ["id"], _t = ["xmlns", "viewBox"], At = ["x", "y", "width", "height"], Et = ["id"], Dt = ["stop-color"], Rt = ["stop-color"], Lt = ["stop-color"], Gt = { key: 0 }, Ut = ["x", "y", "width", "height", "stroke", "stroke-width", "fill", "rx", "onMouseenter", "onClick"], Vt = ["x", "y", "width", "height", "stroke", "stroke-width", "fill", "rx"], Bt = ["opacity", "x", "y", "font-size", "fill", "font-weight"], Ht = ["opacity", "x", "y", "font-size", "fill", "font-weight"], Xt = ["d", "fill"], Yt = ["cx", "cy", "r", "opacity", "stroke", "fill"], Wt = {
14
14
  key: 0,
@@ -1,6 +1,6 @@
1
1
  import { ref as c, computed as _, onMounted as R, onBeforeUnmount as S, createElementBlock as l, createCommentVNode as o, openBlock as i, normalizeStyle as E, unref as m, createElementVNode as r, normalizeClass as C, toDisplayString as p, nextTick as b } from "vue";
2
- import { u as F } from "./useNestedProp-BWzyGJZ8.js";
3
- import { u as L, c as z, X as O, s as I } from "./index-y7ebFPbO.js";
2
+ import { u as F } from "./useNestedProp-g5oKzlVy.js";
3
+ import { u as L, c as z, X as O, s as I } from "./index-B9qF6XbP.js";
4
4
  import { _ as B } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
5
  const N = ["xmlns", "height", "width"], T = {
6
6
  id: "follower",
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),y=require("./useNestedProp-BzGIy5aD.cjs"),i=require("./index-Cww7pocd.cjs"),C=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),_=["xmlns","height","width"],p={id:"follower",fy:"30%",fx:"30%"},x=["stop-color","stop-opacity"],E=["r","fill","stroke","stroke-width","stroke-dasharray"],N=["r"],g={key:2,class:"wave"},V=["id"],w=["id"],S=["filter","stroke"],B={key:3,class:"crosshair"},R=["x1","stroke","stroke-width","stroke-dasharray"],b=["x1","stroke","stroke-width","stroke-dasharray"],F=["y1","stroke","stroke-width","stroke-dasharray"],z=["y1","stroke","stroke-width","stroke-dasharray"],L=["cy","r","fill"],O=["cy","r","fill"],I=["cx","r","fill"],T=["cx","r","fill"],D={key:5,class:"coordinates"},$=["x","y","font-size","fill"],W=["transform"],G=["font-size","fill"],P={__name:"vue-ui-cursor",props:{config:{type:Object,default:{}}},setup(f){const{vue_ui_cursor:h}=i.useConfig(),k=f,n=t.ref(i.createUid()),e=t.computed(()=>y.useNestedProp({userConfig:k.config,defaultConfig:h})),o=t.ref({x:-100,y:-100});function u({clientX:r,clientY:l,...A}){o.value.x=r-e.value.centerCircleRadius,o.value.y=l-e.value.centerCircleRadius}function d(r){o.value.x=r.targetTouches[0].clientX-e.value.centerCircleRadius,o.value.y=r.targetTouches[0].clientY-e.value.centerCircleRadius}const v=t.ref(!0);function a(r){v.value=r}const s=t.ref(!1),c=t.ref(null);function m(){s.value=!1,c.value&&clearTimeout(c.value),t.nextTick(()=>{s.value=!0,c.value=setTimeout(()=>{s.value=!1},1e3)})}return t.onMounted(()=>{const r=e.value.parentId?document.getElementById(e.value.parentId):document.getElementsByTagName("div")[0];r.addEventListener("mousemove",u),r.addEventListener("touchmove",d),r.addEventListener("mouseleave",()=>a(!1)),r.addEventListener("mouseenter",()=>a(!0)),r.addEventListener("click",m)}),t.onBeforeUnmount(()=>{const r=e.value.parentId?document.getElementById(e.value.parentId):document.getElementsByTagName("div")[0];r.removeEventListener("mousemove",u),r.removeEventListener("touchmove",d),r.removeEventListener("mouseleave",()=>a(!1)),r.removeEventListener("mouseenter",()=>a(!0)),r.removeEventListener("click",m)}),t.computed(()=>e.value.centerCircleRadius/2.5),(r,l)=>v.value?(t.openBlock(),t.createElementBlock("svg",{key:0,"data-html2canvas-ignore":"",xmlns:t.unref(i.XMLNS),style:t.normalizeStyle(`z-index: 2147483647; overflow: visible; pointer-events: none;background: transparent; position:fixed; top:${o.value.y}px; left:${o.value.x}px;`),viewBox:"0 0 100 100",height:e.value.centerCircleRadius*2,width:e.value.centerCircleRadius*2},[t.createElementVNode("defs",null,[t.createElementVNode("radialGradient",p,[t.createElementVNode("stop",{offset:"10%","stop-color":e.value.bubbleEffectColor,"stop-opacity":e.value.bubbleEffectOpacity},null,8,x),l[0]||(l[0]=t.createElementVNode("stop",{offset:"95%","stop-color":"transparent"},null,-1))])]),e.value.showCenterCircle?(t.openBlock(),t.createElementBlock("circle",{key:0,cx:50,cy:50,r:e.value.centerCircleRadius,fill:t.unref(i.setOpacity)(e.value.centerCircleColor,e.value.centerCircleOpacity*100),stroke:e.value.centerCircleStroke,"stroke-width":e.value.centerCircleStrokeWidth,"stroke-dasharray":e.value.centerCircleDasharray},null,8,E)):t.createCommentVNode("",!0),e.value.bubbleEffect?(t.openBlock(),t.createElementBlock("circle",{key:1,cx:50,cy:50,r:e.value.centerCircleRadius,fill:"url(#follower)",stroke:"none"},null,8,N)):t.createCommentVNode("",!0),e.value.useWaveOnClick?(t.openBlock(),t.createElementBlock("g",g,[t.createElementVNode("defs",null,[t.createElementVNode("filter",{id:`blur_${n.value}`,x:"-50%",y:"-50%",width:"200%",height:"200%"},[t.createElementVNode("feGaussianBlur",{in:"SourceGraphic",stdDeviation:4,id:`blur_std_${n.value}`},null,8,w),l[1]||(l[1]=t.createElementVNode("feColorMatrix",{type:"saturate",values:"0"},null,-1))],8,V)]),s.value?(t.openBlock(),t.createElementBlock("circle",{key:0,class:t.normalizeClass({"circle-wave":s.value}),cx:50,cy:50,r:50,filter:`url(#blur_${n.value})`,stroke:e.value.centerCircleStroke,fill:"none","stroke-width":"3"},null,10,S)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),e.value.showCrosshair?(t.openBlock(),t.createElementBlock("g",B,[t.createElementVNode("line",{x1:-e.value.centerCircleRadius+50,x2:-5e3,y1:50,y2:50,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,R),t.createElementVNode("line",{x1:50+e.value.centerCircleRadius,x2:5e3,y1:50,y2:50,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,b),t.createElementVNode("line",{x1:50,x2:50,y1:-e.value.centerCircleRadius+50,y2:-5e3,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,F),t.createElementVNode("line",{x1:50,x2:50,y1:e.value.centerCircleRadius+50,y2:5e3,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,z)])):t.createCommentVNode("",!0),e.value.showIntersectCircles?(t.openBlock(),t.createElementBlock("g",{key:4,class:t.normalizeClass({"rotating-circles":e.value.isLoading})},[t.createElementVNode("circle",{cx:50,cy:e.value.centerCircleRadius+50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,L),t.createElementVNode("circle",{cx:50,cy:-e.value.centerCircleRadius+50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,O),t.createElementVNode("circle",{cx:-e.value.centerCircleRadius+50,cy:50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,I),t.createElementVNode("circle",{cx:e.value.centerCircleRadius+50,cy:50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,T)],2)):t.createCommentVNode("",!0),e.value.showCoordinates?(t.openBlock(),t.createElementBlock("g",D,[t.createElementVNode("text",{"text-anchor":"end",x:-e.value.centerCircleRadius+50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset,y:50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset,"font-size":e.value.coordinatesFontSize,fill:e.value.coordinatesColor,style:{"font-variant-numeric":"tabular-nums"},"font-family":"Arial"},t.toDisplayString(o.value.x.toFixed(0)),9,$),t.createElementVNode("g",{transform:`translate(${50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset}, ${-e.value.centerCircleRadius+50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset})`},[t.createElementVNode("text",{"text-anchor":"start","font-size":e.value.coordinatesFontSize,fill:e.value.coordinatesColor,style:{"font-variant-numeric":"tabular-nums"},transform:"rotate(-90)","font-family":"Arial"},t.toDisplayString(o.value.y.toFixed(0)),9,G)],8,W)])):t.createCommentVNode("",!0)],12,_)):t.createCommentVNode("",!0)}},q=C._export_sfc(P,[["__scopeId","data-v-0cca0d39"]]);exports.default=q;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),y=require("./useNestedProp-D4Jn2Oxr.cjs"),i=require("./index-kZKcQZM_.cjs"),C=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),_=["xmlns","height","width"],p={id:"follower",fy:"30%",fx:"30%"},x=["stop-color","stop-opacity"],E=["r","fill","stroke","stroke-width","stroke-dasharray"],N=["r"],g={key:2,class:"wave"},V=["id"],w=["id"],S=["filter","stroke"],B={key:3,class:"crosshair"},R=["x1","stroke","stroke-width","stroke-dasharray"],b=["x1","stroke","stroke-width","stroke-dasharray"],F=["y1","stroke","stroke-width","stroke-dasharray"],z=["y1","stroke","stroke-width","stroke-dasharray"],L=["cy","r","fill"],O=["cy","r","fill"],I=["cx","r","fill"],T=["cx","r","fill"],D={key:5,class:"coordinates"},$=["x","y","font-size","fill"],W=["transform"],G=["font-size","fill"],P={__name:"vue-ui-cursor",props:{config:{type:Object,default:{}}},setup(f){const{vue_ui_cursor:h}=i.useConfig(),k=f,n=t.ref(i.createUid()),e=t.computed(()=>y.useNestedProp({userConfig:k.config,defaultConfig:h})),o=t.ref({x:-100,y:-100});function u({clientX:r,clientY:l,...A}){o.value.x=r-e.value.centerCircleRadius,o.value.y=l-e.value.centerCircleRadius}function d(r){o.value.x=r.targetTouches[0].clientX-e.value.centerCircleRadius,o.value.y=r.targetTouches[0].clientY-e.value.centerCircleRadius}const v=t.ref(!0);function a(r){v.value=r}const s=t.ref(!1),c=t.ref(null);function m(){s.value=!1,c.value&&clearTimeout(c.value),t.nextTick(()=>{s.value=!0,c.value=setTimeout(()=>{s.value=!1},1e3)})}return t.onMounted(()=>{const r=e.value.parentId?document.getElementById(e.value.parentId):document.getElementsByTagName("div")[0];r.addEventListener("mousemove",u),r.addEventListener("touchmove",d),r.addEventListener("mouseleave",()=>a(!1)),r.addEventListener("mouseenter",()=>a(!0)),r.addEventListener("click",m)}),t.onBeforeUnmount(()=>{const r=e.value.parentId?document.getElementById(e.value.parentId):document.getElementsByTagName("div")[0];r.removeEventListener("mousemove",u),r.removeEventListener("touchmove",d),r.removeEventListener("mouseleave",()=>a(!1)),r.removeEventListener("mouseenter",()=>a(!0)),r.removeEventListener("click",m)}),t.computed(()=>e.value.centerCircleRadius/2.5),(r,l)=>v.value?(t.openBlock(),t.createElementBlock("svg",{key:0,"data-html2canvas-ignore":"",xmlns:t.unref(i.XMLNS),style:t.normalizeStyle(`z-index: 2147483647; overflow: visible; pointer-events: none;background: transparent; position:fixed; top:${o.value.y}px; left:${o.value.x}px;`),viewBox:"0 0 100 100",height:e.value.centerCircleRadius*2,width:e.value.centerCircleRadius*2},[t.createElementVNode("defs",null,[t.createElementVNode("radialGradient",p,[t.createElementVNode("stop",{offset:"10%","stop-color":e.value.bubbleEffectColor,"stop-opacity":e.value.bubbleEffectOpacity},null,8,x),l[0]||(l[0]=t.createElementVNode("stop",{offset:"95%","stop-color":"transparent"},null,-1))])]),e.value.showCenterCircle?(t.openBlock(),t.createElementBlock("circle",{key:0,cx:50,cy:50,r:e.value.centerCircleRadius,fill:t.unref(i.setOpacity)(e.value.centerCircleColor,e.value.centerCircleOpacity*100),stroke:e.value.centerCircleStroke,"stroke-width":e.value.centerCircleStrokeWidth,"stroke-dasharray":e.value.centerCircleDasharray},null,8,E)):t.createCommentVNode("",!0),e.value.bubbleEffect?(t.openBlock(),t.createElementBlock("circle",{key:1,cx:50,cy:50,r:e.value.centerCircleRadius,fill:"url(#follower)",stroke:"none"},null,8,N)):t.createCommentVNode("",!0),e.value.useWaveOnClick?(t.openBlock(),t.createElementBlock("g",g,[t.createElementVNode("defs",null,[t.createElementVNode("filter",{id:`blur_${n.value}`,x:"-50%",y:"-50%",width:"200%",height:"200%"},[t.createElementVNode("feGaussianBlur",{in:"SourceGraphic",stdDeviation:4,id:`blur_std_${n.value}`},null,8,w),l[1]||(l[1]=t.createElementVNode("feColorMatrix",{type:"saturate",values:"0"},null,-1))],8,V)]),s.value?(t.openBlock(),t.createElementBlock("circle",{key:0,class:t.normalizeClass({"circle-wave":s.value}),cx:50,cy:50,r:50,filter:`url(#blur_${n.value})`,stroke:e.value.centerCircleStroke,fill:"none","stroke-width":"3"},null,10,S)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),e.value.showCrosshair?(t.openBlock(),t.createElementBlock("g",B,[t.createElementVNode("line",{x1:-e.value.centerCircleRadius+50,x2:-5e3,y1:50,y2:50,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,R),t.createElementVNode("line",{x1:50+e.value.centerCircleRadius,x2:5e3,y1:50,y2:50,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,b),t.createElementVNode("line",{x1:50,x2:50,y1:-e.value.centerCircleRadius+50,y2:-5e3,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,F),t.createElementVNode("line",{x1:50,x2:50,y1:e.value.centerCircleRadius+50,y2:5e3,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,z)])):t.createCommentVNode("",!0),e.value.showIntersectCircles?(t.openBlock(),t.createElementBlock("g",{key:4,class:t.normalizeClass({"rotating-circles":e.value.isLoading})},[t.createElementVNode("circle",{cx:50,cy:e.value.centerCircleRadius+50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,L),t.createElementVNode("circle",{cx:50,cy:-e.value.centerCircleRadius+50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,O),t.createElementVNode("circle",{cx:-e.value.centerCircleRadius+50,cy:50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,I),t.createElementVNode("circle",{cx:e.value.centerCircleRadius+50,cy:50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,T)],2)):t.createCommentVNode("",!0),e.value.showCoordinates?(t.openBlock(),t.createElementBlock("g",D,[t.createElementVNode("text",{"text-anchor":"end",x:-e.value.centerCircleRadius+50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset,y:50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset,"font-size":e.value.coordinatesFontSize,fill:e.value.coordinatesColor,style:{"font-variant-numeric":"tabular-nums"},"font-family":"Arial"},t.toDisplayString(o.value.x.toFixed(0)),9,$),t.createElementVNode("g",{transform:`translate(${50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset}, ${-e.value.centerCircleRadius+50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset})`},[t.createElementVNode("text",{"text-anchor":"start","font-size":e.value.coordinatesFontSize,fill:e.value.coordinatesColor,style:{"font-variant-numeric":"tabular-nums"},transform:"rotate(-90)","font-family":"Arial"},t.toDisplayString(o.value.y.toFixed(0)),9,G)],8,W)])):t.createCommentVNode("",!0)],12,_)):t.createCommentVNode("",!0)}},q=C._export_sfc(P,[["__scopeId","data-v-0cca0d39"]]);exports.default=q;
@@ -1,7 +1,7 @@
1
1
  import { useCssVars as ee, computed as T, ref as s, watch as te, createElementBlock as w, openBlock as y, createCommentVNode as E, createElementVNode as p, normalizeStyle as $, createStaticVNode as oe, Fragment as L, renderList as ae, normalizeClass as le, renderSlot as ne } from "vue";
2
2
  import ue from "./pdf-d7kl0_wm.js";
3
- import { u as se } from "./useNestedProp-BWzyGJZ8.js";
4
- import { u as ie, c as re } from "./index-y7ebFPbO.js";
3
+ import { u as se } from "./useNestedProp-g5oKzlVy.js";
4
+ import { u as ie, c as re } from "./index-B9qF6XbP.js";
5
5
  import { _ as de } from "./_plugin-vue_export-helper-CHgC5LLL.js";
6
6
  const ce = {
7
7
  key: 0,
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),A=require("./pdf-DV2jHb_u.cjs"),G=require("./useNestedProp-BzGIy5aD.cjs"),$=require("./index-Cww7pocd.cjs"),J=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),K={key:0,"data-html2canvas-ignore":"",style:{width:"100%",display:"flex","justify-content":"end"}},Q=["disabled"],Z=["stroke"],ee={key:1},te=["id"],oe=["onMousedown","onTouchstart"],le=["onMousedown","onTouchstart"],ae=["onMousedown","onTouchstart"],ne=["onMousedown","onTouchstart"],ue=["onMousedown","onTouchstart"],M=20,se={__name:"vue-ui-dashboard",props:{dataset:Array,config:Object},emits:["change"],setup(x,{expose:S,emit:X}){o.useCssVars(e=>({"014a5839":F.value,c96c137e:R.value}));const{vue_ui_dashboard:Y}=$.useConfig(),_=x,r=o.computed(()=>G.useNestedProp({userConfig:_.config,defaultConfig:Y})),E=o.ref($.createUid()),c=o.ref(r.value.locked);function V(){c.value=!c.value}const s=o.ref(_.dataset.map((e,t)=>({...e,index:t}))),h=o.ref(null),u=o.ref(null),v=o.ref({x:0,y:0}),f=o.ref({x:0,y:0}),i=o.ref(null),d=o.ref(!1),p=o.ref(null),m=o.ref(!1),b=o.ref(!1);function z(e){const t=e.target;(t.tagName==="INPUT"&&t.type==="range"||t.classList.contains("range-handle"))&&(b.value=!0)}function N(e){const t=e.target;t.tagName==="INPUT"&&t.type==="range"&&(b.value=!1)}function C(){m.value=!0,A.default({domElement:document.getElementById(`vue-ui-dashboard_${E.value}`),fileName:"vue-ui-dashboard"}).finally(()=>{m.value=!1})}function H(e){if(!c.value&&(d.value=!0,p.value=e,u.value===null)){h.value=e,v.value={x:event.clientX,y:event.clientY};const t=s.value[e],a=100-t.width,l=100-t.height;t.left<0&&(t.left=0),t.top<0&&(t.top=0),t.left>a&&(t.left=a),t.top>l&&(t.top=l),t.left<0&&(t.left=0),t.top<0&&(t.top=0),t.left+t.width>100&&(t.left=100-t.width),t.top+t.height>100&&(t.top=100-t.height)}}function y(e,t){d.value=!0,p.value=e,u.value={index:e,direction:t};const a=s.value[e];f.value={x:event.clientX,y:event.clientY,initialWidth:a.width,initialHeight:a.height}}function B(e,t,a){if(u.value.direction.includes("top")){const l=e.height-a/i.value.offsetHeight*100;l>=M&&(e.top+=a/i.value.offsetHeight*100,e.height=l)}if(u.value.direction.includes("bottom")){const l=e.height+a/i.value.offsetHeight*100;l>=M&&(e.height=l)}if(u.value.direction.includes("left")){const l=e.width-t/i.value.offsetWidth*100;l>=M&&(e.left+=t/i.value.offsetWidth*100,e.width=l)}if(u.value.direction.includes("right")){const l=e.width+t/i.value.offsetWidth*100;l>=M&&(e.width=l)}}function I(e){if(!(c.value||b.value)){if(d.value=!0,h.value!==null){const t=s.value[h.value],a=e.clientX-v.value.x,l=e.clientY-v.value.y,n=t.left+a/i.value.offsetWidth*100,g=t.top+l/i.value.offsetHeight*100;n>=0&&g>=0&&n+t.width<=100&&g+t.height<=100&&(t.left=n,t.top=g),v.value={x:e.clientX,y:e.clientY}}if(u.value!==null){const t=s.value[u.value.index],a=e.clientX-f.value.x,l=e.clientY-f.value.y;B(t,a,l),f.value={x:e.clientX,y:e.clientY}}}}const P=X;o.watch(s,e=>{e&&!d.value&&P("change",s.value)},{deep:!0});function D(){h.value=null,u.value=null,d.value=!1,p.value=null,s.value.forEach(e=>{e.left=Math.round(e.left/100*100),e.top=Math.round(e.top/100*100),e.width=Math.round(e.width/100*100),e.height=Math.round(e.height/100*100)})}function L(e){c.value||b.value||(d.value=!0,p.value=e,u.value===null&&(h.value=e,v.value={x:event.touches[0].clientX,y:event.touches[0].clientY}))}function k(e,t,a){if(d.value=!0,p.value=e,u.value===null){u.value={index:e,direction:t};const l=s.value[e];f.value={x:a.touches[0].clientX,y:a.touches[0].clientY,initialWidth:l.width,initialHeight:l.height}}}function T(e){if(d.value=!0,e.preventDefault(),u.value!==null){const t=s.value[u.value.index],a=e.touches[0].clientX-f.value.x,l=e.touches[0].clientY-f.value.y;B(t,a,l),f.value={x:e.touches[0].clientX,y:e.touches[0].clientY}}}function W(e){if(!(c.value||b.value)&&(d.value=!0,e.preventDefault(),h.value!==null)){const t=s.value[h.value],a=e.touches[0].clientX-v.value.x,l=e.touches[0].clientY-v.value.y,n=t.left+a/i.value.offsetWidth*100,g=t.top+l/i.value.offsetHeight*100;n>=0&&g>=0&&n+t.width<=100&&g+t.height<=100&&(t.left=n,t.top=g),v.value={x:e.touches[0].clientX,y:e.touches[0].clientY}}}function w(){d.value=!1,p.value=null,h.value=null,u.value=null,s.value.forEach(e=>{e.left=Math.round(e.left/100*100),e.top=Math.round(e.top/100*100),e.width=Math.round(e.width/100*100),e.height=Math.round(e.height/100*100)})}const F=o.computed(()=>r.value.style.item.borderColor),R=o.computed(()=>r.value.style.resizeHandles.backgroundColor),q=o.computed(()=>r.value.style.board.aspectRatio),O=o.computed(()=>r.value.style.board.backgroundColor),U=o.computed(()=>r.value.style.board.border);function j(){return s.value}return S({generatePdf:C,getItemsPositions:j,toggleLock:V}),(e,t)=>(o.openBlock(),o.createElementBlock("div",{onMousedown:z,onMouseup:N,onTouchstart:z,onTouchend:N},[r.value.allowPrint?(o.openBlock(),o.createElementBlock("div",K,[o.createElementVNode("button",{class:"vue-ui-dashboard-button",onClick:C,disabled:m.value,style:o.normalizeStyle([{"margin-top":"12px"},`color:${r.value.style.board.color}`])},[m.value?(o.openBlock(),o.createElementBlock("svg",{key:0,class:"vue-ui-dashboard-print-icon",xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:r.value.style.board.color,fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t[4]||(t[4]=[o.createStaticVNode('<path stroke="none" d="M0 0h24v24H0z" fill="none" data-v-07570d07></path><path d="M18 16v.01" data-v-07570d07></path><path d="M6 16v.01" data-v-07570d07></path><path d="M12 5v.01" data-v-07570d07></path><path d="M12 12v.01" data-v-07570d07></path><path d="M12 1a4 4 0 0 1 2.001 7.464l.001 .072a3.998 3.998 0 0 1 1.987 3.758l.22 .128a3.978 3.978 0 0 1 1.591 -.417l.2 -.005a4 4 0 1 1 -3.994 3.77l-.28 -.16c-.522 .25 -1.108 .39 -1.726 .39c-.619 0 -1.205 -.14 -1.728 -.391l-.279 .16l.007 .231a4 4 0 1 1 -2.212 -3.579l.222 -.129a3.998 3.998 0 0 1 1.988 -3.756l.002 -.071a4 4 0 0 1 -1.995 -3.265l-.005 -.2a4 4 0 0 1 4 -4z" data-v-07570d07></path>',6)]),8,Z)):(o.openBlock(),o.createElementBlock("span",ee,"PDF"))],12,Q)])):o.createCommentVNode("",!0),o.createElementVNode("div",{class:"vue-ui-dashboard-container",ref_key:"dashboardContainer",ref:i,id:`vue-ui-dashboard_${E.value}`,style:o.normalizeStyle(`border:${U.value}; sbackground:${O.value}; aspect-ratio:${q.value}`)},[o.createElementVNode("div",{class:"vue-ui-dashboard-grid-container",ref:"container",onMousemove:I,onMouseup:D,onTouchmove:W,onTouchend:w,style:o.normalizeStyle(`background:${r.value.style.board.backgroundColor}`)},[t[5]||(t[5]=o.createElementVNode("div",{class:"vue-ui-dashboard-grid"},null,-1)),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(s.value,(a,l)=>(o.openBlock(),o.createElementBlock("div",{key:a.id,class:o.normalizeClass({"vue-ui-dashboard-grid-item":!0,"vue-ui-dashboard-grid-item--locked":c.value}),style:o.normalizeStyle({width:`${a.width}%`,height:`${a.height}%`,left:`${a.left}%`,top:`${a.top}%`,cursor:"move",boxShadow:p.value===l?"0 6px 12px -3px rgba(0,0,0,0.3)":"",zIndex:p.value===l?s.value.length+1:a.index,backgroundColor:r.value.style.item.backgroundColor}),onMousedown:n=>H(l),onTouchstart:n=>L(l)},[c.value?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-top-left",onMousedown:n=>y(l,"top-left"),onTouchstart:n=>k(l,"top-left",n),onTouchmove:t[0]||(t[0]=n=>T(n)),onTouchend:w},null,40,le),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-top-right",onMousedown:n=>y(l,"top-right"),onTouchstart:n=>k(l,"top-right",n),onTouchmove:t[1]||(t[1]=n=>T(n)),onTouchend:w},null,40,ae),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-bottom-left",onMousedown:n=>y(l,"bottom-left"),onTouchstart:n=>k(l,"bottom-left",n),onTouchmove:t[2]||(t[2]=n=>T(n)),onTouchend:w},null,40,ne),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-bottom-right",onMousedown:n=>y(l,"bottom-right"),onTouchstart:n=>k(l,"bottom-right",n),onTouchmove:t[3]||(t[3]=n=>T(n)),onTouchend:w},null,40,ue)],64)),o.renderSlot(e.$slots,"content",{item:a,index:l,left:a.left,top:a.top,height:a.height,width:a.width},void 0,!0)],46,oe))),128))],36)],12,te)],32))}},re=J._export_sfc(se,[["__scopeId","data-v-07570d07"]]);exports.default=re;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),A=require("./pdf-DV2jHb_u.cjs"),G=require("./useNestedProp-D4Jn2Oxr.cjs"),$=require("./index-kZKcQZM_.cjs"),J=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),K={key:0,"data-html2canvas-ignore":"",style:{width:"100%",display:"flex","justify-content":"end"}},Q=["disabled"],Z=["stroke"],ee={key:1},te=["id"],oe=["onMousedown","onTouchstart"],le=["onMousedown","onTouchstart"],ae=["onMousedown","onTouchstart"],ne=["onMousedown","onTouchstart"],ue=["onMousedown","onTouchstart"],M=20,se={__name:"vue-ui-dashboard",props:{dataset:Array,config:Object},emits:["change"],setup(x,{expose:S,emit:X}){o.useCssVars(e=>({"014a5839":F.value,c96c137e:R.value}));const{vue_ui_dashboard:Y}=$.useConfig(),_=x,r=o.computed(()=>G.useNestedProp({userConfig:_.config,defaultConfig:Y})),E=o.ref($.createUid()),c=o.ref(r.value.locked);function V(){c.value=!c.value}const s=o.ref(_.dataset.map((e,t)=>({...e,index:t}))),h=o.ref(null),u=o.ref(null),v=o.ref({x:0,y:0}),f=o.ref({x:0,y:0}),i=o.ref(null),d=o.ref(!1),p=o.ref(null),m=o.ref(!1),b=o.ref(!1);function z(e){const t=e.target;(t.tagName==="INPUT"&&t.type==="range"||t.classList.contains("range-handle"))&&(b.value=!0)}function N(e){const t=e.target;t.tagName==="INPUT"&&t.type==="range"&&(b.value=!1)}function C(){m.value=!0,A.default({domElement:document.getElementById(`vue-ui-dashboard_${E.value}`),fileName:"vue-ui-dashboard"}).finally(()=>{m.value=!1})}function H(e){if(!c.value&&(d.value=!0,p.value=e,u.value===null)){h.value=e,v.value={x:event.clientX,y:event.clientY};const t=s.value[e],a=100-t.width,l=100-t.height;t.left<0&&(t.left=0),t.top<0&&(t.top=0),t.left>a&&(t.left=a),t.top>l&&(t.top=l),t.left<0&&(t.left=0),t.top<0&&(t.top=0),t.left+t.width>100&&(t.left=100-t.width),t.top+t.height>100&&(t.top=100-t.height)}}function y(e,t){d.value=!0,p.value=e,u.value={index:e,direction:t};const a=s.value[e];f.value={x:event.clientX,y:event.clientY,initialWidth:a.width,initialHeight:a.height}}function B(e,t,a){if(u.value.direction.includes("top")){const l=e.height-a/i.value.offsetHeight*100;l>=M&&(e.top+=a/i.value.offsetHeight*100,e.height=l)}if(u.value.direction.includes("bottom")){const l=e.height+a/i.value.offsetHeight*100;l>=M&&(e.height=l)}if(u.value.direction.includes("left")){const l=e.width-t/i.value.offsetWidth*100;l>=M&&(e.left+=t/i.value.offsetWidth*100,e.width=l)}if(u.value.direction.includes("right")){const l=e.width+t/i.value.offsetWidth*100;l>=M&&(e.width=l)}}function I(e){if(!(c.value||b.value)){if(d.value=!0,h.value!==null){const t=s.value[h.value],a=e.clientX-v.value.x,l=e.clientY-v.value.y,n=t.left+a/i.value.offsetWidth*100,g=t.top+l/i.value.offsetHeight*100;n>=0&&g>=0&&n+t.width<=100&&g+t.height<=100&&(t.left=n,t.top=g),v.value={x:e.clientX,y:e.clientY}}if(u.value!==null){const t=s.value[u.value.index],a=e.clientX-f.value.x,l=e.clientY-f.value.y;B(t,a,l),f.value={x:e.clientX,y:e.clientY}}}}const P=X;o.watch(s,e=>{e&&!d.value&&P("change",s.value)},{deep:!0});function D(){h.value=null,u.value=null,d.value=!1,p.value=null,s.value.forEach(e=>{e.left=Math.round(e.left/100*100),e.top=Math.round(e.top/100*100),e.width=Math.round(e.width/100*100),e.height=Math.round(e.height/100*100)})}function L(e){c.value||b.value||(d.value=!0,p.value=e,u.value===null&&(h.value=e,v.value={x:event.touches[0].clientX,y:event.touches[0].clientY}))}function k(e,t,a){if(d.value=!0,p.value=e,u.value===null){u.value={index:e,direction:t};const l=s.value[e];f.value={x:a.touches[0].clientX,y:a.touches[0].clientY,initialWidth:l.width,initialHeight:l.height}}}function T(e){if(d.value=!0,e.preventDefault(),u.value!==null){const t=s.value[u.value.index],a=e.touches[0].clientX-f.value.x,l=e.touches[0].clientY-f.value.y;B(t,a,l),f.value={x:e.touches[0].clientX,y:e.touches[0].clientY}}}function W(e){if(!(c.value||b.value)&&(d.value=!0,e.preventDefault(),h.value!==null)){const t=s.value[h.value],a=e.touches[0].clientX-v.value.x,l=e.touches[0].clientY-v.value.y,n=t.left+a/i.value.offsetWidth*100,g=t.top+l/i.value.offsetHeight*100;n>=0&&g>=0&&n+t.width<=100&&g+t.height<=100&&(t.left=n,t.top=g),v.value={x:e.touches[0].clientX,y:e.touches[0].clientY}}}function w(){d.value=!1,p.value=null,h.value=null,u.value=null,s.value.forEach(e=>{e.left=Math.round(e.left/100*100),e.top=Math.round(e.top/100*100),e.width=Math.round(e.width/100*100),e.height=Math.round(e.height/100*100)})}const F=o.computed(()=>r.value.style.item.borderColor),R=o.computed(()=>r.value.style.resizeHandles.backgroundColor),q=o.computed(()=>r.value.style.board.aspectRatio),O=o.computed(()=>r.value.style.board.backgroundColor),U=o.computed(()=>r.value.style.board.border);function j(){return s.value}return S({generatePdf:C,getItemsPositions:j,toggleLock:V}),(e,t)=>(o.openBlock(),o.createElementBlock("div",{onMousedown:z,onMouseup:N,onTouchstart:z,onTouchend:N},[r.value.allowPrint?(o.openBlock(),o.createElementBlock("div",K,[o.createElementVNode("button",{class:"vue-ui-dashboard-button",onClick:C,disabled:m.value,style:o.normalizeStyle([{"margin-top":"12px"},`color:${r.value.style.board.color}`])},[m.value?(o.openBlock(),o.createElementBlock("svg",{key:0,class:"vue-ui-dashboard-print-icon",xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:r.value.style.board.color,fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},t[4]||(t[4]=[o.createStaticVNode('<path stroke="none" d="M0 0h24v24H0z" fill="none" data-v-07570d07></path><path d="M18 16v.01" data-v-07570d07></path><path d="M6 16v.01" data-v-07570d07></path><path d="M12 5v.01" data-v-07570d07></path><path d="M12 12v.01" data-v-07570d07></path><path d="M12 1a4 4 0 0 1 2.001 7.464l.001 .072a3.998 3.998 0 0 1 1.987 3.758l.22 .128a3.978 3.978 0 0 1 1.591 -.417l.2 -.005a4 4 0 1 1 -3.994 3.77l-.28 -.16c-.522 .25 -1.108 .39 -1.726 .39c-.619 0 -1.205 -.14 -1.728 -.391l-.279 .16l.007 .231a4 4 0 1 1 -2.212 -3.579l.222 -.129a3.998 3.998 0 0 1 1.988 -3.756l.002 -.071a4 4 0 0 1 -1.995 -3.265l-.005 -.2a4 4 0 0 1 4 -4z" data-v-07570d07></path>',6)]),8,Z)):(o.openBlock(),o.createElementBlock("span",ee,"PDF"))],12,Q)])):o.createCommentVNode("",!0),o.createElementVNode("div",{class:"vue-ui-dashboard-container",ref_key:"dashboardContainer",ref:i,id:`vue-ui-dashboard_${E.value}`,style:o.normalizeStyle(`border:${U.value}; sbackground:${O.value}; aspect-ratio:${q.value}`)},[o.createElementVNode("div",{class:"vue-ui-dashboard-grid-container",ref:"container",onMousemove:I,onMouseup:D,onTouchmove:W,onTouchend:w,style:o.normalizeStyle(`background:${r.value.style.board.backgroundColor}`)},[t[5]||(t[5]=o.createElementVNode("div",{class:"vue-ui-dashboard-grid"},null,-1)),(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(s.value,(a,l)=>(o.openBlock(),o.createElementBlock("div",{key:a.id,class:o.normalizeClass({"vue-ui-dashboard-grid-item":!0,"vue-ui-dashboard-grid-item--locked":c.value}),style:o.normalizeStyle({width:`${a.width}%`,height:`${a.height}%`,left:`${a.left}%`,top:`${a.top}%`,cursor:"move",boxShadow:p.value===l?"0 6px 12px -3px rgba(0,0,0,0.3)":"",zIndex:p.value===l?s.value.length+1:a.index,backgroundColor:r.value.style.item.backgroundColor}),onMousedown:n=>H(l),onTouchstart:n=>L(l)},[c.value?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-top-left",onMousedown:n=>y(l,"top-left"),onTouchstart:n=>k(l,"top-left",n),onTouchmove:t[0]||(t[0]=n=>T(n)),onTouchend:w},null,40,le),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-top-right",onMousedown:n=>y(l,"top-right"),onTouchstart:n=>k(l,"top-right",n),onTouchmove:t[1]||(t[1]=n=>T(n)),onTouchend:w},null,40,ae),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-bottom-left",onMousedown:n=>y(l,"bottom-left"),onTouchstart:n=>k(l,"bottom-left",n),onTouchmove:t[2]||(t[2]=n=>T(n)),onTouchend:w},null,40,ne),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-bottom-right",onMousedown:n=>y(l,"bottom-right"),onTouchstart:n=>k(l,"bottom-right",n),onTouchmove:t[3]||(t[3]=n=>T(n)),onTouchend:w},null,40,ue)],64)),o.renderSlot(e.$slots,"content",{item:a,index:l,left:a.left,top:a.top,height:a.height,width:a.width},void 0,!0)],46,oe))),128))],36)],12,te)],32))}},re=J._export_sfc(se,[["__scopeId","data-v-07570d07"]]);exports.default=re;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),g=require("./useNestedProp-BzGIy5aD.cjs"),L=require("./index-Cww7pocd.cjs"),f={key:0},m=["d","fill"],k=["d","fill"],h=["d","fill"],v=["d","fill"],C=["d","fill"],N=["d","fill"],b=["d","fill"],B={key:1},E=["cx","cy","fill"],q={__name:"Digit",props:{quanta:{type:String,default:null},backgroundColor:{type:String,default:"#e1e5e8"},color:{type:String,default:"#000000"},x:{type:Number,default:0},y:{type:Number,default:0}},setup(e){const $=e,u=t.ref({0:"1111110",1:"0110000",2:"1101101",3:"1111001",4:"0110011",5:"1011011",6:"1011111",7:"1110000",8:"1111111",9:"1111011","-":"0000001",X:"0000000"}),l=t.computed(()=>[void 0,null].includes($.quanta)?u.value.X:u.value[$.quanta]);return(a,x)=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[[void 0,null,"."].includes(e.quanta)?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock("g",f,[t.createElementVNode("path",{d:`M ${e.x} ${e.y} L ${e.x+2} ${e.y-2} L ${e.x+24} ${e.y-2} L ${e.x+26} ${e.y} L ${e.x+24} ${e.y+2} L ${e.x+2} ${e.y+2}Z`,fill:l.value[0]==1?e.color:e.backgroundColor,stroke:"none"},null,8,m),t.createElementVNode("path",{d:`M ${e.x+26} ${e.y+26} L ${e.x+26} ${e.y+4} L ${e.x+28} ${e.y+2} L ${e.x+30} ${e.y+4} L ${e.x+30} ${e.y+26} L ${e.x+28} ${e.y+28} L ${e.x+26} ${e.y+26}`,fill:l.value[1]==1?e.color:e.backgroundColor,stroke:"none"},null,8,k),t.createElementVNode("path",{d:`M ${e.x+26} ${e.y+56} L ${e.x+26} ${e.y+34} L ${e.x+28} ${e.y+32} L ${e.x+30} ${e.y+34} L ${e.x+30} ${e.y+56} L ${e.x+28} ${e.y+58} L ${e.x+26} ${e.y+56}`,fill:l.value[2]==1?e.color:e.backgroundColor,stroke:"none"},null,8,h),t.createElementVNode("path",{d:`M ${e.x+2} ${e.y+58} L ${e.x} ${e.y+60} L ${e.x+2} ${e.y+62} L ${e.x+24} ${e.y+62} L ${e.x+26} ${e.y+60} L ${e.x+24} ${e.y+58} L ${e.x+2} ${e.y+58}`,fill:l.value[3]==1?e.color:e.backgroundColor,stroke:"none"},null,8,v),t.createElementVNode("path",{d:`M ${e.x} ${e.y+34} L ${e.x-2} ${e.y+32} L ${e.x-4} ${e.y+34} L ${e.x-4} ${e.y+56} L ${e.x-2} ${e.y+58} L ${e.x} ${e.y+56} L ${e.x} ${e.y+34}`,fill:l.value[4]==1?e.color:e.backgroundColor,stroke:"none"},null,8,C),t.createElementVNode("path",{d:`M ${e.x-2} ${e.y+2} L ${e.x} ${e.y+4} L ${e.x} ${e.y+26} L ${e.x-2} ${e.y+28} L ${e.x-4} ${e.y+26} L ${e.x-4} ${e.y+4} L ${e.x-2} ${e.y+2}`,fill:l.value[5]==1?e.color:e.backgroundColor,stroke:"none"},null,8,N),t.createElementVNode("path",{d:`M ${e.x+2} ${e.y+28} L ${e.x} ${e.y+30} L ${e.x+2} ${e.y+32} L ${e.x+24} ${e.y+32} L ${e.x+26} ${e.y+30} L ${e.x+24} ${e.y+28} L ${e.x+2} ${e.y+28}`,fill:l.value[6]==1?e.color:e.backgroundColor,stroke:"none"},null,8,b)])),e.quanta=="."?(t.openBlock(),t.createElementBlock("g",B,[t.createElementVNode("circle",{cx:e.x-8,cy:e.y+60,r:3,fill:e.color},null,8,E)])):t.createCommentVNode("",!0)],64))}},M=["xmlns","viewBox"],V={__name:"vue-ui-digits",props:{dataset:{type:Number,default:0},config:{type:Object,default(){return{}}}},setup(e){const{vue_ui_digits:$}=L.useConfig(),u=e,l=t.computed(()=>g.useNestedProp({userConfig:u.config,defaultConfig:$})),a=t.computed(()=>{const c=(u.dataset||0).toString().split(""),i=[],n={x:10,y:10};let d=0;for(let y=0;y<c.length;y+=1){const o=c[y];i.push({x:n.x+d,y:n.y,quanta:o}),o=="."?d+=2:d+=44}return i}),x=t.computed(()=>Math.max(...a.value.map(c=>c.x))+36);return(c,i)=>(t.openBlock(),t.createElementBlock("svg",{class:"vue-ui-digits",xmlns:t.unref(L.XMLNS),viewBox:`0 0 ${x.value} 80`,style:t.normalizeStyle(`background:${l.value.backgroundColor};${l.value.height?`height:${l.value.height};`:""}${l.value.width?`width:${l.value.width}`:""}`)},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.value,n=>(t.openBlock(),t.createBlock(q,{x:n.x,y:n.y,quanta:n.quanta,color:l.value.digits.color,backgroundColor:l.value.digits.skeletonColor},null,8,["x","y","quanta","color","backgroundColor"]))),256))],12,M))}};exports.default=V;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),g=require("./useNestedProp-D4Jn2Oxr.cjs"),L=require("./index-kZKcQZM_.cjs"),f={key:0},m=["d","fill"],k=["d","fill"],h=["d","fill"],v=["d","fill"],C=["d","fill"],N=["d","fill"],b=["d","fill"],B={key:1},E=["cx","cy","fill"],q={__name:"Digit",props:{quanta:{type:String,default:null},backgroundColor:{type:String,default:"#e1e5e8"},color:{type:String,default:"#000000"},x:{type:Number,default:0},y:{type:Number,default:0}},setup(e){const $=e,u=t.ref({0:"1111110",1:"0110000",2:"1101101",3:"1111001",4:"0110011",5:"1011011",6:"1011111",7:"1110000",8:"1111111",9:"1111011","-":"0000001",X:"0000000"}),l=t.computed(()=>[void 0,null].includes($.quanta)?u.value.X:u.value[$.quanta]);return(a,x)=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[[void 0,null,"."].includes(e.quanta)?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock("g",f,[t.createElementVNode("path",{d:`M ${e.x} ${e.y} L ${e.x+2} ${e.y-2} L ${e.x+24} ${e.y-2} L ${e.x+26} ${e.y} L ${e.x+24} ${e.y+2} L ${e.x+2} ${e.y+2}Z`,fill:l.value[0]==1?e.color:e.backgroundColor,stroke:"none"},null,8,m),t.createElementVNode("path",{d:`M ${e.x+26} ${e.y+26} L ${e.x+26} ${e.y+4} L ${e.x+28} ${e.y+2} L ${e.x+30} ${e.y+4} L ${e.x+30} ${e.y+26} L ${e.x+28} ${e.y+28} L ${e.x+26} ${e.y+26}`,fill:l.value[1]==1?e.color:e.backgroundColor,stroke:"none"},null,8,k),t.createElementVNode("path",{d:`M ${e.x+26} ${e.y+56} L ${e.x+26} ${e.y+34} L ${e.x+28} ${e.y+32} L ${e.x+30} ${e.y+34} L ${e.x+30} ${e.y+56} L ${e.x+28} ${e.y+58} L ${e.x+26} ${e.y+56}`,fill:l.value[2]==1?e.color:e.backgroundColor,stroke:"none"},null,8,h),t.createElementVNode("path",{d:`M ${e.x+2} ${e.y+58} L ${e.x} ${e.y+60} L ${e.x+2} ${e.y+62} L ${e.x+24} ${e.y+62} L ${e.x+26} ${e.y+60} L ${e.x+24} ${e.y+58} L ${e.x+2} ${e.y+58}`,fill:l.value[3]==1?e.color:e.backgroundColor,stroke:"none"},null,8,v),t.createElementVNode("path",{d:`M ${e.x} ${e.y+34} L ${e.x-2} ${e.y+32} L ${e.x-4} ${e.y+34} L ${e.x-4} ${e.y+56} L ${e.x-2} ${e.y+58} L ${e.x} ${e.y+56} L ${e.x} ${e.y+34}`,fill:l.value[4]==1?e.color:e.backgroundColor,stroke:"none"},null,8,C),t.createElementVNode("path",{d:`M ${e.x-2} ${e.y+2} L ${e.x} ${e.y+4} L ${e.x} ${e.y+26} L ${e.x-2} ${e.y+28} L ${e.x-4} ${e.y+26} L ${e.x-4} ${e.y+4} L ${e.x-2} ${e.y+2}`,fill:l.value[5]==1?e.color:e.backgroundColor,stroke:"none"},null,8,N),t.createElementVNode("path",{d:`M ${e.x+2} ${e.y+28} L ${e.x} ${e.y+30} L ${e.x+2} ${e.y+32} L ${e.x+24} ${e.y+32} L ${e.x+26} ${e.y+30} L ${e.x+24} ${e.y+28} L ${e.x+2} ${e.y+28}`,fill:l.value[6]==1?e.color:e.backgroundColor,stroke:"none"},null,8,b)])),e.quanta=="."?(t.openBlock(),t.createElementBlock("g",B,[t.createElementVNode("circle",{cx:e.x-8,cy:e.y+60,r:3,fill:e.color},null,8,E)])):t.createCommentVNode("",!0)],64))}},M=["xmlns","viewBox"],V={__name:"vue-ui-digits",props:{dataset:{type:Number,default:0},config:{type:Object,default(){return{}}}},setup(e){const{vue_ui_digits:$}=L.useConfig(),u=e,l=t.computed(()=>g.useNestedProp({userConfig:u.config,defaultConfig:$})),a=t.computed(()=>{const c=(u.dataset||0).toString().split(""),i=[],n={x:10,y:10};let d=0;for(let y=0;y<c.length;y+=1){const o=c[y];i.push({x:n.x+d,y:n.y,quanta:o}),o=="."?d+=2:d+=44}return i}),x=t.computed(()=>Math.max(...a.value.map(c=>c.x))+36);return(c,i)=>(t.openBlock(),t.createElementBlock("svg",{class:"vue-ui-digits",xmlns:t.unref(L.XMLNS),viewBox:`0 0 ${x.value} 80`,style:t.normalizeStyle(`background:${l.value.backgroundColor};${l.value.height?`height:${l.value.height};`:""}${l.value.width?`width:${l.value.width}`:""}`)},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.value,n=>(t.openBlock(),t.createBlock(q,{x:n.x,y:n.y,quanta:n.quanta,color:l.value.digits.color,backgroundColor:l.value.digits.skeletonColor},null,8,["x","y","quanta","color","backgroundColor"]))),256))],12,M))}};exports.default=V;
@@ -1,6 +1,6 @@
1
1
  import { ref as k, computed as d, createElementBlock as i, openBlock as $, Fragment as o, createCommentVNode as m, createElementVNode as l, normalizeStyle as v, unref as C, renderList as b, createBlock as N } from "vue";
2
- import { u as q } from "./useNestedProp-BWzyGJZ8.js";
3
- import { u as M, X as S } from "./index-y7ebFPbO.js";
2
+ import { u as q } from "./useNestedProp-g5oKzlVy.js";
3
+ import { u as M, X as S } from "./index-B9qF6XbP.js";
4
4
  const w = { key: 0 }, B = ["d", "fill"], F = ["d", "fill"], X = ["d", "fill"], E = ["d", "fill"], I = ["d", "fill"], O = ["d", "fill"], A = ["d", "fill"], D = { key: 1 }, G = ["cx", "cy", "fill"], V = {
5
5
  __name: "Digit",
6
6
  props: {