vue-data-ui 2.5.3 → 2.5.4
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.
- package/dist/{Arrow-6nrhi8WG.cjs → Arrow-CugMOJh3.cjs} +1 -1
- package/dist/{Arrow-XMgbgyuW.js → Arrow-F-M9c-Vx.js} +1 -1
- package/dist/{BaseIcon-DR07PjFD.cjs → BaseIcon-CSbujQk3.cjs} +1 -1
- package/dist/{BaseIcon-DlLGeFMf.js → BaseIcon-DTEOvybQ.js} +1 -1
- package/dist/{DataTable-DpOcjX7A.js → DataTable-B3ZldeJU.js} +2 -2
- package/dist/{DataTable-MIejZXnG.cjs → DataTable-BxaOAPGG.cjs} +1 -1
- package/dist/{Legend-BIU7oBn9.cjs → Legend-BFdRFUZD.cjs} +1 -1
- package/dist/{Legend-DPDHhWVk.js → Legend-DuOUM8rR.js} +2 -2
- package/dist/{PackageVersion-BMaWMyBh.js → PackageVersion-BJurjgIS.js} +1 -1
- package/dist/{PackageVersion-D_q7BR7F.cjs → PackageVersion-DK_OFHd7.cjs} +1 -1
- package/dist/{PenAndPaper-Bsdk39zY.cjs → PenAndPaper-CDwDlhXM.cjs} +1 -1
- package/dist/{PenAndPaper-CcwNT4Bh.js → PenAndPaper-D6oZdwvp.js} +3 -3
- package/dist/{Shape-DWxbSIcY.js → Shape-CHIgmdeu.js} +1 -1
- package/dist/{Shape-Cr_u005f.cjs → Shape-DQlHou1s.cjs} +1 -1
- package/dist/{Slicer-B6s2TqP0.cjs → Slicer-Cu27QOdn.cjs} +1 -1
- package/dist/{Slicer-JRKSbbDy.js → Slicer-HlD3UeXI.js} +2 -2
- package/dist/{Title-NfOh4kUn.cjs → Title-Cnr0E9IA.cjs} +1 -1
- package/dist/{Title-C8VNjPYZ.js → Title-r4pZn0TU.js} +1 -1
- package/dist/{Tooltip-CYuuVkOt.cjs → Tooltip-BK34ShAt.cjs} +1 -1
- package/dist/{Tooltip-DSW91EHV.js → Tooltip-BRDNF1M6.js} +1 -1
- package/dist/{index-CueqoMEP.cjs → index-D4Ci0bak.cjs} +1 -1
- package/dist/{index-DvsVo_hF.js → index-m6iVGCIc.js} +1 -1
- package/dist/style.css +1 -1
- package/dist/{useNestedProp-CJiFKFcq.js → useNestedProp-BO65z1Rt.js} +1 -1
- package/dist/{useNestedProp-DtRFN8OV.cjs → useNestedProp-B_G2vdgc.cjs} +1 -1
- package/dist/{usePrinter-0Gq80Qj7.js → usePrinter-D6-AMOJS.js} +1 -1
- package/dist/{usePrinter-BwJkQJjS.cjs → usePrinter-ZADvMzaH.cjs} +1 -1
- package/dist/{vue-data-ui-DPLDsW1L.js → vue-data-ui-B2BpJIsK.js} +61 -61
- package/dist/{vue-data-ui-Bqnrd-5I.cjs → vue-data-ui-JHXT_i8D.cjs} +1 -1
- package/dist/vue-data-ui.cjs +1 -1
- package/dist/vue-data-ui.js +1 -1
- package/dist/{vue-ui-3d-bar-CsRiqki9.js → vue-ui-3d-bar-BerWlwad.js} +9 -9
- package/dist/{vue-ui-3d-bar-CjPVTkWT.cjs → vue-ui-3d-bar-DhtyZWBp.cjs} +1 -1
- package/dist/{vue-ui-accordion-CDV5rAk1.cjs → vue-ui-accordion-BTL7UkJz.cjs} +1 -1
- package/dist/{vue-ui-accordion-BP7hzx5r.js → vue-ui-accordion-CXNwNRM_.js} +3 -3
- package/dist/{vue-ui-age-pyramid-D9wWRCgY.cjs → vue-ui-age-pyramid-CvDUqBY8.cjs} +1 -1
- package/dist/{vue-ui-age-pyramid-BS6fTuBy.js → vue-ui-age-pyramid-DysOw6YD.js} +10 -10
- package/dist/{vue-ui-annotator-CBPLXTfb.js → vue-ui-annotator-CUxow_1G.js} +1 -1
- package/dist/{vue-ui-annotator-CdNHLgre.cjs → vue-ui-annotator-LNW5c818.cjs} +1 -1
- package/dist/{vue-ui-bullet-DrfP6AvR.js → vue-ui-bullet-BZJJiw9i.js} +8 -8
- package/dist/{vue-ui-bullet-_FvdQ6ZJ.cjs → vue-ui-bullet-mrfn6v28.cjs} +1 -1
- package/dist/{vue-ui-candlestick-D7nvnwpv.js → vue-ui-candlestick-C1RqJrCY.js} +11 -11
- package/dist/{vue-ui-candlestick-C3-6t1CB.cjs → vue-ui-candlestick-DDhpAe9Y.cjs} +1 -1
- package/dist/{vue-ui-carousel-table-Bbmb0jbj.cjs → vue-ui-carousel-table--uUg5El4.cjs} +1 -1
- package/dist/{vue-ui-carousel-table-Kd8b6ReH.js → vue-ui-carousel-table-lMOZQ6R8.js} +4 -4
- package/dist/{vue-ui-chestnut-erK7AKQ8.cjs → vue-ui-chestnut-B3-VR9yB.cjs} +1 -1
- package/dist/{vue-ui-chestnut-DvHYiXM9.js → vue-ui-chestnut-C4fwPxl1.js} +8 -8
- package/dist/vue-ui-circle-pack-CXrc78U1.cjs +1 -0
- package/dist/{vue-ui-circle-pack-B2Jvlo9h.js → vue-ui-circle-pack-r05Ynz-5.js} +13 -13
- package/dist/{vue-ui-cursor-D8e3qBlL.js → vue-ui-cursor-DPWtuCQX.js} +2 -2
- package/dist/{vue-ui-cursor-dwGCbooF.cjs → vue-ui-cursor-r8i851v-.cjs} +1 -1
- package/dist/{vue-ui-dashboard-CuSNUMIB.js → vue-ui-dashboard-CRll2osF.js} +2 -2
- package/dist/{vue-ui-dashboard-CBHjQOhA.cjs → vue-ui-dashboard-Tla8OwYU.cjs} +1 -1
- package/dist/{vue-ui-digits-BFe4Q8jw.js → vue-ui-digits-BUXM9Hw1.js} +2 -2
- package/dist/{vue-ui-digits-DqqF_rBj.cjs → vue-ui-digits-ztSsVVIv.cjs} +1 -1
- package/dist/{vue-ui-donut-a_lWdeZ6.cjs → vue-ui-donut-DrQ7UQkp.cjs} +1 -1
- package/dist/{vue-ui-donut-DG8DoJa6.js → vue-ui-donut-RXhsvvxk.js} +12 -12
- package/dist/{vue-ui-donut-evolution-DY8_uKxG.cjs → vue-ui-donut-evolution-DbjPrIu3.cjs} +1 -1
- package/dist/{vue-ui-donut-evolution-D7SXN5Fv.js → vue-ui-donut-evolution-XOwENyp5.js} +11 -11
- package/dist/{vue-ui-dumbbell-CGRXAsqn.js → vue-ui-dumbbell-Dqs_9bOT.js} +10 -10
- package/dist/{vue-ui-dumbbell-B06Wj7Ut.cjs → vue-ui-dumbbell-xu5_5shw.cjs} +1 -1
- package/dist/{vue-ui-flow-BSGGgzZ6.js → vue-ui-flow-C0pzB2gR.js} +9 -9
- package/dist/{vue-ui-flow-LRaJdFd0.cjs → vue-ui-flow-RtY6EVZx.cjs} +1 -1
- package/dist/{vue-ui-funnel-CsqzwoHx.js → vue-ui-funnel-DVLoFHCF.js} +9 -9
- package/dist/{vue-ui-funnel-B6jYZTw4.cjs → vue-ui-funnel-oQ0cxx-J.cjs} +1 -1
- package/dist/{vue-ui-galaxy-SNQkmKfQ.cjs → vue-ui-galaxy-CXCt3KcT.cjs} +1 -1
- package/dist/{vue-ui-galaxy-pDTnmtWu.js → vue-ui-galaxy-CtQY-Svd.js} +11 -11
- package/dist/{vue-ui-gauge-isjCEm02.js → vue-ui-gauge-CODVyI5P.js} +7 -7
- package/dist/{vue-ui-gauge-DvA86dcf.cjs → vue-ui-gauge-Cf1FL8oo.cjs} +1 -1
- package/dist/{vue-ui-gizmo-Pl9dy5_L.js → vue-ui-gizmo-CBcGGjIi.js} +3 -3
- package/dist/{vue-ui-gizmo-Dp3RUivS.cjs → vue-ui-gizmo-CqwDBebT.cjs} +1 -1
- package/dist/{vue-ui-heatmap-DzgHfDrm.js → vue-ui-heatmap-BUtkysVs.js} +10 -10
- package/dist/{vue-ui-heatmap-CYyq4a10.cjs → vue-ui-heatmap-qEmYPZbd.cjs} +1 -1
- package/dist/{vue-ui-history-plot-LuPWgDTO.js → vue-ui-history-plot-NimiFXGH.js} +11 -11
- package/dist/{vue-ui-history-plot-CJlrimZQ.cjs → vue-ui-history-plot-SNqQH6w1.cjs} +1 -1
- package/dist/{vue-ui-kpi-j6_a8Jwp.cjs → vue-ui-kpi-KcjC8oHU.cjs} +1 -1
- package/dist/{vue-ui-kpi-BYkBJwCG.js → vue-ui-kpi-PpcxcfOy.js} +3 -3
- package/dist/{vue-ui-mini-loader-X7h5Lzni.cjs → vue-ui-mini-loader-BVDaghpN.cjs} +1 -1
- package/dist/{vue-ui-mini-loader-BRMOQFKB.js → vue-ui-mini-loader-Db4Z47H8.js} +2 -2
- package/dist/{vue-ui-molecule-BrCx5WXs.js → vue-ui-molecule-BN9Rk5mt.js} +11 -11
- package/dist/{vue-ui-molecule-Cp80biW7.cjs → vue-ui-molecule-DWK9F255.cjs} +1 -1
- package/dist/{vue-ui-mood-radar-CyC6MKg-.js → vue-ui-mood-radar-COYf5-82.js} +11 -11
- package/dist/{vue-ui-mood-radar-Be9iZpBO.cjs → vue-ui-mood-radar-DUZ0CTv2.cjs} +1 -1
- package/dist/{vue-ui-nested-donuts-BcAydkAj.cjs → vue-ui-nested-donuts-ChC_mKQK.cjs} +1 -1
- package/dist/{vue-ui-nested-donuts-DQAAyLNs.js → vue-ui-nested-donuts-x_mGivS2.js} +11 -11
- package/dist/{vue-ui-onion-CDcgdgR-.cjs → vue-ui-onion-B3AxBNNO.cjs} +1 -1
- package/dist/{vue-ui-onion-BTMe2wPT.js → vue-ui-onion-PN4EpGz4.js} +11 -11
- package/dist/{vue-ui-parallel-coordinate-plot-RibTf77c.cjs → vue-ui-parallel-coordinate-plot-BbybW_NU.cjs} +1 -1
- package/dist/{vue-ui-parallel-coordinate-plot-CzD_iV1N.js → vue-ui-parallel-coordinate-plot-D7fONKY5.js} +12 -12
- package/dist/{vue-ui-quadrant-CtLlN4Np.cjs → vue-ui-quadrant-4OfBh6aQ.cjs} +1 -1
- package/dist/{vue-ui-quadrant-CXBWJktj.js → vue-ui-quadrant-ounvlinz.js} +12 -12
- package/dist/{vue-ui-quick-chart-C0P3z6H-.js → vue-ui-quick-chart-BKKI1C5i.js} +9 -9
- package/dist/{vue-ui-quick-chart-BUEXpGlk.cjs → vue-ui-quick-chart-gGmNTDNG.cjs} +1 -1
- package/dist/{vue-ui-radar-WzgVDLrP.cjs → vue-ui-radar-BK52aCAG.cjs} +1 -1
- package/dist/{vue-ui-radar-BgjzRWIt.js → vue-ui-radar-DQN-x_Z1.js} +12 -12
- package/dist/{vue-ui-rating-4TbMJSET.js → vue-ui-rating-8M-dNrfY.js} +2 -2
- package/dist/{vue-ui-rating-DnzC-oNs.cjs → vue-ui-rating-DWnvRkfx.cjs} +1 -1
- package/dist/{vue-ui-relation-circle-DWv5jADb.js → vue-ui-relation-circle-BsZnvw15.js} +7 -7
- package/dist/{vue-ui-relation-circle-DKn0WLpM.cjs → vue-ui-relation-circle-C86zfgYR.cjs} +1 -1
- package/dist/{vue-ui-rings-CxiF8j0S.js → vue-ui-rings-CRsDNe-o.js} +12 -12
- package/dist/{vue-ui-rings-BWc7qNm4.cjs → vue-ui-rings-SgNgftWB.cjs} +1 -1
- package/dist/{vue-ui-scatter-DoY8JXSp.cjs → vue-ui-scatter-CdJie66o.cjs} +1 -1
- package/dist/{vue-ui-scatter-Bp_j5D1x.js → vue-ui-scatter-Du2PvA0r.js} +12 -12
- package/dist/{vue-ui-screenshot-DHuHPM3D.cjs → vue-ui-screenshot-BbfcpPbP.cjs} +1 -1
- package/dist/{vue-ui-screenshot-DDUob_jJ.js → vue-ui-screenshot-D-6uk7cV.js} +1 -1
- package/dist/{vue-ui-skeleton-C-p4O0A6.cjs → vue-ui-skeleton-8d9YBsC-.cjs} +1 -1
- package/dist/{vue-ui-skeleton-Cv782a-c.js → vue-ui-skeleton-aZahITpG.js} +3 -3
- package/dist/{vue-ui-smiley-DaEq3tD3.cjs → vue-ui-smiley-LcAq4yk7.cjs} +1 -1
- package/dist/{vue-ui-smiley-DdlbB9fP.js → vue-ui-smiley-YmY60NmL.js} +2 -2
- package/dist/{vue-ui-spark-trend-OEX6Tphl.cjs → vue-ui-spark-trend-C2bAfpqt.cjs} +1 -1
- package/dist/{vue-ui-spark-trend-BK0uzlY8.js → vue-ui-spark-trend-CBrcmNWo.js} +5 -5
- package/dist/{vue-ui-sparkbar-Xiw3srTe.js → vue-ui-sparkbar-C3I3hvjY.js} +4 -4
- package/dist/{vue-ui-sparkbar-DfrAT4lX.cjs → vue-ui-sparkbar-u5E5wVAO.cjs} +1 -1
- package/dist/{vue-ui-sparkgauge-NoxywkTb.js → vue-ui-sparkgauge-B5Ll6mpc.js} +4 -4
- package/dist/{vue-ui-sparkgauge-BXZoEnWG.cjs → vue-ui-sparkgauge-C4PmCxtR.cjs} +1 -1
- package/dist/{vue-ui-sparkhistogram-DDRAG1Sk.js → vue-ui-sparkhistogram-BFYpwxZ9.js} +5 -5
- package/dist/{vue-ui-sparkhistogram-gdujA7q3.cjs → vue-ui-sparkhistogram-BP4jEXtC.cjs} +1 -1
- package/dist/{vue-ui-sparkline-CPLa9ydE.js → vue-ui-sparkline-BUypnQdu.js} +4 -4
- package/dist/{vue-ui-sparkline-CZPnHe2F.cjs → vue-ui-sparkline-CANH6-4C.cjs} +1 -1
- package/dist/{vue-ui-sparkstackbar-BjwDlfeR.js → vue-ui-sparkstackbar-D3mseF6j.js} +5 -5
- package/dist/{vue-ui-sparkstackbar-Dj4qQdNG.cjs → vue-ui-sparkstackbar-DaDGaG4d.cjs} +1 -1
- package/dist/{vue-ui-stackbar-CDFhf1x7.js → vue-ui-stackbar-Kc2MRgBp.js} +13 -13
- package/dist/{vue-ui-stackbar-B0cr5TwH.cjs → vue-ui-stackbar-dpca1jL7.cjs} +1 -1
- package/dist/{vue-ui-strip-plot-C-OYdiLq.cjs → vue-ui-strip-plot-DqoZugSf.cjs} +1 -1
- package/dist/{vue-ui-strip-plot-DMQXtQsQ.js → vue-ui-strip-plot-DtIV3O-C.js} +11 -11
- package/dist/{vue-ui-table-DPEebAu7.js → vue-ui-table-C-mRIujK.js} +1 -1
- package/dist/{vue-ui-table-CMkBEYJX.cjs → vue-ui-table-C9Int_9C.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-Cbp0Z-Mr.js → vue-ui-table-heatmap-BDOxml31.js} +4 -4
- package/dist/{vue-ui-table-heatmap-BAjIg7Wc.cjs → vue-ui-table-heatmap-D-6wmiUN.cjs} +1 -1
- package/dist/{vue-ui-table-sparkline-VSnW3NqR.cjs → vue-ui-table-sparkline-Bp6mwwJD.cjs} +1 -1
- package/dist/{vue-ui-table-sparkline-BkYKg9q_.js → vue-ui-table-sparkline-CaV2U4UR.js} +5 -5
- package/dist/{vue-ui-thermometer-DW_6vkbY.js → vue-ui-thermometer-BREunTaH.js} +7 -7
- package/dist/{vue-ui-thermometer-BjEyhB3b.cjs → vue-ui-thermometer-CONg_NWo.cjs} +1 -1
- package/dist/{vue-ui-timer-BZckinO9.js → vue-ui-timer-DnfFciAy.js} +5 -5
- package/dist/{vue-ui-timer-2pxJosNJ.cjs → vue-ui-timer-jgelBK9i.cjs} +1 -1
- package/dist/{vue-ui-tiremarks-B0wz0bS9.js → vue-ui-tiremarks-C4NEY43E.js} +7 -7
- package/dist/{vue-ui-tiremarks-BCFpAfeP.cjs → vue-ui-tiremarks-CQ6nfZIP.cjs} +1 -1
- package/dist/{vue-ui-treemap-DJOuwtpS.cjs → vue-ui-treemap-E4dKMckc.cjs} +1 -1
- package/dist/{vue-ui-treemap-BFIZMHZQ.js → vue-ui-treemap-uSbVj2ef.js} +11 -11
- package/dist/{vue-ui-vertical-bar-x-X6YIW8.cjs → vue-ui-vertical-bar-CQtesFbI.cjs} +1 -1
- package/dist/{vue-ui-vertical-bar-Ct3d1tZD.js → vue-ui-vertical-bar-XdEIKWO8.js} +12 -12
- package/dist/{vue-ui-waffle-CsC3qCL4.cjs → vue-ui-waffle-32Arb3qH.cjs} +1 -1
- package/dist/{vue-ui-waffle-7gSGJyVF.js → vue-ui-waffle-BYxe-miL.js} +12 -12
- package/dist/{vue-ui-wheel-CBkGs_Fe.js → vue-ui-wheel-B-ScVQsN.js} +7 -7
- package/dist/{vue-ui-wheel-CNprPxmK.cjs → vue-ui-wheel-rna7vOjr.cjs} +1 -1
- package/dist/{vue-ui-word-cloud-CxZb54Vp.js → vue-ui-word-cloud-COpBIMWk.js} +10 -10
- package/dist/{vue-ui-word-cloud-YD9RSixa.cjs → vue-ui-word-cloud-Fu1DVDXc.cjs} +1 -1
- package/dist/{vue-ui-xy-CkHeH0pr.cjs → vue-ui-xy-BkynGdon.cjs} +1 -1
- package/dist/{vue-ui-xy-CWuxVm-0.js → vue-ui-xy-Bw5Vrmit.js} +14 -14
- package/dist/{vue-ui-xy-canvas-B16QoQdu.cjs → vue-ui-xy-canvas-22M2lGoy.cjs} +1 -1
- package/dist/{vue-ui-xy-canvas-D_96vDyU.js → vue-ui-xy-canvas-DCrcrdCe.js} +11 -11
- package/package.json +1 -1
- package/dist/vue-ui-circle-pack-BWI4fbSc.cjs +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-CueqoMEP.cjs"),Z=require("./usePrinter-BwJkQJjS.cjs"),me=require("./vue-ui-skeleton-C-p4O0A6.cjs"),be=require("./BaseIcon-DR07PjFD.cjs"),ge=require("./vue-ui-accordion-CDV5rAk1.cjs"),ee=require("./useNestedProp-DtRFN8OV.cjs"),ke=require("./PackageVersion-D_q7BR7F.cjs"),_e=require("./PenAndPaper-Bsdk39zY.cjs"),xe=require("./useUserOptionState-BgepsfED.cjs"),Be=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ee=["id"],Ne={key:1,ref:"noTitle",class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},Se=["xmlns","viewBox"],Ce=["width","height"],we={key:1},ze=["fill","font-weight","font-size","x","y"],Ve=["fill","font-weight","font-size","x","y"],$e=["id"],Te=["stop-color"],Fe=["stop-color"],Le=["id"],De=["stop-color"],Oe=["stop-color"],Pe=["id"],Me=["stop-color"],Ie=["stop-color"],Re=["stop-color"],Xe=["id"],Ae=["stop-color"],je=["stop-color"],Ge=["stop-color"],Ue=["id"],qe=["stop-color"],Ye=["stop-color"],He=["stop-color"],We={key:2},Ke=["x","y","font-size","font-weight","fill"],Je=["x","y","font-size","font-weight","fill"],Qe=["d","stroke"],Ze=["cx","cy","r","fill"],et=["cx","cy","r","fill","stroke","stroke-width","onClick"],tt={key:3},lt=["x","y","font-size","fill","onClick"],at={key:0},ot=["x","y","fill","font-size","font-weight"],nt=["x","y","height","width","fill","rx","onClick"],rt=["x","y","height","width","fill","rx","stroke","stroke-width","onClick"],st={key:4},ut=["x","y","fill","font-size","onClick"],ct=["d","stroke"],it=["fill","cx","cy","r","onClick"],dt={key:5},yt=["x","y","font-size","font-weight","fill"],vt=["x1","x2","y1","y2","stroke","stroke-width"],ht=["y","height","width"],pt={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},ft={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},mt={viewBox:"0 0 20 20",height:"16",width:"16"},bt=["fill"],gt={key:7},kt=["y","height","width"],_t={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},xt={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},Bt={viewBox:"0 0 20 20",height:"16",width:"16"},Et=["fill"],Nt=["cx","cy","fill"],St=["d","stroke"],Ct=["cx","cy","fill"],wt=["d","stroke"],zt=["cx","cy","fill"],Vt=["cx","cy","fill"],$t=["x","y","fill","font-size","font-weight"],Tt=["x","y","fill","font-size","font-weight"],Ft=["x","text-anchor","y","fill","font-size"],Lt=["x","text-anchor","y","fill","font-size"],Dt=["x","text-anchor","y","fill","font-size"],Ot=["x","text-anchor","y","fill","font-size"],Pt=["x","text-anchor","y","fill","font-size"],Mt=["x","y","font-size","fill"],It=["x","y","font-size","fill"],Rt=["x","y","font-size","fill"],Xt={key:4,class:"vue-data-ui-watermark"},At={key:6,ref:"source",dir:"auto"},jt={style:{"padding-top":"36px",position:"relative"}},Gt={class:"vue-ui-data-table"},Ut={key:0},qt=["data-cell"],Yt={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Ht={key:0},Wt={key:1},Kt=["data-cell"],Jt={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Qt={key:0},Zt={key:1},el=["data-cell"],tl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},ll={key:0},al={key:1},ol=["data-cell"],nl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},rl={key:0},sl={key:1},ul=["data-cell"],cl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},il={key:0},dl={key:1},yl=["data-cell"],vl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},hl={key:0},pl={key:1},fl=["data-cell"],ml={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},bl={key:0},gl={key:1},kl=["data-cell"],_l={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},xl=["data-cell"],Bl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},El=["data-cell"],Nl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Sl=["data-cell"],Cl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},wl=["data-cell"],zl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Vl={__name:"vue-ui-chestnut",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectRoot","selectBranch","selectNut"],setup(te,{expose:le,emit:S}){const k=te;e.useCssVars(a=>({a946cfe6:a.tdo}));const{vue_ui_chestnut:ae}=o.useConfig(),z=e.computed(()=>!!k.dataset&&k.dataset.length),h=e.ref(o.createUid()),T=e.ref(null),oe=e.ref(null),I=e.ref(0),t=e.computed({get:()=>A(),set:a=>a}),{userOptionsVisible:F,setUserOptionsVisibility:R,keepUserOptionState:X}=xe.useUserOptionState({config:t.value});function A(){const a=ee.useNestedProp({userConfig:k.config,defaultConfig:ae});return a.theme?{...ee.useNestedProp({userConfig:o.themes.vue_ui_chestnut[a.theme]||k.config,defaultConfig:a}),customPalette:o.themePalettes[a.theme]||o.palette}:a}e.watch(()=>k.config,a=>{t.value=A(),F.value=!t.value.userOptions.showOnChartHover,C.value.showTable=t.value.table.show,K()},{deep:!0});const{isPrinting:j,isImaging:G,generatePdf:U,generateImage:q}=Z.usePrinter({elementId:`vue-ui-chestnut_${h.value}`,fileName:t.value.style.chart.layout.title.text||"vue-ui-chestnut"}),ne=e.computed(()=>t.value.userOptions.show),L=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),C=e.ref({showTable:t.value.table.show}),D=e.ref(null),Y=e.ref(!1),re=e.computed(()=>t.value.table.responsiveBreakpoint),r=e.ref({gap:6,padding:{top:102,left:12,right:12,bottom:96},width:1024,height:0,branchSize:32,branchStart:128}),f=e.computed(()=>({left:r.value.padding.left,top:r.value.padding.top,right:r.value.width-r.value.padding.right,bottom:r.value.height-r.value.padding.bottom,width:r.value.width-(r.value.padding.left+r.value.padding.right),height:r.value.height-(r.value.padding.top+r.value.padding.bottom),seedX:r.value.padding.left+64})),_=e.computed(()=>z.value?k.dataset.flatMap(a=>(a.branches||[]).map(s=>s.value||0)).reduce((a,s)=>a+s,0):0),m=e.computed(()=>(k.dataset.forEach((a,s)=>{o.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","branches"]}).forEach(l=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:l,index:s})}),a.branches&&a.branches.forEach((l,n)=>{o.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","value"]}).forEach(d=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:d,index:`${s} - ${n}`})}),l.breakdown&&l.breakdown.forEach((d,i)=>{o.getMissingDatasetAttributes({datasetObject:d,requiredAttributes:["name","value"]}).forEach(y=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:y,index:`${s} - ${n} - ${i}`})})})})}),k.dataset.map((a,s)=>{const l=(a.branches||[]).map(n=>n.value||0).reduce((n,d)=>n+d,0);return{...a,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],id:a.id||`root_${s}_${h.value}`,type:"root",total:l,rootIndex:s,branches:(a.branches||[]).map((n,d)=>({...n,rootName:a.name,rootIndex:s,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],value:n.value>=0?n.value:0,id:n.id||`branch_${s}_${d}_${h.value}`,proportionToRoot:n.value/l,type:"branch",breakdown:(n.breakdown||[]).map((i,y)=>({table:{rootName:a.name,rootValue:l,rootToTotal:l/_.value,branchName:n.name,branchValue:n.value,branchToTotal:n.value/_.value,branchToRoot:n.value/l,nutName:i.name,nutValue:i.value,nutToTotal:i.value/_.value,nutToRoot:i.value/l,nutToBranch:i.value/n.value},...i,type:"nut",branchName:n.name,rootName:a.name,branchTotal:n.value>=0?n.value:0,proportionToBranch:i.value/n.value,proportionToRoot:i.value/l,proportionToTree:i.value/_.value,rootIndex:s,id:i.id||`nut_${s}_${d}_${y}_${h.value}`,color:o.convertColorToHex(i.color)||L.value[y]||o.palette[y]||o.palette[y%o.palette.length],value:i.value>=0?i.value:0}))}))}})));function se(){return m.value}const ue=e.computed(()=>m.value.flatMap(a=>a.branches).length),ce=e.computed(()=>Math.max(...m.value.map(a=>a.branches.map(s=>s.value).reduce((s,l)=>s+l,0)))),ie=e.computed(()=>Math.max(...m.value.flatMap(a=>a.branches.map(s=>s.value)))),H=e.computed(()=>256+r.value.padding.left),B=e.computed(()=>m.value.sort((a,s)=>s.total-a.total).map((a,s)=>{const l=f.value.height/m.value.length/2,n=a.total/ce.value*(l>64?64:l);return{...a,x:f.value.seedX,y:f.value.top+f.value.height/m.value.length*(s+1)-(f.value.height/m.value.length/2+r.value.gap/2),r:n<r.value.branchSize/2?r.value.branchSize/2:n}})),de=e.computed(()=>t.value.style.chart.layout.branches.widthRatio<=0?.1:t.value.style.chart.layout.branches.widthRatio>1.8?1.8:t.value.style.chart.layout.branches.widthRatio),ye=e.computed(()=>B.value.flatMap(a=>a.branches)),E=e.computed(()=>ye.value.sort((a,s)=>s.value-a.value).map((a,s)=>({...a,y1:s*r.value.branchSize+f.value.top+s*r.value.gap,y2:s*r.value.branchSize+r.value.branchSize,x1:H.value,x2:384*a.value/ie.value*de.value+H.value})));function O(a){const s=B.value.find(l=>l.rootIndex===a.rootIndex);return{x:s.x,y:s.y,r:s.r}}const u=e.ref(null),x=e.ref(null),v=e.ref(null),b=e.ref(null);function p(){u.value=null,v.value=null,b.value=null}function g(a){return b.value?b.value===null?!0:a.type==="root"?a.id===b.value.id:a.rootIndex===b.value.rootIndex:u.value===null&&v.value===null?!0:a.type==="nut"?u.value.id===a.id:a.type==="branch"?v.value.id===a.id:a.type==="root"?v.value&&v.value.rootIndex===a.rootIndex||u.value&&u.value.rootIndex===a.rootIndex:!1}function ve(a){p(),e.nextTick(()=>{u.value=a,v.value=a,x.value=o.makeDonut({series:a.breakdown,base:1},a.x2+24+t.value.style.chart.layout.nuts.offsetX,a.y1+r.value.branchSize/2,80,80),S("selectNut",a.breakdown)})}function N(){u.value=null,x.value=null,S("selectNut",null)}function P(a){v.value&&v.value.id===a.id?(v.value=null,p(),S("selectBranch",null)):(p(),v.value=a,S("selectBranch",a))}function W(a){b.value&&b.value.id===a.id?(p(),S("selectRoot",null)):(p(),b.value=a,S("selectRoot",a))}function he(){return f.value.bottom-(u.value.y1+180)<0?0:f.value.bottom}function w(a){return a.proportion*100>t.value.style.chart.layout.nuts.selected.labels.dataLabels.hideUnderValue}function pe(){const a=new ResizeObserver(s=>{s.forEach(l=>{Y.value=l.contentRect.width<re.value})});D.value&&a.observe(D.value)}e.onMounted(()=>{K()});function K(){o.objectIsEmpty(k.dataset)&&o.error({componentName:"VueUiChestnut",type:"dataset"});const a=ue.value*(r.value.branchSize+r.value.gap)+r.value.padding.top+r.value.padding.bottom;r.value.height=a,pe()}const c=e.computed(()=>{const a=[t.value.table.th.translations.rootName,t.value.table.th.translations.rootValue,t.value.table.th.translations.rootToTotal,t.value.table.th.translations.branchName,t.value.table.th.translations.branchValue,t.value.table.th.translations.branchToRoot,t.value.table.th.translations.branchToTotal,t.value.table.th.translations.nutName,t.value.table.th.translations.nutValue,t.value.table.th.translations.nutToBranch,t.value.table.th.translations.nutToRoot,t.value.table.th.translations.nutToTotal],s=m.value.flatMap((l,n)=>l.branches.flatMap((d,i)=>d.breakdown.flatMap((y,Tl)=>y.table)));return{head:a,body:s}});function J(){e.nextTick(()=>{const a=[[t.value.style.chart.layout.title.text],[t.value.style.chart.layout.title.subtitle.text],[""],["Grand total",_.value],[""]],s=c.value.head,l=c.value.body.map((i,y)=>[c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootName,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootValue,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootToTotal,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchName,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchValue,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToRoot,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToTotal,i.nutName,i.nutValue,i.nutToBranch,i.nutToRoot,i.nutToTotal]),n=a.concat([s]).concat(l),d=o.createCsvContent(n);o.downloadCsv({csvContent:d,title:t.value.style.chart.layout.title.text||"vue-ui-chestnut"})})}const V=e.ref(!1);function fe(a){V.value=a,I.value+=1}function Q(){C.value.showTable=!C.value.showTable}const $=e.ref(!1);function M(){$.value=!$.value}return le({getData:se,generatePdf:U,generateCsv:J,generateImage:q,toggleTable:Q,toggleAnnotator:M}),(a,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-chestnut ${V.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"chestnutChart",ref:T,id:`vue-ui-chestnut_${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:s[2]||(s[2]=()=>e.unref(R)(!0)),onMouseleave:s[3]||(s[3]=()=>e.unref(R)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(_e.PenAndPaper,{key:0,parent:T.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:$.value,onClose:M},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),ne.value?(e.openBlock(),e.createElementBlock("div",Ne,null,512)):e.createCommentVNode("",!0),t.value.userOptions.show&&z.value&&(e.unref(X)||e.unref(F))?(e.openBlock(),e.createBlock(Z.UserOptions,{ref_key:"details",ref:oe,key:`user_options_${I.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(G),isPrinting:e.unref(j),uid:h.value,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:t.value.userOptions.buttons.csv,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:V.value,titles:{...t.value.userOptions.buttonTitles},chartElement:T.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:$.value,onToggleFullscreen:fe,onGeneratePdf:e.unref(U),onGenerateCsv:J,onGenerateImage:e.unref(q),onToggleTable:Q,onToggleAnnotator:M,style:e.normalizeStyle({visibility:e.unref(X)?e.unref(F)?"visible":"hidden":"visible"})},e.createSlots({_:2},[a.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,a.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,a.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,a.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,a.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:n})=>[e.renderSlot(a.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:n})),void 0,!0)]),key:"4"}:void 0,a.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:l,isAnnotator:n})=>[e.renderSlot(a.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:l,isAnnotator:n})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),r.value.height>0&&z.value?(e.openBlock(),e.createElementBlock("svg",{key:3,xmlns:e.unref(o.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":V.value,"vue-data-ui-fulscreen--off":!V.value}),viewBox:`0 0 ${r.value.width<=0?10:r.value.width} ${r.value.height<=0?10:r.value.height}`,style:e.normalizeStyle(`overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(ke._sfc_main),a.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:r.value.width<=0?10:r.value.width,height:r.value.height<=0?10:r.value.height,style:{pointerEvents:"none"}},[e.renderSlot(a.$slots,"chart-background",{},void 0,!0)],8,Ce)):e.createCommentVNode("",!0),u.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("g",we,[t.value.style.chart.layout.title.text?(e.openBlock(),e.createElementBlock("text",{key:0,"text-anchor":"middle",fill:t.value.style.chart.layout.title.color,"font-weight":t.value.style.chart.layout.title.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.fontSize,x:r.value.width/2,y:12+t.value.style.chart.layout.title.fontSize+t.value.style.chart.layout.title.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.text),9,ze)):e.createCommentVNode("",!0),t.value.style.chart.layout.title.subtitle.text?(e.openBlock(),e.createElementBlock("text",{key:1,"text-anchor":"middle",fill:t.value.style.chart.layout.title.subtitle.color,"font-weight":t.value.style.chart.layout.title.subtitle.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.subtitle.fontSize,x:r.value.width/2,y:48+t.value.style.chart.layout.title.subtitle.fontSize+t.value.style.chart.layout.title.subtitle.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.subtitle.text),9,Ve)):e.createCommentVNode("",!0)])),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(l,n)=>(e.openBlock(),e.createElementBlock("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`root_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.05),100-t.value.style.chart.layout.roots.gradientIntensity)},null,8,Te),e.createElementVNode("stop",{offset:"100%","stop-color":l.color},null,8,Fe)],8,$e))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,l=>(e.openBlock(),e.createElementBlock("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`branch_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":l.color},null,8,De),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.02),100-t.value.style.chart.layout.branches.gradientIntensity)},null,8,Oe)],8,Le))),256)),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nutpick_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Me),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.selected.gradientIntensity)},null,8,Ie),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Re)],8,Pe),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ae),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.gradientIntensity)},null,8,je),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ge)],8,Xe),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_underlayer_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,100)},null,8,qe),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,60)},null,8,Ye),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,0)},null,8,He)],8,Ue)]),t.value.style.chart.layout.grandTotal.show?(e.openBlock(),e.createElementBlock("g",We,[e.createElementVNode("text",{x:f.value.seedX,y:32+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(t.value.style.chart.layout.grandTotal.text),9,Ke),e.createElementVNode("text",{x:f.value.seedX,y:38+t.value.style.chart.layout.grandTotal.fontSize+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.layout.grandTotal.formatter,_.value,e.unref(o.dataLabel)({p:t.value.style.chart.layout.grandTotal.prefix,v:_.value,s:t.value.style.chart.layout.grandTotal.suffix,r:t.value.style.chart.layout.grandTotal.roundingValue}))),9,Je)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,l=>(e.openBlock(),e.createElementBlock("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value.branchSize,(n,d)=>(e.openBlock(),e.createElementBlock("path",{d:`M
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),o=require("./index-D4Ci0bak.cjs"),Z=require("./usePrinter-ZADvMzaH.cjs"),me=require("./vue-ui-skeleton-8d9YBsC-.cjs"),be=require("./BaseIcon-CSbujQk3.cjs"),ge=require("./vue-ui-accordion-BTL7UkJz.cjs"),ee=require("./useNestedProp-B_G2vdgc.cjs"),ke=require("./PackageVersion-DK_OFHd7.cjs"),_e=require("./PenAndPaper-CDwDlhXM.cjs"),xe=require("./useUserOptionState-BgepsfED.cjs"),Be=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ee=["id"],Ne={key:1,ref:"noTitle",class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},Se=["xmlns","viewBox"],Ce=["width","height"],we={key:1},ze=["fill","font-weight","font-size","x","y"],Ve=["fill","font-weight","font-size","x","y"],$e=["id"],Te=["stop-color"],Fe=["stop-color"],Le=["id"],De=["stop-color"],Oe=["stop-color"],Pe=["id"],Me=["stop-color"],Ie=["stop-color"],Re=["stop-color"],Xe=["id"],Ae=["stop-color"],je=["stop-color"],Ge=["stop-color"],Ue=["id"],qe=["stop-color"],Ye=["stop-color"],He=["stop-color"],We={key:2},Ke=["x","y","font-size","font-weight","fill"],Je=["x","y","font-size","font-weight","fill"],Qe=["d","stroke"],Ze=["cx","cy","r","fill"],et=["cx","cy","r","fill","stroke","stroke-width","onClick"],tt={key:3},lt=["x","y","font-size","fill","onClick"],at={key:0},ot=["x","y","fill","font-size","font-weight"],nt=["x","y","height","width","fill","rx","onClick"],rt=["x","y","height","width","fill","rx","stroke","stroke-width","onClick"],st={key:4},ut=["x","y","fill","font-size","onClick"],ct=["d","stroke"],it=["fill","cx","cy","r","onClick"],dt={key:5},yt=["x","y","font-size","font-weight","fill"],vt=["x1","x2","y1","y2","stroke","stroke-width"],ht=["y","height","width"],pt={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},ft={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},mt={viewBox:"0 0 20 20",height:"16",width:"16"},bt=["fill"],gt={key:7},kt=["y","height","width"],_t={style:{width:"100%",height:"100%",display:"flex","align-items":"center","justify-content":"center","flex-direction":"column"}},xt={style:{display:"flex","align-items":"center","justify-content":"center",gap:"12px","flex-wrap":"wrap","flex-direction":"row"}},Bt={viewBox:"0 0 20 20",height:"16",width:"16"},Et=["fill"],Nt=["cx","cy","fill"],St=["d","stroke"],Ct=["cx","cy","fill"],wt=["d","stroke"],zt=["cx","cy","fill"],Vt=["cx","cy","fill"],$t=["x","y","fill","font-size","font-weight"],Tt=["x","y","fill","font-size","font-weight"],Ft=["x","text-anchor","y","fill","font-size"],Lt=["x","text-anchor","y","fill","font-size"],Dt=["x","text-anchor","y","fill","font-size"],Ot=["x","text-anchor","y","fill","font-size"],Pt=["x","text-anchor","y","fill","font-size"],Mt=["x","y","font-size","fill"],It=["x","y","font-size","fill"],Rt=["x","y","font-size","fill"],Xt={key:4,class:"vue-data-ui-watermark"},At={key:6,ref:"source",dir:"auto"},jt={style:{"padding-top":"36px",position:"relative"}},Gt={class:"vue-ui-data-table"},Ut={key:0},qt=["data-cell"],Yt={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Ht={key:0},Wt={key:1},Kt=["data-cell"],Jt={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Qt={key:0},Zt={key:1},el=["data-cell"],tl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},ll={key:0},al={key:1},ol=["data-cell"],nl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},rl={key:0},sl={key:1},ul=["data-cell"],cl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},il={key:0},dl={key:1},yl=["data-cell"],vl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},hl={key:0},pl={key:1},fl=["data-cell"],ml={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},bl={key:0},gl={key:1},kl=["data-cell"],_l={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},xl=["data-cell"],Bl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},El=["data-cell"],Nl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Sl=["data-cell"],Cl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},wl=["data-cell"],zl={style:{display:"flex","align-items":"center",gap:"5px","justify-content":"flex-end",width:"100%","padding-right":"3px"}},Vl={__name:"vue-ui-chestnut",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectRoot","selectBranch","selectNut"],setup(te,{expose:le,emit:S}){const k=te;e.useCssVars(a=>({a946cfe6:a.tdo}));const{vue_ui_chestnut:ae}=o.useConfig(),z=e.computed(()=>!!k.dataset&&k.dataset.length),h=e.ref(o.createUid()),T=e.ref(null),oe=e.ref(null),I=e.ref(0),t=e.computed({get:()=>A(),set:a=>a}),{userOptionsVisible:F,setUserOptionsVisibility:R,keepUserOptionState:X}=xe.useUserOptionState({config:t.value});function A(){const a=ee.useNestedProp({userConfig:k.config,defaultConfig:ae});return a.theme?{...ee.useNestedProp({userConfig:o.themes.vue_ui_chestnut[a.theme]||k.config,defaultConfig:a}),customPalette:o.themePalettes[a.theme]||o.palette}:a}e.watch(()=>k.config,a=>{t.value=A(),F.value=!t.value.userOptions.showOnChartHover,C.value.showTable=t.value.table.show,K()},{deep:!0});const{isPrinting:j,isImaging:G,generatePdf:U,generateImage:q}=Z.usePrinter({elementId:`vue-ui-chestnut_${h.value}`,fileName:t.value.style.chart.layout.title.text||"vue-ui-chestnut"}),ne=e.computed(()=>t.value.userOptions.show),L=e.computed(()=>o.convertCustomPalette(t.value.customPalette)),C=e.ref({showTable:t.value.table.show}),D=e.ref(null),Y=e.ref(!1),re=e.computed(()=>t.value.table.responsiveBreakpoint),r=e.ref({gap:6,padding:{top:102,left:12,right:12,bottom:96},width:1024,height:0,branchSize:32,branchStart:128}),f=e.computed(()=>({left:r.value.padding.left,top:r.value.padding.top,right:r.value.width-r.value.padding.right,bottom:r.value.height-r.value.padding.bottom,width:r.value.width-(r.value.padding.left+r.value.padding.right),height:r.value.height-(r.value.padding.top+r.value.padding.bottom),seedX:r.value.padding.left+64})),_=e.computed(()=>z.value?k.dataset.flatMap(a=>(a.branches||[]).map(s=>s.value||0)).reduce((a,s)=>a+s,0):0),m=e.computed(()=>(k.dataset.forEach((a,s)=>{o.getMissingDatasetAttributes({datasetObject:a,requiredAttributes:["name","branches"]}).forEach(l=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:l,index:s})}),a.branches&&a.branches.forEach((l,n)=>{o.getMissingDatasetAttributes({datasetObject:l,requiredAttributes:["name","value"]}).forEach(d=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:d,index:`${s} - ${n}`})}),l.breakdown&&l.breakdown.forEach((d,i)=>{o.getMissingDatasetAttributes({datasetObject:d,requiredAttributes:["name","value"]}).forEach(y=>{o.error({componentName:"VueUiChestnut",type:"datasetSerieAttribute",property:y,index:`${s} - ${n} - ${i}`})})})})}),k.dataset.map((a,s)=>{const l=(a.branches||[]).map(n=>n.value||0).reduce((n,d)=>n+d,0);return{...a,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],id:a.id||`root_${s}_${h.value}`,type:"root",total:l,rootIndex:s,branches:(a.branches||[]).map((n,d)=>({...n,rootName:a.name,rootIndex:s,color:o.convertColorToHex(a.color)||L.value[s]||o.palette[s]||o.palette[s%o.palette.length],value:n.value>=0?n.value:0,id:n.id||`branch_${s}_${d}_${h.value}`,proportionToRoot:n.value/l,type:"branch",breakdown:(n.breakdown||[]).map((i,y)=>({table:{rootName:a.name,rootValue:l,rootToTotal:l/_.value,branchName:n.name,branchValue:n.value,branchToTotal:n.value/_.value,branchToRoot:n.value/l,nutName:i.name,nutValue:i.value,nutToTotal:i.value/_.value,nutToRoot:i.value/l,nutToBranch:i.value/n.value},...i,type:"nut",branchName:n.name,rootName:a.name,branchTotal:n.value>=0?n.value:0,proportionToBranch:i.value/n.value,proportionToRoot:i.value/l,proportionToTree:i.value/_.value,rootIndex:s,id:i.id||`nut_${s}_${d}_${y}_${h.value}`,color:o.convertColorToHex(i.color)||L.value[y]||o.palette[y]||o.palette[y%o.palette.length],value:i.value>=0?i.value:0}))}))}})));function se(){return m.value}const ue=e.computed(()=>m.value.flatMap(a=>a.branches).length),ce=e.computed(()=>Math.max(...m.value.map(a=>a.branches.map(s=>s.value).reduce((s,l)=>s+l,0)))),ie=e.computed(()=>Math.max(...m.value.flatMap(a=>a.branches.map(s=>s.value)))),H=e.computed(()=>256+r.value.padding.left),B=e.computed(()=>m.value.sort((a,s)=>s.total-a.total).map((a,s)=>{const l=f.value.height/m.value.length/2,n=a.total/ce.value*(l>64?64:l);return{...a,x:f.value.seedX,y:f.value.top+f.value.height/m.value.length*(s+1)-(f.value.height/m.value.length/2+r.value.gap/2),r:n<r.value.branchSize/2?r.value.branchSize/2:n}})),de=e.computed(()=>t.value.style.chart.layout.branches.widthRatio<=0?.1:t.value.style.chart.layout.branches.widthRatio>1.8?1.8:t.value.style.chart.layout.branches.widthRatio),ye=e.computed(()=>B.value.flatMap(a=>a.branches)),E=e.computed(()=>ye.value.sort((a,s)=>s.value-a.value).map((a,s)=>({...a,y1:s*r.value.branchSize+f.value.top+s*r.value.gap,y2:s*r.value.branchSize+r.value.branchSize,x1:H.value,x2:384*a.value/ie.value*de.value+H.value})));function O(a){const s=B.value.find(l=>l.rootIndex===a.rootIndex);return{x:s.x,y:s.y,r:s.r}}const u=e.ref(null),x=e.ref(null),v=e.ref(null),b=e.ref(null);function p(){u.value=null,v.value=null,b.value=null}function g(a){return b.value?b.value===null?!0:a.type==="root"?a.id===b.value.id:a.rootIndex===b.value.rootIndex:u.value===null&&v.value===null?!0:a.type==="nut"?u.value.id===a.id:a.type==="branch"?v.value.id===a.id:a.type==="root"?v.value&&v.value.rootIndex===a.rootIndex||u.value&&u.value.rootIndex===a.rootIndex:!1}function ve(a){p(),e.nextTick(()=>{u.value=a,v.value=a,x.value=o.makeDonut({series:a.breakdown,base:1},a.x2+24+t.value.style.chart.layout.nuts.offsetX,a.y1+r.value.branchSize/2,80,80),S("selectNut",a.breakdown)})}function N(){u.value=null,x.value=null,S("selectNut",null)}function P(a){v.value&&v.value.id===a.id?(v.value=null,p(),S("selectBranch",null)):(p(),v.value=a,S("selectBranch",a))}function W(a){b.value&&b.value.id===a.id?(p(),S("selectRoot",null)):(p(),b.value=a,S("selectRoot",a))}function he(){return f.value.bottom-(u.value.y1+180)<0?0:f.value.bottom}function w(a){return a.proportion*100>t.value.style.chart.layout.nuts.selected.labels.dataLabels.hideUnderValue}function pe(){const a=new ResizeObserver(s=>{s.forEach(l=>{Y.value=l.contentRect.width<re.value})});D.value&&a.observe(D.value)}e.onMounted(()=>{K()});function K(){o.objectIsEmpty(k.dataset)&&o.error({componentName:"VueUiChestnut",type:"dataset"});const a=ue.value*(r.value.branchSize+r.value.gap)+r.value.padding.top+r.value.padding.bottom;r.value.height=a,pe()}const c=e.computed(()=>{const a=[t.value.table.th.translations.rootName,t.value.table.th.translations.rootValue,t.value.table.th.translations.rootToTotal,t.value.table.th.translations.branchName,t.value.table.th.translations.branchValue,t.value.table.th.translations.branchToRoot,t.value.table.th.translations.branchToTotal,t.value.table.th.translations.nutName,t.value.table.th.translations.nutValue,t.value.table.th.translations.nutToBranch,t.value.table.th.translations.nutToRoot,t.value.table.th.translations.nutToTotal],s=m.value.flatMap((l,n)=>l.branches.flatMap((d,i)=>d.breakdown.flatMap((y,Tl)=>y.table)));return{head:a,body:s}});function J(){e.nextTick(()=>{const a=[[t.value.style.chart.layout.title.text],[t.value.style.chart.layout.title.subtitle.text],[""],["Grand total",_.value],[""]],s=c.value.head,l=c.value.body.map((i,y)=>[c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootName,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootValue,c.value.body[y-1]&&c.value.body[y-1].rootName===i.rootName?"":i.rootToTotal,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchName,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchValue,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToRoot,c.value.body[y-1]&&c.value.body[y-1].branchName===i.branchName?"":i.branchToTotal,i.nutName,i.nutValue,i.nutToBranch,i.nutToRoot,i.nutToTotal]),n=a.concat([s]).concat(l),d=o.createCsvContent(n);o.downloadCsv({csvContent:d,title:t.value.style.chart.layout.title.text||"vue-ui-chestnut"})})}const V=e.ref(!1);function fe(a){V.value=a,I.value+=1}function Q(){C.value.showTable=!C.value.showTable}const $=e.ref(!1);function M(){$.value=!$.value}return le({getData:se,generatePdf:U,generateCsv:J,generateImage:q,toggleTable:Q,toggleAnnotator:M}),(a,s)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(`vue-ui-chestnut ${V.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"chestnutChart",ref:T,id:`vue-ui-chestnut_${h.value}`,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:s[2]||(s[2]=()=>e.unref(R)(!0)),onMouseleave:s[3]||(s[3]=()=>e.unref(R)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(_e.PenAndPaper,{key:0,parent:T.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:$.value,onClose:M},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),ne.value?(e.openBlock(),e.createElementBlock("div",Ne,null,512)):e.createCommentVNode("",!0),t.value.userOptions.show&&z.value&&(e.unref(X)||e.unref(F))?(e.openBlock(),e.createBlock(Z.UserOptions,{ref_key:"details",ref:oe,key:`user_options_${I.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isImaging:e.unref(G),isPrinting:e.unref(j),uid:h.value,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:t.value.userOptions.buttons.csv,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:V.value,titles:{...t.value.userOptions.buttonTitles},chartElement:T.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:$.value,onToggleFullscreen:fe,onGeneratePdf:e.unref(U),onGenerateCsv:J,onGenerateImage:e.unref(q),onToggleTable:Q,onToggleAnnotator:M,style:e.normalizeStyle({visibility:e.unref(X)?e.unref(F)?"visible":"hidden":"visible"})},e.createSlots({_:2},[a.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,a.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,a.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,a.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(a.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,a.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:n})=>[e.renderSlot(a.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:n})),void 0,!0)]),key:"4"}:void 0,a.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:l,isAnnotator:n})=>[e.renderSlot(a.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:l,isAnnotator:n})),void 0,!0)]),key:"5"}:void 0]),1032,["backgroundColor","color","isImaging","isPrinting","uid","hasPdf","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),r.value.height>0&&z.value?(e.openBlock(),e.createElementBlock("svg",{key:3,xmlns:e.unref(o.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":V.value,"vue-data-ui-fulscreen--off":!V.value}),viewBox:`0 0 ${r.value.width<=0?10:r.value.width} ${r.value.height<=0?10:r.value.height}`,style:e.normalizeStyle(`overflow:visible;background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(ke._sfc_main),a.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:0,y:0,width:r.value.width<=0?10:r.value.width,height:r.value.height<=0?10:r.value.height,style:{pointerEvents:"none"}},[e.renderSlot(a.$slots,"chart-background",{},void 0,!0)],8,Ce)):e.createCommentVNode("",!0),u.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("g",we,[t.value.style.chart.layout.title.text?(e.openBlock(),e.createElementBlock("text",{key:0,"text-anchor":"middle",fill:t.value.style.chart.layout.title.color,"font-weight":t.value.style.chart.layout.title.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.fontSize,x:r.value.width/2,y:12+t.value.style.chart.layout.title.fontSize+t.value.style.chart.layout.title.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.text),9,ze)):e.createCommentVNode("",!0),t.value.style.chart.layout.title.subtitle.text?(e.openBlock(),e.createElementBlock("text",{key:1,"text-anchor":"middle",fill:t.value.style.chart.layout.title.subtitle.color,"font-weight":t.value.style.chart.layout.title.subtitle.bold?"bold":"normal","font-size":t.value.style.chart.layout.title.subtitle.fontSize,x:r.value.width/2,y:48+t.value.style.chart.layout.title.subtitle.fontSize+t.value.style.chart.layout.title.subtitle.offsetY,onClick:p},e.toDisplayString(t.value.style.chart.layout.title.subtitle.text),9,Ve)):e.createCommentVNode("",!0)])),e.createElementVNode("defs",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(l,n)=>(e.openBlock(),e.createElementBlock("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`root_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.05),100-t.value.style.chart.layout.roots.gradientIntensity)},null,8,Te),e.createElementVNode("stop",{offset:"100%","stop-color":l.color},null,8,Fe)],8,$e))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,l=>(e.openBlock(),e.createElementBlock("linearGradient",{x1:"0%",y1:"0%",x2:"100%",y2:"0%",id:`branch_gradient_${h.value}_${l.rootIndex}`},[e.createElementVNode("stop",{offset:"0%","stop-color":l.color},null,8,De),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(e.unref(o.shiftHue)(l.color,.02),100-t.value.style.chart.layout.branches.gradientIntensity)},null,8,Oe)],8,Le))),256)),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nutpick_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Me),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.selected.gradientIntensity)},null,8,Ie),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Re)],8,Pe),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ae),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)("#FFFFFF",t.value.style.chart.layout.nuts.gradientIntensity)},null,8,je),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)("#FFFFFF",0)},null,8,Ge)],8,Xe),e.createElementVNode("radialGradient",{cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%",id:`nut_underlayer_${h.value}`},[e.createElementVNode("stop",{offset:"0%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,100)},null,8,qe),e.createElementVNode("stop",{offset:"80%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,60)},null,8,Ye),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(o.setOpacity)(t.value.style.chart.backgroundColor,0)},null,8,He)],8,Ue)]),t.value.style.chart.layout.grandTotal.show?(e.openBlock(),e.createElementBlock("g",We,[e.createElementVNode("text",{x:f.value.seedX,y:32+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(t.value.style.chart.layout.grandTotal.text),9,Ke),e.createElementVNode("text",{x:f.value.seedX,y:38+t.value.style.chart.layout.grandTotal.fontSize+t.value.style.chart.layout.grandTotal.offsetY,"font-size":t.value.style.chart.layout.grandTotal.fontSize,"font-weight":t.value.style.chart.layout.grandTotal.bold?"bold":"normal",fill:t.value.style.chart.layout.grandTotal.color,"text-anchor":"middle",onClick:p},e.toDisplayString(e.unref(o.applyDataLabel)(t.value.style.chart.layout.grandTotal.formatter,_.value,e.unref(o.dataLabel)({p:t.value.style.chart.layout.grandTotal.prefix,v:_.value,s:t.value.style.chart.layout.grandTotal.suffix,r:t.value.style.chart.layout.grandTotal.roundingValue}))),9,Je)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,l=>(e.openBlock(),e.createElementBlock("g",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value.branchSize,(n,d)=>(e.openBlock(),e.createElementBlock("path",{d:`M
|
|
2
2
|
${l.x1},${l.y1+d}
|
|
3
3
|
C${l.x1-20},${l.y1+d}
|
|
4
4
|
${l.x1-80},${l.y1+d}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { useCssVars as Ye, computed as m, ref as T, watch as qe, onMounted as He, openBlock as a, createElementBlock as o, normalizeClass as k, normalizeStyle as h, unref as n, createBlock as K, createCommentVNode as f, createSlots as We, withCtx as X, renderSlot as F, normalizeProps as ue, guardReactiveProps as ne, createVNode as $e, toDisplayString as c, createElementVNode as s, Fragment as g, renderList as _, createTextVNode as J, withKeys as Ke, nextTick as Ce } from "vue";
|
|
2
|
-
import { u as Je, c as Qe, t as Ze, a as et, p as P, b as tt, g as re, e as Q, d as ie, o as lt, X as at, s as S, w as Te, i as G, f as z, G as ze, m as Ne, j as ot, k as V, n as H, q as st, r as ut } from "./index-
|
|
3
|
-
import { u as nt, U as rt } from "./usePrinter-
|
|
4
|
-
import it from "./vue-ui-skeleton-
|
|
5
|
-
import ct from "./BaseIcon-
|
|
6
|
-
import dt from "./vue-ui-accordion-
|
|
7
|
-
import { u as Se } from "./useNestedProp-
|
|
8
|
-
import { _ as vt } from "./PackageVersion-
|
|
9
|
-
import { P as yt } from "./PenAndPaper-
|
|
2
|
+
import { u as Je, c as Qe, t as Ze, a as et, p as P, b as tt, g as re, e as Q, d as ie, o as lt, X as at, s as S, w as Te, i as G, f as z, G as ze, m as Ne, j as ot, k as V, n as H, q as st, r as ut } from "./index-m6iVGCIc.js";
|
|
3
|
+
import { u as nt, U as rt } from "./usePrinter-D6-AMOJS.js";
|
|
4
|
+
import it from "./vue-ui-skeleton-aZahITpG.js";
|
|
5
|
+
import ct from "./BaseIcon-DTEOvybQ.js";
|
|
6
|
+
import dt from "./vue-ui-accordion-CXNwNRM_.js";
|
|
7
|
+
import { u as Se } from "./useNestedProp-BO65z1Rt.js";
|
|
8
|
+
import { _ as vt } from "./PackageVersion-BJurjgIS.js";
|
|
9
|
+
import { P as yt } from "./PenAndPaper-D6oZdwvp.js";
|
|
10
10
|
import { u as ht } from "./useUserOptionState-BIvW1Kz7.js";
|
|
11
11
|
import { _ as ft } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
12
12
|
const bt = ["id"], pt = {
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),r=require("./index-D4Ci0bak.cjs"),de=require("./useNestedProp-B_G2vdgc.cjs"),ve=require("./usePrinter-ZADvMzaH.cjs"),Se=require("./Title-Cnr0E9IA.cjs"),Te=require("./PenAndPaper-CDwDlhXM.cjs"),Ve=require("./useUserOptionState-BgepsfED.cjs"),Oe=require("./PackageVersion-DK_OFHd7.cjs"),Fe=require("./vue-ui-accordion-BTL7UkJz.cjs"),Ie=require("./DataTable-BxaOAPGG.cjs"),Me=require("./vue-ui-skeleton-8d9YBsC-.cjs"),_e=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Ae=["id"],De=["xmlns","viewBox"],Le=["x","y","width","height"],qe=["id"],Ue=["stop-color"],Re=["stop-color"],He=["stop-color"],Ge={key:0},We=["x","y","width","height","stroke","stroke-width","fill","rx","onMouseenter"],Xe=["x","y","width","height","stroke","stroke-width","fill","rx"],Ye=["opacity","x","y","font-size","fill","font-weight"],je=["opacity","x","y","font-size","fill","font-weight"],Ze=["d","fill"],Je=["cx","cy","r","opacity","stroke","fill"],Ke={key:0,style:{pointerEvents:"none"}},Qe={key:1},et=["opacity","x","y","font-size","fill","font-weight"],tt=["opacity","x","y","font-size","fill","font-weight"],lt={key:6,class:"vue-data-ui-watermark"},ot=["innerHTML"],at={__name:"vue-ui-circle-pack",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},setup(he,{expose:me}){const y=he;e.useCssVars(l=>({"49c9a662":C.value,"0c7b2888":_.value}));const{vue_ui_circle_pack:pe}=r.useConfig(),P=e.computed(()=>!!y.dataset&&y.dataset.length),k=e.ref(r.createUid()),O=e.ref(null),fe=e.ref(null),ye=e.ref(null),H=e.ref(0),G=e.ref(0),W=e.ref(0),ge=e.ref(null),t=e.computed({get:()=>j(),set:l=>l}),{userOptionsVisible:F,setUserOptionsVisibility:X,keepUserOptionState:Y}=Ve.useUserOptionState({config:t.value});function j(){const l=de.useNestedProp({userConfig:y.config,defaultConfig:pe});return l.theme?{...de.useNestedProp({userConfig:r.themes.vue_ui_circle_pack[l.theme]||y.config,defaultConfig:l}),customPalette:r.themePalettes[l.theme]||r.palette}:l}e.watch(()=>y.config,l=>{t.value=j(),F.value=!t.value.userOptions.showOnChartHover,I(),H.value+=1,G.value+=1,b.value.showTable=t.value.table.show},{deep:!0});const{isPrinting:Z,isImaging:J,generatePdf:K,generateImage:Q}=ve.usePrinter({elementId:`vue-ui-circle-pack_${k.value}`,fileName:t.value.style.chart.title.text||"vue-ui-circle-pack"}),ke=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),b=e.ref({showTable:t.value.table.show});async function I(){r.objectIsEmpty(y.dataset)&&r.error({componentName:"VueUiCirclePack",type:"dataset"}),await xe()}e.onMounted(I),e.watch(()=>y.dataset,async l=>{await I()},{deep:!0});const ee=e.computed(()=>r.convertCustomPalette(t.value.customPalette));function te(l,a){return Math.hypot(a.x-l.x,a.y-l.y)}function le(l,a){return a.some(o=>te(l,o)<l.radius+o.radius)}function be(l,a,o,u){const c=a*2;for(let p of l)for(let f=0;f<360;f+=30){let $=f*Math.PI/180,i=p.x+c*Math.cos($),n=p.y+c*Math.sin($),h={x:i,y:n,radius:a};if(i-a>=0&&i+a<=o&&n-a>=0&&n+a<=u&&!le(h,l))return{x:i,y:n}}return null}function Ce(l,a,o,u,c=0,p=0){const f=Math.max(...l.map(h=>h.value)),i=l.map((h,d)=>({...h,radius:h.value/f*u,index:d})).map((h,d)=>({...h,index:d})).toSorted((h,d)=>d.radius-h.radius);let n=[];n.push({...i[0],x:a/2+c,y:o/2+p});for(let h of i.slice(1)){let{radius:d,...ne}=h,D=be(n,d,a,o);if(D)n.push({...ne,x:D.x,y:D.y,radius:d});else{let L=null,se=1/0;for(let T of n)for(let q=0;q<360;q+=15){let ue=q*Math.PI/180,U=T.x+(d+T.radius)*Math.cos(ue),R=T.y+(d+T.radius)*Math.sin(ue),V={...ne,x:U,y:R,radius:d};if(U-d>=0&&U+d<=a&&R-d>=0&&R+d<=o&&!le(V,n)){let ie=n.reduce((Ee,ce)=>Ee+(te(V,ce)<V.radius+ce.radius?1:0),0);ie<se&&(se=ie,L=V)}}L&&n.push(L)}}return n}const M=e.computed(()=>y.dataset.map((l,a)=>{const o=r.convertColorToHex(l.color)||ee.value[a]||r.themePalettes[t.value.theme||"default"][a%r.themePalettes[t.value.theme||"default"].length]||r.palette[a]||r.palette[a%r.palette.length];return{...l,id:r.createUid(),color:o}}).filter(l=>![null,void 0,1/0,-1/0].includes(l.value))),m=e.ref([]);async function xe(){m.value=Ce(M.value,1e4,1e4,32)}const oe=e.computed(()=>({width:100,height:100})),v=e.computed(()=>{const l=m.value.reduce((i,n)=>n.x-n.radius<i.x-i.radius?n:i,m.value[0]),a=m.value.reduce((i,n)=>n.y-n.radius<i.y-i.radius?n:i,m.value[0]),o=m.value.reduce((i,n)=>n.x+n.radius>i.x+i.radius?n:i,m.value[0]),u=m.value.reduce((i,n)=>n.y+n.radius>i.y+i.radius?n:i,m.value[0]),c=(l==null?void 0:l.x)||0,p=(o==null?void 0:o.x)||oe.value.width,f=(a==null?void 0:a.y)||0,$=(u==null?void 0:u.y)||oe.value.height;return{maxX:p,minX:c,width:Math.abs(p-c)+(l?l.radius:0)+(o?o.radius:0)+t.value.style.chart.circles.strokeWidth*4,height:Math.abs($-f)+(a?a.radius:0)+(u?u.radius:0)+t.value.style.chart.circles.strokeWidth*4,x:l?(l==null?void 0:l.x)-(l==null?void 0:l.radius)-t.value.style.chart.circles.strokeWidth*2:0,y:a?(a==null?void 0:a.y)-(a==null?void 0:a.radius)-t.value.style.chart.circles.strokeWidth*2:0}}),we=e.computed(()=>m.value.map(l=>{if(l.breakdown)return r.makeDonut({series:l.breakdown.map((a,o)=>({...a,color:r.convertColorToHex(a.color)||ee.value[o]||r.palette[o]||r.palette[o%r.palette.length]}))},l.x,l.y,l.radius,l.radius,1.99999,2,1,360,105.25,l.radius/2)})),s=e.ref(null);function Be(l){t.value.style.chart.circles.zoom.show&&(s.value=l)}const C=e.computed(()=>s.value?s.value.radius:0),_=e.computed(()=>s.value?s.value.radius>v.value.width/6*t.value.style.chart.circles.zoom.zoomRatio?s.value.radius:v.value.width/6*t.value.style.chart.circles.zoom.zoomRatio:0),g=e.ref(0),ze=e.computed(()=>({pointerEvents:"none",opacity:g.value,filter:`drop-shadow(0px 0px 6px ${r.darkenHexColor(s.value.color,t.value.style.chart.circles.zoom.shadowForce)})`})),x=e.ref(C.value);e.watchEffect(()=>{x.value=C.value,g.value=0;let l=null;function a(o){l||(l=o);const u=(o-l)/t.value.style.chart.circles.zoom.animationFrameMs;u<1?(x.value=C.value+(_.value-C.value)*u,g.value=0+t.value.style.chart.circles.zoom.opacity*u,requestAnimationFrame(a)):(x.value=_.value,g.value=t.value.style.chart.circles.zoom.opacity)}requestAnimationFrame(a)});const w=e.computed(()=>({name:t.value.style.chart.circles.zoom.label.name.fontSize*v.value.width/300,value:t.value.style.chart.circles.zoom.label.value.fontSize*v.value.width/300}));function B(l){return r.applyDataLabel(t.value.style.chart.circles.labels.value.formatter,l.value,r.dataLabel({p:t.value.style.chart.circles.labels.value.prefix,v:l.value,s:t.value.style.chart.circles.labels.value.suffix,r:t.value.style.chart.circles.labels.value.rounding}))}function $e(){return r.applyDataLabel(t.value.style.chart.circles.zoom.label.value.formatter,s.value.value,r.dataLabel({p:t.value.style.chart.circles.zoom.label.value.prefix,v:s.value.value,s:t.value.style.chart.circles.zoom.label.value.suffix,r:t.value.style.chart.circles.zoom.label.rounding}))}const z=e.ref(!1);function Pe(l){z.value=l,W.value+=1}const N=e.ref(!1);function A(){N.value=!N.value}const E=e.computed(()=>{const l=M.value.map(o=>({name:o.name,value:o.value,color:o.color})).toSorted((o,u)=>u.value-o.value),a=l.map(o=>o.value);return{head:l,body:a}});function ae(){e.nextTick(()=>{const l=E.value.head.map((u,c)=>[[u.name],[E.value.body[c]]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],[t.value.table.columnNames.value]]].concat(l),o=r.createCsvContent(a);r.downloadCsv({csvContent:o,title:t.value.style.chart.title.text||"vue-ui-circle-pack"})})}const S=e.computed(()=>{const l=[t.value.table.columnNames.datapoint,t.value.table.columnNames.value],a=E.value.head.map((c,p)=>{const f=r.dataLabel({p:t.value.style.chart.circles.labels.value.prefix,v:E.value.body[p],s:t.value.style.chart.circles.labels.value.suffix,r:t.value.style.chart.circles.labels.value.rounding});return[{color:c.color,name:c.name},f]}),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};return{colNames:[t.value.table.columnNames.datapoint,t.value.table.columnNames.value],head:l,body:a,config:o}});function re(){b.value.showTable=!b.value.showTable}function Ne(){return M.value}return me({getData:Ne,generateCsv:ae,generatePdf:K,generateImage:Q,toggleTable:re,toggleAnnotator:A}),(l,a)=>(e.openBlock(),e.createElementBlock("div",{id:`vue-ui-circle-pack_${k.value}`,class:e.normalizeClass(`vue-ui-circle-pack ${z.value?"vue-data-ui-wrapper-fullscreen":""}`),ref_key:"circlePackChart",ref:O,style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; text-align:center;background:${t.value.style.chart.backgroundColor}`),onMouseenter:a[2]||(a[2]=()=>e.unref(X)(!0)),onMouseleave:a[3]||(a[3]=()=>e.unref(X)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(Te.PenAndPaper,{key:0,parent:O.value,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:N.value,onClose:A},null,8,["parent","backgroundColor","color","active"])):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"userConfig",{},void 0,!0),ke.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:ye,class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},null,512)):e.createCommentVNode("",!0),t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:2,ref_key:"chartTitle",ref:fe,style:"width:100%;background:transparent;padding-bottom:12px"},[(e.openBlock(),e.createBlock(Se._sfc_main,{key:`title_${H.value}`,config:{title:{cy:"donut-div-title",...t.value.style.chart.title},subtitle:{cy:"donut-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],512)):e.createCommentVNode("",!0),t.value.userOptions.show&&P.value&&(e.unref(Y)||e.unref(F))?(e.openBlock(),e.createBlock(ve.UserOptions,{ref:"details",key:`user_option_${W.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(Z),isImaging:e.unref(J),uid:k.value,hasTooltip:!1,hasLabel:!1,hasPdf:t.value.userOptions.buttons.pdf,hasImg:t.value.userOptions.buttons.img,hasXls:t.value.userOptions.buttons.csv,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:z.value,chartElement:O.value,position:t.value.userOptions.position,titles:{...t.value.userOptions.buttonTitles},hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:N.value,onToggleFullscreen:Pe,onGeneratePdf:e.unref(K),onGenerateCsv:ae,onGenerateImage:e.unref(Q),onToggleTable:re,onToggleAnnotator:A,style:e.normalizeStyle({visibility:e.unref(Y)?e.unref(F)?"visible":"hidden":"visible"})},e.createSlots({_:2},[l.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"0"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen: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","hasImg","hasXls","hasTable","hasFullscreen","isFullscreen","chartElement","position","titles","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),P.value?(e.openBlock(),e.createElementBlock("svg",{key:4,xmlns:e.unref(r.XMLNS),viewBox:`${v.value.x} ${v.value.y} ${v.value.width} ${v.value.height}`,width:"100%",class:e.normalizeClass({"vue-data-ui-fullscreen--on":z.value,"vue-data-ui-fulscreen--off":!z.value}),style:e.normalizeStyle(`max-width:100%;overflow:visible;background:transparent;color:${t.value.style.chart.color};`)},[e.createVNode(Oe._sfc_main),l.$slots["chart-background"]?(e.openBlock(),e.createElementBlock("foreignObject",{key:0,x:v.value.x,y:v.value.y,width:v.value.width,height:v.value.height,style:{pointerEvents:"none"}},[e.renderSlot(l.$slots,"chart-background",{},void 0,!0)],8,Le)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,o=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("defs",null,[e.createElementVNode("radialGradient",{id:o.id,fy:"30%"},[e.createElementVNode("stop",{offset:"10%","stop-color":e.unref(r.lightenHexColor)(o.color,t.value.style.chart.circles.gradient.intensity/100)},null,8,Ue),e.createElementVNode("stop",{offset:"90%","stop-color":e.unref(r.darkenHexColor)(o.color,.1)},null,8,Re),e.createElementVNode("stop",{offset:"100%","stop-color":o.color},null,8,He)],8,qe)]),l.$slots.pattern?(e.openBlock(),e.createElementBlock("g",Ge,[e.createElementVNode("defs",null,[e.renderSlot(l.$slots,"pattern",e.normalizeProps(e.guardReactiveProps({...o,patternId:`pattern_${k.value}_${o.id}`})),void 0,!0)])])):e.createCommentVNode("",!0),e.createElementVNode("rect",{x:o.x-o.radius,y:o.y-o.radius,width:o.radius*2,height:o.radius*2,stroke:t.value.style.chart.circles.stroke,"stroke-width":t.value.style.chart.circles.strokeWidth,fill:t.value.style.chart.circles.gradient.show?`url(#${o.id})`:o.color,rx:o.radius,onMouseenter:()=>Be(o),onMouseout:a[0]||(a[0]=u=>s.value=null)},null,40,We),l.$slots.pattern?(e.openBlock(),e.createElementBlock("rect",{key:1,x:o.x-o.radius,y:o.y-o.radius,width:o.radius*2,height:o.radius*2,stroke:t.value.style.chart.circles.stroke,"stroke-width":t.value.style.chart.circles.strokeWidth,fill:`url(#pattern_${k.value}_${o.id})`,rx:o.radius,style:{pointerEvents:"none"}},null,8,Xe)):e.createCommentVNode("",!0),t.value.style.chart.circles.labels.name.show&&o.name?(e.openBlock(),e.createElementBlock("text",{key:2,style:{pointerEvents:"none",transition:"opacity 0.2s ease-in-out"},opacity:s.value?.2:1,x:o.x,y:o.y-o.radius/2.5+t.value.style.chart.circles.labels.name.offsetY,"font-size":o.radius/o.name.length*2,fill:t.value.style.chart.circles.labels.name.color?t.value.style.chart.circles.labels.name.color:e.unref(r.adaptColorToBackground)(o.color),"font-weight":t.value.style.chart.circles.labels.name.bold?"bold":"normal","text-anchor":"middle"},e.toDisplayString(o.name),9,Ye)):e.createCommentVNode("",!0),t.value.style.chart.circles.labels.value.show?(e.openBlock(),e.createElementBlock("text",{key:3,style:{pointerEvents:"none",transition:"opacity 0.2s ease-in-out"},opacity:s.value?.2:1,x:o.x,y:o.y+o.radius/B(o).length*(B(o).length===1?1:2)/2+t.value.style.chart.circles.labels.value.offsetY,"font-size":o.radius/B(o).length*(B(o).length===1?1:2),fill:t.value.style.chart.circles.labels.value.color?t.value.style.chart.circles.labels.value.color:e.unref(r.adaptColorToBackground)(o.color),"font-weight":t.value.style.chart.circles.labels.value.bold?"bold":"normal","text-anchor":"middle"},e.toDisplayString(B(o)),9,je)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(we.value,u=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u,c=>(e.openBlock(),e.createElementBlock("path",{d:c.arcSlice,fill:c.color,stroke:"black"},null,8,Ze))),256))],64))),256))],64))),256)),s.value&&t.value.style.chart.circles.zoom.show?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("circle",{style:e.normalizeStyle(ze.value),cx:s.value.x,cy:s.value.y,r:x.value,opacity:g.value,stroke:t.value.style.chart.circles.stroke,fill:t.value.style.chart.circles.gradient.show?`url(#${s.value.id})`:s.value.color},null,12,Je),l.$slots["zoom-label"]?(e.openBlock(),e.createElementBlock("g",Ke,[e.renderSlot(l.$slots,"zoom-label",e.normalizeProps(e.guardReactiveProps({...s.value,zoomOpacity:g.value,currentRadius:x.value,fontSize:w.value})),void 0,!0)])):(e.openBlock(),e.createElementBlock("g",Qe,[e.createElementVNode("text",{style:{pointerEvents:"none"},opacity:g.value,x:s.value.x,y:s.value.y+t.value.style.chart.circles.zoom.label.name.offsetY-w.value.name/4,"text-anchor":"middle","font-size":w.value.name,fill:t.value.style.chart.circles.zoom.label.name.color?t.value.style.chart.circles.zoom.label.name.color:e.unref(r.adaptColorToBackground)(s.value.color),"font-weight":t.value.style.chart.circles.zoom.label.name.bold?"bold":"normal"},e.toDisplayString(s.value.name),9,et),e.createElementVNode("text",{style:{pointerEvents:"none"},opacity:g.value,x:s.value.x,y:s.value.y+w.value.value+t.value.style.chart.circles.zoom.label.value.offsetY,"text-anchor":"middle","font-size":w.value.value,fill:t.value.style.chart.circles.zoom.label.value.color?t.value.style.chart.circles.zoom.label.value.color:e.unref(r.adaptColorToBackground)(s.value.color),"font-weight":t.value.style.chart.circles.zoom.label.value.bold?"bold":"normal"},e.toDisplayString($e()),9,tt)]))],64)):e.createCommentVNode("",!0),e.renderSlot(l.$slots,"svg",{svg:{...v.value}},void 0,!0)],14,De)):e.createCommentVNode("",!0),P.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(Me.default,{key:5,config:{type:"circlePack",style:{color:"#CCCCCC"}}})),l.$slots.watermark?(e.openBlock(),e.createElementBlock("div",lt,[e.renderSlot(l.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(Z)||e.unref(J)})),void 0,!0)])):e.createCommentVNode("",!0),l.$slots.source?(e.openBlock(),e.createElementBlock("div",{key:7,ref_key:"source",ref:ge,dir:"auto"},[e.renderSlot(l.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),P.value?(e.openBlock(),e.createBlock(Fe.default,{key:8,hideDetails:"",config:{open:b.value.showTable,maxHeight:1e4,body:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color},head:{backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color}}},{content:e.withCtx(()=>[(e.openBlock(),e.createBlock(Ie.DataTable,{key:`table_${G.value}`,colNames:S.value.colNames,head:S.value.head,body:S.value.body,config:S.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[1]||(a[1]=o=>b.value.showTable=!1)},{th:e.withCtx(({th:o})=>[e.createElementVNode("div",{innerHTML:o,style:{display:"flex","align-items":"center"}},null,8,ot)]),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)],46,Ae))}},rt=_e._export_sfc(at,[["__scopeId","data-v-0106231a"]]);exports.default=rt;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { useCssVars as Qe, computed as y, ref as h, watch as Ie, onMounted as et, watchEffect as tt, openBlock as s, createElementBlock as i, normalizeClass as Fe, normalizeStyle as W, unref as c, createBlock as T, createCommentVNode as f, renderSlot as m, createSlots as lt, withCtx as C, normalizeProps as D, guardReactiveProps as L, createVNode as at, Fragment as O, renderList as se, createElementVNode as k, toDisplayString as G, createTextVNode as ot, nextTick as st } from "vue";
|
|
2
|
-
import { u as nt, c as Ne, t as rt, a as ne, p as P, o as ut, e as it, b as ct, d as Se, m as vt, h as Me, f as re, X as dt, l as ht, G as Y, i as _e, q as ft, r as yt } from "./index-
|
|
3
|
-
import { u as Ae } from "./useNestedProp-
|
|
4
|
-
import { u as pt, U as mt } from "./usePrinter-
|
|
5
|
-
import { _ as bt } from "./Title-
|
|
6
|
-
import { P as gt } from "./PenAndPaper-
|
|
2
|
+
import { u as nt, c as Ne, t as rt, a as ne, p as P, o as ut, e as it, b as ct, d as Se, m as vt, h as Me, f as re, X as dt, l as ht, G as Y, i as _e, q as ft, r as yt } from "./index-m6iVGCIc.js";
|
|
3
|
+
import { u as Ae } from "./useNestedProp-BO65z1Rt.js";
|
|
4
|
+
import { u as pt, U as mt } from "./usePrinter-D6-AMOJS.js";
|
|
5
|
+
import { _ as bt } from "./Title-r4pZn0TU.js";
|
|
6
|
+
import { P as gt } from "./PenAndPaper-D6oZdwvp.js";
|
|
7
7
|
import { u as kt } from "./useUserOptionState-BIvW1Kz7.js";
|
|
8
|
-
import { _ as wt } from "./PackageVersion-
|
|
9
|
-
import xt from "./vue-ui-accordion-
|
|
10
|
-
import { D as Ct } from "./DataTable-
|
|
11
|
-
import $t from "./vue-ui-skeleton-
|
|
8
|
+
import { _ as wt } from "./PackageVersion-BJurjgIS.js";
|
|
9
|
+
import xt from "./vue-ui-accordion-CXNwNRM_.js";
|
|
10
|
+
import { D as Ct } from "./DataTable-B3ZldeJU.js";
|
|
11
|
+
import $t from "./vue-ui-skeleton-aZahITpG.js";
|
|
12
12
|
import { _ as zt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
13
13
|
const Pt = ["id"], Tt = ["xmlns", "viewBox"], Ot = ["x", "y", "width", "height"], It = ["id"], Ft = ["stop-color"], Nt = ["stop-color"], St = ["stop-color"], Mt = { key: 0 }, _t = ["x", "y", "width", "height", "stroke", "stroke-width", "fill", "rx", "onMouseenter"], At = ["x", "y", "width", "height", "stroke", "stroke-width", "fill", "rx"], Et = ["opacity", "x", "y", "font-size", "fill", "font-weight"], Dt = ["opacity", "x", "y", "font-size", "fill", "font-weight"], Lt = ["d", "fill"], Gt = ["cx", "cy", "r", "opacity", "stroke", "fill"], Ut = {
|
|
14
14
|
key: 0,
|
|
@@ -35,8 +35,8 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], Ot = ["x", "y", "width", "height"]
|
|
|
35
35
|
setup(Ee, { expose: De }) {
|
|
36
36
|
const $ = Ee;
|
|
37
37
|
Qe((t) => ({
|
|
38
|
-
"
|
|
39
|
-
"
|
|
38
|
+
"49c9a662": N.value,
|
|
39
|
+
"0c7b2888": K.value
|
|
40
40
|
}));
|
|
41
41
|
const { vue_ui_circle_pack: Le } = nt(), U = y(() => !!$.dataset && $.dataset.length), I = h(Ne()), j = h(null), Ge = h(null), Ue = h(null), ue = h(0), ie = h(0), ce = h(0), Be = h(null), e = y({
|
|
42
42
|
get: () => he(),
|
|
@@ -129,7 +129,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], Ot = ["x", "y", "width", "height"]
|
|
|
129
129
|
return o;
|
|
130
130
|
}
|
|
131
131
|
const J = y(() => $.dataset.map((t, a) => {
|
|
132
|
-
const l = Se(t.color) || be.value[a] || ne[e.value.theme || "default"][a % ne[e.value.theme].length] || P[a] || P[a % P.length];
|
|
132
|
+
const l = Se(t.color) || be.value[a] || ne[e.value.theme || "default"][a % ne[e.value.theme || "default"].length] || P[a] || P[a % P.length];
|
|
133
133
|
return {
|
|
134
134
|
...t,
|
|
135
135
|
id: Ne(),
|
|
@@ -633,7 +633,7 @@ const Pt = ["id"], Tt = ["xmlns", "viewBox"], Ot = ["x", "y", "width", "height"]
|
|
|
633
633
|
}, 8, ["config"])) : f("", !0)
|
|
634
634
|
], 46, Pt));
|
|
635
635
|
}
|
|
636
|
-
}, sl = /* @__PURE__ */ zt(Wt, [["__scopeId", "data-v-
|
|
636
|
+
}, sl = /* @__PURE__ */ zt(Wt, [["__scopeId", "data-v-0106231a"]]);
|
|
637
637
|
export {
|
|
638
638
|
sl as default
|
|
639
639
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ref as n, computed as m, onMounted as R, onBeforeUnmount as E, openBlock as o, createElementBlock as l, unref as C, normalizeStyle as b, createElementVNode as r, createCommentVNode as a, normalizeClass as p, toDisplayString as x, nextTick as F, pushScopeId as I, popScopeId as L } from "vue";
|
|
2
|
-
import { u as z } from "./useNestedProp-
|
|
3
|
-
import { u as O, c as B, X as N, s as T } from "./index-
|
|
2
|
+
import { u as z } from "./useNestedProp-BO65z1Rt.js";
|
|
3
|
+
import { u as O, c as B, X as N, s as T } from "./index-m6iVGCIc.js";
|
|
4
4
|
import { _ as D } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
5
5
|
const g = (i) => (I("data-v-6a1383ea"), i = i(), L(), i), $ = ["xmlns", "height", "width"], W = {
|
|
6
6
|
id: "follower",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),_=require("./useNestedProp-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),_=require("./useNestedProp-B_G2vdgc.cjs"),i=require("./index-D4Ci0bak.cjs"),C=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),m=l=>(t.pushScopeId("data-v-6a1383ea"),l=l(),t.popScopeId(),l),p=["xmlns","height","width"],x={id:"follower",fy:"30%",fx:"30%"},E=["stop-color","stop-opacity"],N=m(()=>t.createElementVNode("stop",{offset:"95%","stop-color":"transparent"},null,-1)),g=["r","fill","stroke","stroke-width","stroke-dasharray"],V=["r","fill"],S={key:2,class:"wave"},w=["id"],B=["id"],R=m(()=>t.createElementVNode("feColorMatrix",{type:"saturate",values:"0"},null,-1)),b=["filter","stroke"],F={key:3,class:"crosshair"},z=["x1","stroke","stroke-width","stroke-dasharray"],I=["x1","stroke","stroke-width","stroke-dasharray"],L=["y1","stroke","stroke-width","stroke-dasharray"],O=["y1","stroke","stroke-width","stroke-dasharray"],T=["cy","r","fill"],D=["cy","r","fill"],$=["cx","r","fill"],W=["cx","r","fill"],G={key:5,class:"coordinates"},P=["x","y","font-size","fill"],q=["transform"],A=["font-size","fill"],M={__name:"vue-ui-cursor",props:{config:{type:Object,default:{}}},setup(l){const k=l,{vue_ui_cursor:y}=i.useConfig(),c=t.ref(i.createUid()),e=t.computed(()=>_.useNestedProp({userConfig:k.config,defaultConfig:y})),o=t.ref({x:-100,y:-100});function u({clientX:r,clientY:f,...j}){o.value.x=r-e.value.centerCircleRadius,o.value.y=f-e.value.centerCircleRadius}function d(r){o.value.x=r.targetTouches[0].clientX-e.value.centerCircleRadius,o.value.y=r.targetTouches[0].clientY-e.value.centerCircleRadius}const v=t.ref(!0);function s(r){v.value=r}const a=t.ref(!1),n=t.ref(null);function h(){a.value=!1,n.value&&clearTimeout(n.value),t.nextTick(()=>{a.value=!0,n.value=setTimeout(()=>{a.value=!1},1e3)})}return t.onMounted(()=>{const r=e.value.parentId?document.getElementById(e.value.parentId):document.getElementsByTagName("div")[0];r.addEventListener("mousemove",u),r.addEventListener("touchmove",d),r.addEventListener("mouseleave",()=>s(!1)),r.addEventListener("mouseenter",()=>s(!0)),r.addEventListener("click",h)}),t.onBeforeUnmount(()=>{const r=e.value.parentId?document.getElementById(e.value.parentId):document.getElementsByTagName("div")[0];r.removeEventListener("mousemove",u),r.removeEventListener("touchmove",d),r.removeEventListener("mouseleave",()=>s(!1)),r.removeEventListener("mouseenter",()=>s(!0)),r.removeEventListener("click",h)}),t.computed(()=>e.value.centerCircleRadius/2.5),(r,f)=>v.value?(t.openBlock(),t.createElementBlock("svg",{key:0,"data-html2canvas-ignore":"",xmlns:t.unref(i.XMLNS),style:t.normalizeStyle(`z-index: 2147483647; overflow: visible; pointer-events: none;background: transparent; position:fixed; top:${o.value.y}px; left:${o.value.x}px;`),viewBox:"0 0 100 100",height:e.value.centerCircleRadius*2,width:e.value.centerCircleRadius*2},[t.createElementVNode("defs",null,[t.createElementVNode("radialGradient",x,[t.createElementVNode("stop",{offset:"10%","stop-color":e.value.bubbleEffectColor,"stop-opacity":e.value.bubbleEffectOpacity},null,8,E),N])]),e.value.showCenterCircle?(t.openBlock(),t.createElementBlock("circle",{key:0,cx:50,cy:50,r:e.value.centerCircleRadius,fill:t.unref(i.setOpacity)(e.value.centerCircleColor,e.value.centerCircleOpacity*100),stroke:e.value.centerCircleStroke,"stroke-width":e.value.centerCircleStrokeWidth,"stroke-dasharray":e.value.centerCircleDasharray},null,8,g)):t.createCommentVNode("",!0),e.value.bubbleEffect?(t.openBlock(),t.createElementBlock("circle",{key:1,cx:50,cy:50,r:e.value.centerCircleRadius,fill:"url(#follower)",stroke:"none"},null,8,V)):t.createCommentVNode("",!0),e.value.useWaveOnClick?(t.openBlock(),t.createElementBlock("g",S,[t.createElementVNode("defs",null,[t.createElementVNode("filter",{id:`blur_${c.value}`,x:"-50%",y:"-50%",width:"200%",height:"200%"},[t.createElementVNode("feGaussianBlur",{in:"SourceGraphic",stdDeviation:4,id:`blur_std_${c.value}`},null,8,B),R],8,w)]),a.value?(t.openBlock(),t.createElementBlock("circle",{key:0,class:t.normalizeClass({"circle-wave":a.value}),cx:50,cy:50,r:50,filter:`url(#blur_${c.value})`,stroke:e.value.centerCircleStroke,fill:"none","stroke-width":"3"},null,10,b)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),e.value.showCrosshair?(t.openBlock(),t.createElementBlock("g",F,[t.createElementVNode("line",{x1:-e.value.centerCircleRadius+50,x2:-5e3,y1:50,y2:50,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,z),t.createElementVNode("line",{x1:50+e.value.centerCircleRadius,x2:5e3,y1:50,y2:50,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,I),t.createElementVNode("line",{x1:50,x2:50,y1:-e.value.centerCircleRadius+50,y2:-5e3,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,L),t.createElementVNode("line",{x1:50,x2:50,y1:e.value.centerCircleRadius+50,y2:5e3,stroke:e.value.crosshairStroke,"stroke-width":e.value.crosshairStrokeWidth,"stroke-dasharray":e.value.crosshairDasharray,"stroke-linecap":"round"},null,8,O)])):t.createCommentVNode("",!0),e.value.showIntersectCircles?(t.openBlock(),t.createElementBlock("g",{key:4,class:t.normalizeClass({"rotating-circles":e.value.isLoading})},[t.createElementVNode("circle",{cx:50,cy:e.value.centerCircleRadius+50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,T),t.createElementVNode("circle",{cx:50,cy:-e.value.centerCircleRadius+50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,D),t.createElementVNode("circle",{cx:-e.value.centerCircleRadius+50,cy:50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,$),t.createElementVNode("circle",{cx:e.value.centerCircleRadius+50,cy:50,r:e.value.intersectCirclesRadius,fill:e.value.intersectCirclesFill},null,8,W)],2)):t.createCommentVNode("",!0),e.value.showCoordinates?(t.openBlock(),t.createElementBlock("g",G,[t.createElementVNode("text",{"text-anchor":"end",x:-e.value.centerCircleRadius+50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset,y:50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset,"font-size":e.value.coordinatesFontSize,fill:e.value.coordinatesColor,style:{"font-variant-numeric":"tabular-nums"},"font-family":"Arial"},t.toDisplayString(o.value.x.toFixed(0)),9,P),t.createElementVNode("g",{transform:`translate(${50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset}, ${-e.value.centerCircleRadius+50-e.value.coordinatesFontSize/2+e.value.coordinatesOffset})`},[t.createElementVNode("text",{"text-anchor":"start","font-size":e.value.coordinatesFontSize,fill:e.value.coordinatesColor,style:{"font-variant-numeric":"tabular-nums"},transform:"rotate(-90)","font-family":"Arial"},t.toDisplayString(o.value.y.toFixed(0)),9,A)],8,q)])):t.createCommentVNode("",!0)],12,p)):t.createCommentVNode("",!0)}},U=C._export_sfc(M,[["__scopeId","data-v-6a1383ea"]]);exports.default=U;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { useCssVars as Z, computed as _, ref as s, watch as ee, openBlock as w, createElementBlock as y, createElementVNode as g, normalizeStyle as x, createCommentVNode as E, Fragment as L, renderList as te, normalizeClass as oe, renderSlot as ae, pushScopeId as ne, popScopeId as le, createStaticVNode as ue } from "vue";
|
|
2
2
|
import se from "./pdf-B7oVat64.js";
|
|
3
|
-
import { u as ie } from "./useNestedProp-
|
|
4
|
-
import { u as re } from "./index-
|
|
3
|
+
import { u as ie } from "./useNestedProp-BO65z1Rt.js";
|
|
4
|
+
import { u as re } from "./index-m6iVGCIc.js";
|
|
5
5
|
import { _ as de } from "./_plugin-vue_export-helper-CHgC5LLL.js";
|
|
6
6
|
const ce = (M) => (ne("data-v-0caf17e8"), M = M(), le(), M), he = {
|
|
7
7
|
key: 0,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),j=require("./pdf-9cRTLjY8.cjs"),U=require("./useNestedProp-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),j=require("./pdf-9cRTLjY8.cjs"),U=require("./useNestedProp-B_G2vdgc.cjs"),A=require("./index-D4Ci0bak.cjs"),G=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),J=b=>(o.pushScopeId("data-v-0caf17e8"),b=b(),o.popScopeId(),b),K={key:0,"data-html2canvas-ignore":"",style:{width:"100%",display:"flex","justify-content":"end"}},Q=["disabled"],Z=["stroke"],ee=o.createStaticVNode('<path stroke="none" d="M0 0h24v24H0z" fill="none" data-v-0caf17e8></path><path d="M18 16v.01" data-v-0caf17e8></path><path d="M6 16v.01" data-v-0caf17e8></path><path d="M12 5v.01" data-v-0caf17e8></path><path d="M12 12v.01" data-v-0caf17e8></path><path d="M12 1a4 4 0 0 1 2.001 7.464l.001 .072a3.998 3.998 0 0 1 1.987 3.758l.22 .128a3.978 3.978 0 0 1 1.591 -.417l.2 -.005a4 4 0 1 1 -3.994 3.77l-.28 -.16c-.522 .25 -1.108 .39 -1.726 .39c-.619 0 -1.205 -.14 -1.728 -.391l-.279 .16l.007 .231a4 4 0 1 1 -2.212 -3.579l.222 -.129a3.998 3.998 0 0 1 1.988 -3.756l.002 -.071a4 4 0 0 1 -1.995 -3.265l-.005 -.2a4 4 0 0 1 4 -4z" data-v-0caf17e8></path>',6),te=[ee],oe={key:1},ae=["id"],le=J(()=>o.createElementVNode("div",{class:"vue-ui-dashboard-grid"},null,-1)),ne=["onMousedown","onTouchstart"],ue=["onMousedown","onTouchstart"],se=["onMousedown","onTouchstart"],re=["onMousedown","onTouchstart"],ie=["onMousedown","onTouchstart"],T=20,ce={__name:"vue-ui-dashboard",props:{dataset:Array,config:Object},emits:["change"],setup(b,{expose:x,emit:S}){const E=b;o.useCssVars(e=>({"4458b906":L.value,"8bf0a1d8":W.value}));const{vue_ui_dashboard:I}=A.useConfig(),r=o.computed(()=>U.useNestedProp({userConfig:E.config,defaultConfig:I})),z=o.ref(`vue-ui-dashboard-${Math.random()}`),d=o.ref(r.value.locked);function X(){d.value=!d.value}const s=o.ref(E.dataset.map((e,t)=>({...e,index:t}))),h=o.ref(null),u=o.ref(null),v=o.ref({x:0,y:0}),f=o.ref({x:0,y:0}),i=o.ref(null),c=o.ref(!1),p=o.ref(null),m=o.ref(!1),w=o.ref(!1);function N(e){const t=e.target;(t.tagName==="INPUT"&&t.type==="range"||t.classList.contains("range-handle"))&&(w.value=!0)}function C(e){const t=e.target;t.tagName==="INPUT"&&t.type==="range"&&(w.value=!1)}function $(){m.value=!0,j.default({domElement:document.getElementById(`vue-ui-dashboard_${z.value}`),fileName:"vue-ui-dashboard"}).finally(()=>{m.value=!1})}function Y(e){if(!d.value&&(c.value=!0,p.value=e,u.value===null)){h.value=e,v.value={x:event.clientX,y:event.clientY};const t=s.value[e],l=100-t.width,a=100-t.height;t.left<0&&(t.left=0),t.top<0&&(t.top=0),t.left>l&&(t.left=l),t.top>a&&(t.top=a),t.left<0&&(t.left=0),t.top<0&&(t.top=0),t.left+t.width>100&&(t.left=100-t.width),t.top+t.height>100&&(t.top=100-t.height)}}function k(e,t){c.value=!0,p.value=e,u.value={index:e,direction:t};const l=s.value[e];f.value={x:event.clientX,y:event.clientY,initialWidth:l.width,initialHeight:l.height}}function B(e,t,l){if(u.value.direction.includes("top")){const a=e.height-l/i.value.offsetHeight*100;a>=T&&(e.top+=l/i.value.offsetHeight*100,e.height=a)}if(u.value.direction.includes("bottom")){const a=e.height+l/i.value.offsetHeight*100;a>=T&&(e.height=a)}if(u.value.direction.includes("left")){const a=e.width-t/i.value.offsetWidth*100;a>=T&&(e.left+=t/i.value.offsetWidth*100,e.width=a)}if(u.value.direction.includes("right")){const a=e.width+t/i.value.offsetWidth*100;a>=T&&(e.width=a)}}function V(e){if(!(d.value||w.value)){if(c.value=!0,h.value!==null){const t=s.value[h.value],l=e.clientX-v.value.x,a=e.clientY-v.value.y,n=t.left+l/i.value.offsetWidth*100,g=t.top+a/i.value.offsetHeight*100;n>=0&&g>=0&&n+t.width<=100&&g+t.height<=100&&(t.left=n,t.top=g),v.value={x:e.clientX,y:e.clientY}}if(u.value!==null){const t=s.value[u.value.index],l=e.clientX-f.value.x,a=e.clientY-f.value.y;B(t,l,a),f.value={x:e.clientX,y:e.clientY}}}}o.watch(s,e=>{e&&!c.value&&S("change",s.value)},{deep:!0});function H(){h.value=null,u.value=null,c.value=!1,p.value=null,s.value.forEach(e=>{e.left=Math.round(e.left/100*100),e.top=Math.round(e.top/100*100),e.width=Math.round(e.width/100*100),e.height=Math.round(e.height/100*100)})}function P(e){d.value||w.value||(c.value=!0,p.value=e,u.value===null&&(h.value=e,v.value={x:event.touches[0].clientX,y:event.touches[0].clientY}))}function _(e,t,l){if(c.value=!0,p.value=e,u.value===null){u.value={index:e,direction:t};const a=s.value[e];f.value={x:l.touches[0].clientX,y:l.touches[0].clientY,initialWidth:a.width,initialHeight:a.height}}}function M(e){if(c.value=!0,e.preventDefault(),u.value!==null){const t=s.value[u.value.index],l=e.touches[0].clientX-f.value.x,a=e.touches[0].clientY-f.value.y;B(t,l,a),f.value={x:e.touches[0].clientX,y:e.touches[0].clientY}}}function D(e){if(!(d.value||w.value)&&(c.value=!0,e.preventDefault(),h.value!==null)){const t=s.value[h.value],l=e.touches[0].clientX-v.value.x,a=e.touches[0].clientY-v.value.y,n=t.left+l/i.value.offsetWidth*100,g=t.top+a/i.value.offsetHeight*100;n>=0&&g>=0&&n+t.width<=100&&g+t.height<=100&&(t.left=n,t.top=g),v.value={x:e.touches[0].clientX,y:e.touches[0].clientY}}}function y(){c.value=!1,p.value=null,h.value=null,u.value=null,s.value.forEach(e=>{e.left=Math.round(e.left/100*100),e.top=Math.round(e.top/100*100),e.width=Math.round(e.width/100*100),e.height=Math.round(e.height/100*100)})}const L=o.computed(()=>r.value.style.item.borderColor),W=o.computed(()=>r.value.style.resizeHandles.backgroundColor),F=o.computed(()=>r.value.style.board.aspectRatio),R=o.computed(()=>r.value.style.board.backgroundColor),q=o.computed(()=>r.value.style.board.border);function O(){return s.value}return x({generatePdf:$,getItemsPositions:O,toggleLock:X}),(e,t)=>(o.openBlock(),o.createElementBlock("div",{onMousedown:N,onMouseup:C,onTouchstart:N,onTouchend:C},[r.value.allowPrint?(o.openBlock(),o.createElementBlock("div",K,[o.createElementVNode("button",{class:"vue-ui-dashboard-button",onClick:$,disabled:m.value,style:o.normalizeStyle([{"margin-top":"12px"},`color:${r.value.style.board.color}`])},[m.value?(o.openBlock(),o.createElementBlock("svg",{key:0,class:"vue-ui-dashboard-print-icon",xmlns:"http://www.w3.org/2000/svg",width:"20",height:"20",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:r.value.style.board.color,fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},te,8,Z)):(o.openBlock(),o.createElementBlock("span",oe,"PDF"))],12,Q)])):o.createCommentVNode("",!0),o.createElementVNode("div",{class:"vue-ui-dashboard-container",ref_key:"dashboardContainer",ref:i,id:`vue-ui-dashboard_${z.value}`,style:o.normalizeStyle(`border:${q.value}; sbackground:${R.value}; aspect-ratio:${F.value}`)},[o.createElementVNode("div",{class:"vue-ui-dashboard-grid-container",ref:"container",onMousemove:V,onMouseup:H,onTouchmove:D,onTouchend:y,style:o.normalizeStyle(`background:${r.value.style.board.backgroundColor}`)},[le,(o.openBlock(!0),o.createElementBlock(o.Fragment,null,o.renderList(s.value,(l,a)=>(o.openBlock(),o.createElementBlock("div",{key:l.id,class:o.normalizeClass({"vue-ui-dashboard-grid-item":!0,"vue-ui-dashboard-grid-item--locked":d.value}),style:o.normalizeStyle({width:`${l.width}%`,height:`${l.height}%`,left:`${l.left}%`,top:`${l.top}%`,cursor:"move",boxShadow:p.value===a?"0 6px 12px -3px rgba(0,0,0,0.3)":"",zIndex:p.value===a?s.value.length+1:l.index,backgroundColor:r.value.style.item.backgroundColor}),onMousedown:n=>Y(a),onTouchstart:n=>P(a)},[d.value?o.createCommentVNode("",!0):(o.openBlock(),o.createElementBlock(o.Fragment,{key:0},[o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-top-left",onMousedown:n=>k(a,"top-left"),onTouchstart:n=>_(a,"top-left",n),onTouchmove:t[0]||(t[0]=n=>M(n)),onTouchend:y},null,40,ue),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-top-right",onMousedown:n=>k(a,"top-right"),onTouchstart:n=>_(a,"top-right",n),onTouchmove:t[1]||(t[1]=n=>M(n)),onTouchend:y},null,40,se),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-bottom-left",onMousedown:n=>k(a,"bottom-left"),onTouchstart:n=>_(a,"bottom-left",n),onTouchmove:t[2]||(t[2]=n=>M(n)),onTouchend:y},null,40,re),o.createElementVNode("div",{class:"vue-ui-dashboard-resize-handle vue-ui-dashboard-bottom-right",onMousedown:n=>k(a,"bottom-right"),onTouchstart:n=>_(a,"bottom-right",n),onTouchmove:t[3]||(t[3]=n=>M(n)),onTouchend:y},null,40,ie)],64)),o.renderSlot(e.$slots,"content",{item:l,index:a,left:l.left,top:l.top,height:l.height,width:l.width},void 0,!0)],46,ne))),128))],36)],12,ae)],32))}},de=G._export_sfc(ce,[["__scopeId","data-v-0caf17e8"]]);exports.default=de;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ref as k, computed as d, openBlock as $, createElementBlock as i, Fragment as o, createElementVNode as l, createCommentVNode as m, unref as v, normalizeStyle as C, renderList as b, createBlock as N } from "vue";
|
|
2
|
-
import { u as q } from "./useNestedProp-
|
|
3
|
-
import { u as M, X as S } from "./index-
|
|
2
|
+
import { u as q } from "./useNestedProp-BO65z1Rt.js";
|
|
3
|
+
import { u as M, X as S } from "./index-m6iVGCIc.js";
|
|
4
4
|
const w = { key: 0 }, B = ["d", "fill"], F = ["d", "fill"], X = ["d", "fill"], E = ["d", "fill"], I = ["d", "fill"], O = ["d", "fill"], A = ["d", "fill"], D = { key: 1 }, G = ["cx", "cy", "fill"], V = {
|
|
5
5
|
__name: "Digit",
|
|
6
6
|
props: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),g=require("./useNestedProp-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),g=require("./useNestedProp-B_G2vdgc.cjs"),L=require("./index-D4Ci0bak.cjs"),f={key:0},m=["d","fill"],k=["d","fill"],h=["d","fill"],v=["d","fill"],C=["d","fill"],N=["d","fill"],b=["d","fill"],B={key:1},E=["cx","cy","fill"],q={__name:"Digit",props:{quanta:{type:String,default:null},backgroundColor:{type:String,default:"#e1e5e8"},color:{type:String,default:"#000000"},x:{type:Number,default:0},y:{type:Number,default:0}},setup(e){const u=e,$=t.ref({0:"1111110",1:"0110000",2:"1101101",3:"1111001",4:"0110011",5:"1011011",6:"1011111",7:"1110000",8:"1111111",9:"1111011","-":"0000001",X:"0000000"}),l=t.computed(()=>[void 0,null].includes(u.quanta)?$.value.X:$.value[u.quanta]);return(a,x)=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[[void 0,null,"."].includes(e.quanta)?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock("g",f,[t.createElementVNode("path",{d:`M ${e.x} ${e.y} L ${e.x+2} ${e.y-2} L ${e.x+24} ${e.y-2} L ${e.x+26} ${e.y} L ${e.x+24} ${e.y+2} L ${e.x+2} ${e.y+2}Z`,fill:l.value[0]==1?e.color:e.backgroundColor,stroke:"none"},null,8,m),t.createElementVNode("path",{d:`M ${e.x+26} ${e.y+26} L ${e.x+26} ${e.y+4} L ${e.x+28} ${e.y+2} L ${e.x+30} ${e.y+4} L ${e.x+30} ${e.y+26} L ${e.x+28} ${e.y+28} L ${e.x+26} ${e.y+26}`,fill:l.value[1]==1?e.color:e.backgroundColor,stroke:"none"},null,8,k),t.createElementVNode("path",{d:`M ${e.x+26} ${e.y+56} L ${e.x+26} ${e.y+34} L ${e.x+28} ${e.y+32} L ${e.x+30} ${e.y+34} L ${e.x+30} ${e.y+56} L ${e.x+28} ${e.y+58} L ${e.x+26} ${e.y+56}`,fill:l.value[2]==1?e.color:e.backgroundColor,stroke:"none"},null,8,h),t.createElementVNode("path",{d:`M ${e.x+2} ${e.y+58} L ${e.x} ${e.y+60} L ${e.x+2} ${e.y+62} L ${e.x+24} ${e.y+62} L ${e.x+26} ${e.y+60} L ${e.x+24} ${e.y+58} L ${e.x+2} ${e.y+58}`,fill:l.value[3]==1?e.color:e.backgroundColor,stroke:"none"},null,8,v),t.createElementVNode("path",{d:`M ${e.x} ${e.y+34} L ${e.x-2} ${e.y+32} L ${e.x-4} ${e.y+34} L ${e.x-4} ${e.y+56} L ${e.x-2} ${e.y+58} L ${e.x} ${e.y+56} L ${e.x} ${e.y+34}`,fill:l.value[4]==1?e.color:e.backgroundColor,stroke:"none"},null,8,C),t.createElementVNode("path",{d:`M ${e.x-2} ${e.y+2} L ${e.x} ${e.y+4} L ${e.x} ${e.y+26} L ${e.x-2} ${e.y+28} L ${e.x-4} ${e.y+26} L ${e.x-4} ${e.y+4} L ${e.x-2} ${e.y+2}`,fill:l.value[5]==1?e.color:e.backgroundColor,stroke:"none"},null,8,N),t.createElementVNode("path",{d:`M ${e.x+2} ${e.y+28} L ${e.x} ${e.y+30} L ${e.x+2} ${e.y+32} L ${e.x+24} ${e.y+32} L ${e.x+26} ${e.y+30} L ${e.x+24} ${e.y+28} L ${e.x+2} ${e.y+28}`,fill:l.value[6]==1?e.color:e.backgroundColor,stroke:"none"},null,8,b)])),e.quanta=="."?(t.openBlock(),t.createElementBlock("g",B,[t.createElementVNode("circle",{cx:e.x-8,cy:e.y+60,r:3,fill:e.color},null,8,E)])):t.createCommentVNode("",!0)],64))}},M=["xmlns","viewBox"],V={__name:"vue-ui-digits",props:{dataset:{type:Number,default:0},config:{type:Object,default(){return{}}}},setup(e){const u=e,{vue_ui_digits:$}=L.useConfig(),l=t.computed(()=>g.useNestedProp({userConfig:u.config,defaultConfig:$})),a=t.computed(()=>{const c=(u.dataset||0).toString().split(""),d=[],n={x:10,y:10};let i=0;for(let y=0;y<c.length;y+=1){const o=c[y];d.push({x:n.x+i,y:n.y,quanta:o}),o=="."?i+=2:i+=44}return d}),x=t.computed(()=>Math.max(...a.value.map(c=>c.x))+36);return(c,d)=>(t.openBlock(),t.createElementBlock("svg",{xmlns:t.unref(L.XMLNS),viewBox:`0 0 ${x.value} 80`,style:t.normalizeStyle(`background:${l.value.backgroundColor};${l.value.height?`height:${l.value.height};`:""}${l.value.width?`width:${l.value.width}`:""}`)},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.value,n=>(t.openBlock(),t.createBlock(q,{x:n.x,y:n.y,quanta:n.quanta,color:l.value.digits.color,backgroundColor:l.value.digits.skeletonColor},null,8,["x","y","quanta","color","backgroundColor"]))),256))],12,M))}};exports.default=V;
|