vue-data-ui 2.4.21 → 2.4.22

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 (147) hide show
  1. package/dist/{Arrow-BuVX2WoN.js → Arrow-BW_I0Vmx.js} +1 -1
  2. package/dist/{Arrow-DDe-g8rw.cjs → Arrow-D2zjDsxe.cjs} +1 -1
  3. package/dist/{BaseIcon-BdKOa64A.cjs → BaseIcon-BCC16NCl.cjs} +1 -1
  4. package/dist/{BaseIcon-BRSPQaGQ.js → BaseIcon-BbbAnrZI.js} +1 -1
  5. package/dist/{DataTable-BpVz3DBX.js → DataTable-Ce4R8v-3.js} +2 -2
  6. package/dist/{DataTable-H-KTkjfv.cjs → DataTable-DeevzR8O.cjs} +1 -1
  7. package/dist/{Legend-G5Zc4QaZ.cjs → Legend-BksImVUi.cjs} +1 -1
  8. package/dist/{Legend-hnLfwhmm.js → Legend-C6q2bLVV.js} +1 -1
  9. package/dist/{PackageVersion-BbQFSVXm.cjs → PackageVersion-AftniVVo.cjs} +1 -1
  10. package/dist/{PackageVersion-wqab02xF.js → PackageVersion-g2UOsY7H.js} +1 -1
  11. package/dist/{PenAndPaper-C_laA5mt.js → PenAndPaper-DRFeGfqV.js} +3 -3
  12. package/dist/{PenAndPaper-BX8pR5oV.cjs → PenAndPaper-j5noaKJZ.cjs} +1 -1
  13. package/dist/{Shape-QdnXSUyn.js → Shape-CBu7ails.js} +1 -1
  14. package/dist/{Shape-CJbFv4bs.cjs → Shape-Cf2Cj3g6.cjs} +1 -1
  15. package/dist/{Slicer-DV1kBscZ.js → Slicer-C0bRksfh.js} +2 -2
  16. package/dist/{Slicer-C1blYfez.cjs → Slicer-IneBjcpY.cjs} +1 -1
  17. package/dist/{Title-DBozX6nP.js → Title-B2orjUIW.js} +1 -1
  18. package/dist/{Title-BRqTk-nT.cjs → Title-BxrsVY3-.cjs} +1 -1
  19. package/dist/{Tooltip-DvGSIp31.cjs → Tooltip-BXc56Oxr.cjs} +1 -1
  20. package/dist/{Tooltip-Com_T8vc.js → Tooltip-CXjc5vb3.js} +1 -1
  21. package/dist/{index-CsQwCVqU.cjs → index-3oZdQf6G.cjs} +1 -1
  22. package/dist/{index-hV0hU1iE.js → index-D020Kb3z.js} +1 -1
  23. package/dist/style.css +1 -1
  24. package/dist/{useNestedProp-CRAUOmT5.js → useNestedProp-CZkNAGQh.js} +1 -1
  25. package/dist/{useNestedProp-DSYpaLxP.cjs → useNestedProp-vPTP0Wem.cjs} +1 -1
  26. package/dist/{usePrinter-O2fMMTMe.cjs → usePrinter-BKzxQK4e.cjs} +1 -1
  27. package/dist/{usePrinter-y3d31M4g.js → usePrinter-CN0J0NFL.js} +1 -1
  28. package/dist/{vue-data-ui-qBad3a6z.cjs → vue-data-ui-CWDZLUkp.cjs} +1 -1
  29. package/dist/{vue-data-ui-bEKZH8jG.js → vue-data-ui-e2cclW_4.js} +58 -58
  30. package/dist/vue-data-ui.cjs +1 -1
  31. package/dist/vue-data-ui.js +1 -1
  32. package/dist/{vue-ui-3d-bar-CkqKnqQt.cjs → vue-ui-3d-bar-DCeFCwb0.cjs} +1 -1
  33. package/dist/{vue-ui-3d-bar-f7YaBbrh.js → vue-ui-3d-bar-DggyGAlC.js} +9 -9
  34. package/dist/{vue-ui-accordion-m-s-7akB.js → vue-ui-accordion-B0fEWLwn.js} +3 -3
  35. package/dist/{vue-ui-accordion-CaktYQoo.cjs → vue-ui-accordion-QoJofzqF.cjs} +1 -1
  36. package/dist/{vue-ui-age-pyramid-EKKYQu3N.cjs → vue-ui-age-pyramid-CXtRGpVa.cjs} +1 -1
  37. package/dist/{vue-ui-age-pyramid-DkfNZR86.js → vue-ui-age-pyramid-DGDvfcvP.js} +10 -10
  38. package/dist/{vue-ui-annotator-DrVu5Pu0.js → vue-ui-annotator-BETCQ-pV.js} +1 -1
  39. package/dist/{vue-ui-annotator-v07J6oQG.cjs → vue-ui-annotator-BEZ0D_12.cjs} +1 -1
  40. package/dist/{vue-ui-bullet-CYDMehDZ.js → vue-ui-bullet-BK3d_nhc.js} +8 -8
  41. package/dist/{vue-ui-bullet-CdG92x7A.cjs → vue-ui-bullet-qAGQkwN4.cjs} +1 -1
  42. package/dist/{vue-ui-candlestick-Bw1O3QmK.js → vue-ui-candlestick-DQR8cYLr.js} +11 -11
  43. package/dist/{vue-ui-candlestick-D9yN-yRo.cjs → vue-ui-candlestick-DwfFHSRG.cjs} +1 -1
  44. package/dist/{vue-ui-carousel-table-kcQa0FHw.js → vue-ui-carousel-table-B6TSxUwp.js} +4 -4
  45. package/dist/{vue-ui-carousel-table-Cg6hAEVv.cjs → vue-ui-carousel-table-BrIXFgJp.cjs} +1 -1
  46. package/dist/{vue-ui-chestnut-Qu8c3_vB.cjs → vue-ui-chestnut-CWtw_edx.cjs} +1 -1
  47. package/dist/{vue-ui-chestnut-DE1AMXeX.js → vue-ui-chestnut-CpINqXRz.js} +8 -8
  48. package/dist/{vue-ui-cursor-DG8oufeh.cjs → vue-ui-cursor-DvX6FbhZ.cjs} +1 -1
  49. package/dist/{vue-ui-cursor-DbfjKtpf.js → vue-ui-cursor-yI58QC1O.js} +2 -2
  50. package/dist/{vue-ui-dashboard-BbwgfxLx.cjs → vue-ui-dashboard-BCic2CfN.cjs} +1 -1
  51. package/dist/{vue-ui-dashboard-CAkCNUBh.js → vue-ui-dashboard-Bb7vJ0Nx.js} +2 -2
  52. package/dist/{vue-ui-digits-DgQkxULm.cjs → vue-ui-digits-C4dI1v6b.cjs} +1 -1
  53. package/dist/{vue-ui-digits-BaXAiH4u.js → vue-ui-digits-D4uy7_hL.js} +2 -2
  54. package/dist/{vue-ui-donut-7GM_Wd1Y.js → vue-ui-donut-CRiEc5mP.js} +11 -11
  55. package/dist/{vue-ui-donut-BHzCOBu6.cjs → vue-ui-donut-ClvjMOxC.cjs} +1 -1
  56. package/dist/{vue-ui-donut-evolution-C-TkUOr6.cjs → vue-ui-donut-evolution-DFkGtmhv.cjs} +1 -1
  57. package/dist/{vue-ui-donut-evolution-DbU4RlP6.js → vue-ui-donut-evolution-DgrQVEh2.js} +11 -11
  58. package/dist/{vue-ui-dumbbell-DacMeiTU.cjs → vue-ui-dumbbell-BdkARfxX.cjs} +1 -1
  59. package/dist/{vue-ui-dumbbell-BacTx3zB.js → vue-ui-dumbbell-QCB4jZm4.js} +10 -10
  60. package/dist/{vue-ui-flow-D2G0YWL9.js → vue-ui-flow-CRnCk5Is.js} +9 -9
  61. package/dist/{vue-ui-flow-BUAvjG7i.cjs → vue-ui-flow-CYfdTIad.cjs} +1 -1
  62. package/dist/{vue-ui-galaxy-CxfV3BIw.cjs → vue-ui-galaxy-Cn9t3BG5.cjs} +1 -1
  63. package/dist/{vue-ui-galaxy-D6RFyIbQ.js → vue-ui-galaxy-WhRsA1Is.js} +11 -11
  64. package/dist/{vue-ui-gauge-DNJXnyLw.js → vue-ui-gauge-DwmCZiTj.js} +7 -7
  65. package/dist/{vue-ui-gauge-CJ5TKJpb.cjs → vue-ui-gauge-jYskVFUy.cjs} +1 -1
  66. package/dist/{vue-ui-gizmo-BBA51j_0.cjs → vue-ui-gizmo-C2P2qQYU.cjs} +1 -1
  67. package/dist/{vue-ui-gizmo-Db7-gRmB.js → vue-ui-gizmo-DpEZm4Uk.js} +3 -3
  68. package/dist/{vue-ui-heatmap-KQj8Jbpt.cjs → vue-ui-heatmap-D7TGNxC-.cjs} +1 -1
  69. package/dist/{vue-ui-heatmap-Ba6RMSTk.js → vue-ui-heatmap-u3SOjwts.js} +10 -10
  70. package/dist/{vue-ui-kpi-1srKxA1L.cjs → vue-ui-kpi-CCr0pHjp.cjs} +1 -1
  71. package/dist/{vue-ui-kpi-C8wyHy1H.js → vue-ui-kpi-Cdz5RM6j.js} +3 -3
  72. package/dist/{vue-ui-mini-loader-DutVmCuC.js → vue-ui-mini-loader-B2Xh0j5H.js} +2 -2
  73. package/dist/{vue-ui-mini-loader-BgKTecng.cjs → vue-ui-mini-loader-BuCeYPNP.cjs} +1 -1
  74. package/dist/{vue-ui-molecule-BOkIojio.js → vue-ui-molecule-GPDqR2rp.js} +11 -11
  75. package/dist/{vue-ui-molecule-CSezTn3m.cjs → vue-ui-molecule-z1A47zG1.cjs} +1 -1
  76. package/dist/{vue-ui-mood-radar-C8U8PHaq.js → vue-ui-mood-radar-DdQC5bH5.js} +11 -11
  77. package/dist/{vue-ui-mood-radar-CNTDrRs6.cjs → vue-ui-mood-radar-YZfCADah.cjs} +1 -1
  78. package/dist/{vue-ui-nested-donuts-DRWWnsdR.cjs → vue-ui-nested-donuts-CDSRcEX0.cjs} +1 -1
  79. package/dist/{vue-ui-nested-donuts-Bv2D1uFd.js → vue-ui-nested-donuts-Cf_KfoeP.js} +11 -11
  80. package/dist/{vue-ui-onion-CsnwbXED.cjs → vue-ui-onion-CmGZo3Sf.cjs} +1 -1
  81. package/dist/{vue-ui-onion-CT9YjU8v.js → vue-ui-onion-Lw3ohFAX.js} +11 -11
  82. package/dist/{vue-ui-parallel-coordinate-plot-C8KCRAX1.cjs → vue-ui-parallel-coordinate-plot-AHpf7ejC.cjs} +1 -1
  83. package/dist/{vue-ui-parallel-coordinate-plot-in5qpfXf.js → vue-ui-parallel-coordinate-plot-BsT0r0hr.js} +12 -12
  84. package/dist/{vue-ui-quadrant-Bw-0aW4F.cjs → vue-ui-quadrant-BPUIyB4-.cjs} +1 -1
  85. package/dist/{vue-ui-quadrant-C_9VNAXg.js → vue-ui-quadrant-BTmoe6UT.js} +12 -12
  86. package/dist/{vue-ui-quick-chart-C0YqMjyE.cjs → vue-ui-quick-chart-BYyXa06h.cjs} +1 -1
  87. package/dist/{vue-ui-quick-chart-BDBlm9uu.js → vue-ui-quick-chart-CRtE0pcc.js} +9 -9
  88. package/dist/{vue-ui-radar-C2QM_ee9.js → vue-ui-radar-BpkjOSOI.js} +12 -12
  89. package/dist/{vue-ui-radar-DXKMbeyW.cjs → vue-ui-radar-krdMX_hl.cjs} +1 -1
  90. package/dist/{vue-ui-rating-CsOknvaV.cjs → vue-ui-rating-9kj9GE7P.cjs} +1 -1
  91. package/dist/{vue-ui-rating-DVpgv2AY.js → vue-ui-rating-D1RlkwK9.js} +2 -2
  92. package/dist/{vue-ui-relation-circle-OXfdAyky.js → vue-ui-relation-circle-B7WGb08k.js} +7 -7
  93. package/dist/{vue-ui-relation-circle-ZA-M7aSc.cjs → vue-ui-relation-circle-Kv3G0P5k.cjs} +1 -1
  94. package/dist/{vue-ui-rings-qLQ-gl21.js → vue-ui-rings-DjXcLsY1.js} +11 -11
  95. package/dist/{vue-ui-rings-rftqDu-q.cjs → vue-ui-rings-DsZPnoqm.cjs} +1 -1
  96. package/dist/{vue-ui-scatter-Cv2IcrVH.cjs → vue-ui-scatter-D3ntjnfT.cjs} +1 -1
  97. package/dist/{vue-ui-scatter-4LbMvEAD.js → vue-ui-scatter-DEkTyyG8.js} +12 -12
  98. package/dist/{vue-ui-screenshot-BgjnQNxG.cjs → vue-ui-screenshot-BEbUxjNl.cjs} +1 -1
  99. package/dist/{vue-ui-screenshot-BV6ZYQRk.js → vue-ui-screenshot-kiJVXAGt.js} +1 -1
  100. package/dist/{vue-ui-skeleton-DsRTbz6d.cjs → vue-ui-skeleton-CI8sxaqr.cjs} +1 -1
  101. package/dist/{vue-ui-skeleton-BY8Jg9a_.js → vue-ui-skeleton-E1-7diF5.js} +3 -3
  102. package/dist/{vue-ui-smiley-BQ_3uicm.js → vue-ui-smiley-Cjbqlfre.js} +2 -2
  103. package/dist/{vue-ui-smiley-DB3y8CIb.cjs → vue-ui-smiley-CmkUQtfb.cjs} +1 -1
  104. package/dist/{vue-ui-spark-trend-Cgn7ONtS.cjs → vue-ui-spark-trend-C60Ypeev.cjs} +1 -1
  105. package/dist/{vue-ui-spark-trend-BhCJfY_p.js → vue-ui-spark-trend-DfpFe1UQ.js} +5 -5
  106. package/dist/{vue-ui-sparkbar-DxXt-GHr.js → vue-ui-sparkbar-B5oV2RUs.js} +4 -4
  107. package/dist/{vue-ui-sparkbar-D4GIhUXT.cjs → vue-ui-sparkbar-BAa71eZp.cjs} +1 -1
  108. package/dist/{vue-ui-sparkgauge-BbltbIrq.cjs → vue-ui-sparkgauge-UejPQm4b.cjs} +1 -1
  109. package/dist/{vue-ui-sparkgauge-BCPkJveV.js → vue-ui-sparkgauge-xlERw-g0.js} +4 -4
  110. package/dist/{vue-ui-sparkhistogram-DzX6lkk8.cjs → vue-ui-sparkhistogram-DC4jzkI0.cjs} +1 -1
  111. package/dist/{vue-ui-sparkhistogram-BKcr2mFc.js → vue-ui-sparkhistogram-nzFRlmgx.js} +5 -5
  112. package/dist/{vue-ui-sparkline-C-svTmFU.cjs → vue-ui-sparkline-BT4hxfBE.cjs} +1 -1
  113. package/dist/{vue-ui-sparkline-DYHUFUOp.js → vue-ui-sparkline-Duu0VrnG.js} +4 -4
  114. package/dist/{vue-ui-sparkstackbar-CL0uL_Te.cjs → vue-ui-sparkstackbar-K_vPau1u.cjs} +1 -1
  115. package/dist/{vue-ui-sparkstackbar-Btag2osm.js → vue-ui-sparkstackbar-tyoFIhva.js} +5 -5
  116. package/dist/{vue-ui-stackbar-CML7v_yU.cjs → vue-ui-stackbar-DRlvF164.cjs} +1 -1
  117. package/dist/{vue-ui-stackbar-C2mRU7ya.js → vue-ui-stackbar-e8BUjttp.js} +12 -12
  118. package/dist/{vue-ui-strip-plot-Vn5sEcME.cjs → vue-ui-strip-plot-8MOhIicL.cjs} +1 -1
  119. package/dist/{vue-ui-strip-plot-BIXF3VxN.js → vue-ui-strip-plot-Ef8oKjNV.js} +11 -11
  120. package/dist/{vue-ui-table-CyuRalnp.js → vue-ui-table-BOV6jtcL.js} +1 -1
  121. package/dist/{vue-ui-table-BbVpmm0B.cjs → vue-ui-table-DfevkNnK.cjs} +1 -1
  122. package/dist/{vue-ui-table-heatmap-DrQXQd41.cjs → vue-ui-table-heatmap-BMyRP1ol.cjs} +1 -1
  123. package/dist/{vue-ui-table-heatmap-DlGeS3l9.js → vue-ui-table-heatmap-CL-MybKI.js} +4 -4
  124. package/dist/{vue-ui-table-sparkline-DauDTktD.cjs → vue-ui-table-sparkline-CsqcT3ff.cjs} +1 -1
  125. package/dist/{vue-ui-table-sparkline-Yg2I33yZ.js → vue-ui-table-sparkline-DXvxiDJJ.js} +5 -5
  126. package/dist/{vue-ui-thermometer-Bglz0dOQ.cjs → vue-ui-thermometer-DyYqfAOW.cjs} +1 -1
  127. package/dist/{vue-ui-thermometer-DXwbqNrn.js → vue-ui-thermometer-WKzTNOOX.js} +7 -7
  128. package/dist/{vue-ui-timer-Brr7buaM.js → vue-ui-timer-CFDkyaxV.js} +5 -5
  129. package/dist/{vue-ui-timer-CpSEl8UD.cjs → vue-ui-timer-DQQGe1jt.cjs} +1 -1
  130. package/dist/{vue-ui-tiremarks-zdGmZNjo.cjs → vue-ui-tiremarks-C8iAWe-u.cjs} +1 -1
  131. package/dist/{vue-ui-tiremarks-DJowPFwY.js → vue-ui-tiremarks-aiUC8-YL.js} +7 -7
  132. package/dist/{vue-ui-treemap-a7NSP656.cjs → vue-ui-treemap-BORZ3g1I.cjs} +1 -1
  133. package/dist/{vue-ui-treemap-Bn5JU5BI.js → vue-ui-treemap-Bw-bWkza.js} +11 -11
  134. package/dist/{vue-ui-vertical-bar-CZxN7L9z.js → vue-ui-vertical-bar--mYbTcpi.js} +11 -11
  135. package/dist/{vue-ui-vertical-bar-BYG1vGlT.cjs → vue-ui-vertical-bar-B3ypOHUB.cjs} +1 -1
  136. package/dist/{vue-ui-waffle-CzUpKfkZ.js → vue-ui-waffle-Bj-tJs4n.js} +11 -11
  137. package/dist/{vue-ui-waffle-BbDBOivH.cjs → vue-ui-waffle-_84Hvek7.cjs} +1 -1
  138. package/dist/{vue-ui-wheel-CCje_ZSc.js → vue-ui-wheel-BywwqvY2.js} +7 -7
  139. package/dist/{vue-ui-wheel-lN3uYCr4.cjs → vue-ui-wheel-C-v9TgG1.cjs} +1 -1
  140. package/dist/{vue-ui-word-cloud-BjvG3n7x.cjs → vue-ui-word-cloud-CaQ4jLed.cjs} +1 -1
  141. package/dist/{vue-ui-word-cloud-D_5y92zN.js → vue-ui-word-cloud-CwExwCYc.js} +10 -10
  142. package/dist/{vue-ui-xy-Drm1aAb-.js → vue-ui-xy-CAYxRDzC.js} +14 -14
  143. package/dist/{vue-ui-xy-B-WlwJXZ.cjs → vue-ui-xy-CT3-xPpa.cjs} +1 -1
  144. package/dist/{vue-ui-xy-canvas-jieVsnBN.js → vue-ui-xy-canvas-BOElCo0f.js} +133 -131
  145. package/dist/vue-ui-xy-canvas-CdrfnVuI.cjs +9 -0
  146. package/package.json +1 -1
  147. package/dist/vue-ui-xy-canvas-BHrq_CYD.cjs +0 -9
@@ -1,15 +1,15 @@
1
1
  import { computed as c, onMounted as ge, ref as v, watch as ke, openBlock as r, createElementBlock as y, normalizeClass as Y, normalizeStyle as V, createBlock as h, createCommentVNode as u, createVNode as j, unref as s, createSlots as be, withCtx as f, renderSlot as m, normalizeProps as B, guardReactiveProps as D, createElementVNode as a, Fragment as J, renderList as Q, toDisplayString as M, createTextVNode as Z, nextTick as Ce } from "vue";
2
- import { u as _e, o as xe, e as ee, c as we, t as $e, O as Me, X as Pe, s as C, w as Ne, P as Ae, i as te, f as O, q as Te, r as Le } from "./index-hV0hU1iE.js";
3
- import { _ as Oe } from "./Title-DBozX6nP.js";
4
- import { u as Ie, U as Fe } from "./usePrinter-y3d31M4g.js";
5
- import { L as Se } from "./Legend-hnLfwhmm.js";
6
- import P from "./BaseIcon-BRSPQaGQ.js";
7
- import { D as Ve } from "./DataTable-BpVz3DBX.js";
8
- import je from "./vue-ui-skeleton-BY8Jg9a_.js";
9
- import Be from "./vue-ui-accordion-m-s-7akB.js";
10
- import { u as oe } from "./useNestedProp-CRAUOmT5.js";
11
- import { _ as De } from "./PackageVersion-wqab02xF.js";
12
- import { P as We } from "./PenAndPaper-C_laA5mt.js";
2
+ import { u as _e, o as xe, e as ee, c as we, t as $e, O as Me, X as Pe, s as C, w as Ne, P as Ae, i as te, f as O, q as Te, r as Le } from "./index-D020Kb3z.js";
3
+ import { _ as Oe } from "./Title-B2orjUIW.js";
4
+ import { u as Ie, U as Fe } from "./usePrinter-CN0J0NFL.js";
5
+ import { L as Se } from "./Legend-C6q2bLVV.js";
6
+ import P from "./BaseIcon-BbbAnrZI.js";
7
+ import { D as Ve } from "./DataTable-Ce4R8v-3.js";
8
+ import je from "./vue-ui-skeleton-E1-7diF5.js";
9
+ import Be from "./vue-ui-accordion-B0fEWLwn.js";
10
+ import { u as oe } from "./useNestedProp-CZkNAGQh.js";
11
+ import { _ as De } from "./PackageVersion-g2UOsY7H.js";
12
+ import { P as We } from "./PenAndPaper-DRFeGfqV.js";
13
13
  import { _ as ze } from "./_plugin-vue_export-helper-CHgC5LLL.js";
14
14
  const Ge = ["id"], Ee = {
15
15
  key: 2,
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-CsQwCVqU.cjs"),Q=require("./Title-BRqTk-nT.cjs"),L=require("./usePrinter-O2fMMTMe.cjs"),Z=require("./Legend-G5Zc4QaZ.cjs"),f=require("./BaseIcon-BdKOa64A.cjs"),ee=require("./DataTable-H-KTkjfv.cjs"),te=require("./vue-ui-skeleton-DsRTbz6d.cjs"),oe=require("./vue-ui-accordion-CaktYQoo.cjs"),O=require("./useNestedProp-DSYpaLxP.cjs"),le=require("./PackageVersion-BbQFSVXm.cjs"),ae=require("./PenAndPaper-BX8pR5oV.cjs"),re=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),ne=["id"],se={key:2,style:"width:100%;background:transparent"},ue=["xmlns","viewBox"],ie=["id"],ce=["stop-color"],de=["stop-color"],ye=["x1","y1","x2","y2","stroke","stroke-width"],ve=["d","stroke","stroke-width"],me=["stroke"],he=["fill"],pe=["stroke"],fe=["fill"],ke=["stroke"],ge=["fill"],be=["stroke"],Ce=["fill"],Ne=["stroke"],xe=["fill"],we=["d","stroke","stroke-width","fill"],_e=["x1","y1","stroke"],Ve=["cx","cy","fill","stroke"],Pe=["fill","stroke"],Be=["y","fill","font-weight"],$e=["y","fill"],Me={key:5,class:"vue-data-ui-watermark"},Ee=["onClick"],Ae={style:{"font-weight":"bold"}},Se={key:8,ref:"source",dir:"auto"},Te=["innerHTML"],Le={__name:"vue-ui-mood-radar",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(I,{expose:F}){const s=I,{vue_ui_mood_radar:D}=r.useConfig(),m=e.computed(()=>!!s.dataset&&Object.keys(s.dataset).length);e.onMounted(()=>{_()});function _(){r.objectIsEmpty(s.dataset)&&r.error({componentName:"VueUiMoodRadar",type:"dataset"})}const h=e.ref(r.createUid()),N=e.ref(null),q=e.ref(null),n=e.ref(null),z=e.ref(null),j=e.ref(0),W=e.ref(0),V=e.ref(0),t=e.computed({get:()=>P(),set:l=>l});function P(){const l=O.useNestedProp({userConfig:s.config,defaultConfig:D});return l.theme?{...O.useNestedProp({userConfig:r.themes.vue_ui_mood_radar[l.theme]||s.config,defaultConfig:l})}:l}e.watch(()=>s.config,l=>{t.value=P(),_(),j.value+=1,W.value+=1,V.value+=1},{deep:!0});const{isPrinting:B,isImaging:$,generatePdf:M,generateImage:E}=L.usePrinter({elementId:h.value,fileName:t.value.style.chart.title.text||"vue-ui-mood-radar"}),G=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),k=e.ref({showTable:t.value.table.show}),d=e.computed(()=>({height:256,width:256})),x=e.computed(()=>r.createPolygonPath({plot:{x:128,y:d.value.height/2},radius:90,sides:5,rotation:11}));function R({centerX:l,centerY:a,apexX:o,apexY:u,proportion:c,key:p,value:J}){return{x:l+(o-l)*c,y:a+(u-a)*c,key:p,value:J}}const U=e.computed(()=>Math.max(...Object.values(s.dataset).map(l=>isNaN(l)?0:l))),v=e.computed(()=>Object.values(s.dataset).reduce((l,a)=>(isNaN(l)?0:l)+(isNaN(a)?0:a),0)),i=e.computed(()=>Object.keys(s.dataset).map((l,a)=>{const o=typeof s.dataset[l]!="number"||isNaN(s.dataset[l])?0:s.dataset[l];return{index:a,key:l,value:o,proportion:o/v.value,color:t.value.style.chart.layout.smileys.colors[l]}}).sort((l,a)=>a.key-l.key)),A=e.computed(()=>m.value?(["1","2","3","4","5"].forEach(l=>{[null,void 0].includes(s.dataset[l])&&r.error({componentName:"VueUiMoodRadar",type:"datasetAttribute",property:l})}),x.value.coordinates.map((l,a)=>{const o=R({centerX:d.value.width/2,centerY:d.value.height/2,apexX:l.x,apexY:l.y,proportion:i.value[a].value/U.value,key:i.value[a].key,value:i.value[a].value});return{...l,plots:o,key:i.value[a].key}})):[]),H=e.computed(()=>({cy:"mood-radar-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":""}));function X(l){l===n.value?n.value=null:n.value=l}const y=e.computed(()=>{const l=i.value.map(o=>({name:o.key,color:o.color})),a=i.value.map(o=>isNaN(o.value)?0:o.value);return{head:l,body:a}});function S(){e.nextTick(()=>{const l=y.value.head.map((u,c)=>[[u.name],[y.value.body[c]],[isNaN(y.value.body[c]/v.value)?"-":y.value.body[c]/v.value*100]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],["val"],["%"]]].concat(l),o=r.createCsvContent(a);r.downloadCsv({csvContent:o,title:t.value.style.chart.title.text||"vue-ui-mood-radar"})})}const g=e.computed(()=>{const l=[' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>',Number(v.value.toFixed(t.value.table.td.roundingValue)).toLocaleString(),"100%"],a=y.value.head.map((c,p)=>[{color:c.color,name:c.name},y.value.body[p].toFixed(t.value.table.td.roundingValue),isNaN(y.value.body[p]/v.value)?"-":(y.value.body[p]/v.value*100).toFixed(t.value.table.td.roundingPercentage)+"%"]),o={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},u=[t.value.table.columnNames.series,t.value.table.columnNames.value,t.value.table.columnNames.percentage];return{head:l,body:a,config:o,colNames:u}});function K(){return i.value}function T(){k.value.showTable=!k.value.showTable}const b=e.ref(!1);function Y(l){b.value=l}const C=e.ref(!1);function w(){C.value=!C.value}return F({getData:K,generatePdf:M,generateCsv:S,generateImage:E,toggleTable:T,toggleAnnotator:w}),(l,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-mood-radar ${b.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),ref_key:"moodRadarChart",ref:N,id:`${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`)},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(ae.PenAndPaper,{key:0,parent:N.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:C.value,onClose:w},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),G.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:z,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",se,[e.createVNode(Q._sfc_main,{config:{title:{cy:"mood-radar-title",...t.value.style.chart.title},subtitle:{cy:"mood-radar-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"])])):e.createCommentVNode("",!0),t.value.userOptions.show&&m.value?(e.openBlock(),e.createBlock(L.UserOptions,{key:3,ref_key:"details",ref:q,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(B),isImaging:e.unref($),uid:h.value,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,titles:{...t.value.userOptions.buttonTitles},chartElement:N.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:C.value,onToggleFullscreen:Y,onGeneratePdf:e.unref(M),onGenerateCsv:S,onGenerateImage:e.unref(E),onToggleTable:T,onToggleAnnotator:w},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:o,isFullscreen:u})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:u})),void 0,!0)]),key:"4"}:void 0,l.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:o,isAnnotator:u})=>[e.renderSlot(l.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:o,isAnnotator:u})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(r.XMLNS),viewBox:`0 0 ${d.value.width} ${d.value.height}`,class:e.normalizeClass({"vue-data-ui-fullscreen--on":b.value,"vue-data-ui-fulscreen--off":!b.value}),style:e.normalizeStyle(`overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(le._sfc_main),e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`mood_radar_gradient_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(r.setOpacity)(t.value.style.chart.layout.dataPolygon.color,t.value.style.chart.layout.dataPolygon.opacity)},null,8,ce),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(r.setOpacity)(e.unref(r.shiftHue)(t.value.style.chart.layout.dataPolygon.color,t.value.style.chart.layout.dataPolygon.gradient.intensity/100),t.value.style.chart.layout.dataPolygon.opacity)},null,8,de)],8,ie)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value.coordinates,o=>(e.openBlock(),e.createElementBlock("line",{x1:d.value.width/2,y1:d.value.height/2,x2:o.x,y2:o.y,stroke:t.value.style.chart.layout.grid.stroke,"stroke-width":t.value.style.chart.layout.grid.strokeWidth},null,8,ye))),256)),e.createElementVNode("path",{d:x.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,ve),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[5],"stroke-width":"1","stroke-linecap":"round",d:"M119 25A1 1 0 00137 25 1 1 0 00119 25M123 26C124 33 132 33 133 26L123 26M123 22A1 1 0 00126 22 1 1 0 00123 22M130 22A1 1 0 00133 22 1 1 0 00130 22"},null,8,me),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[0]||(a[0]=o=>n.value=5),onMouseleave:a[1]||(a[1]=o=>n.value=null),cx:"128",cy:"25",r:"20",fill:n.value===5?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[5],20):"transparent"},null,40,he),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[4],"stroke-width":"1","stroke-linecap":"round",d:"M218 95A1 1 0 00236 95 1 1 0 00218 95M222 97C225 99 229 99 232 97M222 92A1 1 0 00225 92 1 1 0 00222 92M229 92A1 1 0 00232 92 1 1 0 00229 92"},null,8,pe),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[2]||(a[2]=o=>n.value=4),onMouseleave:a[3]||(a[3]=o=>n.value=null),cx:"227",cy:"95.5",r:"20",fill:n.value===4?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[4],20):"transparent"},null,40,fe),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[3],"stroke-width":"1","stroke-linecap":"round",d:"M181 213A1 1 0 00199 213 1 1 0 00181 213M185 210A1 1 0 00188 210 1 1 0 00185 210M192 210A1 1 0 00195 210 1 1 0 00192 210M185 215 195 215"},null,8,ke),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[4]||(a[4]=o=>n.value=3),onMouseleave:a[5]||(a[5]=o=>n.value=null),cx:"190",cy:"213.5",r:"20",fill:n.value===3?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[3],20):"transparent"},null,40,ge),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[2],"stroke-width":"1","stroke-linecap":"round",d:"M56 213A1 1 0 0074 213 1 1 0 0056 213M60 216C63 214 67 214 70 216M60 210A1 1 0 0063 210 1 1 0 0060 210M67 210A1 1 0 0070 210 1 1 0 0067 210"},null,8,be),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[6]||(a[6]=o=>n.value=2),onMouseleave:a[7]||(a[7]=o=>n.value=null),cx:"65",cy:"213.5",r:"20",fill:n.value===2?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[2],20):"transparent"},null,40,Ce),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[1],"stroke-width":"1","stroke-linecap":"round",d:"M20 96A1 1 0 0038 96 1 1 0 0020 96M24 100C25 95 33 95 34 100L24 100M24 93A1 1 0 0027 93 1 1 0 0024 93M31 93A1 1 0 0034 93 1 1 0 0031 93"},null,8,Ne),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[8]||(a[8]=o=>n.value=1),onMouseleave:a[9]||(a[9]=o=>n.value=null),cx:"29",cy:"95.5",r:"20",fill:n.value===1?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[1],20):"transparent"},null,40,xe),e.createElementVNode("path",{d:e.unref(r.makePath)(A.value.map(o=>o.plots)),stroke:t.value.style.chart.layout.dataPolygon.stroke,"stroke-width":t.value.style.chart.layout.dataPolygon.strokeWidth,"stroke-linecap":"round","stroke-linejoin":"round",fill:t.value.style.chart.layout.dataPolygon.gradient.show?`url(#mood_radar_gradient_${h.value})`:e.unref(r.setOpacity)(t.value.style.chart.layout.dataPolygon.color,t.value.style.chart.layout.dataPolygon.opacity)},null,8,we),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(A.value.map(o=>o.plots),(o,u)=>(e.openBlock(),e.createElementBlock("g",{class:"vue-ui-mood-radar-trap",style:e.normalizeStyle(`opacity:${n.value==o.key?"1":"0"}`)},[e.createElementVNode("line",{x1:o.x,y1:o.y,x2:128,y2:128,stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,_e),e.createElementVNode("circle",{cx:o.x,cy:o.y,fill:t.value.style.chart.layout.smileys.colors[o.key],r:"3",stroke:t.value.style.chart.backgroundColor,"stroke-width":.5},null,8,Ve),e.createElementVNode("circle",{cx:128,cy:128,fill:t.value.style.chart.layout.smileys.colors[o.key],r:"3",stroke:t.value.style.chart.backgroundColor,"stroke-width":.5},null,8,Pe),e.createElementVNode("text",{x:128,y:["5",5].includes(o.key)?145:120,fill:t.value.style.chart.layout.dataLabel.color,"font-size":"12","text-anchor":"middle","font-weight":t.value.style.chart.layout.dataLabel.bold?"bold":"normal"},e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.dataLabel.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.dataLabel.prefix,v:o.value,s:t.value.style.chart.layout.dataLabel.suffix,r:t.value.style.chart.layout.dataLabel.roundingValue}),{datapoint:o,seriesIndex:u})),9,Be),e.createElementVNode("text",{x:128,y:["5",5].includes(o.key)?163:102,fill:t.value.style.chart.layout.dataLabel.color,"font-size":"12","text-anchor":"middle"}," ("+e.toDisplayString(e.unref(r.dataLabel)({v:o.value/v.value*100,s:"%",r:t.value.style.chart.layout.dataLabel.roundingPercentage}))+") ",9,$e)],4))),256)),e.renderSlot(l.$slots,"svg",{svg:d.value},void 0,!0)],14,ue)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Me,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(B)||e.unref($)})),void 0,!0)])):e.createCommentVNode("",!0),m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(te.default,{key:6,config:{type:"radar",style:{backgroundColor:t.value.style.chart.backgroundColor,radar:{grid:{color:"#CCCCCC"},shapes:{color:"#CCCCCC"}}}}},null,8,["config"])),t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(Z.Legend,{legendSet:i.value,config:H.value,key:`legend_${V.value}`,style:{display:"flex","row-gap":"6px"}},{item:e.withCtx(({legend:o,index:u})=>[e.createElementVNode("div",{onClick:()=>X(o.key),style:{display:"flex","flex-direction":"row",gap:"3px","align-items":"center",margin:"3px 0"}},[o.key==1?(e.openBlock(),e.createBlock(f.default,{key:0,strokeWidth:1,name:"moodSad",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==2?(e.openBlock(),e.createBlock(f.default,{key:1,strokeWidth:1,name:"moodFlat",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==3?(e.openBlock(),e.createBlock(f.default,{key:2,strokeWidth:1,name:"moodNeutral",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==4?(e.openBlock(),e.createBlock(f.default,{key:3,strokeWidth:1,name:"smiley",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==5?(e.openBlock(),e.createBlock(f.default,{key:4,strokeWidth:1,name:"moodHappy",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),e.createElementVNode("span",Ae,e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.dataLabel.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.dataLabel.prefix,v:o.value,s:t.value.style.chart.layout.dataLabel.suffix,r:t.value.style.chart.layout.dataLabel.roundingValue}),{datapoint:o,seriesIndex:u})),1),e.createTextVNode(" ("+e.toDisplayString(e.unref(r.dataLabel)({v:o.proportion*100,s:"%",r:t.value.style.chart.legend.roundingPercentage}))+") ",1)],8,Ee)]),_:1},8,["legendSet","config"])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"legend",{legend:i.value},void 0,!0),l.$slots.source?(e.openBlock(),e.createElementBlock("div",Se,[e.renderSlot(l.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createBlock(oe.default,{key:9,hideDetails:"",config:{open:k.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.createVNode(ee.DataTable,{colNames:g.value.colNames,head:g.value.head,body:g.value.body,config:g.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[10]||(a[10]=o=>k.value.showTable=!1)},{th:e.withCtx(({th:o})=>[e.createElementVNode("div",{innerHTML:o,style:{display:"flex","align-items":"center"}},null,8,Te)]),td:e.withCtx(({td:o})=>[e.createTextVNode(e.toDisplayString(o.name||o),1)]),_:1},8,["colNames","head","body","config","title"])]),_:1},8,["config"])):e.createCommentVNode("",!0)],14,ne))}},Oe=re._export_sfc(Le,[["__scopeId","data-v-80a971b6"]]);exports.default=Oe;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-3oZdQf6G.cjs"),Q=require("./Title-BxrsVY3-.cjs"),L=require("./usePrinter-BKzxQK4e.cjs"),Z=require("./Legend-BksImVUi.cjs"),f=require("./BaseIcon-BCC16NCl.cjs"),ee=require("./DataTable-DeevzR8O.cjs"),te=require("./vue-ui-skeleton-CI8sxaqr.cjs"),oe=require("./vue-ui-accordion-QoJofzqF.cjs"),O=require("./useNestedProp-vPTP0Wem.cjs"),le=require("./PackageVersion-AftniVVo.cjs"),ae=require("./PenAndPaper-j5noaKJZ.cjs"),re=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),ne=["id"],se={key:2,style:"width:100%;background:transparent"},ue=["xmlns","viewBox"],ie=["id"],ce=["stop-color"],de=["stop-color"],ye=["x1","y1","x2","y2","stroke","stroke-width"],ve=["d","stroke","stroke-width"],me=["stroke"],he=["fill"],pe=["stroke"],fe=["fill"],ke=["stroke"],ge=["fill"],be=["stroke"],Ce=["fill"],Ne=["stroke"],xe=["fill"],we=["d","stroke","stroke-width","fill"],_e=["x1","y1","stroke"],Ve=["cx","cy","fill","stroke"],Pe=["fill","stroke"],Be=["y","fill","font-weight"],$e=["y","fill"],Me={key:5,class:"vue-data-ui-watermark"},Ee=["onClick"],Ae={style:{"font-weight":"bold"}},Se={key:8,ref:"source",dir:"auto"},Te=["innerHTML"],Le={__name:"vue-ui-mood-radar",props:{config:{type:Object,default(){return{}}},dataset:{type:Object,default(){return{}}}},setup(I,{expose:F}){const s=I,{vue_ui_mood_radar:D}=r.useConfig(),m=e.computed(()=>!!s.dataset&&Object.keys(s.dataset).length);e.onMounted(()=>{_()});function _(){r.objectIsEmpty(s.dataset)&&r.error({componentName:"VueUiMoodRadar",type:"dataset"})}const h=e.ref(r.createUid()),N=e.ref(null),q=e.ref(null),n=e.ref(null),z=e.ref(null),j=e.ref(0),W=e.ref(0),V=e.ref(0),t=e.computed({get:()=>P(),set:l=>l});function P(){const l=O.useNestedProp({userConfig:s.config,defaultConfig:D});return l.theme?{...O.useNestedProp({userConfig:r.themes.vue_ui_mood_radar[l.theme]||s.config,defaultConfig:l})}:l}e.watch(()=>s.config,l=>{t.value=P(),_(),j.value+=1,W.value+=1,V.value+=1},{deep:!0});const{isPrinting:B,isImaging:$,generatePdf:M,generateImage:E}=L.usePrinter({elementId:h.value,fileName:t.value.style.chart.title.text||"vue-ui-mood-radar"}),G=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),k=e.ref({showTable:t.value.table.show}),d=e.computed(()=>({height:256,width:256})),x=e.computed(()=>r.createPolygonPath({plot:{x:128,y:d.value.height/2},radius:90,sides:5,rotation:11}));function R({centerX:l,centerY:a,apexX:o,apexY:u,proportion:c,key:p,value:J}){return{x:l+(o-l)*c,y:a+(u-a)*c,key:p,value:J}}const U=e.computed(()=>Math.max(...Object.values(s.dataset).map(l=>isNaN(l)?0:l))),v=e.computed(()=>Object.values(s.dataset).reduce((l,a)=>(isNaN(l)?0:l)+(isNaN(a)?0:a),0)),i=e.computed(()=>Object.keys(s.dataset).map((l,a)=>{const o=typeof s.dataset[l]!="number"||isNaN(s.dataset[l])?0:s.dataset[l];return{index:a,key:l,value:o,proportion:o/v.value,color:t.value.style.chart.layout.smileys.colors[l]}}).sort((l,a)=>a.key-l.key)),A=e.computed(()=>m.value?(["1","2","3","4","5"].forEach(l=>{[null,void 0].includes(s.dataset[l])&&r.error({componentName:"VueUiMoodRadar",type:"datasetAttribute",property:l})}),x.value.coordinates.map((l,a)=>{const o=R({centerX:d.value.width/2,centerY:d.value.height/2,apexX:l.x,apexY:l.y,proportion:i.value[a].value/U.value,key:i.value[a].key,value:i.value[a].value});return{...l,plots:o,key:i.value[a].key}})):[]),H=e.computed(()=>({cy:"mood-radar-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":""}));function X(l){l===n.value?n.value=null:n.value=l}const y=e.computed(()=>{const l=i.value.map(o=>({name:o.key,color:o.color})),a=i.value.map(o=>isNaN(o.value)?0:o.value);return{head:l,body:a}});function S(){e.nextTick(()=>{const l=y.value.head.map((u,c)=>[[u.name],[y.value.body[c]],[isNaN(y.value.body[c]/v.value)?"-":y.value.body[c]/v.value*100]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],["val"],["%"]]].concat(l),o=r.createCsvContent(a);r.downloadCsv({csvContent:o,title:t.value.style.chart.title.text||"vue-ui-mood-radar"})})}const g=e.computed(()=>{const l=[' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>',Number(v.value.toFixed(t.value.table.td.roundingValue)).toLocaleString(),"100%"],a=y.value.head.map((c,p)=>[{color:c.color,name:c.name},y.value.body[p].toFixed(t.value.table.td.roundingValue),isNaN(y.value.body[p]/v.value)?"-":(y.value.body[p]/v.value*100).toFixed(t.value.table.td.roundingPercentage)+"%"]),o={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},u=[t.value.table.columnNames.series,t.value.table.columnNames.value,t.value.table.columnNames.percentage];return{head:l,body:a,config:o,colNames:u}});function K(){return i.value}function T(){k.value.showTable=!k.value.showTable}const b=e.ref(!1);function Y(l){b.value=l}const C=e.ref(!1);function w(){C.value=!C.value}return F({getData:K,generatePdf:M,generateCsv:S,generateImage:E,toggleTable:T,toggleAnnotator:w}),(l,a)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-mood-radar ${b.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),ref_key:"moodRadarChart",ref:N,id:`${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`)},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(ae.PenAndPaper,{key:0,parent:N.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:C.value,onClose:w},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),G.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:z,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",se,[e.createVNode(Q._sfc_main,{config:{title:{cy:"mood-radar-title",...t.value.style.chart.title},subtitle:{cy:"mood-radar-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"])])):e.createCommentVNode("",!0),t.value.userOptions.show&&m.value?(e.openBlock(),e.createBlock(L.UserOptions,{key:3,ref_key:"details",ref:q,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(B),isImaging:e.unref($),uid:h.value,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,titles:{...t.value.userOptions.buttonTitles},chartElement:N.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:C.value,onToggleFullscreen:Y,onGeneratePdf:e.unref(M),onGenerateCsv:S,onGenerateImage:e.unref(E),onToggleTable:T,onToggleAnnotator:w},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:o,isFullscreen:u})=>[e.renderSlot(l.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:o,isFullscreen:u})),void 0,!0)]),key:"4"}:void 0,l.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:o,isAnnotator:u})=>[e.renderSlot(l.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:o,isAnnotator:u})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage"])):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(r.XMLNS),viewBox:`0 0 ${d.value.width} ${d.value.height}`,class:e.normalizeClass({"vue-data-ui-fullscreen--on":b.value,"vue-data-ui-fulscreen--off":!b.value}),style:e.normalizeStyle(`overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(le._sfc_main),e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`mood_radar_gradient_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(r.setOpacity)(t.value.style.chart.layout.dataPolygon.color,t.value.style.chart.layout.dataPolygon.opacity)},null,8,ce),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(r.setOpacity)(e.unref(r.shiftHue)(t.value.style.chart.layout.dataPolygon.color,t.value.style.chart.layout.dataPolygon.gradient.intensity/100),t.value.style.chart.layout.dataPolygon.opacity)},null,8,de)],8,ie)]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value.coordinates,o=>(e.openBlock(),e.createElementBlock("line",{x1:d.value.width/2,y1:d.value.height/2,x2:o.x,y2:o.y,stroke:t.value.style.chart.layout.grid.stroke,"stroke-width":t.value.style.chart.layout.grid.strokeWidth},null,8,ye))),256)),e.createElementVNode("path",{d:x.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,ve),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[5],"stroke-width":"1","stroke-linecap":"round",d:"M119 25A1 1 0 00137 25 1 1 0 00119 25M123 26C124 33 132 33 133 26L123 26M123 22A1 1 0 00126 22 1 1 0 00123 22M130 22A1 1 0 00133 22 1 1 0 00130 22"},null,8,me),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[0]||(a[0]=o=>n.value=5),onMouseleave:a[1]||(a[1]=o=>n.value=null),cx:"128",cy:"25",r:"20",fill:n.value===5?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[5],20):"transparent"},null,40,he),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[4],"stroke-width":"1","stroke-linecap":"round",d:"M218 95A1 1 0 00236 95 1 1 0 00218 95M222 97C225 99 229 99 232 97M222 92A1 1 0 00225 92 1 1 0 00222 92M229 92A1 1 0 00232 92 1 1 0 00229 92"},null,8,pe),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[2]||(a[2]=o=>n.value=4),onMouseleave:a[3]||(a[3]=o=>n.value=null),cx:"227",cy:"95.5",r:"20",fill:n.value===4?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[4],20):"transparent"},null,40,fe),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[3],"stroke-width":"1","stroke-linecap":"round",d:"M181 213A1 1 0 00199 213 1 1 0 00181 213M185 210A1 1 0 00188 210 1 1 0 00185 210M192 210A1 1 0 00195 210 1 1 0 00192 210M185 215 195 215"},null,8,ke),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[4]||(a[4]=o=>n.value=3),onMouseleave:a[5]||(a[5]=o=>n.value=null),cx:"190",cy:"213.5",r:"20",fill:n.value===3?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[3],20):"transparent"},null,40,ge),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[2],"stroke-width":"1","stroke-linecap":"round",d:"M56 213A1 1 0 0074 213 1 1 0 0056 213M60 216C63 214 67 214 70 216M60 210A1 1 0 0063 210 1 1 0 0060 210M67 210A1 1 0 0070 210 1 1 0 0067 210"},null,8,be),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[6]||(a[6]=o=>n.value=2),onMouseleave:a[7]||(a[7]=o=>n.value=null),cx:"65",cy:"213.5",r:"20",fill:n.value===2?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[2],20):"transparent"},null,40,Ce),e.createElementVNode("path",{fill:"none",stroke:t.value.style.chart.layout.smileys.colors[1],"stroke-width":"1","stroke-linecap":"round",d:"M20 96A1 1 0 0038 96 1 1 0 0020 96M24 100C25 95 33 95 34 100L24 100M24 93A1 1 0 0027 93 1 1 0 0024 93M31 93A1 1 0 0034 93 1 1 0 0031 93"},null,8,Ne),e.createElementVNode("circle",{class:"vue-ui-mood-radar-trap",onMouseenter:a[8]||(a[8]=o=>n.value=1),onMouseleave:a[9]||(a[9]=o=>n.value=null),cx:"29",cy:"95.5",r:"20",fill:n.value===1?e.unref(r.setOpacity)(t.value.style.chart.layout.smileys.colors[1],20):"transparent"},null,40,xe),e.createElementVNode("path",{d:e.unref(r.makePath)(A.value.map(o=>o.plots)),stroke:t.value.style.chart.layout.dataPolygon.stroke,"stroke-width":t.value.style.chart.layout.dataPolygon.strokeWidth,"stroke-linecap":"round","stroke-linejoin":"round",fill:t.value.style.chart.layout.dataPolygon.gradient.show?`url(#mood_radar_gradient_${h.value})`:e.unref(r.setOpacity)(t.value.style.chart.layout.dataPolygon.color,t.value.style.chart.layout.dataPolygon.opacity)},null,8,we),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(A.value.map(o=>o.plots),(o,u)=>(e.openBlock(),e.createElementBlock("g",{class:"vue-ui-mood-radar-trap",style:e.normalizeStyle(`opacity:${n.value==o.key?"1":"0"}`)},[e.createElementVNode("line",{x1:o.x,y1:o.y,x2:128,y2:128,stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,_e),e.createElementVNode("circle",{cx:o.x,cy:o.y,fill:t.value.style.chart.layout.smileys.colors[o.key],r:"3",stroke:t.value.style.chart.backgroundColor,"stroke-width":.5},null,8,Ve),e.createElementVNode("circle",{cx:128,cy:128,fill:t.value.style.chart.layout.smileys.colors[o.key],r:"3",stroke:t.value.style.chart.backgroundColor,"stroke-width":.5},null,8,Pe),e.createElementVNode("text",{x:128,y:["5",5].includes(o.key)?145:120,fill:t.value.style.chart.layout.dataLabel.color,"font-size":"12","text-anchor":"middle","font-weight":t.value.style.chart.layout.dataLabel.bold?"bold":"normal"},e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.dataLabel.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.dataLabel.prefix,v:o.value,s:t.value.style.chart.layout.dataLabel.suffix,r:t.value.style.chart.layout.dataLabel.roundingValue}),{datapoint:o,seriesIndex:u})),9,Be),e.createElementVNode("text",{x:128,y:["5",5].includes(o.key)?163:102,fill:t.value.style.chart.layout.dataLabel.color,"font-size":"12","text-anchor":"middle"}," ("+e.toDisplayString(e.unref(r.dataLabel)({v:o.value/v.value*100,s:"%",r:t.value.style.chart.layout.dataLabel.roundingPercentage}))+") ",9,$e)],4))),256)),e.renderSlot(l.$slots,"svg",{svg:d.value},void 0,!0)],14,ue)):e.createCommentVNode("",!0),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",Me,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(B)||e.unref($)})),void 0,!0)])):e.createCommentVNode("",!0),m.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(te.default,{key:6,config:{type:"radar",style:{backgroundColor:t.value.style.chart.backgroundColor,radar:{grid:{color:"#CCCCCC"},shapes:{color:"#CCCCCC"}}}}},null,8,["config"])),t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(Z.Legend,{legendSet:i.value,config:H.value,key:`legend_${V.value}`,style:{display:"flex","row-gap":"6px"}},{item:e.withCtx(({legend:o,index:u})=>[e.createElementVNode("div",{onClick:()=>X(o.key),style:{display:"flex","flex-direction":"row",gap:"3px","align-items":"center",margin:"3px 0"}},[o.key==1?(e.openBlock(),e.createBlock(f.default,{key:0,strokeWidth:1,name:"moodSad",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==2?(e.openBlock(),e.createBlock(f.default,{key:1,strokeWidth:1,name:"moodFlat",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==3?(e.openBlock(),e.createBlock(f.default,{key:2,strokeWidth:1,name:"moodNeutral",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==4?(e.openBlock(),e.createBlock(f.default,{key:3,strokeWidth:1,name:"smiley",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),o.key==5?(e.openBlock(),e.createBlock(f.default,{key:4,strokeWidth:1,name:"moodHappy",stroke:t.value.style.chart.layout.smileys.colors[o.key]},null,8,["stroke"])):e.createCommentVNode("",!0),e.createElementVNode("span",Ae,e.toDisplayString(e.unref(r.applyDataLabel)(t.value.style.chart.layout.dataLabel.formatter,o.value,e.unref(r.dataLabel)({p:t.value.style.chart.layout.dataLabel.prefix,v:o.value,s:t.value.style.chart.layout.dataLabel.suffix,r:t.value.style.chart.layout.dataLabel.roundingValue}),{datapoint:o,seriesIndex:u})),1),e.createTextVNode(" ("+e.toDisplayString(e.unref(r.dataLabel)({v:o.proportion*100,s:"%",r:t.value.style.chart.legend.roundingPercentage}))+") ",1)],8,Ee)]),_:1},8,["legendSet","config"])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"legend",{legend:i.value},void 0,!0),l.$slots.source?(e.openBlock(),e.createElementBlock("div",Se,[e.renderSlot(l.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),m.value?(e.openBlock(),e.createBlock(oe.default,{key:9,hideDetails:"",config:{open:k.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.createVNode(ee.DataTable,{colNames:g.value.colNames,head:g.value.head,body:g.value.body,config:g.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[10]||(a[10]=o=>k.value.showTable=!1)},{th:e.withCtx(({th:o})=>[e.createElementVNode("div",{innerHTML:o,style:{display:"flex","align-items":"center"}},null,8,Te)]),td:e.withCtx(({td:o})=>[e.createTextVNode(e.toDisplayString(o.name||o),1)]),_:1},8,["colNames","head","body","config","title"])]),_:1},8,["config"])):e.createCommentVNode("",!0)],14,ne))}},Oe=re._export_sfc(Le,[["__scopeId","data-v-80a971b6"]]);exports.default=Oe;
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-CsQwCVqU.cjs"),pe=require("./useResponsive-BJ7DTGpm.cjs"),Ne=require("./Title-BRqTk-nT.cjs"),he=require("./usePrinter-O2fMMTMe.cjs"),Se=require("./DataTable-H-KTkjfv.cjs"),Ee=require("./Tooltip-DvGSIp31.cjs"),Ve=require("./Legend-G5Zc4QaZ.cjs"),Fe=require("./vue-ui-skeleton-DsRTbz6d.cjs"),Te=require("./vue-ui-accordion-CaktYQoo.cjs"),ye=require("./useNestedProp-DSYpaLxP.cjs"),Pe=require("./PackageVersion-BbQFSVXm.cjs"),De=require("./PenAndPaper-BX8pR5oV.cjs"),ze=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),q=B=>(e.pushScopeId("data-v-038450b3"),B=B(),e.popScopeId(),B),Oe=["id"],Ie=["xmlns","viewBox"],Ae=["id"],Me=q(()=>e.createElementVNode("stop",{offset:"0%","stop-color":"#FFFFFF","stop-opacity":"0"},null,-1)),Re=["offset","stop-color"],qe=["offset","stop-opacity"],Ue=q(()=>e.createElementVNode("stop",{offset:"100%","stop-color":"#FFFFFF","stop-opacity":"0"},null,-1)),Ye=["id"],Xe=["id"],Ge=q(()=>e.createElementVNode("feColorMatrix",{type:"saturate",values:"0"},null,-1)),He=["id"],We=["flood-color"],Je=["d","fill","stroke","stroke-width","filter"],Ke={key:0},Qe=["d","fill"],Ze={key:1},je=["x","y","font-size","font-weight","fill"],et={key:2},tt=["filter"],lt=["text-anchor","x","y","fill","font-size","font-weight"],at=["text-anchor","x","y","fill","font-size","font-weight"],ot=["text-anchor","x","y","fill","font-size","font-weight"],nt=["d","fill","onMouseenter","onClick"],rt={key:5,class:"vue-data-ui-watermark"},st={key:0,class:"vue-ui-nested-donuts-legend-title"},ut=["onClick"],it=["innerHTML"],ct={__name:"vue-ui-nested-donuts",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(B,{expose:me,emit:U}){const k=B,{vue_ui_nested_donuts:be}=r.useConfig(),_=e.computed(()=>!!k.dataset&&k.dataset.length),p=e.ref(r.createUid()),T=e.ref(!1),P=e.ref(""),ge=e.ref(null),Y=e.ref(0),w=e.ref(null),X=e.ref(null),D=e.ref(null),G=e.ref(null),H=e.ref(null),W=e.ref(0),J=e.ref(0),K=e.ref(0),x=e.ref(!1);function ke(l){x.value=l,Y.value+=1}const t=e.computed({get:()=>Q(),set:l=>l});function Q(){const l=ye.useNestedProp({userConfig:k.config,defaultConfig:be});return l.theme?{...ye.useNestedProp({userConfig:r.themes.vue_ui_nested_donuts[l.theme]||k.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>k.config,l=>{t.value=Q(),Z(),W.value+=1,J.value+=1,K.value+=1},{deep:!0});const $=e.ref(null);e.onMounted(()=>{Z()});function Z(){if(r.objectIsEmpty(k.dataset)&&r.error({componentName:"VueUiNestedDonuts",type:"dataset"}),t.value.responsive){const l=pe.throttle(()=>{const{width:s,height:o}=pe.useResponsive({chart:w.value,title:t.value.style.chart.title.text?X.value:null,legend:t.value.style.chart.legend.show?D.value:null,source:G.value,noTitle:H.value});d.value.width=s,d.value.height=o});$.value=new ResizeObserver(l),$.value.observe(w.value.parentNode)}}e.onBeforeUnmount(()=>{$.value&&$.value.disconnect()});const{isPrinting:j,isImaging:ee,generatePdf:te,generateImage:le}=he.usePrinter({elementId:`nested_donuts_${p.value}`,fileName:t.value.style.chart.title.text||"vue-ui-nested-donuts"}),Ce=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),Le=e.computed(()=>r.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}),d=e.ref({height:512,width:512});function we({datapoint:l,index:s}){U("selectDatapoint",{datapoint:l,index:s})}const v=e.ref([]),m=e.computed(()=>(k.dataset.forEach((l,s)=>{[null,void 0].includes(l.name)&&r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"name",index:s}),[null,void 0].includes(l.series)?r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"series",index:s}):l.series.length===0?r.error({componentName:"VueUiNestedDonuts",type:"datasetAttributeEmpty",property:`series at index ${s}`}):l.series.forEach((o,n)=>{[null,void 0].includes(o.name)&&r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"name",index:n,key:"serie"}),[null,void 0].includes(o.values)&&r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"values",index:n,key:"serie"})})}),k.dataset.map((l,s)=>({...l,total:l.series.filter(o=>!v.value.includes(o.id)).map(o=>r.sanitizeArray(o.values).reduce((n,a)=>n+a,0)).reduce((o,n)=>o+n,0),datasetIndex:s,id:`${p.value}_${s}`,series:l.series.map((o,n)=>({name:o.name,arcOf:l.name,arcOfId:`${p.value}_${s}`,id:`${p.value}_${s}_${n}`,seriesIndex:n,datasetIndex:s,color:r.convertColorToHex(o.color)||Le.value[n]||r.palette[n]||r.palette[n%r.palette.length],value:r.sanitizeArray(o.values).reduce((a,u)=>a+u,0),absoluteValues:o.values||[]}))})))),b=e.computed(()=>Math.min(d.value.height,d.value.width)*(t.value.style.chart.layout.donut.strokeWidth/512)),ae=e.computed(()=>[...m.value].map((l,s)=>{const o=l.series.filter(n=>!v.value.includes(n.id)).map(n=>n.value).reduce((n,a)=>n+a,0);return{...l,total:o,series:l.series.filter(n=>!v.value.includes(n.id)).map(n=>({...n,proportion:n.value/o}))}}));function Be(l,s,o){let n=0;for(let a=0;a<l.length;a+=1)o.includes(l[a])&&(n+=1);return n<s}const c=e.ref(ae.value);e.watch(()=>ae.value,l=>c.value=l);const oe=e.ref(null),ne=e.ref(null);function z(l){U("selectLegend",l);const s=m.value.flatMap(i=>i.series).find(i=>i.id===l.id),o=c.value.flatMap(i=>i.series).find(i=>i.id===l.id);let a=o?o.value:0;const u=m.value.find(i=>i.id===s.arcOfId).series.map(i=>i.id),f=Be(u,u.length-1,v.value);if(v.value.includes(l.id)){let i=function(){a>s.value?(cancelAnimationFrame(oe.value),c.value=c.value.map(y=>({...y,series:y.series.map(g=>g.id==l.id?{...g,value:s.value}:g)}))):(a+=s.value*.025,c.value=c.value.map(y=>({...y,series:y.series.map(g=>g.id===l.id?{...g,value:a}:g)})),oe.value=requestAnimationFrame(i))};v.value=v.value.filter(y=>y!==l.id),i()}else if(f){let i=function(){a<.1?(cancelAnimationFrame(ne.value),v.value.push(l.id),c.value=c.value.map((y,g)=>({...y,series:y.series.map(L=>L.id===l.id?{...L,value:0}:L)}))):(a/=1.1,c.value=c.value.map((y,g)=>({...y,series:y.series.map(L=>L.id===l.id?{...L,value:a}:L)})),ne.value=requestAnimationFrame(i))};i()}}const O=e.computed(()=>b.value/m.value.length*t.value.style.chart.layout.donut.spacingRatio),re=e.computed(()=>c.value.map((l,s)=>b.value-s*b.value/m.value.length)),N=e.computed(()=>c.value.map((l,s)=>{const o=s*b.value/m.value.length;return{...l,radius:b.value-o,donut:r.makeDonut({series:l.series},d.value.width/2,d.value.height/2,b.value-o,b.value-o,1.99999,2,1,360,105.25,O.value)}})),se=e.computed(()=>[...m.value].map((l,s)=>{const o=s*b.value/m.value.length;return{sizeRatio:o,donut:r.makeDonut({series:[{value:1}]},d.value.width/2,d.value.height/2,b.value-o,b.value-o,1.99999,2,1,360,105.25,b.value/m.value.length*t.value.style.chart.layout.donut.spacingRatio)[0]}})),ue=e.ref(null),S=e.ref(null),E=e.ref(null),I=e.ref(null);function xe({datapoint:l,_relativeIndex:s,seriesIndex:o}){ue.value=l.arcOfId,S.value=l.id,E.value=o,I.value={datapoint:l,seriesIndex:o,series:c.value,config:t.value};const n=t.value.style.chart.tooltip.customFormat;if(r.isFunction(n)&&r.functionReturnsString(()=>n({seriesIndex:o,datapoint:l,series:c.value,config:t.value})))P.value=n({seriesIndex:o,datapoint:l,series:c.value,config:t.value});else{let a="";if(t.value.style.chart.tooltip.showAllItemsAtIndex&&v.value.length===0){const u=c.value.map(f=>f.series.find(i=>i.seriesIndex===o));u.forEach((f,i)=>{if(!f)return"";a+=`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-3oZdQf6G.cjs"),pe=require("./useResponsive-BJ7DTGpm.cjs"),Ne=require("./Title-BxrsVY3-.cjs"),he=require("./usePrinter-BKzxQK4e.cjs"),Se=require("./DataTable-DeevzR8O.cjs"),Ee=require("./Tooltip-BXc56Oxr.cjs"),Ve=require("./Legend-BksImVUi.cjs"),Fe=require("./vue-ui-skeleton-CI8sxaqr.cjs"),Te=require("./vue-ui-accordion-QoJofzqF.cjs"),ye=require("./useNestedProp-vPTP0Wem.cjs"),Pe=require("./PackageVersion-AftniVVo.cjs"),De=require("./PenAndPaper-j5noaKJZ.cjs"),ze=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),q=B=>(e.pushScopeId("data-v-038450b3"),B=B(),e.popScopeId(),B),Oe=["id"],Ie=["xmlns","viewBox"],Ae=["id"],Me=q(()=>e.createElementVNode("stop",{offset:"0%","stop-color":"#FFFFFF","stop-opacity":"0"},null,-1)),Re=["offset","stop-color"],qe=["offset","stop-opacity"],Ue=q(()=>e.createElementVNode("stop",{offset:"100%","stop-color":"#FFFFFF","stop-opacity":"0"},null,-1)),Ye=["id"],Xe=["id"],Ge=q(()=>e.createElementVNode("feColorMatrix",{type:"saturate",values:"0"},null,-1)),He=["id"],We=["flood-color"],Je=["d","fill","stroke","stroke-width","filter"],Ke={key:0},Qe=["d","fill"],Ze={key:1},je=["x","y","font-size","font-weight","fill"],et={key:2},tt=["filter"],lt=["text-anchor","x","y","fill","font-size","font-weight"],at=["text-anchor","x","y","fill","font-size","font-weight"],ot=["text-anchor","x","y","fill","font-size","font-weight"],nt=["d","fill","onMouseenter","onClick"],rt={key:5,class:"vue-data-ui-watermark"},st={key:0,class:"vue-ui-nested-donuts-legend-title"},ut=["onClick"],it=["innerHTML"],ct={__name:"vue-ui-nested-donuts",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(B,{expose:me,emit:U}){const k=B,{vue_ui_nested_donuts:be}=r.useConfig(),_=e.computed(()=>!!k.dataset&&k.dataset.length),p=e.ref(r.createUid()),T=e.ref(!1),P=e.ref(""),ge=e.ref(null),Y=e.ref(0),w=e.ref(null),X=e.ref(null),D=e.ref(null),G=e.ref(null),H=e.ref(null),W=e.ref(0),J=e.ref(0),K=e.ref(0),x=e.ref(!1);function ke(l){x.value=l,Y.value+=1}const t=e.computed({get:()=>Q(),set:l=>l});function Q(){const l=ye.useNestedProp({userConfig:k.config,defaultConfig:be});return l.theme?{...ye.useNestedProp({userConfig:r.themes.vue_ui_nested_donuts[l.theme]||k.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>k.config,l=>{t.value=Q(),Z(),W.value+=1,J.value+=1,K.value+=1},{deep:!0});const $=e.ref(null);e.onMounted(()=>{Z()});function Z(){if(r.objectIsEmpty(k.dataset)&&r.error({componentName:"VueUiNestedDonuts",type:"dataset"}),t.value.responsive){const l=pe.throttle(()=>{const{width:s,height:o}=pe.useResponsive({chart:w.value,title:t.value.style.chart.title.text?X.value:null,legend:t.value.style.chart.legend.show?D.value:null,source:G.value,noTitle:H.value});d.value.width=s,d.value.height=o});$.value=new ResizeObserver(l),$.value.observe(w.value.parentNode)}}e.onBeforeUnmount(()=>{$.value&&$.value.disconnect()});const{isPrinting:j,isImaging:ee,generatePdf:te,generateImage:le}=he.usePrinter({elementId:`nested_donuts_${p.value}`,fileName:t.value.style.chart.title.text||"vue-ui-nested-donuts"}),Ce=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),Le=e.computed(()=>r.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}),d=e.ref({height:512,width:512});function we({datapoint:l,index:s}){U("selectDatapoint",{datapoint:l,index:s})}const v=e.ref([]),m=e.computed(()=>(k.dataset.forEach((l,s)=>{[null,void 0].includes(l.name)&&r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"name",index:s}),[null,void 0].includes(l.series)?r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"series",index:s}):l.series.length===0?r.error({componentName:"VueUiNestedDonuts",type:"datasetAttributeEmpty",property:`series at index ${s}`}):l.series.forEach((o,n)=>{[null,void 0].includes(o.name)&&r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"name",index:n,key:"serie"}),[null,void 0].includes(o.values)&&r.error({componentName:"VueUiNestedDonuts",type:"datasetSerieAttribute",property:"values",index:n,key:"serie"})})}),k.dataset.map((l,s)=>({...l,total:l.series.filter(o=>!v.value.includes(o.id)).map(o=>r.sanitizeArray(o.values).reduce((n,a)=>n+a,0)).reduce((o,n)=>o+n,0),datasetIndex:s,id:`${p.value}_${s}`,series:l.series.map((o,n)=>({name:o.name,arcOf:l.name,arcOfId:`${p.value}_${s}`,id:`${p.value}_${s}_${n}`,seriesIndex:n,datasetIndex:s,color:r.convertColorToHex(o.color)||Le.value[n]||r.palette[n]||r.palette[n%r.palette.length],value:r.sanitizeArray(o.values).reduce((a,u)=>a+u,0),absoluteValues:o.values||[]}))})))),b=e.computed(()=>Math.min(d.value.height,d.value.width)*(t.value.style.chart.layout.donut.strokeWidth/512)),ae=e.computed(()=>[...m.value].map((l,s)=>{const o=l.series.filter(n=>!v.value.includes(n.id)).map(n=>n.value).reduce((n,a)=>n+a,0);return{...l,total:o,series:l.series.filter(n=>!v.value.includes(n.id)).map(n=>({...n,proportion:n.value/o}))}}));function Be(l,s,o){let n=0;for(let a=0;a<l.length;a+=1)o.includes(l[a])&&(n+=1);return n<s}const c=e.ref(ae.value);e.watch(()=>ae.value,l=>c.value=l);const oe=e.ref(null),ne=e.ref(null);function z(l){U("selectLegend",l);const s=m.value.flatMap(i=>i.series).find(i=>i.id===l.id),o=c.value.flatMap(i=>i.series).find(i=>i.id===l.id);let a=o?o.value:0;const u=m.value.find(i=>i.id===s.arcOfId).series.map(i=>i.id),f=Be(u,u.length-1,v.value);if(v.value.includes(l.id)){let i=function(){a>s.value?(cancelAnimationFrame(oe.value),c.value=c.value.map(y=>({...y,series:y.series.map(g=>g.id==l.id?{...g,value:s.value}:g)}))):(a+=s.value*.025,c.value=c.value.map(y=>({...y,series:y.series.map(g=>g.id===l.id?{...g,value:a}:g)})),oe.value=requestAnimationFrame(i))};v.value=v.value.filter(y=>y!==l.id),i()}else if(f){let i=function(){a<.1?(cancelAnimationFrame(ne.value),v.value.push(l.id),c.value=c.value.map((y,g)=>({...y,series:y.series.map(L=>L.id===l.id?{...L,value:0}:L)}))):(a/=1.1,c.value=c.value.map((y,g)=>({...y,series:y.series.map(L=>L.id===l.id?{...L,value:a}:L)})),ne.value=requestAnimationFrame(i))};i()}}const O=e.computed(()=>b.value/m.value.length*t.value.style.chart.layout.donut.spacingRatio),re=e.computed(()=>c.value.map((l,s)=>b.value-s*b.value/m.value.length)),N=e.computed(()=>c.value.map((l,s)=>{const o=s*b.value/m.value.length;return{...l,radius:b.value-o,donut:r.makeDonut({series:l.series},d.value.width/2,d.value.height/2,b.value-o,b.value-o,1.99999,2,1,360,105.25,O.value)}})),se=e.computed(()=>[...m.value].map((l,s)=>{const o=s*b.value/m.value.length;return{sizeRatio:o,donut:r.makeDonut({series:[{value:1}]},d.value.width/2,d.value.height/2,b.value-o,b.value-o,1.99999,2,1,360,105.25,b.value/m.value.length*t.value.style.chart.layout.donut.spacingRatio)[0]}})),ue=e.ref(null),S=e.ref(null),E=e.ref(null),I=e.ref(null);function xe({datapoint:l,_relativeIndex:s,seriesIndex:o}){ue.value=l.arcOfId,S.value=l.id,E.value=o,I.value={datapoint:l,seriesIndex:o,series:c.value,config:t.value};const n=t.value.style.chart.tooltip.customFormat;if(r.isFunction(n)&&r.functionReturnsString(()=>n({seriesIndex:o,datapoint:l,series:c.value,config:t.value})))P.value=n({seriesIndex:o,datapoint:l,series:c.value,config:t.value});else{let a="";if(t.value.style.chart.tooltip.showAllItemsAtIndex&&v.value.length===0){const u=c.value.map(f=>f.series.find(i=>i.seriesIndex===o));u.forEach((f,i)=>{if(!f)return"";a+=`
2
2
  <div style="display:flex; flex-direction: column; justify-content:flex-start; align-items:flex-start;padding:6px 0; ${i<u.length-1?`border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor}`:""}">
3
3
  <div style="display:flex; flex-direction: row; gap: 3px; justify-content:flex-start; align-items:center;">
4
4
  <svg viewBox="0 0 20 20" height="${t.value.style.chart.tooltip.fontSize}" width="${t.value.style.chart.tooltip.fontSize}">
@@ -1,16 +1,16 @@
1
1
  import { computed as g, ref as i, watch as ze, onMounted as et, onBeforeUnmount as tt, openBlock as s, createElementBlock as n, normalizeClass as P, normalizeStyle as re, createBlock as D, createCommentVNode as v, unref as r, createSlots as lt, withCtx as m, renderSlot as k, normalizeProps as R, guardReactiveProps as E, createVNode as Ve, createElementVNode as p, Fragment as L, renderList as F, toDisplayString as N, createTextVNode as Q, nextTick as at, pushScopeId as ot, popScopeId as st } from "vue";
2
- import { u as ut, c as nt, t as rt, a as it, p as Z, o as dt, e as V, b as ct, I as Me, d as vt, m as Be, f as x, X as ft, s as Ue, K as ht, k as M, n as ie, i as G, x as Re, y as yt, q as pt, r as bt } from "./index-hV0hU1iE.js";
2
+ import { u as ut, c as nt, t as rt, a as it, p as Z, o as dt, e as V, b as ct, I as Me, d as vt, m as Be, f as x, X as ft, s as Ue, K as ht, k as M, n as ie, i as G, x as Re, y as yt, q as pt, r as bt } from "./index-D020Kb3z.js";
3
3
  import { t as gt, u as mt } from "./useResponsive-CoxXLe23.js";
4
- import { _ as kt } from "./Title-DBozX6nP.js";
5
- import { u as wt, U as _t } from "./usePrinter-y3d31M4g.js";
6
- import { D as $t } from "./DataTable-BpVz3DBX.js";
7
- import { _ as Lt } from "./Tooltip-Com_T8vc.js";
8
- import { L as xt } from "./Legend-hnLfwhmm.js";
9
- import Ct from "./vue-ui-skeleton-BY8Jg9a_.js";
10
- import Tt from "./vue-ui-accordion-m-s-7akB.js";
11
- import { u as Ee } from "./useNestedProp-CRAUOmT5.js";
12
- import { _ as Ft } from "./PackageVersion-wqab02xF.js";
13
- import { P as St } from "./PenAndPaper-C_laA5mt.js";
4
+ import { _ as kt } from "./Title-B2orjUIW.js";
5
+ import { u as wt, U as _t } from "./usePrinter-CN0J0NFL.js";
6
+ import { D as $t } from "./DataTable-Ce4R8v-3.js";
7
+ import { _ as Lt } from "./Tooltip-CXjc5vb3.js";
8
+ import { L as xt } from "./Legend-C6q2bLVV.js";
9
+ import Ct from "./vue-ui-skeleton-E1-7diF5.js";
10
+ import Tt from "./vue-ui-accordion-B0fEWLwn.js";
11
+ import { u as Ee } from "./useNestedProp-CZkNAGQh.js";
12
+ import { _ as Ft } from "./PackageVersion-g2UOsY7H.js";
13
+ import { P as St } from "./PenAndPaper-DRFeGfqV.js";
14
14
  import { _ as Nt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
15
15
  const de = (B) => (ot("data-v-038450b3"), B = B(), st(), B), It = ["id"], At = ["xmlns", "viewBox"], Ot = ["id"], Pt = /* @__PURE__ */ de(() => /* @__PURE__ */ p("stop", {
16
16
  offset: "0%",
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-CsQwCVqU.cjs"),Z=require("./useResponsive-BJ7DTGpm.cjs"),ye=require("./Title-BRqTk-nT.cjs"),ee=require("./usePrinter-O2fMMTMe.cjs"),ke=require("./Legend-G5Zc4QaZ.cjs"),be=require("./DataTable-H-KTkjfv.cjs"),Ce=require("./Tooltip-DvGSIp31.cjs"),we=require("./vue-ui-skeleton-DsRTbz6d.cjs"),$e=require("./vue-ui-accordion-CaktYQoo.cjs"),te=require("./useNestedProp-DSYpaLxP.cjs"),xe=require("./PackageVersion-BbQFSVXm.cjs"),Be=require("./PenAndPaper-BX8pR5oV.cjs"),Te=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Pe=["id"],Se=["xmlns","viewBox"],_e=["cx","cy","r","stroke","stroke-width","stroke-dasharray","stroke-dashoffset"],Ne=["cx","cy","r","stroke","stroke-width","stroke-dasharray","stroke-dashoffset"],Oe=["id"],Ve=["stdDeviation"],Ae=["filter"],Ee=["cx","cy","r","stroke-width","stroke-dasharray","stroke-dashoffset"],Fe=["cx","cy","r","stroke-width","stroke-dasharray","stroke-dashoffset","onMouseenter"],Ie={key:1},Le=["onMouseenter"],Me=["x","y","font-size","fill","font-weight"],Re={key:5,class:"vue-data-ui-watermark"},De=["onClick"],ze=["innerHTML"],qe={__name:"vue-ui-onion",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend"],setup(ae,{expose:le,emit:oe}){const p=ae,{vue_ui_onion:re}=u.useConfig(),w=e.computed(()=>!!p.dataset&&p.dataset.length),m=e.ref(u.createUid()),ne=e.ref(null),E=e.ref(0),$=e.ref(!1),P=e.ref(""),d=e.ref([]),y=e.ref(null),F=e.ref(null),I=e.ref(null),L=e.ref(null),M=e.ref(null),R=e.ref(0),D=e.ref(0),z=e.ref(0),t=e.computed({get:()=>q(),set:a=>a});function q(){const a=te.useNestedProp({userConfig:p.config,defaultConfig:re});return a.theme?{...te.useNestedProp({userConfig:u.themes.vue_ui_onion[a.theme]||p.config,defaultConfig:a}),customPalette:u.themePalettes[a.theme]||u.palette}:a}e.watch(()=>p.config,a=>{t.value=q(),H(),R.value+=1,D.value+=1,z.value+=1},{deep:!0});const{isPrinting:Y,isImaging:X,generatePdf:U,generateImage:G}=ee.usePrinter({elementId:`vue-ui-onion_${m.value}`,fileName:t.value.style.chart.title.text||"vue-ui-onion"}),ue=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),se=e.computed(()=>u.convertCustomPalette(t.value.customPalette)),f=e.ref({showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),n=e.ref({height:512,width:512,padding:{top:64,left:64,right:64,bottom:64},minRadius:64}),x=e.ref(null);e.onMounted(()=>{H()});function H(){if(u.objectIsEmpty(p.dataset)&&u.error({componentName:"VueUiOnion",type:"dataset"}),t.value.responsive){const r=Z.throttle(()=>{const{width:l,height:o}=Z.useResponsive({chart:y.value,title:t.value.style.chart.title.text?F.value:null,legend:t.value.style.chart.legend.show?I.value:null,source:L.value,noTitle:M.value});n.value.width=l,n.value.height=o,n.value.padding.top=Math.max(l,o)*.125,n.value.padding.right=Math.max(l,o)*.125,n.value.padding.bottom=Math.max(l,o)*.125,n.value.padding.left=Math.max(l,o)*.125,n.value.minRadius=Math.min(l,o)*.125});x.value=new ResizeObserver(r),x.value.observe(y.value.parentNode)}}e.onBeforeUnmount(()=>{x.value&&x.value.disconnect()});const s=e.computed(()=>({top:n.value.padding.top,left:n.value.padding.left,right:n.value.width-n.value.padding.right,bottom:n.value.height-n.value.padding.bottom,centerX:n.value.width/2,centerY:n.value.height/2,width:n.value.width-n.value.padding.right-n.value.padding.left,height:n.value.height-n.value.padding.bottom-n.value.padding.top,minRadius:n.value.minRadius,maxRadius:Math.min(n.value.width,n.value.height)-n.value.padding.top*2})),i=e.computed(()=>(p.dataset.forEach((a,r)=>{[null,void 0].includes(a.name)&&u.error({componentName:"VueUiOnion",type:"datasetSerieAttribute",property:"name",index:r}),[void 0].includes(a.percentage)&&u.error({componentName:"VueUiOnion",type:"datasetSerieAttribute",property:"percentage",index:r})}),p.dataset.map((a,r)=>{const l=`onion_serie_${r}_${m.value}`;return{...a,percentage:a.percentage||0,targetPercentage:a.percentage||0,color:u.convertColorToHex(a.color)||se.value[r]||u.palette[r],id:l,shape:"circle",opacity:d.value.includes(l)?.5:1,absoluteIndex:r,segregate:()=>W(l),isSegregated:d.value.includes(l)}}))),k=e.ref(i.value),ie=e.computed(()=>t.value.useStartAnimation),ce=e.ref(null),de=e.computed(()=>Math.max(...i.value.map(a=>a.percentage))),S=e.ref(!1);e.watch(()=>i.value,ve,{immediate:!0});function ve(){if(ie.value&&!S.value){let r=function(){a>=de.value?(cancelAnimationFrame(ce.value),k.value=i.value,S.value=!0):(k.value=i.value.map(l=>({...l,percentage:a<l.targetPercentage?a:l.targetPercentage})),a+=1,requestAnimationFrame(r),S.value=!0)};k.value=i.value.map(l=>({...l,percentage:0}));let a=0;r()}else k.value=i.value}const he=e.computed(()=>({cy:"onion-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":""})),pe=e.computed(()=>i.value.filter(a=>!d.value.includes(a.id)).length),g=e.computed(()=>{const a=Math.min(s.value.width,s.value.height)/2/i.value.length;return{gutter:(a>t.value.style.chart.layout.maxThickness?t.value.style.chart.layout.maxThickness:a)*t.value.style.chart.layout.gutter.width,track:(a>t.value.style.chart.layout.maxThickness?t.value.style.chart.layout.maxThickness:a)*t.value.style.chart.layout.track.width}}),v=e.computed(()=>k.value.filter(a=>!d.value.includes(a.id)).map((a,r)=>{const l=(s.value.maxRadius-g.value.track)/pe.value/2*(1+r),o=s.value.centerY-l;return{percentage:a.percentage||0,...a,labelY:o,radius:l,path:fe(l,a.percentage||0)}}));function fe(a,r){const l=2*Math.PI*a,o=l*.75,c=`${o} ${l}`,C=o*(1-r/100);return{bgDashArray:`${o} ${l}`,bgDashOffset:0,dashArray:c,dashOffset:C,fullOffset:0,active:`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-3oZdQf6G.cjs"),Z=require("./useResponsive-BJ7DTGpm.cjs"),ye=require("./Title-BxrsVY3-.cjs"),ee=require("./usePrinter-BKzxQK4e.cjs"),ke=require("./Legend-BksImVUi.cjs"),be=require("./DataTable-DeevzR8O.cjs"),Ce=require("./Tooltip-BXc56Oxr.cjs"),we=require("./vue-ui-skeleton-CI8sxaqr.cjs"),$e=require("./vue-ui-accordion-QoJofzqF.cjs"),te=require("./useNestedProp-vPTP0Wem.cjs"),xe=require("./PackageVersion-AftniVVo.cjs"),Be=require("./PenAndPaper-j5noaKJZ.cjs"),Te=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Pe=["id"],Se=["xmlns","viewBox"],_e=["cx","cy","r","stroke","stroke-width","stroke-dasharray","stroke-dashoffset"],Ne=["cx","cy","r","stroke","stroke-width","stroke-dasharray","stroke-dashoffset"],Oe=["id"],Ve=["stdDeviation"],Ae=["filter"],Ee=["cx","cy","r","stroke-width","stroke-dasharray","stroke-dashoffset"],Fe=["cx","cy","r","stroke-width","stroke-dasharray","stroke-dashoffset","onMouseenter"],Ie={key:1},Le=["onMouseenter"],Me=["x","y","font-size","fill","font-weight"],Re={key:5,class:"vue-data-ui-watermark"},De=["onClick"],ze=["innerHTML"],qe={__name:"vue-ui-onion",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend"],setup(ae,{expose:le,emit:oe}){const p=ae,{vue_ui_onion:re}=u.useConfig(),w=e.computed(()=>!!p.dataset&&p.dataset.length),m=e.ref(u.createUid()),ne=e.ref(null),E=e.ref(0),$=e.ref(!1),P=e.ref(""),d=e.ref([]),y=e.ref(null),F=e.ref(null),I=e.ref(null),L=e.ref(null),M=e.ref(null),R=e.ref(0),D=e.ref(0),z=e.ref(0),t=e.computed({get:()=>q(),set:a=>a});function q(){const a=te.useNestedProp({userConfig:p.config,defaultConfig:re});return a.theme?{...te.useNestedProp({userConfig:u.themes.vue_ui_onion[a.theme]||p.config,defaultConfig:a}),customPalette:u.themePalettes[a.theme]||u.palette}:a}e.watch(()=>p.config,a=>{t.value=q(),H(),R.value+=1,D.value+=1,z.value+=1},{deep:!0});const{isPrinting:Y,isImaging:X,generatePdf:U,generateImage:G}=ee.usePrinter({elementId:`vue-ui-onion_${m.value}`,fileName:t.value.style.chart.title.text||"vue-ui-onion"}),ue=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),se=e.computed(()=>u.convertCustomPalette(t.value.customPalette)),f=e.ref({showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),n=e.ref({height:512,width:512,padding:{top:64,left:64,right:64,bottom:64},minRadius:64}),x=e.ref(null);e.onMounted(()=>{H()});function H(){if(u.objectIsEmpty(p.dataset)&&u.error({componentName:"VueUiOnion",type:"dataset"}),t.value.responsive){const r=Z.throttle(()=>{const{width:l,height:o}=Z.useResponsive({chart:y.value,title:t.value.style.chart.title.text?F.value:null,legend:t.value.style.chart.legend.show?I.value:null,source:L.value,noTitle:M.value});n.value.width=l,n.value.height=o,n.value.padding.top=Math.max(l,o)*.125,n.value.padding.right=Math.max(l,o)*.125,n.value.padding.bottom=Math.max(l,o)*.125,n.value.padding.left=Math.max(l,o)*.125,n.value.minRadius=Math.min(l,o)*.125});x.value=new ResizeObserver(r),x.value.observe(y.value.parentNode)}}e.onBeforeUnmount(()=>{x.value&&x.value.disconnect()});const s=e.computed(()=>({top:n.value.padding.top,left:n.value.padding.left,right:n.value.width-n.value.padding.right,bottom:n.value.height-n.value.padding.bottom,centerX:n.value.width/2,centerY:n.value.height/2,width:n.value.width-n.value.padding.right-n.value.padding.left,height:n.value.height-n.value.padding.bottom-n.value.padding.top,minRadius:n.value.minRadius,maxRadius:Math.min(n.value.width,n.value.height)-n.value.padding.top*2})),i=e.computed(()=>(p.dataset.forEach((a,r)=>{[null,void 0].includes(a.name)&&u.error({componentName:"VueUiOnion",type:"datasetSerieAttribute",property:"name",index:r}),[void 0].includes(a.percentage)&&u.error({componentName:"VueUiOnion",type:"datasetSerieAttribute",property:"percentage",index:r})}),p.dataset.map((a,r)=>{const l=`onion_serie_${r}_${m.value}`;return{...a,percentage:a.percentage||0,targetPercentage:a.percentage||0,color:u.convertColorToHex(a.color)||se.value[r]||u.palette[r],id:l,shape:"circle",opacity:d.value.includes(l)?.5:1,absoluteIndex:r,segregate:()=>W(l),isSegregated:d.value.includes(l)}}))),k=e.ref(i.value),ie=e.computed(()=>t.value.useStartAnimation),ce=e.ref(null),de=e.computed(()=>Math.max(...i.value.map(a=>a.percentage))),S=e.ref(!1);e.watch(()=>i.value,ve,{immediate:!0});function ve(){if(ie.value&&!S.value){let r=function(){a>=de.value?(cancelAnimationFrame(ce.value),k.value=i.value,S.value=!0):(k.value=i.value.map(l=>({...l,percentage:a<l.targetPercentage?a:l.targetPercentage})),a+=1,requestAnimationFrame(r),S.value=!0)};k.value=i.value.map(l=>({...l,percentage:0}));let a=0;r()}else k.value=i.value}const he=e.computed(()=>({cy:"onion-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":""})),pe=e.computed(()=>i.value.filter(a=>!d.value.includes(a.id)).length),g=e.computed(()=>{const a=Math.min(s.value.width,s.value.height)/2/i.value.length;return{gutter:(a>t.value.style.chart.layout.maxThickness?t.value.style.chart.layout.maxThickness:a)*t.value.style.chart.layout.gutter.width,track:(a>t.value.style.chart.layout.maxThickness?t.value.style.chart.layout.maxThickness:a)*t.value.style.chart.layout.track.width}}),v=e.computed(()=>k.value.filter(a=>!d.value.includes(a.id)).map((a,r)=>{const l=(s.value.maxRadius-g.value.track)/pe.value/2*(1+r),o=s.value.centerY-l;return{percentage:a.percentage||0,...a,labelY:o,radius:l,path:fe(l,a.percentage||0)}}));function fe(a,r){const l=2*Math.PI*a,o=l*.75,c=`${o} ${l}`,C=o*(1-r/100);return{bgDashArray:`${o} ${l}`,bgDashOffset:0,dashArray:c,dashOffset:C,fullOffset:0,active:`
2
2
  M ${s.value.centerX},${s.value.centerY-a}
3
3
  A ${a},${a} 0 1 1
4
4
  ${s.value.centerX+a*Math.cos(Math.PI*3/4)},${s.value.centerY+a*Math.sin(Math.PI*3/4)}
@@ -1,16 +1,16 @@
1
1
  import { computed as d, ref as s, watch as ye, onMounted as ze, onBeforeUnmount as Ye, openBlock as n, createElementBlock as u, normalizeClass as V, normalizeStyle as q, createBlock as C, createCommentVNode as g, unref as v, createSlots as Be, withCtx as h, renderSlot as f, normalizeProps as S, guardReactiveProps as M, createVNode as me, Fragment as F, renderList as N, createElementVNode as _, toDisplayString as O, createTextVNode as Ve, nextTick as Xe } from "vue";
2
- import { u as Ge, c as Ue, t as Ee, a as He, p as be, b as We, o as je, e as J, d as qe, X as Je, f as R, i as K, x as ke, q as Ke, r as Qe, y as Ze } from "./index-hV0hU1iE.js";
2
+ import { u as Ge, c as Ue, t as Ee, a as He, p as be, b as We, o as je, e as J, d as qe, X as Je, f as R, i as K, x as ke, q as Ke, r as Qe, y as Ze } from "./index-D020Kb3z.js";
3
3
  import { t as et, u as tt } from "./useResponsive-CoxXLe23.js";
4
- import { _ as at } from "./Title-DBozX6nP.js";
5
- import { u as lt, U as ot } from "./usePrinter-y3d31M4g.js";
6
- import { L as rt } from "./Legend-hnLfwhmm.js";
7
- import { D as nt } from "./DataTable-BpVz3DBX.js";
8
- import { _ as st } from "./Tooltip-Com_T8vc.js";
9
- import ut from "./vue-ui-skeleton-BY8Jg9a_.js";
10
- import it from "./vue-ui-accordion-m-s-7akB.js";
11
- import { u as $e } from "./useNestedProp-CRAUOmT5.js";
12
- import { _ as ct } from "./PackageVersion-wqab02xF.js";
13
- import { P as dt } from "./PenAndPaper-C_laA5mt.js";
4
+ import { _ as at } from "./Title-B2orjUIW.js";
5
+ import { u as lt, U as ot } from "./usePrinter-CN0J0NFL.js";
6
+ import { L as rt } from "./Legend-C6q2bLVV.js";
7
+ import { D as nt } from "./DataTable-Ce4R8v-3.js";
8
+ import { _ as st } from "./Tooltip-CXjc5vb3.js";
9
+ import ut from "./vue-ui-skeleton-E1-7diF5.js";
10
+ import it from "./vue-ui-accordion-B0fEWLwn.js";
11
+ import { u as $e } from "./useNestedProp-CZkNAGQh.js";
12
+ import { _ as ct } from "./PackageVersion-g2UOsY7H.js";
13
+ import { P as dt } from "./PenAndPaper-DRFeGfqV.js";
14
14
  import { _ as vt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
15
15
  const ht = ["id"], ft = ["xmlns", "viewBox"], gt = ["cx", "cy", "r", "stroke", "stroke-width", "stroke-dasharray", "stroke-dashoffset"], pt = ["cx", "cy", "r", "stroke", "stroke-width", "stroke-dasharray", "stroke-dashoffset"], yt = ["id"], mt = ["stdDeviation"], bt = ["filter"], kt = ["cx", "cy", "r", "stroke-width", "stroke-dasharray", "stroke-dashoffset"], $t = ["cx", "cy", "r", "stroke-width", "stroke-dasharray", "stroke-dashoffset", "onMouseenter"], wt = { key: 1 }, Ct = ["onMouseenter"], xt = ["x", "y", "font-size", "fill", "font-weight"], Tt = {
16
16
  key: 5,
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-CsQwCVqU.cjs"),se=require("./useResponsive-BJ7DTGpm.cjs"),xe=require("./Title-BRqTk-nT.cjs"),Ce=require("./Legend-G5Zc4QaZ.cjs"),we=require("./Tooltip-DvGSIp31.cjs"),Be=require("./Shape-CJbFv4bs.cjs"),re=require("./usePrinter-O2fMMTMe.cjs"),$e=require("./DataTable-H-KTkjfv.cjs"),ze=require("./vue-ui-accordion-CaktYQoo.cjs"),Ne=require("./vue-ui-skeleton-DsRTbz6d.cjs"),ue=require("./useNestedProp-DSYpaLxP.cjs"),Se=require("./PackageVersion-BbQFSVXm.cjs"),Ae=require("./PenAndPaper-BX8pR5oV.cjs"),Te=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Pe=["id"],_e=["xmlns","viewBox"],Fe={style:{"pointer-events":"none"}},Me=["x1","x2","y1","y2","stroke","stroke-width"],Ee=["x","y","fill","font-size","font-weight"],Ie=["x1","x2","y1","y2","stroke","stroke-width"],Le=["x","y","fill","font-size","font-weight"],Ve={key:0},Oe=["x","y","font-size","fill"],De=["width","x","y"],qe={style:{width:"100%"}},Re=["x","y","fill","font-weight","font-size","onMouseenter"],Ue=["d","stroke","stroke-width","onMouseenter"],We=["d","onMouseenter"],je={key:5,class:"vue-data-ui-watermark"},He=["onClick"],Ge=["innerHTML"],Ye={__name:"vue-ui-parallel-coordinate-plot",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(ie,{expose:ce,emit:I}){const b=ie,{vue_ui_parallel_coordinate_plot:de}=u.useConfig(),x=e.computed({get(){return!!b.dataset&&b.dataset.length},set(a){return a}}),L=e.ref(0),C=e.ref(null),V=e.ref(null),O=e.ref(null),D=e.ref(null),q=e.ref(null),R=e.ref(0),U=e.ref(0),W=e.ref(0),T=e.ref(u.createUid()),$=e.ref(!1);function ve(a){$.value=a,L.value+=1}const t=e.computed({get:()=>j(),set:a=>a});function j(){const a=ue.useNestedProp({userConfig:b.config,defaultConfig:de});return a.theme?{...ue.useNestedProp({userConfig:u.themes.vue_ui_parallel_coordinate_plot[a.theme]||b.config,defaultConfig:a}),customPalette:u.themePalettes[a.theme]||u.palette}:a}e.watch(()=>b.config,a=>{t.value=j(),H(),R.value+=1,W.value+=1,U.value+=1},{deep:!0});const z=e.ref(null);e.onMounted(()=>{H()});function H(){if(u.objectIsEmpty(b.dataset)?u.error({componentName:"VueUiParallelCoordinatePlot",type:"dataset"}):b.dataset.forEach((a,o)=>{u.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","series"]}).forEach(l=>{x.value=!1,u.error({componentName:"VueUiParallelCoordinatePlot",type:"datasetSerieAttribute",property:l,index:o})})}),t.value.responsive){const a=se.throttle(()=>{const{width:o,height:l}=se.useResponsive({chart:C.value,title:t.value.style.chart.title.text?V.value:null,legend:t.value.style.chart.legend.show?O.value:null,source:D.value,noTitle:q.value});c.value.width=o,c.value.height=l,c.value.plotSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.plots.radius,threshold:2,fallback:2}),c.value.ticksFontSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.yAxis.labels.ticks.fontSize,threshold:10,fallback:10}),c.value.datapointFontSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.yAxis.labels.datapoints.fontSize,threshold:10,fallback:10}),c.value.axisNameFontSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.yAxis.labels.axisNamesFontSize,threshold:12,fallback:12})});z.value=new ResizeObserver(a),z.value.observe(C.value.parentNode)}}e.onBeforeUnmount(()=>{z.value&&z.value.disconnect()});const{isPrinting:G,isImaging:Y,generatePdf:X,generateImage:J}=re.usePrinter({elementId:`pcp_${T.value}`,fileName:t.value.style.chart.title.text||"vue-ui-parallel-coordinate-plot"}),pe=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),c=e.ref({height:t.value.style.chart.height,width:t.value.style.chart.width,plotSize:t.value.style.chart.plots.radius,ticksFontSize:t.value.style.chart.yAxis.labels.ticks.fontSize,datapointFontSize:t.value.style.chart.yAxis.labels.datapoints.fontSize,axisNameFontSize:t.value.style.chart.yAxis.labels.axisNamesFontSize}),d=e.computed(()=>{const{top:a,right:o,bottom:l,left:n}=t.value.style.chart.padding,r=c.value.height,s=c.value.width;return{chartHeight:r,chartWidth:s,height:r-a-l,width:s-n-o,top:a,left:n,right:s-o,bottom:r-l}}),he=e.computed(()=>u.convertCustomPalette(t.value.customPalette)),h=e.ref({dataLabels:{show:t.value.style.chart.yAxis.labels.datapoints.show},showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),f=e.ref([]);function K(a){f.value.includes(a)?f.value=f.value.filter(o=>o!==a):f.value.push(a)}const k=e.computed(()=>b.dataset.map((a,o)=>{const l=u.convertColorToHex(a.color)||he.value[o]||u.palette[o]||u.palette[o%u.palette.length];return{...a,series:a.series.map(n=>({...n,id:u.createUid(),color:l})),seriesIndex:o,color:l,id:u.createUid(),shape:a.shape||"circle"}})),me=e.computed(()=>k.value.map(a=>({...a,opacity:f.value.includes(a.id)?.5:1,segregate:()=>K(a.id),isSegregated:f.value.includes(a.id)}))),ye=e.computed(()=>({cy:"pcp-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":""})),Q=e.computed(()=>Math.max(...k.value.filter(a=>!f.value.includes(a.id)).map(a=>Math.max(...a.series.flatMap(o=>o.values.length))))),y=e.computed(()=>d.value.width/Q.value),P=e.computed(()=>k.value.filter(a=>!f.value.includes(a.id))),m=e.computed(()=>{let a=[];for(let o=0;o<Q.value;o+=1){const l=Math.min(...P.value.flatMap(v=>v.series.map(A=>A.values[o]||0)||0)),n=Math.max(...P.value.flatMap(v=>v.series.map(A=>A.values[o]||0)||0)),r=n===l?l/4:l,s=n===l?n*2:n,i=u.calculateNiceScale(r,s,t.value.style.chart.yAxis.scaleTicks),g=i.ticks.map((v,A)=>{const be=i.min<0?v+Math.abs(i.min):v-Math.abs(i.min),ke=i.min<0?i.max+Math.abs(i.min):i.max-Math.abs(i.min);return{y:d.value.bottom-d.value.height*(be/ke),x:d.value.left+y.value*o+y.value/2,value:v}});a.push({scale:i,ticks:g,name:t.value.style.chart.yAxis.labels.axisNames[o]||`Y-${o+1}`})}return a}),_=e.computed(()=>P.value.map((a,o)=>({...a,series:a.series.map((l,n)=>({...l,datapoints:l.values.map((r,s)=>{const i=m.value[s].scale.min<0?(r||0)+Math.abs(m.value[s].scale.min):(r||0)-Math.abs(m.value[s].scale.min),g=m.value[s].scale.min<0?m.value[s].scale.max+Math.abs(m.value[s].scale.min):m.value[s].scale.max-Math.abs(m.value[s].scale.min);return{name:l.name,seriesName:a.name,axisIndex:s,datapointIndex:n,seriesIndex:o,value:r||0,x:d.value.left+y.value*s+y.value/2,y:d.value.bottom-d.value.height*(i/g),comment:l.comments&&l.comments[s]||""}})}))})).map(a=>({...a,series:a.series.map(o=>{const l=u.createStraightPath(o.datapoints),n=u.createSmoothPath(o.datapoints),r=u.getPathLengthFromCoordinates(t.value.style.chart.lines.smooth?`M ${n}`:`M ${l}`);return{...o,smoothPath:n,straightPath:l,pathLength:r}})})));function Z({value:a,index:o,datapoint:l}){return u.applyDataLabel(t.value.style.chart.yAxis.labels.formatters[o]||null,a,u.dataLabel({p:t.value.style.chart.yAxis.labels.prefixes[o]||"",v:a,s:t.value.style.chart.yAxis.labels.suffixes[o]||"",r:t.value.style.chart.yAxis.labels.roundings[o]||0}),{datapoint:l,seriesIndex:o})}const p=e.ref(null),F=e.ref(null),w=e.ref(!1),M=e.ref("");function N({shape:a,serieName:o,serie:l,relativeIndex:n,seriesIndex:r}){F.value={serie:l,relativeIndex:n,seriesIndex:r,series:k.value,scales:m.value},w.value=!0,p.value=l.id;let s="";const i=t.value.style.chart.tooltip.customFormat;u.isFunction(i)&&u.functionReturnsString(()=>i({serie:l,seriesIndex:l.seriesIndex,series:k.value,config:t.value,scales:m.value}))?M.value=i({serie:l,seriesIndex:l.seriesIndex,series:k.value,config:t.value,scales:m.value}):(s+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${o?o+" - ":""}${l.name}</div>`,m.value.map(g=>g.name).forEach((g,v)=>{s+=`
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),u=require("./index-3oZdQf6G.cjs"),se=require("./useResponsive-BJ7DTGpm.cjs"),xe=require("./Title-BxrsVY3-.cjs"),Ce=require("./Legend-BksImVUi.cjs"),we=require("./Tooltip-BXc56Oxr.cjs"),Be=require("./Shape-Cf2Cj3g6.cjs"),re=require("./usePrinter-BKzxQK4e.cjs"),$e=require("./DataTable-DeevzR8O.cjs"),ze=require("./vue-ui-accordion-QoJofzqF.cjs"),Ne=require("./vue-ui-skeleton-CI8sxaqr.cjs"),ue=require("./useNestedProp-vPTP0Wem.cjs"),Se=require("./PackageVersion-AftniVVo.cjs"),Ae=require("./PenAndPaper-j5noaKJZ.cjs"),Te=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Pe=["id"],_e=["xmlns","viewBox"],Fe={style:{"pointer-events":"none"}},Me=["x1","x2","y1","y2","stroke","stroke-width"],Ee=["x","y","fill","font-size","font-weight"],Ie=["x1","x2","y1","y2","stroke","stroke-width"],Le=["x","y","fill","font-size","font-weight"],Ve={key:0},Oe=["x","y","font-size","fill"],De=["width","x","y"],qe={style:{width:"100%"}},Re=["x","y","fill","font-weight","font-size","onMouseenter"],Ue=["d","stroke","stroke-width","onMouseenter"],We=["d","onMouseenter"],je={key:5,class:"vue-data-ui-watermark"},He=["onClick"],Ge=["innerHTML"],Ye={__name:"vue-ui-parallel-coordinate-plot",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(ie,{expose:ce,emit:I}){const b=ie,{vue_ui_parallel_coordinate_plot:de}=u.useConfig(),x=e.computed({get(){return!!b.dataset&&b.dataset.length},set(a){return a}}),L=e.ref(0),C=e.ref(null),V=e.ref(null),O=e.ref(null),D=e.ref(null),q=e.ref(null),R=e.ref(0),U=e.ref(0),W=e.ref(0),T=e.ref(u.createUid()),$=e.ref(!1);function ve(a){$.value=a,L.value+=1}const t=e.computed({get:()=>j(),set:a=>a});function j(){const a=ue.useNestedProp({userConfig:b.config,defaultConfig:de});return a.theme?{...ue.useNestedProp({userConfig:u.themes.vue_ui_parallel_coordinate_plot[a.theme]||b.config,defaultConfig:a}),customPalette:u.themePalettes[a.theme]||u.palette}:a}e.watch(()=>b.config,a=>{t.value=j(),H(),R.value+=1,W.value+=1,U.value+=1},{deep:!0});const z=e.ref(null);e.onMounted(()=>{H()});function H(){if(u.objectIsEmpty(b.dataset)?u.error({componentName:"VueUiParallelCoordinatePlot",type:"dataset"}):b.dataset.forEach((a,o)=>{u.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","series"]}).forEach(l=>{x.value=!1,u.error({componentName:"VueUiParallelCoordinatePlot",type:"datasetSerieAttribute",property:l,index:o})})}),t.value.responsive){const a=se.throttle(()=>{const{width:o,height:l}=se.useResponsive({chart:C.value,title:t.value.style.chart.title.text?V.value:null,legend:t.value.style.chart.legend.show?O.value:null,source:D.value,noTitle:q.value});c.value.width=o,c.value.height=l,c.value.plotSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.plots.radius,threshold:2,fallback:2}),c.value.ticksFontSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.yAxis.labels.ticks.fontSize,threshold:10,fallback:10}),c.value.datapointFontSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.yAxis.labels.datapoints.fontSize,threshold:10,fallback:10}),c.value.axisNameFontSize=u.translateSize({relator:Math.min(o,l),adjuster:600,source:t.value.style.chart.yAxis.labels.axisNamesFontSize,threshold:12,fallback:12})});z.value=new ResizeObserver(a),z.value.observe(C.value.parentNode)}}e.onBeforeUnmount(()=>{z.value&&z.value.disconnect()});const{isPrinting:G,isImaging:Y,generatePdf:X,generateImage:J}=re.usePrinter({elementId:`pcp_${T.value}`,fileName:t.value.style.chart.title.text||"vue-ui-parallel-coordinate-plot"}),pe=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),c=e.ref({height:t.value.style.chart.height,width:t.value.style.chart.width,plotSize:t.value.style.chart.plots.radius,ticksFontSize:t.value.style.chart.yAxis.labels.ticks.fontSize,datapointFontSize:t.value.style.chart.yAxis.labels.datapoints.fontSize,axisNameFontSize:t.value.style.chart.yAxis.labels.axisNamesFontSize}),d=e.computed(()=>{const{top:a,right:o,bottom:l,left:n}=t.value.style.chart.padding,r=c.value.height,s=c.value.width;return{chartHeight:r,chartWidth:s,height:r-a-l,width:s-n-o,top:a,left:n,right:s-o,bottom:r-l}}),he=e.computed(()=>u.convertCustomPalette(t.value.customPalette)),h=e.ref({dataLabels:{show:t.value.style.chart.yAxis.labels.datapoints.show},showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),f=e.ref([]);function K(a){f.value.includes(a)?f.value=f.value.filter(o=>o!==a):f.value.push(a)}const k=e.computed(()=>b.dataset.map((a,o)=>{const l=u.convertColorToHex(a.color)||he.value[o]||u.palette[o]||u.palette[o%u.palette.length];return{...a,series:a.series.map(n=>({...n,id:u.createUid(),color:l})),seriesIndex:o,color:l,id:u.createUid(),shape:a.shape||"circle"}})),me=e.computed(()=>k.value.map(a=>({...a,opacity:f.value.includes(a.id)?.5:1,segregate:()=>K(a.id),isSegregated:f.value.includes(a.id)}))),ye=e.computed(()=>({cy:"pcp-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":""})),Q=e.computed(()=>Math.max(...k.value.filter(a=>!f.value.includes(a.id)).map(a=>Math.max(...a.series.flatMap(o=>o.values.length))))),y=e.computed(()=>d.value.width/Q.value),P=e.computed(()=>k.value.filter(a=>!f.value.includes(a.id))),m=e.computed(()=>{let a=[];for(let o=0;o<Q.value;o+=1){const l=Math.min(...P.value.flatMap(v=>v.series.map(A=>A.values[o]||0)||0)),n=Math.max(...P.value.flatMap(v=>v.series.map(A=>A.values[o]||0)||0)),r=n===l?l/4:l,s=n===l?n*2:n,i=u.calculateNiceScale(r,s,t.value.style.chart.yAxis.scaleTicks),g=i.ticks.map((v,A)=>{const be=i.min<0?v+Math.abs(i.min):v-Math.abs(i.min),ke=i.min<0?i.max+Math.abs(i.min):i.max-Math.abs(i.min);return{y:d.value.bottom-d.value.height*(be/ke),x:d.value.left+y.value*o+y.value/2,value:v}});a.push({scale:i,ticks:g,name:t.value.style.chart.yAxis.labels.axisNames[o]||`Y-${o+1}`})}return a}),_=e.computed(()=>P.value.map((a,o)=>({...a,series:a.series.map((l,n)=>({...l,datapoints:l.values.map((r,s)=>{const i=m.value[s].scale.min<0?(r||0)+Math.abs(m.value[s].scale.min):(r||0)-Math.abs(m.value[s].scale.min),g=m.value[s].scale.min<0?m.value[s].scale.max+Math.abs(m.value[s].scale.min):m.value[s].scale.max-Math.abs(m.value[s].scale.min);return{name:l.name,seriesName:a.name,axisIndex:s,datapointIndex:n,seriesIndex:o,value:r||0,x:d.value.left+y.value*s+y.value/2,y:d.value.bottom-d.value.height*(i/g),comment:l.comments&&l.comments[s]||""}})}))})).map(a=>({...a,series:a.series.map(o=>{const l=u.createStraightPath(o.datapoints),n=u.createSmoothPath(o.datapoints),r=u.getPathLengthFromCoordinates(t.value.style.chart.lines.smooth?`M ${n}`:`M ${l}`);return{...o,smoothPath:n,straightPath:l,pathLength:r}})})));function Z({value:a,index:o,datapoint:l}){return u.applyDataLabel(t.value.style.chart.yAxis.labels.formatters[o]||null,a,u.dataLabel({p:t.value.style.chart.yAxis.labels.prefixes[o]||"",v:a,s:t.value.style.chart.yAxis.labels.suffixes[o]||"",r:t.value.style.chart.yAxis.labels.roundings[o]||0}),{datapoint:l,seriesIndex:o})}const p=e.ref(null),F=e.ref(null),w=e.ref(!1),M=e.ref("");function N({shape:a,serieName:o,serie:l,relativeIndex:n,seriesIndex:r}){F.value={serie:l,relativeIndex:n,seriesIndex:r,series:k.value,scales:m.value},w.value=!0,p.value=l.id;let s="";const i=t.value.style.chart.tooltip.customFormat;u.isFunction(i)&&u.functionReturnsString(()=>i({serie:l,seriesIndex:l.seriesIndex,series:k.value,config:t.value,scales:m.value}))?M.value=i({serie:l,seriesIndex:l.seriesIndex,series:k.value,config:t.value,scales:m.value}):(s+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${o?o+" - ":""}${l.name}</div>`,m.value.map(g=>g.name).forEach((g,v)=>{s+=`
2
2
  <div class="vue-ui-tooltip-item" style="text-align:left">
3
3
  <span>${g}: </span>
4
4
  <span>
@@ -1,17 +1,17 @@
1
1
  import { computed as g, ref as c, watch as je, onMounted as Ue, onBeforeUnmount as Ve, openBlock as u, createElementBlock as r, normalizeClass as W, normalizeStyle as T, createBlock as M, createCommentVNode as m, unref as z, createSlots as Ge, withCtx as x, renderSlot as b, normalizeProps as E, guardReactiveProps as B, createVNode as $e, Fragment as C, renderList as I, createElementVNode as P, toDisplayString as O, createTextVNode as He } from "vue";
2
- import { u as Xe, c as Z, t as Ye, a as qe, p as G, o as Qe, e as Ae, g as Je, b as Ke, d as Ze, C as et, Q as tt, R as at, S as lt, X as ot, x as _e, i as Te, f as Me, y as st, q as nt, r as ut, E as H } from "./index-hV0hU1iE.js";
2
+ import { u as Xe, c as Z, t as Ye, a as qe, p as G, o as Qe, e as Ae, g as Je, b as Ke, d as Ze, C as et, Q as tt, R as at, S as lt, X as ot, x as _e, i as Te, f as Me, y as st, q as nt, r as ut, E as H } from "./index-D020Kb3z.js";
3
3
  import { t as rt, u as it } from "./useResponsive-CoxXLe23.js";
4
- import { _ as ct } from "./Title-DBozX6nP.js";
5
- import { L as vt } from "./Legend-hnLfwhmm.js";
6
- import { _ as dt } from "./Tooltip-Com_T8vc.js";
7
- import { _ as ht } from "./Shape-QdnXSUyn.js";
8
- import { u as pt, U as mt } from "./usePrinter-y3d31M4g.js";
9
- import { D as yt } from "./DataTable-BpVz3DBX.js";
10
- import ft from "./vue-ui-accordion-m-s-7akB.js";
11
- import gt from "./vue-ui-skeleton-BY8Jg9a_.js";
12
- import { u as ze } from "./useNestedProp-CRAUOmT5.js";
13
- import { _ as bt } from "./PackageVersion-wqab02xF.js";
14
- import { P as xt } from "./PenAndPaper-C_laA5mt.js";
4
+ import { _ as ct } from "./Title-B2orjUIW.js";
5
+ import { L as vt } from "./Legend-C6q2bLVV.js";
6
+ import { _ as dt } from "./Tooltip-CXjc5vb3.js";
7
+ import { _ as ht } from "./Shape-CBu7ails.js";
8
+ import { u as pt, U as mt } from "./usePrinter-CN0J0NFL.js";
9
+ import { D as yt } from "./DataTable-Ce4R8v-3.js";
10
+ import ft from "./vue-ui-accordion-B0fEWLwn.js";
11
+ import gt from "./vue-ui-skeleton-E1-7diF5.js";
12
+ import { u as ze } from "./useNestedProp-CZkNAGQh.js";
13
+ import { _ as bt } from "./PackageVersion-g2UOsY7H.js";
14
+ import { P as xt } from "./PenAndPaper-DRFeGfqV.js";
15
15
  import { _ as kt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
16
16
  const Ct = ["id"], wt = ["xmlns", "viewBox"], $t = { style: { "pointer-events": "none" } }, At = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], _t = ["x", "y", "fill", "font-size", "font-weight"], Tt = ["x1", "x2", "y1", "y2", "stroke", "stroke-width"], Mt = ["x", "y", "fill", "font-size", "font-weight"], zt = { key: 0 }, It = ["x", "y", "font-size", "fill"], Pt = ["width", "x", "y"], Ft = { style: { width: "100%" } }, Nt = ["x", "y", "fill", "font-weight", "font-size", "onMouseenter"], Lt = ["d", "stroke", "stroke-width", "onMouseenter"], St = ["d", "onMouseenter"], Ot = {
17
17
  key: 5,