vue-data-ui 2.4.83 → 2.4.85

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 (172) hide show
  1. package/dist/{Arrow-DdtSSnUZ.cjs → Arrow-Ajt3NMEa.cjs} +1 -1
  2. package/dist/{Arrow-Bl2aigOV.js → Arrow-Qayb_B0s.js} +1 -1
  3. package/dist/{BaseIcon-DG_iYn4X.js → BaseIcon-B8U62FEj.js} +1 -1
  4. package/dist/{BaseIcon-D92qdnv7.cjs → BaseIcon-BVrsMbvi.cjs} +1 -1
  5. package/dist/{DataTable-DyvnYg-x.cjs → DataTable-1PQD-SFb.cjs} +1 -1
  6. package/dist/{DataTable-CaiuB_-j.js → DataTable-C0tCPQ9i.js} +2 -2
  7. package/dist/{Legend-D2J3bvDm.cjs → Legend-BJ2Wbqut.cjs} +1 -1
  8. package/dist/{Legend-Br9uWuyZ.js → Legend-BTpe6qQB.js} +2 -2
  9. package/dist/{PackageVersion-Bxz2crF7.cjs → PackageVersion-BjfedMsH.cjs} +1 -1
  10. package/dist/{PackageVersion-tmgQTzP2.js → PackageVersion-CENy3Lm2.js} +1 -1
  11. package/dist/{PenAndPaper-CJ3Rnk2Q.js → PenAndPaper-Dr7ndoP_.js} +3 -3
  12. package/dist/{PenAndPaper-BFCXiNMF.cjs → PenAndPaper-nqRtAh6J.cjs} +1 -1
  13. package/dist/{Shape-qjsquBuY.cjs → Shape-Boa32JEn.cjs} +1 -1
  14. package/dist/{Shape-6QlwV5xV.js → Shape-zFv85Gc2.js} +1 -1
  15. package/dist/{Slicer-B9BStSWS.js → Slicer-BUYuk07t.js} +109 -124
  16. package/dist/Slicer-D6QLMg5N.cjs +1 -0
  17. package/dist/{Title-Bhq6SOYu.js → Title-CaET2xuF.js} +1 -1
  18. package/dist/{Title-BqNuK5vc.cjs → Title-DJUxOiaO.cjs} +1 -1
  19. package/dist/{Tooltip-CeBpQ6yn.js → Tooltip-Bkc4233T.js} +1 -1
  20. package/dist/{Tooltip-Kn7RnF0L.cjs → Tooltip-C5QuW94e.cjs} +1 -1
  21. package/dist/{index-BqR_a-C7.js → index-B7nCQFK0.js} +2 -1
  22. package/dist/index-COIn1phv.cjs +9 -0
  23. package/dist/style.css +1 -1
  24. package/dist/types/vue-data-ui.d.cts +1 -0
  25. package/dist/types/vue-data-ui.d.ts +1 -0
  26. package/dist/{useNestedProp-DqofSFeh.js → useNestedProp-C9rlBRTT.js} +1 -1
  27. package/dist/{useNestedProp-D_XfpfnF.cjs → useNestedProp-CbMuGGl3.cjs} +1 -1
  28. package/dist/{usePrinter-BPjMJmKg.js → usePrinter-CQMn1b4E.js} +1 -1
  29. package/dist/{usePrinter-Bfrr3DDK.cjs → usePrinter-CXXfgFFN.cjs} +1 -1
  30. package/dist/{vue-data-ui-DsBOcTDd.js → vue-data-ui-BnsKGbqb.js} +60 -60
  31. package/dist/{vue-data-ui-oW2xn5YG.cjs → vue-data-ui-Bu_VIHgr.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-DL4o7lJD.cjs → vue-ui-3d-bar-D39F2dKF.cjs} +1 -1
  35. package/dist/{vue-ui-3d-bar-D5BCQifA.js → vue-ui-3d-bar-V5FBS9MA.js} +9 -9
  36. package/dist/{vue-ui-accordion-Cz3VCEN0.js → vue-ui-accordion-B8ptB5BQ.js} +3 -3
  37. package/dist/{vue-ui-accordion-Sqna6-tk.cjs → vue-ui-accordion-CGlnNTr8.cjs} +1 -1
  38. package/dist/vue-ui-age-pyramid-BdseHKUc.cjs +1 -0
  39. package/dist/{vue-ui-age-pyramid-Cl9eaBGr.js → vue-ui-age-pyramid-Bjp1R8Ku.js} +14 -12
  40. package/dist/{vue-ui-annotator-Ctx3YK1X.cjs → vue-ui-annotator-BoWZZRPg.cjs} +1 -1
  41. package/dist/{vue-ui-annotator-DQKvjXgI.js → vue-ui-annotator-V9m5fTGG.js} +1 -1
  42. package/dist/{vue-ui-bullet-CsMr2xzr.js → vue-ui-bullet-Bqvb5PV-.js} +8 -8
  43. package/dist/{vue-ui-bullet-CWJzycj2.cjs → vue-ui-bullet-DLIxlhFF.cjs} +1 -1
  44. package/dist/{vue-ui-candlestick-DKjfum_x.cjs → vue-ui-candlestick-D4BD8LyJ.cjs} +2 -2
  45. package/dist/{vue-ui-candlestick-BZ12fWHz.js → vue-ui-candlestick-DHCtmsh3.js} +72 -70
  46. package/dist/{vue-ui-carousel-table-CDR1Vv5V.js → vue-ui-carousel-table-Cn2RJkSb.js} +4 -4
  47. package/dist/{vue-ui-carousel-table-C6L5d_Fz.cjs → vue-ui-carousel-table-VIuoh2QI.cjs} +1 -1
  48. package/dist/{vue-ui-chestnut-CAnxXvl6.js → vue-ui-chestnut-C5qUO1uK.js} +8 -8
  49. package/dist/{vue-ui-chestnut-DFgQWktZ.cjs → vue-ui-chestnut-ClG9HZoC.cjs} +1 -1
  50. package/dist/{vue-ui-cursor-BHKTewso.cjs → vue-ui-cursor-Bo8et-dD.cjs} +1 -1
  51. package/dist/{vue-ui-cursor-CEG5U4Hg.js → vue-ui-cursor-eJau3iyr.js} +2 -2
  52. package/dist/{vue-ui-dashboard-CAZvucxS.js → vue-ui-dashboard-DnaH9bCw.js} +2 -2
  53. package/dist/{vue-ui-dashboard-cCxI_-fr.cjs → vue-ui-dashboard-WJqGQ8iR.cjs} +1 -1
  54. package/dist/{vue-ui-digits-xPdav4hy.js → vue-ui-digits-Cqjts2eq.js} +2 -2
  55. package/dist/{vue-ui-digits-Dl0z8lL5.cjs → vue-ui-digits-qIckO4-r.cjs} +1 -1
  56. package/dist/vue-ui-donut-BP7yj2DU.cjs +1 -0
  57. package/dist/{vue-ui-donut-evolution-BgXDvYij.cjs → vue-ui-donut-evolution-Cz8uFJp8.cjs} +1 -1
  58. package/dist/{vue-ui-donut-evolution-DtfH9oY2.js → vue-ui-donut-evolution-EzYvP11F.js} +11 -11
  59. package/dist/{vue-ui-donut-BX4NBJNA.js → vue-ui-donut-pprcnbIw.js} +17 -15
  60. package/dist/vue-ui-dumbbell-CYqHCr2S.cjs +9 -0
  61. package/dist/{vue-ui-dumbbell-DgTOdhga.js → vue-ui-dumbbell-DaxcxmnU.js} +48 -46
  62. package/dist/{vue-ui-flow-DIbRLuAg.js → vue-ui-flow-DbRgaKBu.js} +9 -9
  63. package/dist/{vue-ui-flow-Bt0sz3lA.cjs → vue-ui-flow-HeRCplGL.cjs} +1 -1
  64. package/dist/{vue-ui-funnel-CedEHtHD.js → vue-ui-funnel-B2del8KB.js} +37 -35
  65. package/dist/vue-ui-funnel-DxniWNkD.cjs +1 -0
  66. package/dist/{vue-ui-galaxy-aqDlVOGG.cjs → vue-ui-galaxy-BDA64dud.cjs} +1 -1
  67. package/dist/{vue-ui-galaxy-BcBicruu.js → vue-ui-galaxy-pUYeASJf.js} +11 -11
  68. package/dist/vue-ui-gauge-BOXoAgWk.cjs +1 -0
  69. package/dist/{vue-ui-gauge-B8ybUmVP.js → vue-ui-gauge-DpsXpEaW.js} +28 -26
  70. package/dist/{vue-ui-gizmo-J759kkHO.js → vue-ui-gizmo-BpYrhkon.js} +3 -3
  71. package/dist/{vue-ui-gizmo-DAzVCVgd.cjs → vue-ui-gizmo-Bq9uAmqd.cjs} +1 -1
  72. package/dist/{vue-ui-heatmap-5PChWU--.cjs → vue-ui-heatmap-CbKgGLtN.cjs} +1 -1
  73. package/dist/{vue-ui-heatmap-zXe_ZfjW.js → vue-ui-heatmap-Cz6_9Veh.js} +10 -10
  74. package/dist/vue-ui-history-plot-BoMdvItE.cjs +1 -0
  75. package/dist/{vue-ui-history-plot-DpCqc_J5.js → vue-ui-history-plot-DAotUjSF.js} +56 -54
  76. package/dist/{vue-ui-kpi-B0YGZB0U.js → vue-ui-kpi-Ch2p7m-i.js} +3 -3
  77. package/dist/{vue-ui-kpi-C-7Ihvt0.cjs → vue-ui-kpi-D6mp6EQ2.cjs} +1 -1
  78. package/dist/{vue-ui-mini-loader-Cn4Q6TSw.cjs → vue-ui-mini-loader-CO-KGVlC.cjs} +1 -1
  79. package/dist/{vue-ui-mini-loader-7sjb3XBu.js → vue-ui-mini-loader-E13lmwfO.js} +2 -2
  80. package/dist/{vue-ui-molecule-DZpXgYuN.js → vue-ui-molecule-C69K6EPO.js} +11 -11
  81. package/dist/{vue-ui-molecule-BDumH6dl.cjs → vue-ui-molecule-CeoDnPXB.cjs} +1 -1
  82. package/dist/{vue-ui-mood-radar-pnwFktum.cjs → vue-ui-mood-radar-BwOqQUuT.cjs} +1 -1
  83. package/dist/{vue-ui-mood-radar-CKqyK1Hp.js → vue-ui-mood-radar-DDtky572.js} +11 -11
  84. package/dist/{vue-ui-nested-donuts-DbxWMbwd.js → vue-ui-nested-donuts-AYPYIRrE.js} +16 -14
  85. package/dist/{vue-ui-nested-donuts-CHpsvVxD.cjs → vue-ui-nested-donuts-DMCd6DqT.cjs} +2 -2
  86. package/dist/{vue-ui-onion-F9rcTxc5.cjs → vue-ui-onion-BedLvfFe.cjs} +2 -2
  87. package/dist/{vue-ui-onion-q54wqIiz.js → vue-ui-onion-Bsa88sKK.js} +31 -29
  88. package/dist/{vue-ui-parallel-coordinate-plot-Cwnja7PH.cjs → vue-ui-parallel-coordinate-plot-CSOMIABF.cjs} +2 -2
  89. package/dist/{vue-ui-parallel-coordinate-plot-myA1ugJ6.js → vue-ui-parallel-coordinate-plot-KCEb4iRs.js} +62 -60
  90. package/dist/vue-ui-quadrant-BXQVOvpY.cjs +1 -0
  91. package/dist/{vue-ui-quadrant-OoCEzm12.js → vue-ui-quadrant-Bd_88Eht.js} +16 -14
  92. package/dist/{vue-ui-quick-chart-5lnK5fYa.js → vue-ui-quick-chart-CXAYKYHa.js} +55 -53
  93. package/dist/{vue-ui-quick-chart-CazRj-4z.cjs → vue-ui-quick-chart-dLItYwM_.cjs} +2 -2
  94. package/dist/vue-ui-radar-BuNtocmn.cjs +1 -0
  95. package/dist/{vue-ui-radar-BDKh_0GC.js → vue-ui-radar-De397oTB.js} +100 -98
  96. package/dist/{vue-ui-rating-BOzhaiSc.cjs → vue-ui-rating-BjiMVoyX.cjs} +1 -1
  97. package/dist/{vue-ui-rating-Dt3vyE2H.js → vue-ui-rating-wK3_ZWE5.js} +2 -2
  98. package/dist/vue-ui-relation-circle-BEGyr1h-.cjs +1 -0
  99. package/dist/{vue-ui-relation-circle-BOMeOf10.js → vue-ui-relation-circle-BxlK8MVs.js} +56 -54
  100. package/dist/{vue-ui-rings-3O2lFlg1.js → vue-ui-rings-BXrtMSML.js} +39 -37
  101. package/dist/{vue-ui-rings-DIA0oj1w.cjs → vue-ui-rings-BcNMBXxq.cjs} +2 -2
  102. package/dist/{vue-ui-scatter-SRz39O4w.js → vue-ui-scatter-BWZfLJ9P.js} +52 -50
  103. package/dist/vue-ui-scatter-DTy3yPVu.cjs +1 -0
  104. package/dist/{vue-ui-screenshot-OBhZYkuN.cjs → vue-ui-screenshot-BJgOwFMW.cjs} +1 -1
  105. package/dist/{vue-ui-screenshot-DeseMlsh.js → vue-ui-screenshot-hw4PC9Uu.js} +1 -1
  106. package/dist/{vue-ui-skeleton-6_VzxeeY.cjs → vue-ui-skeleton-BIqMxXV7.cjs} +1 -1
  107. package/dist/{vue-ui-skeleton-DbI8wJH-.js → vue-ui-skeleton-D66ZIUln.js} +3 -3
  108. package/dist/{vue-ui-smiley-BqRjGeM4.js → vue-ui-smiley-DWPYdcDB.js} +2 -2
  109. package/dist/{vue-ui-smiley-CQYCG8iR.cjs → vue-ui-smiley-Duy5Xo-j.cjs} +1 -1
  110. package/dist/{vue-ui-spark-trend-YKlzV5ph.js → vue-ui-spark-trend-Ce4IaqPz.js} +5 -5
  111. package/dist/{vue-ui-spark-trend-C1MfKChb.cjs → vue-ui-spark-trend-DP5foaNi.cjs} +1 -1
  112. package/dist/{vue-ui-sparkbar-BGc7K3E7.cjs → vue-ui-sparkbar-Bbns4V16.cjs} +1 -1
  113. package/dist/{vue-ui-sparkbar-BEY67Uh8.js → vue-ui-sparkbar-Fa-Kc9Fr.js} +4 -4
  114. package/dist/{vue-ui-sparkgauge-DBJ6JcY4.cjs → vue-ui-sparkgauge-BrLrvNLH.cjs} +1 -1
  115. package/dist/{vue-ui-sparkgauge-COy9kS3g.js → vue-ui-sparkgauge-DUWcJ7cM.js} +4 -4
  116. package/dist/{vue-ui-sparkhistogram-Kof1NLnh.cjs → vue-ui-sparkhistogram-B0rhs_UN.cjs} +1 -1
  117. package/dist/{vue-ui-sparkhistogram-TOZ7cGZE.js → vue-ui-sparkhistogram-PgC-c-5a.js} +5 -5
  118. package/dist/{vue-ui-sparkline-Corg_lTS.js → vue-ui-sparkline-BqNlrKjb.js} +37 -35
  119. package/dist/vue-ui-sparkline-c5Awoj8J.cjs +1 -0
  120. package/dist/{vue-ui-sparkstackbar-2Vwz74c6.cjs → vue-ui-sparkstackbar-BmYIcpVZ.cjs} +1 -1
  121. package/dist/{vue-ui-sparkstackbar-D-W-02aO.js → vue-ui-sparkstackbar-DyJIUulr.js} +5 -5
  122. package/dist/{vue-ui-stackbar-DRLdPZii.js → vue-ui-stackbar-BebRtOYL.js} +55 -53
  123. package/dist/{vue-ui-stackbar-DZvxTz3J.cjs → vue-ui-stackbar-DJ9NH_l1.cjs} +2 -2
  124. package/dist/{vue-ui-strip-plot-tQk3HsSn.js → vue-ui-strip-plot-BGHj1BHd.js} +77 -75
  125. package/dist/vue-ui-strip-plot-f7vejZht.cjs +1 -0
  126. package/dist/{vue-ui-table-G09LTync.cjs → vue-ui-table-BFdGppRF.cjs} +1 -1
  127. package/dist/{vue-ui-table-CNsJsvNH.js → vue-ui-table-ClPMKcMn.js} +1 -1
  128. package/dist/{vue-ui-table-heatmap-Dl4lMTS6.cjs → vue-ui-table-heatmap-B7wTjM-H.cjs} +1 -1
  129. package/dist/{vue-ui-table-heatmap-CTs7AxUi.js → vue-ui-table-heatmap-DVQtPt-M.js} +4 -4
  130. package/dist/{vue-ui-table-sparkline-Dy5shfoJ.cjs → vue-ui-table-sparkline-DaKODjfM.cjs} +1 -1
  131. package/dist/{vue-ui-table-sparkline-ZtfktJZh.js → vue-ui-table-sparkline-DjxKXWQm.js} +5 -5
  132. package/dist/{vue-ui-thermometer-CaFnSru6.js → vue-ui-thermometer-CV_9k37V.js} +7 -7
  133. package/dist/{vue-ui-thermometer-039Cyhc2.cjs → vue-ui-thermometer-DE9r0emf.cjs} +1 -1
  134. package/dist/{vue-ui-timer-ChuLD5VW.js → vue-ui-timer-2w5Ayq7G.js} +35 -33
  135. package/dist/vue-ui-timer-Ct-KYWSX.cjs +64 -0
  136. package/dist/{vue-ui-tiremarks-nDFTQjHJ.js → vue-ui-tiremarks-BJnh0GBj.js} +7 -7
  137. package/dist/{vue-ui-tiremarks-BiLfVwpF.cjs → vue-ui-tiremarks-Cf04zARl.cjs} +1 -1
  138. package/dist/{vue-ui-treemap-Dv9HNV59.js → vue-ui-treemap-BD546LBi.js} +37 -35
  139. package/dist/vue-ui-treemap-D0vi4bv4.cjs +1 -0
  140. package/dist/{vue-ui-vertical-bar-W7AgfJa9.cjs → vue-ui-vertical-bar-D3QKHHnS.cjs} +2 -2
  141. package/dist/{vue-ui-vertical-bar-M3IDlqbG.js → vue-ui-vertical-bar-E5CTb1Bd.js} +53 -51
  142. package/dist/{vue-ui-waffle-CJYfXE-I.js → vue-ui-waffle-BAJIMbZK.js} +50 -48
  143. package/dist/vue-ui-waffle-BL0e3Yeq.cjs +1 -0
  144. package/dist/{vue-ui-wheel-BaMfH-RC.js → vue-ui-wheel-CPPLUSFq.js} +22 -20
  145. package/dist/vue-ui-wheel-Dy_B7BTG.cjs +1 -0
  146. package/dist/vue-ui-word-cloud-BPoAoeWZ.cjs +1 -0
  147. package/dist/{vue-ui-word-cloud-qympaTse.js → vue-ui-word-cloud-BVZcDY7m.js} +47 -45
  148. package/dist/vue-ui-xy-D4hRtHAi.cjs +3 -0
  149. package/dist/{vue-ui-xy-canvas-Dn_4rMul.cjs → vue-ui-xy-canvas-BSZTrqci.cjs} +2 -2
  150. package/dist/{vue-ui-xy-canvas-qk5Vd9ng.js → vue-ui-xy-canvas-DFUfTZwz.js} +36 -34
  151. package/dist/{vue-ui-xy-BB_4gujH.js → vue-ui-xy-tB-6IP2y.js} +833 -839
  152. package/package.json +1 -1
  153. package/dist/Slicer-BZ-tooWv.cjs +0 -1
  154. package/dist/index-D4M1RdVn.cjs +0 -9
  155. package/dist/vue-ui-age-pyramid-BP3AgRGA.cjs +0 -1
  156. package/dist/vue-ui-donut--6AZz6OL.cjs +0 -1
  157. package/dist/vue-ui-dumbbell-6eYMBh5-.cjs +0 -9
  158. package/dist/vue-ui-funnel-CnyUx_rr.cjs +0 -1
  159. package/dist/vue-ui-gauge-Cg5wvQOF.cjs +0 -1
  160. package/dist/vue-ui-history-plot-N8Okj-iE.cjs +0 -1
  161. package/dist/vue-ui-quadrant-BSaMyYkS.cjs +0 -1
  162. package/dist/vue-ui-radar-BBKYxxex.cjs +0 -1
  163. package/dist/vue-ui-relation-circle-COKOM6l_.cjs +0 -1
  164. package/dist/vue-ui-scatter-oA9YA_np.cjs +0 -1
  165. package/dist/vue-ui-sparkline-De42544c.cjs +0 -1
  166. package/dist/vue-ui-strip-plot-CY7AKOJ8.cjs +0 -1
  167. package/dist/vue-ui-timer-BIAfoC2X.cjs +0 -64
  168. package/dist/vue-ui-treemap-8aBLlF51.cjs +0 -1
  169. package/dist/vue-ui-waffle-DefdpuXf.cjs +0 -1
  170. package/dist/vue-ui-wheel-DicUDLkK.cjs +0 -1
  171. package/dist/vue-ui-word-cloud-B5n21JbB.cjs +0 -1
  172. package/dist/vue-ui-xy-Du5PZnkC.cjs +0 -3
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),n=require("./index-COIn1phv.cjs"),ne=require("./useResponsive-BJ7DTGpm.cjs"),we=require("./Title-DJUxOiaO.cjs"),se=require("./usePrinter-CXXfgFFN.cjs"),Be=require("./Tooltip-C5QuW94e.cjs"),Pe=require("./vue-ui-sparkbar-Bbns4V16.cjs"),_e=require("./Legend-BJ2Wbqut.cjs"),$e=require("./DataTable-1PQD-SFb.cjs"),xe=require("./vue-ui-skeleton-BIqMxXV7.cjs"),Ne=require("./vue-ui-accordion-CGlnNTr8.cjs"),ue=require("./useNestedProp-CbMuGGl3.cjs"),Te=require("./PackageVersion-BjfedMsH.cjs"),Se=require("./PenAndPaper-nqRtAh6J.cjs"),Ee=require("./useUserOptionState-BgepsfED.cjs"),Ve=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Fe=["id"],Oe=["xmlns","viewBox"],Ae=["width","height"],Le=["id"],ze=["stop-color"],Ie=["stop-color"],Re={key:1},qe=["x1","y1","x2","y2","stroke","stroke-width"],Me={key:0},Ue=["d","stroke","stroke-width"],De=["d","stroke","stroke-width"],Ge={key:2},We=["x","y","text-anchor","font-size","fill","onMouseenter"],He=["points","stroke","stroke-width"],je=["points","stroke","stroke-width","fill"],Xe={key:3},Ye=["cx","cy","fill","r","stroke"],Je={key:5,class:"vue-data-ui-watermark"},Ke=["onClick"],Qe={key:0,style:{"max-width":"200px",margin:"0 auto"}},Ze={__name:"vue-ui-radar",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},emits:["selectLegend"],setup(ie,{expose:ce,emit:de}){const d=ie,{vue_ui_radar:ve}=n.useConfig(),C=e.computed(()=>!!d.dataset&&Object.keys(d.dataset).length),f=e.ref(n.createUid()),pe=e.ref(null),x=e.ref(!1),N=e.ref(""),L=e.ref(0),m=e.ref(null),z=e.ref(null),I=e.ref(null),R=e.ref(null),q=e.ref(null),M=e.ref(0),U=e.ref(0),D=e.ref(0),t=e.computed({get:()=>H(),set:o=>o}),{userOptionsVisible:T,setUserOptionsVisibility:G,keepUserOptionState:W}=Ee.useUserOptionState({config:t.value});function H(){const o=ue.useNestedProp({userConfig:d.config,defaultConfig:ve});return o.theme?{...ue.useNestedProp({userConfig:n.themes.vue_ui_radar[o.theme]||d.config,defaultConfig:o}),customPalette:n.themePalettes[o.theme]||n.palette}:o}e.watch(()=>d.config,o=>{t.value=H(),T.value=!t.value.showOnChartHover,j(),M.value+=1,U.value+=1,D.value+=1},{deep:!0});const B=e.ref(null);function j(){if(n.objectIsEmpty(d.dataset)&&n.error({componentName:"VueUiRadar",type:"dataset"}),t.value.responsive){const o=ne.throttle(()=>{const{width:a,height:l}=ne.useResponsive({chart:m.value,title:t.value.style.chart.title.text?z.value:null,legend:t.value.style.chart.legend.show?I.value:null,source:R.value,noTitle:q.value});requestAnimationFrame(()=>{u.value.width=a,u.value.height=l})});B.value=new ResizeObserver(o),B.value.observe(m.value.parentNode)}}e.onMounted(()=>{j()}),e.onBeforeUnmount(()=>{B.value&&B.value.disconnect()});const{isPrinting:X,isImaging:Y,generatePdf:J,generateImage:K}=se.usePrinter({elementId:`vue-ui-radar_${f.value}`,fileName:t.value.style.chart.title.text||"vue-ui-radar"}),he=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),Q=e.computed(()=>n.convertCustomPalette(t.value.customPalette)),h=e.ref({dataLabels:{show:t.value.style.chart.layout.labels.dataLabels.show},showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),ge=e.computed(()=>({style:{backgroundColor:"#FFFFFF00",animation:{show:t.value.style.chart.tooltip.animation.show,animationFrames:t.value.style.chart.tooltip.animation.animationFrames},labels:{fontSize:t.value.style.chart.tooltip.fontSize,name:{color:t.value.style.chart.tooltip.color}},gutter:{backgroundColor:"#CCCCCC",opacity:30}}})),u=e.ref({height:312,width:512}),i=e.ref([]),w=e.ref(null),y=e.ref(!1);function Z(o){y.value=!0,i.value.includes(o)?(w.value=o,i.value=i.value.filter(a=>a!==o),setTimeout(()=>{y.value=!1,w.value=null},500)):(i.value.push(o),setTimeout(()=>{y.value=!1},500)),de("selectLegend",k.value.filter((a,l)=>!i.value.includes(l)).map(a=>({name:a.name,color:a.color,proportion:a.totalProportion})))}function fe(){return k.value.map(o=>({name:o.name,color:o.color,proportion:o.totalProportion}))}const v=e.computed(()=>[null,void 0].includes(d.dataset.categories)?(n.error({componentName:"VueUiRadar",type:"datasetAttribute",property:"categories ({ name: string; prefix?: string; suffix?: string}[])"}),[]):(d.dataset.categories.length===0?n.error({componentName:"VueUiRadar",type:"datasetAttributeEmpty",property:"categories"}):d.dataset.categories.forEach((o,a)=>{n.getMissingDatasetAttributes({datasetObject:o,requiredAttributes:["name"]}).forEach(l=>{n.error({componentName:"VueUiRadar",type:"datasetAttribute",property:`category.${l} at index ${a}`,index:a})})}),[null,void 0].includes(d.dataset.series)?n.error({componentName:"VueUiRadar",type:"datasetAttribute",property:"series ({ name: string; values: number[]; color?: string; target: number}[])"}):d.dataset.series.forEach((o,a)=>{n.getMissingDatasetAttributes({datasetObject:o,requiredAttributes:["name","values","target"]}).forEach(l=>{n.error({componentName:"VueUiRadar",type:"datasetSerieAttribute",key:"series",property:l,index:a})})}),d.dataset.categories.map((o,a)=>({name:o.name,categoryId:`radar_category_${f.value}_${a}`,color:n.convertColorToHex(o.color)||Q.value[a]||n.palette[a]||n.palette[a%n.palette.length],prefix:o.prefix??"",suffix:o.suffix??""})))),p=e.computed(()=>C.value?d.dataset.series.map((o,a)=>({...o,color:n.convertColorToHex(o.color)||Q.value[a]||n.palette[a]||n.palette[a%n.palette.length],serieId:`radar_serie_${f.value}_${a}`,formatter:o.formatter||null})):[]),ee=e.computed(()=>Math.max(...p.value.flatMap(o=>o.values))),te=e.computed(()=>p.value.length),S=e.computed(()=>Math.min(u.value.width,u.value.height)/3),oe=e.computed(()=>n.createPolygonPath({plot:{x:u.value.width/2,y:u.value.height/2},radius:S.value,sides:te.value,rotation:0})),me=e.computed(()=>{const o=[];for(let a=0;a<S.value;a+=S.value/t.value.style.chart.layout.grid.graduations)o.push(a);return o}),g=e.computed(()=>oe.value.coordinates.map((o,a)=>{const l=p.value[a].values.map(r=>ye({centerX:u.value.width/2,centerY:u.value.height/2,apexX:o.x,apexY:o.y,proportion:r/(p.value[a].target||ee.value)}));return{...o,...p.value[a],plots:l}}));function E({x:o,y:a}){let l="middle";return o=Math.round(o),a=Math.round(a),o>u.value.width/2&&(o+=12,l="start"),o<u.value.width/2&&(o-=12,l="end"),a>u.value.height/2&&(a+=20),a<u.value.height/2&&(a-=12),a===u.value.height/2&&(a+=4),{x:o,y:a,anchor:l}}function ye({centerX:o,centerY:a,apexX:l,apexY:r,proportion:s}){return{x:o+(l-o)*s,y:a+(r-a)*s}}const k=e.computed(()=>{const o=p.value.map((a,l)=>a.values.map(r=>r/(a.target||ee.value)));return v.value.map((a,l)=>({...a,totalProportion:n.checkNaN(o.map(r=>r[l]).reduce((r,s)=>r+s,0)/p.value.length),shape:"circle",opacity:i.value.includes(l)?.5:1,segregate:()=>Z(l),isSegregated:i.value.includes(l)}))}),ke=e.computed(()=>({cy:"radar-div-legend",backgroundColor:t.value.style.chart.legend.backgroundColor,color:t.value.style.chart.legend.color,fontSize:t.value.style.chart.legend.fontSize,paddingBottom:12,fontWeight:t.value.style.chart.legend.bold?"bold":""})),P=e.computed(()=>{const o=[{name:t.value.translations.datapoint,color:""},{name:t.value.translations.target,color:""},...k.value],a=d.dataset.series.map(r=>[r.name,n.applyDataLabel(r.formatter,r.target,n.dataLabel({p:r.prefix,v:r.target,s:r.suffix,r:t.value.table.td.roundingValue})),...r.values.map((s,c)=>`${n.applyDataLabel(r.formatter,s,n.dataLabel({p:v.value[c].prefix,v:s,s:v.value[c].suffix,r:t.value.table.td.roundingValue}))} (${isNaN(s/r.target)?"":n.dataLabel({v:s/r.target*100,s:"%",r:t.value.table.td.roundingPercentage})})`)]),l={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{head:o,body:a,config:l,colNames:o}}),_=e.ref(null),V=e.ref([]),F=e.ref(null);function be(o,a){V.value=[],_.value=a,x.value=!0;let l="";F.value={datapoint:o,seriesIndex:a,series:{categories:v.value,datapoints:p.value,radar:g.value},config:t.value};const r=t.value.style.chart.tooltip.customFormat;if(n.isFunction(r)&&n.functionReturnsString(()=>r({seriesIndex:a,datapoint:o,series:{categories:v.value,datapoints:p.value,radar:g.value},config:t.value})))N.value=r({seriesIndex:a,datapoint:o,series:{categories:v.value,datapoints:p.value,radar:g.value},config:t.value});else{l+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${o.name}</div>`;for(let s=0;s<o.values.length;s+=1)i.value.includes(s)||V.value.push({name:v.value[s].name,value:o.values[s]/o.target*100,color:v.value[s].color,suffix:"%)",prefix:`${n.dataLabel({p:v.value[s].prefix??"",v:o.values[s],s:v.value[s].suffix??"",r:t.value.style.chart.tooltip.roundingValue})} (`,rounding:t.value.style.chart.tooltip.roundingPercentage,formatter:o.formatter});N.value=l}}function ae(){e.nextTick(()=>{const o=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[""]],a=[[""],[t.value.translations.target],...k.value.flatMap(c=>[[c.name],["%"]])],l=d.dataset.series.map((c,tt)=>[c.name,c.target,...c.values.flatMap(A=>[A,isNaN(A/c.target)?"":A/c.target*100])]),r=o.concat([a]).concat(l),s=n.createCsvContent(r);n.downloadCsv({csvContent:s,title:t.value.style.chart.title.text||"vue-ui-radar"})})}const b=e.ref(!1);function Ce(o){b.value=o,L.value+=1}function le(){h.value.showTable=!h.value.showTable}function re(){h.value.showTooltip=!h.value.showTooltip}const $=e.ref(!1);function O(){$.value=!$.value}return ce({getData:fe,generatePdf:J,generateCsv:ae,generateImage:K,toggleTable:le,toggleTooltip:re,toggleAnnotator:O}),(o,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-radar ${b.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),ref_key:"radarChart",ref:m,id:`vue-ui-radar_${f.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; ${t.value.responsive?"height: 100%;":""} text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:a[3]||(a[3]=()=>e.unref(G)(!0)),onMouseleave:a[4]||(a[4]=()=>e.unref(G)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(Se.PenAndPaper,{key:0,parent:m.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:$.value,onClose:O},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),he.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:q,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:z,style:"width:100%;background:transparent;padding-bottom:12px"},[(e.openBlock(),e.createBlock(we._sfc_main,{key:`title_${M.value}`,config:{title:{cy:"radar-div-title",...t.value.style.chart.title},subtitle:{cy:"radar-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&C.value&&(e.unref(W)||e.unref(T))?(e.openBlock(),e.createBlock(se.UserOptions,{ref_key:"details",ref:pe,key:`user_options_${L.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(Y),isPrinting:e.unref(X),uid:f.value,hasTooltip:t.value.userOptions.buttons.tooltip&&t.value.style.chart.tooltip.show,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:t.value.userOptions.buttons.csv,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:b.value,isTooltip:h.value.showTooltip,titles:{...t.value.userOptions.buttonTitles},chartElement:m.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:$.value,onToggleFullscreen:Ce,onGeneratePdf:e.unref(J),onGenerateCsv:ae,onGenerateImage:e.unref(K),onToggleTable:le,onToggleTooltip:re,onToggleAnnotator:O,style:e.normalizeStyle({visibility:e.unref(W)?e.unref(T)?"visible":"hidden":"visible"})},e.createSlots({_:2},[o.$slots.optionTooltip?{name:"optionTooltip",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTooltip",{},void 0,!0)]),key:"0"}:void 0,o.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionPdf",{},void 0,!0)]),key:"1"}:void 0,o.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionCsv",{},void 0,!0)]),key:"2"}:void 0,o.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionImg",{},void 0,!0)]),key:"3"}:void 0,o.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTable",{},void 0,!0)]),key:"4"}:void 0,o.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:r})=>[e.renderSlot(o.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:r})),void 0,!0)]),key:"5"}:void 0,o.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:l,isAnnotator:r})=>[e.renderSlot(o.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:l,isAnnotator:r})),void 0,!0)]),key:"6"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasTooltip","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","isTooltip","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),C.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(n.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":b.value,"vue-data-ui-fulscreen--off":!b.value}),viewBox:`0 0 ${u.value.width<=0?10:u.value.width} ${u.value.height<=0?10:u.value.height}`,style:e.normalizeStyle(`max-width:100%;overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(Te._sfc_main),o.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:u.value.width<=0?10:u.value.width,height:u.value.height<=0?10:u.value.height,style:{pointerEvents:"none"}},[e.renderSlot(o.$slots,"chart-background",{},void 0,!0)],8,Ae)):e.createCommentVNode("",!0),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(l,r)=>(e.openBlock(),e.createElementBlock("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`radar_gradient_${f.value}_${r}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(n.setOpacity)(e.unref(n.shiftHue)(l.color,.05),t.value.style.chart.layout.dataPolygon.opacity)},null,8,ze),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(n.setOpacity)(l.color,t.value.style.chart.layout.dataPolygon.opacity)},null,8,Ie)],8,Le))),256))]),t.value.style.chart.layout.grid.show?(e.openBlock(),e.createElementBlock("g",Re,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,l=>(e.openBlock(),e.createElementBlock("line",{x1:u.value.width/2,y1:u.value.height/2,x2:l.x,y2:l.y,stroke:t.value.style.chart.layout.grid.stroke,"stroke-width":t.value.style.chart.layout.grid.strokeWidth},null,8,qe))),256)),t.value.style.chart.layout.grid.graduations>0?(e.openBlock(),e.createElementBlock("g",Me,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(me.value,l=>(e.openBlock(),e.createElementBlock("path",{d:e.unref(n.createPolygonPath)({plot:{x:u.value.width/2,y:u.value.height/2},radius:l,sides:te.value,rotation:0}).path,fill:"none",stroke:t.value.style.chart.layout.grid.stroke,"stroke-width":t.value.style.chart.layout.grid.strokeWidth},null,8,Ue))),256))])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("path",{d:oe.value.path,fill:"none",stroke:t.value.style.chart.layout.outerPolygon.stroke,"stroke-width":t.value.style.chart.layout.outerPolygon.strokeWidth,"stroke-linejoin":"round","stroke-linecap":"round"},null,8,De),t.value.style.chart.layout.labels.dataLabels.show?(e.openBlock(),e.createElementBlock("g",Ge,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(l,r)=>(e.openBlock(),e.createElementBlock("text",{x:E(l).x,y:E(l).y,"text-anchor":E(l).anchor,"font-size":t.value.style.chart.layout.labels.dataLabels.fontSize,fill:t.value.style.chart.layout.labels.dataLabels.color,onMouseenter:s=>be(l,r),onMouseleave:a[0]||(a[0]=s=>{x.value=!1,_.value=null})},e.toDisplayString(l.name),41,We))),256))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(l,r)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("g",null,[t.value.useCssAnimation||!t.value.useCssAnimation&&!i.value.includes(r)?(e.openBlock(),e.createElementBlock("polygon",{key:0,"data-cy-radar-path":"",points:e.unref(n.makePath)(g.value.map(s=>s.plots[r]),!1,!0),stroke:t.value.style.chart.backgroundColor,"stroke-width":t.value.style.chart.layout.dataPolygon.strokeWidth+1,fill:"none",class:e.normalizeClass({"animated-out":i.value.includes(r)&&t.value.useCssAnimation,"animated-in":y.value&&w.value===r&&t.value.useCssAnimation})},null,10,He)):e.createCommentVNode("",!0),t.value.useCssAnimation||!t.value.useCssAnimation&&!i.value.includes(r)?(e.openBlock(),e.createElementBlock("polygon",{key:1,"data-cy-radar-path":"",points:e.unref(n.makePath)(g.value.map(s=>s.plots[r]),!1,!0),stroke:l.color,"stroke-width":t.value.style.chart.layout.dataPolygon.strokeWidth,fill:t.value.style.chart.layout.dataPolygon.transparent?"transparent":t.value.style.chart.layout.dataPolygon.useGradient?`url(#radar_gradient_${f.value}_${r})`:e.unref(n.setOpacity)(l.color,t.value.style.chart.layout.dataPolygon.opacity),class:e.normalizeClass({"animated-out":i.value.includes(r)&&t.value.useCssAnimation,"animated-in":y.value&&w.value===r&&t.value.useCssAnimation})},null,10,je)):e.createCommentVNode("",!0)])]))),256)),t.value.style.chart.layout.plots.show?(e.openBlock(),e.createElementBlock("g",Xe,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(l,r)=>(e.openBlock(),e.createElementBlock("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.plots,(s,c)=>(e.openBlock(),e.createElementBlock("circle",{cx:s.x,cy:s.y,fill:i.value.includes(c)?"transparent":v.value[c].color,r:_.value!==null&&_.value===r?t.value.style.chart.layout.plots.radius*1.6:t.value.style.chart.layout.plots.radius,stroke:i.value.includes(c)?"transparent":t.value.style.chart.backgroundColor,"stroke-width":.5,class:e.normalizeClass({"animated-out":i.value.includes(c)&&t.value.useCssAnimation,"animated-in":y.value&&w.value===c&&t.value.useCssAnimation})},null,10,Ye))),256))]))),256))])):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"svg",{svg:u.value},void 0,!0)],14,Oe)):e.createCommentVNode("",!0),o.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Je,[e.renderSlot(o.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(X)||e.unref(Y)})),void 0,!0)])):e.createCommentVNode("",!0),C.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(xe.default,{key:6,config:{type:"radar",style:{backgroundColor:t.value.style.chart.backgroundColor,radar:{grid:{color:t.value.style.chart.layout.outerPolygon.stroke},shapes:{color:t.value.style.chart.layout.outerPolygon.stroke}}}}},null,8,["config"])),e.createElementVNode("div",{ref_key:"chartLegend",ref:I},[t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(_e.Legend,{key:`legend_${D.value}`,legendSet:k.value,config:ke.value,onClickMarker:a[1]||(a[1]=({i:l})=>Z(l))},{item:e.withCtx(({legend:l,index:r})=>[e.createElementVNode("div",{"data-cy-legend-item":"",onClick:s=>l.segregate(),style:e.normalizeStyle(`opacity:${i.value.includes(r)?.5:1}`)},e.toDisplayString(l.name)+": "+e.toDisplayString(e.unref(n.dataLabel)({v:l.totalProportion*100,s:"%",r:t.value.style.chart.legend.roundingPercentage})),13,Ke)]),_:1},8,["legendSet","config"])):e.renderSlot(o.$slots,"legend",{key:1,legend:k.value},void 0,!0)],512),o.$slots.source?(e.openBlock(),e.createElementBlock("div",{key:7,ref_key:"source",ref:R,dir:"auto"},[e.renderSlot(o.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),e.createVNode(Be._sfc_main,{show:h.value.showTooltip&&x.value,backgroundColor:t.value.style.chart.tooltip.backgroundColor,color:t.value.style.chart.tooltip.color,borderRadius:t.value.style.chart.tooltip.borderRadius,borderColor:t.value.style.chart.tooltip.borderColor,borderWidth:t.value.style.chart.tooltip.borderWidth,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,fontSize:t.value.style.chart.tooltip.fontSize,position:t.value.style.chart.tooltip.position,offsetY:t.value.style.chart.tooltip.offsetY,parent:m.value,content:N.value,isFullscreen:b.value,isCustom:t.value.style.chart.tooltip.customFormat&&typeof t.value.style.chart.tooltip.customFormat=="function"},{"tooltip-before":e.withCtx(()=>[e.renderSlot(o.$slots,"tooltip-before",e.normalizeProps(e.guardReactiveProps({...F.value})),void 0,!0)]),"tooltip-after":e.withCtx(()=>[["function"].includes(typeof t.value.style.chart.tooltip.customFormat)?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Qe,[e.createVNode(Pe.default,{dataset:V.value,config:ge.value,backgroundOpacity:0},null,8,["dataset","config"])])),e.renderSlot(o.$slots,"tooltip-after",e.normalizeProps(e.guardReactiveProps({...F.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","borderRadius","borderColor","borderWidth","backgroundOpacity","fontSize","position","offsetY","parent","content","isFullscreen","isCustom"]),C.value?(e.openBlock(),e.createBlock(Ne.default,{key:8,hideDetails:"",config:{open:h.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($e.DataTable,{key:`table_${U.value}`,colNames:P.value.colNames,head:P.value.head,body:P.value.body,config:P.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:a[2]||(a[2]=l=>h.value.showTable=!1)},{th:e.withCtx(({th:l})=>[e.createTextVNode(e.toDisplayString(l.name),1)]),td:e.withCtx(({td:l})=>[e.createTextVNode(e.toDisplayString(l),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],46,Fe))}},et=Ve._export_sfc(Ze,[["__scopeId","data-v-dca24370"]]);exports.default=et;
@@ -1,20 +1,20 @@
1
- import { computed as h, ref as i, watch as je, onMounted as He, onBeforeUnmount as Ye, openBlock as r, createElementBlock as n, normalizeClass as z, normalizeStyle as W, unref as d, createBlock as _, createCommentVNode as c, createSlots as qe, withCtx as m, renderSlot as f, normalizeProps as M, guardReactiveProps as R, createVNode as ee, createElementVNode as $, Fragment as P, renderList as T, toDisplayString as U, createTextVNode as Te, nextTick as Je } from "vue";
2
- import { u as Ke, c as Qe, t as Ze, a as et, p as x, o as tt, e as S, b as at, g as xe, d as Oe, O as Ae, v as ot, i as Fe, f as V, X as lt, s as te, w as rt, P as Ne, x as st, y as nt, q as ut, r as it } from "./index-BqR_a-C7.js";
1
+ import { computed as h, ref as i, watch as je, onMounted as qe, onBeforeUnmount as He, openBlock as r, createElementBlock as s, normalizeClass as z, normalizeStyle as W, unref as d, createBlock as _, createCommentVNode as c, createSlots as Ye, withCtx as m, renderSlot as f, normalizeProps as M, guardReactiveProps as R, createVNode as ee, createElementVNode as $, Fragment as P, renderList as T, toDisplayString as U, createTextVNode as Te, nextTick as Je } from "vue";
2
+ import { u as Ke, c as Qe, t as Ze, a as et, p as x, o as tt, e as S, b as at, g as xe, d as Ae, O as Oe, v as ot, i as Fe, f as V, X as lt, s as te, w as rt, P as Ne, x as nt, y as st, q as ut, r as it } from "./index-B7nCQFK0.js";
3
3
  import { t as dt, u as ct } from "./useResponsive-CoxXLe23.js";
4
- import { _ as vt } from "./Title-Bhq6SOYu.js";
5
- import { u as pt, U as ht } from "./usePrinter-BPjMJmKg.js";
6
- import { _ as gt } from "./Tooltip-CeBpQ6yn.js";
7
- import ft from "./vue-ui-sparkbar-BEY67Uh8.js";
8
- import { L as yt } from "./Legend-Br9uWuyZ.js";
9
- import { D as mt } from "./DataTable-CaiuB_-j.js";
10
- import bt from "./vue-ui-skeleton-DbI8wJH-.js";
11
- import kt from "./vue-ui-accordion-Cz3VCEN0.js";
12
- import { u as Se } from "./useNestedProp-DqofSFeh.js";
13
- import { _ as Ct } from "./PackageVersion-tmgQTzP2.js";
14
- import { P as wt } from "./PenAndPaper-CJ3Rnk2Q.js";
4
+ import { _ as vt } from "./Title-CaET2xuF.js";
5
+ import { u as pt, U as ht } from "./usePrinter-CQMn1b4E.js";
6
+ import { _ as gt } from "./Tooltip-Bkc4233T.js";
7
+ import ft from "./vue-ui-sparkbar-Fa-Kc9Fr.js";
8
+ import { L as yt } from "./Legend-BTpe6qQB.js";
9
+ import { D as mt } from "./DataTable-C0tCPQ9i.js";
10
+ import bt from "./vue-ui-skeleton-D66ZIUln.js";
11
+ import kt from "./vue-ui-accordion-B8ptB5BQ.js";
12
+ import { u as Se } from "./useNestedProp-C9rlBRTT.js";
13
+ import { _ as Ct } from "./PackageVersion-CENy3Lm2.js";
14
+ import { P as wt } from "./PenAndPaper-Dr7ndoP_.js";
15
15
  import { u as _t } from "./useUserOptionState-BIvW1Kz7.js";
16
16
  import { _ as $t } from "./_plugin-vue_export-helper-CHgC5LLL.js";
17
- const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["id"], At = ["stop-color"], Ft = ["stop-color"], Nt = { key: 1 }, St = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], It = { key: 0 }, Lt = ["d", "stroke", "stroke-width"], zt = ["d", "stroke", "stroke-width"], Mt = { key: 2 }, Rt = ["x", "y", "text-anchor", "font-size", "fill", "onMouseenter"], Ut = ["points", "stroke", "stroke-width"], Vt = ["points", "stroke", "stroke-width", "fill"], Et = { key: 3 }, Bt = ["cx", "cy", "fill", "r", "stroke"], Dt = {
17
+ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], At = ["id"], Ot = ["stop-color"], Ft = ["stop-color"], Nt = { key: 1 }, St = ["x1", "y1", "x2", "y2", "stroke", "stroke-width"], It = { key: 0 }, Lt = ["d", "stroke", "stroke-width"], zt = ["d", "stroke", "stroke-width"], Mt = { key: 2 }, Rt = ["x", "y", "text-anchor", "font-size", "fill", "onMouseenter"], Ut = ["points", "stroke", "stroke-width"], Vt = ["points", "stroke", "stroke-width", "fill"], Et = { key: 3 }, Bt = ["cx", "cy", "fill", "r", "stroke"], Dt = {
18
18
  key: 5,
19
19
  class: "vue-data-ui-watermark"
20
20
  }, Gt = ["onClick"], Wt = {
@@ -38,10 +38,10 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
38
38
  },
39
39
  emits: ["selectLegend"],
40
40
  setup(Ie, { expose: Le, emit: ze }) {
41
- const g = Ie, { vue_ui_radar: Me } = Ke(), I = h(() => !!g.dataset && Object.keys(g.dataset).length), w = i(Qe()), Re = i(null), X = i(!1), j = i(""), ae = i(0), O = i(null), oe = i(null), le = i(null), re = i(null), se = i(null), ne = i(0), ue = i(0), ie = i(0), e = h({
41
+ const g = Ie, { vue_ui_radar: Me } = Ke(), I = h(() => !!g.dataset && Object.keys(g.dataset).length), w = i(Qe()), Re = i(null), X = i(!1), j = i(""), ae = i(0), A = i(null), oe = i(null), le = i(null), re = i(null), ne = i(null), se = i(0), ue = i(0), ie = i(0), e = h({
42
42
  get: () => ve(),
43
43
  set: (t) => t
44
- }), { userOptionsVisible: H, setUserOptionsVisibility: de, keepUserOptionState: ce } = _t({ config: e.value });
44
+ }), { userOptionsVisible: q, setUserOptionsVisibility: de, keepUserOptionState: ce } = _t({ config: e.value });
45
45
  function ve() {
46
46
  const t = Se({
47
47
  userConfig: g.config,
@@ -56,7 +56,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
56
56
  } : t;
57
57
  }
58
58
  je(() => g.config, (t) => {
59
- e.value = ve(), H.value = !e.value.showOnChartHover, pe(), ne.value += 1, ue.value += 1, ie.value += 1;
59
+ e.value = ve(), q.value = !e.value.showOnChartHover, pe(), se.value += 1, ue.value += 1, ie.value += 1;
60
60
  }, { deep: !0 });
61
61
  const E = i(null);
62
62
  function pe() {
@@ -66,20 +66,22 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
66
66
  }), e.value.responsive) {
67
67
  const t = dt(() => {
68
68
  const { width: a, height: o } = ct({
69
- chart: O.value,
69
+ chart: A.value,
70
70
  title: e.value.style.chart.title.text ? oe.value : null,
71
71
  legend: e.value.style.chart.legend.show ? le.value : null,
72
72
  source: re.value,
73
- noTitle: se.value
73
+ noTitle: ne.value
74
+ });
75
+ requestAnimationFrame(() => {
76
+ u.value.width = a, u.value.height = o;
74
77
  });
75
- u.value.width = a, u.value.height = o;
76
78
  });
77
- E.value = new ResizeObserver(t), E.value.observe(O.value.parentNode);
79
+ E.value = new ResizeObserver(t), E.value.observe(A.value.parentNode);
78
80
  }
79
81
  }
80
- He(() => {
82
+ qe(() => {
81
83
  pe();
82
- }), Ye(() => {
84
+ }), He(() => {
83
85
  E.value && E.value.disconnect();
84
86
  });
85
87
  const { isPrinting: he, isImaging: ge, generatePdf: fe, generateImage: ye } = pt({
@@ -112,12 +114,12 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
112
114
  })), u = i({
113
115
  height: 312,
114
116
  width: 512
115
- }), v = i([]), L = i(null), A = i(!1);
117
+ }), v = i([]), L = i(null), O = i(!1);
116
118
  function be(t) {
117
- A.value = !0, v.value.includes(t) ? (L.value = t, v.value = v.value.filter((a) => a !== t), setTimeout(() => {
118
- A.value = !1, L.value = null;
119
+ O.value = !0, v.value.includes(t) ? (L.value = t, v.value = v.value.filter((a) => a !== t), setTimeout(() => {
120
+ O.value = !1, L.value = null;
119
121
  }, 500)) : (v.value.push(t), setTimeout(() => {
120
- A.value = !1;
122
+ O.value = !1;
121
123
  }, 500)), ze("selectLegend", F.value.filter((a, o) => !v.value.includes(o)).map((a) => ({
122
124
  name: a.name,
123
125
  color: a.color,
@@ -171,22 +173,22 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
171
173
  }), g.dataset.categories.map((t, a) => ({
172
174
  name: t.name,
173
175
  categoryId: `radar_category_${w.value}_${a}`,
174
- color: Oe(t.color) || me.value[a] || x[a] || x[a % x.length],
176
+ color: Ae(t.color) || me.value[a] || x[a] || x[a % x.length],
175
177
  prefix: t.prefix ?? "",
176
178
  suffix: t.suffix ?? ""
177
179
  })))), b = h(() => I.value ? g.dataset.series.map((t, a) => ({
178
180
  ...t,
179
- color: Oe(t.color) || me.value[a] || x[a] || x[a % x.length],
181
+ color: Ae(t.color) || me.value[a] || x[a] || x[a % x.length],
180
182
  serieId: `radar_serie_${w.value}_${a}`,
181
183
  formatter: t.formatter || null
182
- })) : []), ke = h(() => Math.max(...b.value.flatMap((t) => t.values))), Ce = h(() => b.value.length), Y = h(() => Math.min(u.value.width, u.value.height) / 3), we = h(() => Ae({
184
+ })) : []), ke = h(() => Math.max(...b.value.flatMap((t) => t.values))), Ce = h(() => b.value.length), H = h(() => Math.min(u.value.width, u.value.height) / 3), we = h(() => Oe({
183
185
  plot: { x: u.value.width / 2, y: u.value.height / 2 },
184
- radius: Y.value,
186
+ radius: H.value,
185
187
  sides: Ce.value,
186
188
  rotation: 0
187
189
  })), Be = h(() => {
188
190
  const t = [];
189
- for (let a = 0; a < Y.value; a += Y.value / e.value.style.chart.layout.grid.graduations)
191
+ for (let a = 0; a < H.value; a += H.value / e.value.style.chart.layout.grid.graduations)
190
192
  t.push(a);
191
193
  return t;
192
194
  }), C = h(() => we.value.coordinates.map((t, a) => {
@@ -203,21 +205,21 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
203
205
  plots: o
204
206
  };
205
207
  }));
206
- function q({ x: t, y: a }) {
208
+ function Y({ x: t, y: a }) {
207
209
  let o = "middle";
208
210
  return t = Math.round(t), a = Math.round(a), t > u.value.width / 2 && (t += 12, o = "start"), t < u.value.width / 2 && (t -= 12, o = "end"), a > u.value.height / 2 && (a += 20), a < u.value.height / 2 && (a -= 12), a === u.value.height / 2 && (a += 4), { x: t, y: a, anchor: o };
209
211
  }
210
- function De({ centerX: t, centerY: a, apexX: o, apexY: l, proportion: s }) {
212
+ function De({ centerX: t, centerY: a, apexX: o, apexY: l, proportion: n }) {
211
213
  return {
212
- x: t + (o - t) * s,
213
- y: a + (l - a) * s
214
+ x: t + (o - t) * n,
215
+ y: a + (l - a) * n
214
216
  };
215
217
  }
216
218
  const F = h(() => {
217
219
  const t = b.value.map((a, o) => a.values.map((l) => l / (a.target || ke.value)));
218
220
  return y.value.map((a, o) => ({
219
221
  ...a,
220
- totalProportion: ot(t.map((l) => l[o]).reduce((l, s) => l + s, 0) / b.value.length),
222
+ totalProportion: ot(t.map((l) => l[o]).reduce((l, n) => l + n, 0) / b.value.length),
221
223
  shape: "circle",
222
224
  opacity: v.value.includes(o) ? 0.5 : 1,
223
225
  segregate: () => be(o),
@@ -247,12 +249,12 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
247
249
  r: e.value.table.td.roundingValue
248
250
  })
249
251
  ),
250
- ...l.values.map((s, p) => `${Fe(
252
+ ...l.values.map((n, p) => `${Fe(
251
253
  l.formatter,
252
- s,
253
- V({ p: y.value[p].prefix, v: s, s: y.value[p].suffix, r: e.value.table.td.roundingValue })
254
- )} (${isNaN(s / l.target) ? "" : V({
255
- v: s / l.target * 100,
254
+ n,
255
+ V({ p: y.value[p].prefix, v: n, s: y.value[p].suffix, r: e.value.table.td.roundingValue })
256
+ )} (${isNaN(n / l.target) ? "" : V({
257
+ v: n / l.target * 100,
256
258
  s: "%",
257
259
  r: e.value.table.td.roundingPercentage
258
260
  })})`)
@@ -285,7 +287,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
285
287
  config: e.value
286
288
  };
287
289
  const l = e.value.style.chart.tooltip.customFormat;
288
- if (st(l) && nt(() => l({
290
+ if (nt(l) && st(() => l({
289
291
  seriesIndex: a,
290
292
  datapoint: t,
291
293
  series: { categories: y.value, datapoints: b.value, radar: C.value },
@@ -299,13 +301,13 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
299
301
  });
300
302
  else {
301
303
  o += `<div style="width:100%;text-align:center;border-bottom:1px solid ${e.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${t.name}</div>`;
302
- for (let s = 0; s < t.values.length; s += 1)
303
- v.value.includes(s) || J.value.push({
304
- name: y.value[s].name,
305
- value: t.values[s] / t.target * 100,
306
- color: y.value[s].color,
304
+ for (let n = 0; n < t.values.length; n += 1)
305
+ v.value.includes(n) || J.value.push({
306
+ name: y.value[n].name,
307
+ value: t.values[n] / t.target * 100,
308
+ color: y.value[n].color,
307
309
  suffix: "%)",
308
- prefix: `${V({ p: y.value[s].prefix ?? "", v: t.values[s], s: y.value[s].suffix ?? "", r: e.value.style.chart.tooltip.roundingValue })} (`,
310
+ prefix: `${V({ p: y.value[n].prefix ?? "", v: t.values[n], s: y.value[n].suffix ?? "", r: e.value.style.chart.tooltip.roundingValue })} (`,
309
311
  rounding: e.value.style.chart.tooltip.roundingPercentage,
310
312
  formatter: t.formatter
311
313
  });
@@ -317,8 +319,8 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
317
319
  const t = [[e.value.style.chart.title.text], [e.value.style.chart.title.subtitle.text], [""]], a = [[""], [e.value.translations.target], ...F.value.flatMap((p) => [[p.name], ["%"]])], o = g.dataset.series.map((p, jt) => [p.name, p.target, ...p.values.flatMap((Z) => [
318
320
  Z,
319
321
  isNaN(Z / p.target) ? "" : Z / p.target * 100
320
- ])]), l = t.concat([a]).concat(o), s = ut(l);
321
- it({ csvContent: s, title: e.value.style.chart.title.text || "vue-ui-radar" });
322
+ ])]), l = t.concat([a]).concat(o), n = ut(l);
323
+ it({ csvContent: n, title: e.value.style.chart.title.text || "vue-ui-radar" });
322
324
  });
323
325
  }
324
326
  const N = i(!1);
@@ -343,10 +345,10 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
343
345
  toggleTable: $e,
344
346
  toggleTooltip: Pe,
345
347
  toggleAnnotator: Q
346
- }), (t, a) => (r(), n("div", {
348
+ }), (t, a) => (r(), s("div", {
347
349
  class: z(`vue-ui-radar ${N.value ? "vue-data-ui-wrapper-fullscreen" : ""} ${e.value.useCssAnimation ? "" : "vue-ui-dna"}`),
348
350
  ref_key: "radarChart",
349
- ref: O,
351
+ ref: A,
350
352
  id: `vue-ui-radar_${w.value}`,
351
353
  style: W(`font-family:${e.value.style.fontFamily};width:100%; ${e.value.responsive ? "height: 100%;" : ""} text-align:center;background:${e.value.style.chart.backgroundColor}`),
352
354
  onMouseenter: a[3] || (a[3] = () => d(de)(!0)),
@@ -354,27 +356,27 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
354
356
  }, [
355
357
  e.value.userOptions.buttons.annotator ? (r(), _(wt, {
356
358
  key: 0,
357
- parent: O.value,
359
+ parent: A.value,
358
360
  backgroundColor: e.value.style.chart.backgroundColor,
359
361
  color: e.value.style.chart.color,
360
362
  active: G.value,
361
363
  onClose: Q
362
364
  }, null, 8, ["parent", "backgroundColor", "color", "active"])) : c("", !0),
363
- Ue.value ? (r(), n("div", {
365
+ Ue.value ? (r(), s("div", {
364
366
  key: 1,
365
367
  ref_key: "noTitle",
366
- ref: se,
368
+ ref: ne,
367
369
  class: "vue-data-ui-no-title-space",
368
370
  style: "height:36px; width: 100%;background:transparent"
369
371
  }, null, 512)) : c("", !0),
370
- e.value.style.chart.title.text ? (r(), n("div", {
372
+ e.value.style.chart.title.text ? (r(), s("div", {
371
373
  key: 2,
372
374
  ref_key: "chartTitle",
373
375
  ref: oe,
374
376
  style: "width:100%;background:transparent;padding-bottom:12px"
375
377
  }, [
376
378
  (r(), _(vt, {
377
- key: `title_${ne.value}`,
379
+ key: `title_${se.value}`,
378
380
  config: {
379
381
  title: {
380
382
  cy: "radar-div-title",
@@ -387,7 +389,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
387
389
  }
388
390
  }, null, 8, ["config"]))
389
391
  ], 512)) : c("", !0),
390
- e.value.userOptions.show && I.value && (d(ce) || d(H)) ? (r(), _(ht, {
392
+ e.value.userOptions.show && I.value && (d(ce) || d(q)) ? (r(), _(ht, {
391
393
  ref_key: "details",
392
394
  ref: Re,
393
395
  key: `user_options_${ae.value}`,
@@ -405,7 +407,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
405
407
  isFullscreen: N.value,
406
408
  isTooltip: k.value.showTooltip,
407
409
  titles: { ...e.value.userOptions.buttonTitles },
408
- chartElement: O.value,
410
+ chartElement: A.value,
409
411
  position: e.value.userOptions.position,
410
412
  hasAnnotator: e.value.userOptions.buttons.annotator,
411
413
  isAnnotation: G.value,
@@ -417,9 +419,9 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
417
419
  onToggleTooltip: Pe,
418
420
  onToggleAnnotator: Q,
419
421
  style: W({
420
- visibility: d(ce) ? d(H) ? "visible" : "hidden" : "visible"
422
+ visibility: d(ce) ? d(q) ? "visible" : "hidden" : "visible"
421
423
  })
422
- }, qe({ _: 2 }, [
424
+ }, Ye({ _: 2 }, [
423
425
  t.$slots.optionTooltip ? {
424
426
  name: "optionTooltip",
425
427
  fn: m(() => [
@@ -470,7 +472,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
470
472
  key: "6"
471
473
  } : void 0
472
474
  ]), 1032, ["backgroundColor", "color", "isImaging", "isPrinting", "uid", "hasTooltip", "hasPdf", "hasImg", "hasXls", "hasTable", "hasFullscreen", "isFullscreen", "isTooltip", "titles", "chartElement", "position", "hasAnnotator", "isAnnotation", "onGeneratePdf", "onGenerateImage", "style"])) : c("", !0),
473
- I.value ? (r(), n("svg", {
475
+ I.value ? (r(), s("svg", {
474
476
  key: 4,
475
477
  xmlns: d(lt),
476
478
  class: z({ "vue-data-ui-fullscreen--on": N.value, "vue-data-ui-fulscreen--off": !N.value }),
@@ -478,7 +480,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
478
480
  style: W(`max-width:100%;overflow:visible;background:transparent;color:${e.value.style.chart.color}`)
479
481
  }, [
480
482
  ee(Ct),
481
- t.$slots["chart-background"] ? (r(), n("foreignObject", {
483
+ t.$slots["chart-background"] ? (r(), s("foreignObject", {
482
484
  key: 0,
483
485
  x: 0,
484
486
  y: 0,
@@ -491,7 +493,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
491
493
  f(t.$slots, "chart-background", {}, void 0, !0)
492
494
  ], 8, xt)) : c("", !0),
493
495
  $("defs", null, [
494
- (r(!0), n(P, null, T(y.value, (o, l) => (r(), n("radialGradient", {
496
+ (r(!0), s(P, null, T(y.value, (o, l) => (r(), s("radialGradient", {
495
497
  cx: "50%",
496
498
  cy: "50%",
497
499
  r: "50%",
@@ -502,15 +504,15 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
502
504
  $("stop", {
503
505
  offset: "0%",
504
506
  "stop-color": d(te)(d(rt)(o.color, 0.05), e.value.style.chart.layout.dataPolygon.opacity)
505
- }, null, 8, At),
507
+ }, null, 8, Ot),
506
508
  $("stop", {
507
509
  offset: "100%",
508
510
  "stop-color": d(te)(o.color, e.value.style.chart.layout.dataPolygon.opacity)
509
511
  }, null, 8, Ft)
510
- ], 8, Ot))), 256))
512
+ ], 8, At))), 256))
511
513
  ]),
512
- e.value.style.chart.layout.grid.show ? (r(), n("g", Nt, [
513
- (r(!0), n(P, null, T(C.value, (o) => (r(), n("line", {
514
+ e.value.style.chart.layout.grid.show ? (r(), s("g", Nt, [
515
+ (r(!0), s(P, null, T(C.value, (o) => (r(), s("line", {
514
516
  x1: u.value.width / 2,
515
517
  y1: u.value.height / 2,
516
518
  x2: o.x,
@@ -518,9 +520,9 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
518
520
  stroke: e.value.style.chart.layout.grid.stroke,
519
521
  "stroke-width": e.value.style.chart.layout.grid.strokeWidth
520
522
  }, null, 8, St))), 256)),
521
- e.value.style.chart.layout.grid.graduations > 0 ? (r(), n("g", It, [
522
- (r(!0), n(P, null, T(Be.value, (o) => (r(), n("path", {
523
- d: d(Ae)({
523
+ e.value.style.chart.layout.grid.graduations > 0 ? (r(), s("g", It, [
524
+ (r(!0), s(P, null, T(Be.value, (o) => (r(), s("path", {
525
+ d: d(Oe)({
524
526
  plot: { x: u.value.width / 2, y: u.value.height / 2 },
525
527
  radius: o,
526
528
  sides: Ce.value,
@@ -540,57 +542,57 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
540
542
  "stroke-linejoin": "round",
541
543
  "stroke-linecap": "round"
542
544
  }, null, 8, zt),
543
- e.value.style.chart.layout.labels.dataLabels.show ? (r(), n("g", Mt, [
544
- (r(!0), n(P, null, T(C.value, (o, l) => (r(), n("text", {
545
- x: q(o).x,
546
- y: q(o).y,
547
- "text-anchor": q(o).anchor,
545
+ e.value.style.chart.layout.labels.dataLabels.show ? (r(), s("g", Mt, [
546
+ (r(!0), s(P, null, T(C.value, (o, l) => (r(), s("text", {
547
+ x: Y(o).x,
548
+ y: Y(o).y,
549
+ "text-anchor": Y(o).anchor,
548
550
  "font-size": e.value.style.chart.layout.labels.dataLabels.fontSize,
549
551
  fill: e.value.style.chart.layout.labels.dataLabels.color,
550
- onMouseenter: (s) => We(o, l),
551
- onMouseleave: a[0] || (a[0] = (s) => {
552
+ onMouseenter: (n) => We(o, l),
553
+ onMouseleave: a[0] || (a[0] = (n) => {
552
554
  X.value = !1, D.value = null;
553
555
  })
554
556
  }, U(o.name), 41, Rt))), 256))
555
557
  ])) : c("", !0),
556
- (r(!0), n(P, null, T(y.value, (o, l) => (r(), n("g", null, [
558
+ (r(!0), s(P, null, T(y.value, (o, l) => (r(), s("g", null, [
557
559
  $("g", null, [
558
- e.value.useCssAnimation || !e.value.useCssAnimation && !v.value.includes(l) ? (r(), n("polygon", {
560
+ e.value.useCssAnimation || !e.value.useCssAnimation && !v.value.includes(l) ? (r(), s("polygon", {
559
561
  key: 0,
560
562
  "data-cy-radar-path": "",
561
- points: d(Ne)(C.value.map((s) => s.plots[l]), !1, !0),
563
+ points: d(Ne)(C.value.map((n) => n.plots[l]), !1, !0),
562
564
  stroke: e.value.style.chart.backgroundColor,
563
565
  "stroke-width": e.value.style.chart.layout.dataPolygon.strokeWidth + 1,
564
566
  fill: "none",
565
- class: z({ "animated-out": v.value.includes(l) && e.value.useCssAnimation, "animated-in": A.value && L.value === l && e.value.useCssAnimation })
567
+ class: z({ "animated-out": v.value.includes(l) && e.value.useCssAnimation, "animated-in": O.value && L.value === l && e.value.useCssAnimation })
566
568
  }, null, 10, Ut)) : c("", !0),
567
- e.value.useCssAnimation || !e.value.useCssAnimation && !v.value.includes(l) ? (r(), n("polygon", {
569
+ e.value.useCssAnimation || !e.value.useCssAnimation && !v.value.includes(l) ? (r(), s("polygon", {
568
570
  key: 1,
569
571
  "data-cy-radar-path": "",
570
- points: d(Ne)(C.value.map((s) => s.plots[l]), !1, !0),
572
+ points: d(Ne)(C.value.map((n) => n.plots[l]), !1, !0),
571
573
  stroke: o.color,
572
574
  "stroke-width": e.value.style.chart.layout.dataPolygon.strokeWidth,
573
575
  fill: e.value.style.chart.layout.dataPolygon.transparent ? "transparent" : e.value.style.chart.layout.dataPolygon.useGradient ? `url(#radar_gradient_${w.value}_${l})` : d(te)(o.color, e.value.style.chart.layout.dataPolygon.opacity),
574
- class: z({ "animated-out": v.value.includes(l) && e.value.useCssAnimation, "animated-in": A.value && L.value === l && e.value.useCssAnimation })
576
+ class: z({ "animated-out": v.value.includes(l) && e.value.useCssAnimation, "animated-in": O.value && L.value === l && e.value.useCssAnimation })
575
577
  }, null, 10, Vt)) : c("", !0)
576
578
  ])
577
579
  ]))), 256)),
578
- e.value.style.chart.layout.plots.show ? (r(), n("g", Et, [
579
- (r(!0), n(P, null, T(C.value, (o, l) => (r(), n("g", null, [
580
- (r(!0), n(P, null, T(o.plots, (s, p) => (r(), n("circle", {
581
- cx: s.x,
582
- cy: s.y,
580
+ e.value.style.chart.layout.plots.show ? (r(), s("g", Et, [
581
+ (r(!0), s(P, null, T(C.value, (o, l) => (r(), s("g", null, [
582
+ (r(!0), s(P, null, T(o.plots, (n, p) => (r(), s("circle", {
583
+ cx: n.x,
584
+ cy: n.y,
583
585
  fill: v.value.includes(p) ? "transparent" : y.value[p].color,
584
586
  r: D.value !== null && D.value === l ? e.value.style.chart.layout.plots.radius * 1.6 : e.value.style.chart.layout.plots.radius,
585
587
  stroke: v.value.includes(p) ? "transparent" : e.value.style.chart.backgroundColor,
586
588
  "stroke-width": 0.5,
587
- class: z({ "animated-out": v.value.includes(p) && e.value.useCssAnimation, "animated-in": A.value && L.value === p && e.value.useCssAnimation })
589
+ class: z({ "animated-out": v.value.includes(p) && e.value.useCssAnimation, "animated-in": O.value && L.value === p && e.value.useCssAnimation })
588
590
  }, null, 10, Bt))), 256))
589
591
  ]))), 256))
590
592
  ])) : c("", !0),
591
593
  f(t.$slots, "svg", { svg: u.value }, void 0, !0)
592
594
  ], 14, Tt)) : c("", !0),
593
- t.$slots.watermark ? (r(), n("div", Dt, [
595
+ t.$slots.watermark ? (r(), s("div", Dt, [
594
596
  f(t.$slots, "watermark", M(R({ isPrinting: d(he) || d(ge) })), void 0, !0)
595
597
  ])) : c("", !0),
596
598
  I.value ? c("", !0) : (r(), _(bt, {
@@ -623,7 +625,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
623
625
  item: m(({ legend: o, index: l }) => [
624
626
  $("div", {
625
627
  "data-cy-legend-item": "",
626
- onClick: (s) => o.segregate(),
628
+ onClick: (n) => o.segregate(),
627
629
  style: W(`opacity:${v.value.includes(l) ? 0.5 : 1}`)
628
630
  }, U(o.name) + ": " + U(d(V)({
629
631
  v: o.totalProportion * 100,
@@ -637,7 +639,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
637
639
  legend: F.value
638
640
  }, void 0, !0)
639
641
  ], 512),
640
- t.$slots.source ? (r(), n("div", {
642
+ t.$slots.source ? (r(), s("div", {
641
643
  key: 7,
642
644
  ref_key: "source",
643
645
  ref: re,
@@ -656,7 +658,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
656
658
  fontSize: e.value.style.chart.tooltip.fontSize,
657
659
  position: e.value.style.chart.tooltip.position,
658
660
  offsetY: e.value.style.chart.tooltip.offsetY,
659
- parent: O.value,
661
+ parent: A.value,
660
662
  content: j.value,
661
663
  isFullscreen: N.value,
662
664
  isCustom: e.value.style.chart.tooltip.customFormat && typeof e.value.style.chart.tooltip.customFormat == "function"
@@ -665,7 +667,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
665
667
  f(t.$slots, "tooltip-before", M(R({ ...K.value })), void 0, !0)
666
668
  ]),
667
669
  "tooltip-after": m(() => [
668
- ["function"].includes(typeof e.value.style.chart.tooltip.customFormat) ? c("", !0) : (r(), n("div", Wt, [
670
+ ["function"].includes(typeof e.value.style.chart.tooltip.customFormat) ? c("", !0) : (r(), s("div", Wt, [
669
671
  ee(ft, {
670
672
  dataset: J.value,
671
673
  config: Ve.value,
@@ -715,7 +717,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], xt = ["width", "height"], Ot = ["i
715
717
  }, 8, ["config"])) : c("", !0)
716
718
  ], 46, Pt));
717
719
  }
718
- }, ia = /* @__PURE__ */ $t(Xt, [["__scopeId", "data-v-7a50d021"]]);
720
+ }, ia = /* @__PURE__ */ $t(Xt, [["__scopeId", "data-v-dca24370"]]);
719
721
  export {
720
722
  ia as default
721
723
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-D4M1RdVn.cjs"),M=require("./useNestedProp-D_XfpfnF.cjs"),D=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),A={key:0,class:"vue-ui-rating-title",style:{width:"100%"}},R=["src","height","width"],X=["xmlns","height","width"],j=["id"],F=["stop-color"],I=["stop-color"],O=["points","fill","stroke","stroke-width"],Y=["src","alt","height","width","id"],G=["xmlns","viewBox","height","id"],U=["id"],q=["stop-color"],H=["stop-color"],K=["points","fill","stroke"],P=["xmlns","height"],T=["onClick","onMouseenter","onKeyup"],W=["onMouseenter"],J={__name:"vue-ui-rating",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},emits:["rate"],setup(k,{expose:S,emit:_}){const i=k,{vue_ui_rating:w}=o.useConfig(),d=e.ref(o.createUid()),g=e.ref(!1),s=e.ref(void 0),y=e.ref([]),z=e.useSlots();e.onMounted(()=>{z["chart-background"]&&console.warn("VueUiRating does not support the #chart-background slot.")});const t=e.computed({get:()=>f(),set:a=>a});function f(){return M.useNestedProp({userConfig:i.config,defaultConfig:w})}e.watch(()=>i.config,a=>{t.value=f(),h()},{deep:!0});const B=e.computed(()=>typeof i.dataset.rating=="object"&&!Array.isArray(i.dataset.rating)?C(i.dataset.rating):i.dataset.rating),N=e.computed(()=>typeof i.dataset.rating=="object"&&!Array.isArray(i.dataset.rating)),r=e.ref(B.value),m=e.computed(()=>t.value.type==="image"),c=e.computed(()=>t.value.readonly);function C(a){let n=0,l=0;for(const u in a){const L=parseInt(u),$=a[u];n+=L*$,l+=$}if(l===0)return 0;const v=n/l;return Math.min(t.value.to,Math.max(t.value.from,v))}e.onMounted(()=>{h()});function h(){o.objectIsEmpty(i.dataset)&&o.error({componentName:"VueUiRating",type:"dataset"}),y.value=[];for(let a=t.value.from;a<=t.value.to;a+=1)y.value.push(a)}function p(a,n=!1){return a>s.value||c.value?n?t.value.style.image.inactiveOpacity:t.value.style.star.inactiveColor:n?1:t.value.style.star.useGradient?`url(#star_gradient_under_${d.value})`:t.value.style.star.activeColor}function x(a,n=!1){const l=r.value-a,v=n?1:100;switch(!0){case l<=0:return .001;case l>1:return 1*v;default:return l*v}}function b(a){c.value||(r.value=a,_("rate",a))}function E(){return r.value}function V(a=!0){c.value=a}return S({getData:E,toggleReadonly:V}),(a,n)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`background:${t.value.style.backgroundColor};font-family:${t.value.style.fontFamily};width:100%`),class:"vue-ui-rating",onMouseover:n[2]||(n[2]=l=>g.value=!0),onMouseleave:n[3]||(n[3]=l=>{g.value=!1,s.value=void 0})},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",A,[e.createElementVNode("div",{style:e.normalizeStyle(`color:${t.value.style.title.color};font-weight:${t.value.style.title.bold?"bold":"normal"};text-align:${t.value.style.title.textAlign};margin-bottom:${t.value.style.title.offsetY}px;font-size:${t.value.style.title.fontSize}px`)},e.toDisplayString(t.value.style.title.text),5),t.value.style.title.subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`color:${t.value.style.title.subtitle.color};font-size:${t.value.style.title.subtitle.fontSize}px;text-align:${t.value.style.title.textAlign};margin-bottom:${t.value.style.title.subtitle.offsetY}px;font-weight:${t.value.style.title.subtitle.bold?"bold":"normal"}`)},e.toDisplayString(t.value.style.title.subtitle.text),5)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),t.value.style.rating.show&&t.value.style.rating.position==="top"?(e.openBlock(),e.createElementBlock("div",{key:1,style:e.normalizeStyle(`width:100%;text-align:center;margin-bottom:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};margin-left:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"vue-ui-rating-wrapper",style:e.normalizeStyle(`height:${t.value.style.itemSize}px;width:100%;display:flex;align-items:center;justify-content:center`)},[t.value.style.rating.show&&t.value.style.rating.position==="left"?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:fit-content;text-align:center;margin-bottom:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};padding-right:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(l,v)=>(e.openBlock(),e.createElementBlock("div",{class:"vue-ui-rating-unit-container",style:e.normalizeStyle(`position:relative;height:${t.value.style.itemSize}px;width:${t.value.style.itemSize}px`)},[m.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:t.value.style.image.src,height:t.value.style.itemSize,width:t.value.style.itemSize,class:"vue-ui-rating-unit",style:e.normalizeStyle(`position:absolute;top:0;left:0;opacity:${isNaN(s.value)?t.value.style.image.inactiveOpacity:p(l,!0)}`)},null,12,R)):(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(o.XMLNS),viewBox:"0 0 100 100",height:t.value.style.itemSize,width:t.value.style.itemSize,class:"vue-ui-rating-unit"},[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`star_gradient_under_${d.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(o.shiftHue)(t.value.style.star.activeColor,.05)}`},null,8,F),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.star.activeColor},null,8,I)],8,j)]),e.createElementVNode("polygon",{points:e.unref(o.createStar)({plot:{x:50,y:50},radius:30,apexes:t.value.style.star.apexes}),fill:isNaN(s.value)?t.value.style.star.inactiveColor:p(l),stroke:t.value.style.star.borderColor?t.value.style.star.borderColor:s.value?p(l):t.value.style.star.inactiveColor,"stroke-width":t.value.style.star.borderWidth,"stroke-linecap":"round","stroke-linejoin":"round"},null,8,O)],8,X)),m.value?(e.openBlock(),e.createElementBlock("img",{key:2,src:t.value.style.image.src,alt:`${t.value.style.image.alt} ${l}`,height:t.value.style.itemSize,width:t.value.style.itemSize,id:`active_${d.value}_${l}`,class:"vue-ui-rating-unit",style:e.normalizeStyle(`position:absolute;top:0;left:0;clip:rect(0px,${x(v,!0)*t.value.style.itemSize}px,${t.value.style.itemSize}px,0px`)},null,12,Y)):(e.openBlock(),e.createElementBlock("svg",{key:3,xmlns:e.unref(o.XMLNS),viewBox:`0 0 ${x(v)} 100`,height:t.value.style.itemSize,class:"vue-ui-rating-unit",id:`active_${d.value}_${l}`,style:{position:"absolute",top:"0",left:"0"}},[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`star_gradient_over_${d.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(o.shiftHue)(t.value.style.star.activeColor,.05)}`},null,8,q),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.star.activeColor},null,8,H)],8,U)]),e.createElementVNode("polygon",{points:e.unref(o.createStar)({plot:{x:50,y:50},radius:30,apexes:t.value.style.star.apexes}),fill:t.value.style.star.useGradient?`url(#star_gradient_over_${d.value})`:t.value.style.star.activeColor,stroke:t.value.style.star.activeColor},null,8,K)],8,G)),(e.openBlock(),e.createElementBlock("svg",{xmlns:e.unref(o.XMLNS),viewBox:"0 0 100 100",height:t.value.style.itemSize,class:"vue-ui-rating-unit",style:e.normalizeStyle(`position:absolute;top:0;left:0;${c.value?"":"cursor:pointer"}`)},[c.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("rect",{key:0,class:"vue-ui-rating-mouse-trap",x:0,y:0,width:100,height:100,fill:"transparent",onClick:u=>b(l),onMouseenter:u=>s.value=l,onMouseleave:n[0]||(n[0]=u=>s.value=void 0),tabindex:"0",onKeyup:e.withKeys(u=>b(l),["enter"])},null,40,T)),c.value?(e.openBlock(),e.createElementBlock("rect",{key:1,class:"vue-ui-rating-mouse-trap",x:0,y:0,width:100,height:100,fill:"transparent",onMouseenter:u=>s.value=l,onMouseleave:n[1]||(n[1]=u=>s.value=void 0)},null,40,W)):e.createCommentVNode("",!0)],12,P)),t.value.style.tooltip.show&&N.value&&c.value?(e.openBlock(),e.createElementBlock("div",{key:4,class:"vue-ui-rating-tooltip",style:e.normalizeStyle(`border:1px solid ${t.value.style.tooltip.borderColor};position:absolute;top:${-48+t.value.style.tooltip.offsetY}px;left:50%;transform:translateX(-50%);width:fit-content;text-align:center;background:${t.value.style.tooltip.backgroundColor};display:${s.value===l?"block":"none"};padding:2px 12px;border-radius:${t.value.style.tooltip.borderRadius}px;box-shadow:${t.value.style.tooltip.boxShadow}`)},[e.createElementVNode("div",{style:e.normalizeStyle(`width:100%;display:flex;flex-direction:row;gap:6px;position:relative;text-align:center;color:${t.value.style.tooltip.color}`)},[e.createElementVNode("span",{style:e.normalizeStyle(`font-size:${t.value.style.tooltip.fontSize}px`)},e.toDisplayString(l)+":",5),e.createElementVNode("span",{style:e.normalizeStyle(`font-weight:${t.value.style.tooltip.bold?"bold":"normal"};font-size:${t.value.style.tooltip.fontSize}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.tooltip.formatter,i.dataset.rating[l],e.unref(o.dataLabel)({v:i.dataset.rating[l],r:t.value.style.tooltip.roundingValue}),t.value)),5),e.createElementVNode("div",{style:e.normalizeStyle(`font-family:Arial !important;position:absolute;top:calc(100% - 4px);left:50%;transform:translateX(-50%);color:${t.value.style.tooltip.borderColor}`)}," ▼ ",4)],4)],4)):e.createCommentVNode("",!0)],4))),256)),t.value.style.rating.show&&t.value.style.rating.position==="right"?(e.openBlock(),e.createElementBlock("div",{key:1,style:e.normalizeStyle(`width:fit-content;text-align:center;margin-bottom:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};padding-left:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0)],4),t.value.style.rating.show&&t.value.style.rating.position==="bottom"?(e.openBlock(),e.createElementBlock("div",{key:2,style:e.normalizeStyle(`width:100%;text-align:center;margin-top:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};margin-left:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0)],36))}},Q=D._export_sfc(J,[["__scopeId","data-v-9e1d13d5"]]);exports.default=Q;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-COIn1phv.cjs"),M=require("./useNestedProp-CbMuGGl3.cjs"),D=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),A={key:0,class:"vue-ui-rating-title",style:{width:"100%"}},R=["src","height","width"],X=["xmlns","height","width"],j=["id"],F=["stop-color"],I=["stop-color"],O=["points","fill","stroke","stroke-width"],Y=["src","alt","height","width","id"],G=["xmlns","viewBox","height","id"],U=["id"],q=["stop-color"],H=["stop-color"],K=["points","fill","stroke"],P=["xmlns","height"],T=["onClick","onMouseenter","onKeyup"],W=["onMouseenter"],J={__name:"vue-ui-rating",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},emits:["rate"],setup(k,{expose:S,emit:_}){const i=k,{vue_ui_rating:w}=o.useConfig(),d=e.ref(o.createUid()),g=e.ref(!1),s=e.ref(void 0),y=e.ref([]),z=e.useSlots();e.onMounted(()=>{z["chart-background"]&&console.warn("VueUiRating does not support the #chart-background slot.")});const t=e.computed({get:()=>f(),set:a=>a});function f(){return M.useNestedProp({userConfig:i.config,defaultConfig:w})}e.watch(()=>i.config,a=>{t.value=f(),h()},{deep:!0});const B=e.computed(()=>typeof i.dataset.rating=="object"&&!Array.isArray(i.dataset.rating)?C(i.dataset.rating):i.dataset.rating),N=e.computed(()=>typeof i.dataset.rating=="object"&&!Array.isArray(i.dataset.rating)),r=e.ref(B.value),m=e.computed(()=>t.value.type==="image"),c=e.computed(()=>t.value.readonly);function C(a){let n=0,l=0;for(const u in a){const L=parseInt(u),$=a[u];n+=L*$,l+=$}if(l===0)return 0;const v=n/l;return Math.min(t.value.to,Math.max(t.value.from,v))}e.onMounted(()=>{h()});function h(){o.objectIsEmpty(i.dataset)&&o.error({componentName:"VueUiRating",type:"dataset"}),y.value=[];for(let a=t.value.from;a<=t.value.to;a+=1)y.value.push(a)}function p(a,n=!1){return a>s.value||c.value?n?t.value.style.image.inactiveOpacity:t.value.style.star.inactiveColor:n?1:t.value.style.star.useGradient?`url(#star_gradient_under_${d.value})`:t.value.style.star.activeColor}function x(a,n=!1){const l=r.value-a,v=n?1:100;switch(!0){case l<=0:return .001;case l>1:return 1*v;default:return l*v}}function b(a){c.value||(r.value=a,_("rate",a))}function E(){return r.value}function V(a=!0){c.value=a}return S({getData:E,toggleReadonly:V}),(a,n)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(`background:${t.value.style.backgroundColor};font-family:${t.value.style.fontFamily};width:100%`),class:"vue-ui-rating",onMouseover:n[2]||(n[2]=l=>g.value=!0),onMouseleave:n[3]||(n[3]=l=>{g.value=!1,s.value=void 0})},[t.value.style.title.text?(e.openBlock(),e.createElementBlock("div",A,[e.createElementVNode("div",{style:e.normalizeStyle(`color:${t.value.style.title.color};font-weight:${t.value.style.title.bold?"bold":"normal"};text-align:${t.value.style.title.textAlign};margin-bottom:${t.value.style.title.offsetY}px;font-size:${t.value.style.title.fontSize}px`)},e.toDisplayString(t.value.style.title.text),5),t.value.style.title.subtitle.text?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`color:${t.value.style.title.subtitle.color};font-size:${t.value.style.title.subtitle.fontSize}px;text-align:${t.value.style.title.textAlign};margin-bottom:${t.value.style.title.subtitle.offsetY}px;font-weight:${t.value.style.title.subtitle.bold?"bold":"normal"}`)},e.toDisplayString(t.value.style.title.subtitle.text),5)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),t.value.style.rating.show&&t.value.style.rating.position==="top"?(e.openBlock(),e.createElementBlock("div",{key:1,style:e.normalizeStyle(`width:100%;text-align:center;margin-bottom:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};margin-left:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"vue-ui-rating-wrapper",style:e.normalizeStyle(`height:${t.value.style.itemSize}px;width:100%;display:flex;align-items:center;justify-content:center`)},[t.value.style.rating.show&&t.value.style.rating.position==="left"?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle(`width:fit-content;text-align:center;margin-bottom:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};padding-right:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(l,v)=>(e.openBlock(),e.createElementBlock("div",{class:"vue-ui-rating-unit-container",style:e.normalizeStyle(`position:relative;height:${t.value.style.itemSize}px;width:${t.value.style.itemSize}px`)},[m.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:t.value.style.image.src,height:t.value.style.itemSize,width:t.value.style.itemSize,class:"vue-ui-rating-unit",style:e.normalizeStyle(`position:absolute;top:0;left:0;opacity:${isNaN(s.value)?t.value.style.image.inactiveOpacity:p(l,!0)}`)},null,12,R)):(e.openBlock(),e.createElementBlock("svg",{key:1,xmlns:e.unref(o.XMLNS),viewBox:"0 0 100 100",height:t.value.style.itemSize,width:t.value.style.itemSize,class:"vue-ui-rating-unit"},[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`star_gradient_under_${d.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(o.shiftHue)(t.value.style.star.activeColor,.05)}`},null,8,F),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.star.activeColor},null,8,I)],8,j)]),e.createElementVNode("polygon",{points:e.unref(o.createStar)({plot:{x:50,y:50},radius:30,apexes:t.value.style.star.apexes}),fill:isNaN(s.value)?t.value.style.star.inactiveColor:p(l),stroke:t.value.style.star.borderColor?t.value.style.star.borderColor:s.value?p(l):t.value.style.star.inactiveColor,"stroke-width":t.value.style.star.borderWidth,"stroke-linecap":"round","stroke-linejoin":"round"},null,8,O)],8,X)),m.value?(e.openBlock(),e.createElementBlock("img",{key:2,src:t.value.style.image.src,alt:`${t.value.style.image.alt} ${l}`,height:t.value.style.itemSize,width:t.value.style.itemSize,id:`active_${d.value}_${l}`,class:"vue-ui-rating-unit",style:e.normalizeStyle(`position:absolute;top:0;left:0;clip:rect(0px,${x(v,!0)*t.value.style.itemSize}px,${t.value.style.itemSize}px,0px`)},null,12,Y)):(e.openBlock(),e.createElementBlock("svg",{key:3,xmlns:e.unref(o.XMLNS),viewBox:`0 0 ${x(v)} 100`,height:t.value.style.itemSize,class:"vue-ui-rating-unit",id:`active_${d.value}_${l}`,style:{position:"absolute",top:"0",left:"0"}},[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`star_gradient_over_${d.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":`${e.unref(o.shiftHue)(t.value.style.star.activeColor,.05)}`},null,8,q),e.createElementVNode("stop",{offset:"100%","stop-color":t.value.style.star.activeColor},null,8,H)],8,U)]),e.createElementVNode("polygon",{points:e.unref(o.createStar)({plot:{x:50,y:50},radius:30,apexes:t.value.style.star.apexes}),fill:t.value.style.star.useGradient?`url(#star_gradient_over_${d.value})`:t.value.style.star.activeColor,stroke:t.value.style.star.activeColor},null,8,K)],8,G)),(e.openBlock(),e.createElementBlock("svg",{xmlns:e.unref(o.XMLNS),viewBox:"0 0 100 100",height:t.value.style.itemSize,class:"vue-ui-rating-unit",style:e.normalizeStyle(`position:absolute;top:0;left:0;${c.value?"":"cursor:pointer"}`)},[c.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("rect",{key:0,class:"vue-ui-rating-mouse-trap",x:0,y:0,width:100,height:100,fill:"transparent",onClick:u=>b(l),onMouseenter:u=>s.value=l,onMouseleave:n[0]||(n[0]=u=>s.value=void 0),tabindex:"0",onKeyup:e.withKeys(u=>b(l),["enter"])},null,40,T)),c.value?(e.openBlock(),e.createElementBlock("rect",{key:1,class:"vue-ui-rating-mouse-trap",x:0,y:0,width:100,height:100,fill:"transparent",onMouseenter:u=>s.value=l,onMouseleave:n[1]||(n[1]=u=>s.value=void 0)},null,40,W)):e.createCommentVNode("",!0)],12,P)),t.value.style.tooltip.show&&N.value&&c.value?(e.openBlock(),e.createElementBlock("div",{key:4,class:"vue-ui-rating-tooltip",style:e.normalizeStyle(`border:1px solid ${t.value.style.tooltip.borderColor};position:absolute;top:${-48+t.value.style.tooltip.offsetY}px;left:50%;transform:translateX(-50%);width:fit-content;text-align:center;background:${t.value.style.tooltip.backgroundColor};display:${s.value===l?"block":"none"};padding:2px 12px;border-radius:${t.value.style.tooltip.borderRadius}px;box-shadow:${t.value.style.tooltip.boxShadow}`)},[e.createElementVNode("div",{style:e.normalizeStyle(`width:100%;display:flex;flex-direction:row;gap:6px;position:relative;text-align:center;color:${t.value.style.tooltip.color}`)},[e.createElementVNode("span",{style:e.normalizeStyle(`font-size:${t.value.style.tooltip.fontSize}px`)},e.toDisplayString(l)+":",5),e.createElementVNode("span",{style:e.normalizeStyle(`font-weight:${t.value.style.tooltip.bold?"bold":"normal"};font-size:${t.value.style.tooltip.fontSize}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.tooltip.formatter,i.dataset.rating[l],e.unref(o.dataLabel)({v:i.dataset.rating[l],r:t.value.style.tooltip.roundingValue}),t.value)),5),e.createElementVNode("div",{style:e.normalizeStyle(`font-family:Arial !important;position:absolute;top:calc(100% - 4px);left:50%;transform:translateX(-50%);color:${t.value.style.tooltip.borderColor}`)}," ▼ ",4)],4)],4)):e.createCommentVNode("",!0)],4))),256)),t.value.style.rating.show&&t.value.style.rating.position==="right"?(e.openBlock(),e.createElementBlock("div",{key:1,style:e.normalizeStyle(`width:fit-content;text-align:center;margin-bottom:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};padding-left:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0)],4),t.value.style.rating.show&&t.value.style.rating.position==="bottom"?(e.openBlock(),e.createElementBlock("div",{key:2,style:e.normalizeStyle(`width:100%;text-align:center;margin-top:${t.value.style.rating.offsetY}px;font-size:${t.value.style.rating.fontSize}px;font-weight:${t.value.style.rating.bold?"bold":"normal"};margin-left:${t.value.style.rating.offsetX}px`)},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.rating.formatter,r.value,e.unref(o.dataLabel)({v:r.value,r:t.value.style.rating.roundingValue}),t.value)),5)):e.createCommentVNode("",!0)],36))}},Q=D._export_sfc(J,[["__scopeId","data-v-9e1d13d5"]]);exports.default=Q;
@@ -1,6 +1,6 @@
1
1
  import { ref as h, useSlots as T, onMounted as R, computed as x, watch as H, openBlock as a, createElementBlock as o, normalizeStyle as i, createElementVNode as r, toDisplayString as g, createCommentVNode as y, unref as s, Fragment as P, renderList as W, withKeys as q } from "vue";
2
- import { u as J, c as Q, o as Z, e as tt, i as $, f as b, X as k, w as F, V as X } from "./index-BqR_a-C7.js";
3
- import { u as et } from "./useNestedProp-DqofSFeh.js";
2
+ import { u as J, c as Q, o as Z, e as tt, i as $, f as b, X as k, w as F, V as X } from "./index-B7nCQFK0.js";
3
+ import { u as et } from "./useNestedProp-C9rlBRTT.js";
4
4
  import { _ as lt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
5
  const at = {
6
6
  key: 0,