vue-data-ui 2.6.44 → 2.6.46
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-BIsMVdtn.js → Arrow-D4sCAfTr.js} +1 -1
- package/dist/{Arrow-DGay3Mq4.cjs → Arrow-l2Rjf1KV.cjs} +1 -1
- package/dist/{BaseIcon-CNr0ynIA.cjs → BaseIcon-BpdQLb-0.cjs} +1 -1
- package/dist/{BaseIcon-BkG8oy7S.js → BaseIcon-Dx5FJt-N.js} +4 -3
- package/dist/{ColorPicker-BolaeJP4.js → ColorPicker-Ag9OY75a.js} +3 -3
- package/dist/{ColorPicker-Dk1k_q80.cjs → ColorPicker-BkUHmkbg.cjs} +1 -1
- package/dist/{DataTable-ChXRV1c1.cjs → DataTable-B8Ui_Pd4.cjs} +1 -1
- package/dist/{DataTable-CMtUsL3k.js → DataTable-D9wdDVT6.js} +2 -2
- package/dist/{Legend-CNvH8CO_.js → Legend-BCngKEVr.js} +2 -2
- package/dist/{Legend-DpeobB-J.cjs → Legend-BFB4DMQS.cjs} +1 -1
- package/dist/{PackageVersion-DpTw0H2K.js → PackageVersion-DR6SOSy8.js} +3 -3
- package/dist/PackageVersion-Da8iEjju.cjs +1 -0
- package/dist/{PenAndPaper-B3u1FDG_.cjs → PenAndPaper-Dpjaroq-.cjs} +1 -1
- package/dist/{PenAndPaper-CdyjU7Bn.js → PenAndPaper-DxsKkGjV.js} +3 -3
- package/dist/{Shape--0X0ca4a.js → Shape-CcATSdDH.js} +1 -1
- package/dist/{Shape-gapU-fux.cjs → Shape-DomxDqtX.cjs} +1 -1
- package/dist/{Slicer-CZQhXgqN.js → Slicer-Bw4VblBK.js} +2 -2
- package/dist/{Slicer-hryDvXmh.cjs → Slicer-DlCXj2P9.cjs} +1 -1
- package/dist/{Title-DRo5NxnS.cjs → Title-CFmNnjPN.cjs} +1 -1
- package/dist/{Title-CUTRN3ig.js → Title-Dr0O3Ohb.js} +1 -1
- package/dist/{Tooltip-BvEZcxbc.js → Tooltip-C8mLFDBp.js} +1 -1
- package/dist/{Tooltip-Cbjcw6Jz.cjs → Tooltip-UBWsyt1M.cjs} +1 -1
- package/dist/{index-DQCJDAtd.js → index-BdV23M_4.js} +1 -1
- package/dist/{index-hcakVXU6.cjs → index-FtxQWcA1.cjs} +1 -1
- package/dist/style.css +1 -1
- package/dist/types/vue-data-ui.d.cts +2 -1
- package/dist/types/vue-data-ui.d.ts +2 -1
- package/dist/{useNestedProp-DCfCPrTU.cjs → useNestedProp-BIeXIQxH.cjs} +1 -1
- package/dist/{useNestedProp-WD6Qn-jr.js → useNestedProp-DyW-iWus.js} +1 -1
- package/dist/{usePrinter-Dv0RMCX1.cjs → usePrinter-BUMwWyWM.cjs} +1 -1
- package/dist/{usePrinter-FM1PheWO.js → usePrinter-TFomTfxX.js} +1 -1
- package/dist/{vue-data-ui-Byi8FBJM.js → vue-data-ui-Cal0DvqU.js} +61 -61
- package/dist/{vue-data-ui-CDVMMv3d.cjs → vue-data-ui-DBoVETZN.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-CZJ6Zo23.js → vue-ui-3d-bar-DUMfvSbU.js} +9 -9
- package/dist/{vue-ui-3d-bar-DJUNcjtc.cjs → vue-ui-3d-bar-GTKfWFni.cjs} +1 -1
- package/dist/{vue-ui-accordion-BckkmphN.js → vue-ui-accordion-2_hSAOvX.js} +3 -3
- package/dist/{vue-ui-accordion-BfFg-sVJ.cjs → vue-ui-accordion-BIBhKMbJ.cjs} +1 -1
- package/dist/{vue-ui-age-pyramid-DgGMb_Xp.js → vue-ui-age-pyramid-C0UfrmeD.js} +10 -10
- package/dist/{vue-ui-age-pyramid-DunUSOpu.cjs → vue-ui-age-pyramid-DotN5JY1.cjs} +1 -1
- package/dist/{vue-ui-annotator-B_MQz1AA.js → vue-ui-annotator-C-9pwUrR.js} +1 -1
- package/dist/{vue-ui-annotator-B3G-FQLy.cjs → vue-ui-annotator-C0V4kD4I.cjs} +1 -1
- package/dist/{vue-ui-bullet-DYpgP9uL.js → vue-ui-bullet-6vftOeqJ.js} +8 -8
- package/dist/{vue-ui-bullet-8Kk3qeH_.cjs → vue-ui-bullet-Ct39TnfH.cjs} +1 -1
- package/dist/{vue-ui-candlestick-BSB_x1u_.cjs → vue-ui-candlestick-Cxpk32bR.cjs} +1 -1
- package/dist/{vue-ui-candlestick-DnY1Z5sA.js → vue-ui-candlestick-IxSh2gnY.js} +11 -11
- package/dist/{vue-ui-carousel-table-DNnBKojP.cjs → vue-ui-carousel-table-BinpEAPd.cjs} +1 -1
- package/dist/{vue-ui-carousel-table-Cd_2r90R.js → vue-ui-carousel-table-DreHo_wE.js} +4 -4
- package/dist/{vue-ui-chestnut-B1NWviH6.js → vue-ui-chestnut-3saDHpZ-.js} +8 -8
- package/dist/{vue-ui-chestnut-WcoV2zl6.cjs → vue-ui-chestnut-CpYTb1wd.cjs} +1 -1
- package/dist/{vue-ui-circle-pack-CxxPZDLO.js → vue-ui-circle-pack-BechgWzd.js} +9 -9
- package/dist/{vue-ui-circle-pack-D32Zo62g.cjs → vue-ui-circle-pack-BfskRpSw.cjs} +1 -1
- package/dist/{vue-ui-cursor-Df3A3tId.js → vue-ui-cursor-BEuJm8Mb.js} +2 -2
- package/dist/{vue-ui-cursor-BNdKosWF.cjs → vue-ui-cursor-CRMGfBFa.cjs} +1 -1
- package/dist/{vue-ui-dashboard-BD3v2yB2.js → vue-ui-dashboard-DSrb1InR.js} +2 -2
- package/dist/{vue-ui-dashboard-SRIs3xRd.cjs → vue-ui-dashboard-TQto_FFI.cjs} +1 -1
- package/dist/{vue-ui-digits-DiwdDWIi.cjs → vue-ui-digits-BRPGEv7S.cjs} +1 -1
- package/dist/{vue-ui-digits-6ixh72pY.js → vue-ui-digits-BeoOy04C.js} +2 -2
- package/dist/{vue-ui-donut-BLrLvjYC.js → vue-ui-donut-BWQ3vgjP.js} +12 -12
- package/dist/{vue-ui-donut-O_bMKpp0.cjs → vue-ui-donut-Dam0YSMu.cjs} +1 -1
- package/dist/{vue-ui-donut-evolution-COqxvgDm.cjs → vue-ui-donut-evolution-DOXHsGwg.cjs} +1 -1
- package/dist/{vue-ui-donut-evolution-DFeCoFLD.js → vue-ui-donut-evolution-DQIaWcso.js} +11 -11
- package/dist/{vue-ui-dumbbell-CnvbgjAc.cjs → vue-ui-dumbbell--mlgQyZ7.cjs} +1 -1
- package/dist/{vue-ui-dumbbell-BdpORbsw.js → vue-ui-dumbbell-BAA0L5kU.js} +10 -10
- package/dist/{vue-ui-flow-Bq5TNf0q.js → vue-ui-flow-CbIxR8qu.js} +9 -9
- package/dist/{vue-ui-flow-DZW6HtMG.cjs → vue-ui-flow-zigj6Xbo.cjs} +1 -1
- package/dist/{vue-ui-funnel-CdTmW2Dv.js → vue-ui-funnel-C1CjZHuh.js} +9 -9
- package/dist/{vue-ui-funnel-BTs69xlm.cjs → vue-ui-funnel-Cs-Kjiev.cjs} +1 -1
- package/dist/{vue-ui-galaxy-Bks-C0T9.cjs → vue-ui-galaxy-CWI4H3RW.cjs} +1 -1
- package/dist/{vue-ui-galaxy-Dc38cJm-.js → vue-ui-galaxy-G9AFzo0J.js} +11 -11
- package/dist/{vue-ui-gauge-BTCMT6kZ.cjs → vue-ui-gauge-CsyLGIqh.cjs} +1 -1
- package/dist/{vue-ui-gauge-BPe-Wpxa.js → vue-ui-gauge-hDpxwLu6.js} +7 -7
- package/dist/{vue-ui-gizmo-CUKcPiKM.cjs → vue-ui-gizmo-BIcmHlyo.cjs} +1 -1
- package/dist/{vue-ui-gizmo-DBnHMb9H.js → vue-ui-gizmo-Bc-DWND7.js} +3 -3
- package/dist/{vue-ui-heatmap-C1YhyvNx.js → vue-ui-heatmap-8p4PejGU.js} +10 -10
- package/dist/{vue-ui-heatmap-BufOxGx7.cjs → vue-ui-heatmap-DZ9xsMHI.cjs} +1 -1
- package/dist/{vue-ui-history-plot-DWAkb7b_.cjs → vue-ui-history-plot-DiTEY9hR.cjs} +1 -1
- package/dist/{vue-ui-history-plot-oMjKnlp3.js → vue-ui-history-plot-W2UVpzIY.js} +11 -11
- package/dist/{vue-ui-kpi-ufMTcMPT.cjs → vue-ui-kpi-BXQ6gSky.cjs} +1 -1
- package/dist/{vue-ui-kpi-BLHpMBxd.js → vue-ui-kpi-DFFosWUi.js} +3 -3
- package/dist/{vue-ui-mini-loader-BLsy0k_A.js → vue-ui-mini-loader-C2uhjtCz.js} +2 -2
- package/dist/{vue-ui-mini-loader-T1GcVUKb.cjs → vue-ui-mini-loader-C8hmEB9w.cjs} +1 -1
- package/dist/{vue-ui-molecule-BnCvFuus.js → vue-ui-molecule-B1pxOA3p.js} +10 -10
- package/dist/{vue-ui-molecule-B3GExfFV.cjs → vue-ui-molecule-CXIE8hWW.cjs} +1 -1
- package/dist/{vue-ui-mood-radar-Yso-s4of.js → vue-ui-mood-radar-B-bELxUM.js} +11 -11
- package/dist/{vue-ui-mood-radar-Cxt_fhUy.cjs → vue-ui-mood-radar-BuLuDh5y.cjs} +1 -1
- package/dist/{vue-ui-nested-donuts-BfRWRgkw.js → vue-ui-nested-donuts-C4isJwag.js} +11 -11
- package/dist/{vue-ui-nested-donuts-BBzhXq6P.cjs → vue-ui-nested-donuts-C4vK7cf-.cjs} +1 -1
- package/dist/{vue-ui-onion-Dt4TWe6t.js → vue-ui-onion-BNPFlq-G.js} +11 -11
- package/dist/{vue-ui-onion-OEnDmiOB.cjs → vue-ui-onion-nbqNRCyk.cjs} +1 -1
- package/dist/{vue-ui-parallel-coordinate-plot-BnAAzLae.cjs → vue-ui-parallel-coordinate-plot-C9FIQC4s.cjs} +1 -1
- package/dist/{vue-ui-parallel-coordinate-plot-DGLh0ael.js → vue-ui-parallel-coordinate-plot-DFHwTxhN.js} +12 -12
- package/dist/{vue-ui-quadrant-nHh7YqG6.js → vue-ui-quadrant-C4NULaSL.js} +12 -12
- package/dist/{vue-ui-quadrant-B6E6v1xG.cjs → vue-ui-quadrant-CEyZ6gCX.cjs} +1 -1
- package/dist/{vue-ui-quick-chart-Dr20RPOf.cjs → vue-ui-quick-chart-B7PqLKWn.cjs} +1 -1
- package/dist/{vue-ui-quick-chart-SGvhac9d.js → vue-ui-quick-chart-m9kWUtKc.js} +9 -9
- package/dist/{vue-ui-radar-CcdphM-O.js → vue-ui-radar-CKb7rcO0.js} +12 -12
- package/dist/{vue-ui-radar-BRtf9Ps5.cjs → vue-ui-radar-DHH8CDle.cjs} +1 -1
- package/dist/{vue-ui-rating-DRlCBElN.js → vue-ui-rating-BowDISAW.js} +2 -2
- package/dist/{vue-ui-rating-DgwurE4x.cjs → vue-ui-rating-nYq9NVf8.cjs} +1 -1
- package/dist/{vue-ui-relation-circle-B4TErNPT.cjs → vue-ui-relation-circle-CXa8v5cY.cjs} +1 -1
- package/dist/{vue-ui-relation-circle-g1JlL2f2.js → vue-ui-relation-circle-CtaNRzML.js} +7 -7
- package/dist/{vue-ui-rings-CBeL3HIa.cjs → vue-ui-rings-CRgcPBhj.cjs} +1 -1
- package/dist/{vue-ui-rings-BM9uYCUU.js → vue-ui-rings-DaydpH_W.js} +12 -12
- package/dist/{vue-ui-scatter-DT_QBIeo.js → vue-ui-scatter-Bx16gq37.js} +12 -12
- package/dist/{vue-ui-scatter-gkSm6cYR.cjs → vue-ui-scatter-CH8b47_g.cjs} +1 -1
- package/dist/{vue-ui-screenshot-2leQxim8.cjs → vue-ui-screenshot-BOqEw_Ty.cjs} +1 -1
- package/dist/{vue-ui-screenshot-DGbuK-RT.js → vue-ui-screenshot-j_ruTkOe.js} +1 -1
- package/dist/{vue-ui-skeleton-BTfzoolB.js → vue-ui-skeleton-CVnkLuNk.js} +3 -3
- package/dist/{vue-ui-skeleton-FXF7pMM8.cjs → vue-ui-skeleton-CX4m8kLi.cjs} +1 -1
- package/dist/{vue-ui-smiley-rwgYU3A2.js → vue-ui-smiley-DGfBC_1p.js} +2 -2
- package/dist/{vue-ui-smiley-Dijs1HRf.cjs → vue-ui-smiley-DOcs96EG.cjs} +1 -1
- package/dist/{vue-ui-spark-trend-Cj0B6A_8.js → vue-ui-spark-trend-BjNjO7Al.js} +5 -5
- package/dist/{vue-ui-spark-trend-D62Z0XyP.cjs → vue-ui-spark-trend-Cx5_BczW.cjs} +1 -1
- package/dist/{vue-ui-sparkbar-B3R7uA_h.js → vue-ui-sparkbar-Bj9M7Klo.js} +4 -4
- package/dist/{vue-ui-sparkbar-BB_OXsVx.cjs → vue-ui-sparkbar-CzRw1-5c.cjs} +1 -1
- package/dist/{vue-ui-sparkgauge-CV3MRct2.cjs → vue-ui-sparkgauge-iMqket_H.cjs} +1 -1
- package/dist/{vue-ui-sparkgauge-20iVOcBv.js → vue-ui-sparkgauge-mx5x8jhB.js} +4 -4
- package/dist/{vue-ui-sparkhistogram-C8WGWsjQ.js → vue-ui-sparkhistogram-knnJtMmd.js} +5 -5
- package/dist/{vue-ui-sparkhistogram-ASA1Izuq.cjs → vue-ui-sparkhistogram-w4t8R3kU.cjs} +1 -1
- package/dist/{vue-ui-sparkline-jX03CtPG.cjs → vue-ui-sparkline-BgGreU8G.cjs} +1 -1
- package/dist/{vue-ui-sparkline-C4MRWUBA.js → vue-ui-sparkline-C4xJULc3.js} +4 -4
- package/dist/{vue-ui-sparkstackbar-C6jgtbtu.js → vue-ui-sparkstackbar-DKozbgvk.js} +5 -5
- package/dist/{vue-ui-sparkstackbar-BcCB8Id3.cjs → vue-ui-sparkstackbar-oCiVPgqg.cjs} +1 -1
- package/dist/{vue-ui-stackbar-CVS_1WMe.cjs → vue-ui-stackbar-Bomp_wIS.cjs} +1 -1
- package/dist/{vue-ui-stackbar-CkEnBXay.js → vue-ui-stackbar-avxRfDtE.js} +13 -13
- package/dist/{vue-ui-strip-plot-DBabY03i.cjs → vue-ui-strip-plot-7k2wQR85.cjs} +1 -1
- package/dist/{vue-ui-strip-plot-ES7BwMoF.js → vue-ui-strip-plot-CdLa8dCp.js} +11 -11
- package/dist/{vue-ui-table-CCwzUTnA.js → vue-ui-table-C0a-SgcX.js} +1 -1
- package/dist/{vue-ui-table-Cf1g82vY.cjs → vue-ui-table-CE-PgrMl.cjs} +1 -1
- package/dist/{vue-ui-table-heatmap-DtzKVrpK.js → vue-ui-table-heatmap-BoI6tise.js} +4 -4
- package/dist/{vue-ui-table-heatmap-CyHzz9rv.cjs → vue-ui-table-heatmap-ycSv15rY.cjs} +1 -1
- package/dist/{vue-ui-table-sparkline-95pS3pBt.js → vue-ui-table-sparkline-Dxx6025N.js} +5 -5
- package/dist/{vue-ui-table-sparkline-CLAybURJ.cjs → vue-ui-table-sparkline-idKvXcFK.cjs} +1 -1
- package/dist/{vue-ui-thermometer-Cm_KBNVZ.cjs → vue-ui-thermometer-Bu1o-YxS.cjs} +1 -1
- package/dist/{vue-ui-thermometer-BQTWXeqU.js → vue-ui-thermometer-Cx0BYvoa.js} +7 -7
- package/dist/{vue-ui-timer-B0D_sZmm.cjs → vue-ui-timer-D_UKwqRG.cjs} +1 -1
- package/dist/{vue-ui-timer-tLNMbgLM.js → vue-ui-timer-DkGY_7Z9.js} +5 -5
- package/dist/{vue-ui-tiremarks-nIj267dw.js → vue-ui-tiremarks-CL8yqBs3.js} +7 -7
- package/dist/{vue-ui-tiremarks-CWIZflLH.cjs → vue-ui-tiremarks-DTm_Xj8_.cjs} +1 -1
- package/dist/vue-ui-treemap-WcZTaeP0.js +956 -0
- package/dist/vue-ui-treemap-rohF9UGD.cjs +1 -0
- package/dist/{vue-ui-vertical-bar-NCB7yZQF.js → vue-ui-vertical-bar-Czmk3lor.js} +12 -12
- package/dist/{vue-ui-vertical-bar-fh2mIy4s.cjs → vue-ui-vertical-bar-EJofGF6Z.cjs} +1 -1
- package/dist/{vue-ui-waffle-BTz72Vui.cjs → vue-ui-waffle-C7Lq9EWX.cjs} +1 -1
- package/dist/{vue-ui-waffle-C70QQeU2.js → vue-ui-waffle-Ci5lps_0.js} +12 -12
- package/dist/{vue-ui-wheel-C9DYeu9D.cjs → vue-ui-wheel-DSUUCTFP.cjs} +1 -1
- package/dist/{vue-ui-wheel-BKAEI3lz.js → vue-ui-wheel-DWSgTz2U.js} +7 -7
- package/dist/{vue-ui-word-cloud-ChIuYeMe.js → vue-ui-word-cloud-IoOiZMCJ.js} +10 -10
- package/dist/{vue-ui-word-cloud-BgxihpLV.cjs → vue-ui-word-cloud-pp9BsZMx.cjs} +1 -1
- package/dist/{vue-ui-xy-DHgnF-1N.js → vue-ui-xy-Bk09XvD1.js} +14 -14
- package/dist/{vue-ui-xy-canvas-xQvriWI0.js → vue-ui-xy-canvas-BEWBX2Os.js} +12 -12
- package/dist/{vue-ui-xy-canvas-BstJgVjY.cjs → vue-ui-xy-canvas-hUlid7hP.cjs} +1 -1
- package/dist/{vue-ui-xy-BSKwWGbp.cjs → vue-ui-xy-e1xFpXmD.cjs} +1 -1
- package/package.json +1 -1
- package/dist/PackageVersion-C9u9Pwxk.cjs +0 -1
- package/dist/vue-ui-treemap-DRDVV_Da.cjs +0 -1
- package/dist/vue-ui-treemap-Js5dG3BL.js +0 -931
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("./index-hcakVXU6.cjs"),B=require("./DataTable-ChXRV1c1.cjs"),E=require("./Title-DRo5NxnS.cjs"),G=require("./Tooltip-Cbjcw6Jz.cjs"),V=require("./usePrinter-Dv0RMCX1.cjs"),z=require("./Shape-gapU-fux.cjs"),M=require("./BaseIcon-CNr0ynIA.cjs"),T=require("./vue-ui-table-sparkline-CLAybURJ.cjs"),P=require("./vue-ui-skeleton-FXF7pMM8.cjs"),R=require("./Slicer-hryDvXmh.cjs"),D=require("./vue-ui-accordion-BfFg-sVJ.cjs"),v=require("./useNestedProp-DCfCPrTU.cjs"),H=require("./PackageVersion-C9u9Pwxk.cjs"),q=require("./PenAndPaper-B3u1FDG_.cjs"),t=require("vue"),W=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Y=d.createUid(),X={name:"vue-ui-xy",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},components:{DataTable:B.DataTable,Shape:z._sfc_main,Title:E._sfc_main,Tooltip:G._sfc_main,UserOptions:V.UserOptions,BaseIcon:M.default,TableSparkline:T.default,Skeleton:P.default,Slicer:R.Slicer,Accordion:D.default,PackageVersion:H._sfc_main,PenAndPaper:q.PenAndPaper},data(){this.dataset.forEach((h,r)=>{[null,void 0].includes(h.series)&&this.error({componentName:"VueUiXy",type:"datasetSerieAttribute",property:"series (number[])",index:r})});const l=this.config.downsample&&this.config.downsample.threshold?this.config.downsample.threshold:500,i=Math.max(...this.dataset.map(h=>this.largestTriangleThreeBucketsArray({data:h.series,threshold:l}).length)),n={start:0,end:i};return{themePalettes:d.themePalettes,themes:d.themes,slicerStep:0,selectedScale:null,CTX:null,CANVAS:null,opacity:d.opacity,useSafeValues:!0,palette:d.palette,height:600,width:1e3,viewBox:"0 0 1000 600",clientPosition:{x:0,y:0},canvasClientPosition:{x:0,y:0},icons:{line:"line",bar:"bar",plot:"plot"},isAnnotator:!1,isFullscreen:!1,isPrinting:!1,isImaging:!1,isTooltip:!1,mutableConfig:{dataLabels:{show:!0},showTooltip:!0,showTable:!1,isStacked:!1,useIndividualScale:!1},selectedSerieIndex:null,selectedRowIndex:null,segregatedSeries:[],uniqueId:d.createUid(),step:0,tableStep:0,titleStep:0,slicer:n,__to__:null,maxX:i,showSparklineTable:!0,segregateStep:0,sliderId:Y,fontSizes:{xAxis:18,yAxis:12,dataLabels:20,plotLabels:10},plotRadii:{plot:3,line:3},selectedMinimapIndex:null,showUserOptionsOnChartHover:!1,keepUserOptionState:!0,userOptionsVisible:!0,svgRef:null,tagRefs:{}}},watch:{dataset:{handler(l,i){this.maxX=Math.max(...this.dataset.map(n=>this.largestTriangleThreeBucketsArray({data:n.series,threshold:this.FINAL_CONFIG.downsample.threshold}).length)),this.slicer={start:0,end:this.maxX},this.slicerStep+=1,this.segregateStep+=1},deep:!0},config:{handler(l,i){this.FINAL_CONFIG=this.prepareConfig(),this.prepareChart(),this.titleStep+=1,this.tableStep+=1,this.mutableConfig={dataLabels:{show:!0},showTooltip:this.FINAL_CONFIG.chart.tooltip.show===!0,showTable:this.FINAL_CONFIG.showTable===!0,isStacked:this.FINAL_CONFIG.chart.grid.labels.yAxis.stacked,useIndividualScale:this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale}},deep:!0}},computed:{chartAriaLabel(){const l=this.FINAL_CONFIG.chart.title.text||"Chart visualization",i=this.FINAL_CONFIG.chart.title.subtitle.text||"";return`${l}. ${i}`},optimize(){return{linePlot:this.maxSeries>this.FINAL_CONFIG.line.dot.hideAboveMaxSerieLength}},hasOptionsNoTitle(){return this.FINAL_CONFIG.chart.userOptions.show&&(!this.FINAL_CONFIG.chart.title.show||!this.FINAL_CONFIG.chart.title.text)},minimap(){if(!this.FINAL_CONFIG.chart.zoom.minimap.show)return[];const l=this.datasetWithIds.filter(r=>!this.segregatedSeries.includes(r.id)),i=Math.max(...l.map(r=>r.series.length)),n=[];for(let r=0;r<i;r+=1)n.push(l.map(e=>e.series[r]||0).reduce((e,x)=>(e||0)+(x||0),0));const h=Math.min(...n);return n.map(r=>r+(h<0?Math.abs(h):0))},customPalette(){return this.convertCustomPalette(this.FINAL_CONFIG.customPalette)},backgroundColor(){return this.FINAL_CONFIG.chart.backgroundColor},slicerColor(){return this.FINAL_CONFIG.chart.zoom.color},allScales(){const l=this.lineSet.map(e=>({name:e.name,color:e.color,scale:e.individualScale,scaleYLabels:e.scaleYLabels,zero:e.zeroPosition,max:e.individualMax,scaleLabel:e.scaleLabel||"",id:e.id,yOffset:e.yOffset||0,individualHeight:e.individualHeight||this.drawingArea.height,autoScaleYLabels:e.autoScaleYLabels})),i=this.barSet.map(e=>({name:e.name,color:e.color,scale:e.individualScale,scaleYLabels:e.scaleYLabels,zero:e.zeroPosition,max:e.individualMax,scaleLabel:e.scaleLabel||"",id:e.id,yOffset:e.yOffset||0,individualHeight:e.individualHeight||this.drawingArea.height})),n=this.plotSet.map(e=>({name:e.name,color:e.color,scale:e.individualScale,scaleYLabels:e.scaleYLabels,zero:e.zeroPosition,max:e.individualMax,scaleLabel:e.scaleLabel||"",id:e.id,yOffset:e.yOffset||0,individualHeight:e.individualHeight||this.drawingArea.height})),h=this.mutableConfig.useIndividualScale&&!this.mutableConfig.isStacked?Object.values(this.scaleGroups):[...l,...i,...n],r=h.flatMap(e=>e).length;return h.flatMap((e,x)=>({unique:e.unique,id:e.id,groupId:e.groupId,scaleLabel:e.scaleLabel,name:this.mutableConfig.useIndividualScale&&!this.mutableConfig.isStacked?e.unique?e.name:e.groupName:e.name,color:this.mutableConfig.useIndividualScale&&!this.mutableConfig.isStacked?e.unique?e.color:e.groupColor:e.color,scale:e.scale,yOffset:e.yOffset,individualHeight:e.individualHeight,x:this.mutableConfig.isStacked?this.drawingArea.left:this.drawingArea.left/r*(x+1),yLabels:e.scaleYLabels||e.scale.ticks.map(g=>({y:g>=0?e.zero-e.individualHeight*(g/e.max):e.zero+e.individualHeight*Math.abs(g)/e.max,value:g}))}))},isDataset(){return!!this.dataset&&this.dataset.length},chartFont(){const l=document.getElementById(`vue-ui-xy_${this.uniqueId}`);return window.getComputedStyle(l,null).getPropertyValue("font-family")},FINAL_CONFIG:{get:function(){return this.prepareConfig()},set:function(l){return l}},hasHighlightArea(){return Array.isArray(this.FINAL_CONFIG.chart.highlightArea)?this.FINAL_CONFIG.chart.highlightArea.some(l=>l.show):this.FINAL_CONFIG.chart.highlightArea&&this.FINAL_CONFIG.chart.highlightArea.show},highlightAreas(){if(Array.isArray(this.FINAL_CONFIG.chart.highlightArea))return this.FINAL_CONFIG.chart.highlightArea.map(i=>({...i,span:i.from===i.to?1:i.to<i.from?0:i.to-i.from+1}));const l=this.FINAL_CONFIG.chart.highlightArea;return[{...l,span:l.from===l.to?1:l.to<l.from?0:l.to-l.from+1}]},xPadding(){return this.FINAL_CONFIG.chart.grid.position==="middle"?0:this.drawingArea.width/this.maxSeries/2},relativeZero(){return[null,void 0].includes(this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin)?this.niceScale.min>=0?0:Math.abs(this.niceScale.min):-this.niceScale.min},absoluteMax(){return this.niceScale.max+this.relativeZero},datasetWithIds(){return this.useSafeValues?this.dataset.map((l,i)=>({...l,series:this.largestTriangleThreeBucketsArray({data:l.series,threshold:this.FINAL_CONFIG.downsample.threshold}),id:`uniqueId_${i}`})):this.dataset},safeDataset(){return this.useSafeValues?this.dataset.map((l,i)=>{const n=this.largestTriangleThreeBucketsArray({data:l.series,threshold:this.FINAL_CONFIG.downsample.threshold}),h=`uniqueId_${i}`;return{...l,slotAbsoluteIndex:i,series:n.map(r=>this.isSafeValue(r)?r:null).slice(this.slicer.start,this.slicer.end),color:this.convertColorToHex(l.color?l.color:this.customPalette[i]?this.customPalette[i]:this.palette[i]),id:h,scaleLabel:l.scaleLabel||h}}):this.dataset},relativeDataset(){return this.safeDataset.map((l,i)=>({...l,series:l.series.map(n=>n+this.relativeZero),absoluteValues:l.series})).filter(l=>!this.segregatedSeries.includes(l.id))},tableSparklineDataset(){return this.relativeDataset.map(l=>{const i=l.absoluteValues.map(n=>[void 0,null].includes(n)?0:n);return{id:l.id,name:l.name,color:l.color,values:this.fillArray(this.maxSeries,i)}})},tableSparklineConfig(){return{responsiveBreakpoint:this.FINAL_CONFIG.table.responsiveBreakpoint,roundingValues:this.FINAL_CONFIG.table.rounding,showAverage:!1,showMedian:!1,showTotal:!1,fontFamily:this.FINAL_CONFIG.chart.fontFamily,prefix:this.FINAL_CONFIG.chart.labels.prefix,suffix:this.FINAL_CONFIG.chart.labels.suffix,colNames:JSON.parse(JSON.stringify(this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values)),thead:{backgroundColor:this.FINAL_CONFIG.table.th.backgroundColor,color:this.FINAL_CONFIG.table.th.color,outline:this.FINAL_CONFIG.table.th.outline},tbody:{backgroundColor:this.FINAL_CONFIG.table.td.backgroundColor,color:this.FINAL_CONFIG.table.td.color,outline:this.FINAL_CONFIG.table.td.outline},userOptions:{show:!1}}},absoluteDataset(){return this.safeDataset.map((l,i)=>({absoluteIndex:i,...l,series:l.series.map(n=>n+this.relativeZero),absoluteValues:l.series,segregate:()=>this.segregate(l),isSegregated:this.segregatedSeries.includes(l.id)}))},activeSeriesLength(){return this.absoluteDataset.length},activeSeriesWithStackRatios(){return this.assignStackRatios(this.absoluteDataset.filter(l=>!this.segregatedSeries.includes(l.id)))},scaleGroups(){const l=Object.groupBy(this.activeSeriesWithStackRatios,n=>n.scaleLabel),i={};for(const[n,h]of Object.entries(l)){const r=h.flatMap(e=>e.absoluteValues);i[n]={min:Math.min(...r)||0,max:Math.max(...r)||1,groupId:`scale_group_${this.createUid()}`}}return i},barSet(){return this.activeSeriesWithStackRatios.filter(l=>l.type==="bar").map((l,i)=>{this.checkAutoScaleError(l);const n=this.scaleGroups[l.scaleLabel].min,h=this.scaleGroups[l.scaleLabel].max;l.absoluteValues.filter(N=>![null,void 0].includes(N)).map(N=>(N-n)/(h-n));const r={valueMin:n,valueMax:h<0?0:h},e={max:l.scaleMax||Math.max(...l.absoluteValues)||1,min:l.scaleMin||Math.min(...l.absoluteValues.filter(N=>![void 0,null].includes(N)))>0?0:Math.min(...l.absoluteValues.filter(N=>![null,void 0].includes(N)))},x=l.scaleSteps||this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps,g=1.0000001,u=this.calculateNiceScaleWithExactExtremes(e.min,e.max===e.min?e.max*g:e.max,x),b=this.calculateNiceScaleWithExactExtremes(r.valueMin,r.valueMax===r.valueMin?r.valueMax*g:r.valueMax,x),L=u.min>=0?0:Math.abs(u.min),_=0,C=u.max+L,y=b.max+Math.abs(_),m=this.mutableConfig.isStacked?this.drawingArea.height*(1-l.cumulatedStackRatio):0,F=this.mutableConfig.isStacked?this.drawingArea.height*l.stackRatio-this.FINAL_CONFIG.chart.grid.labels.yAxis.gap:this.drawingArea.height,A=this.drawingArea.bottom-m-F*L/C,O=this.drawingArea.bottom-m-F*_/y,a=this.absoluteDataset.filter(N=>N.type==="bar").filter(N=>!this.segregatedSeries.includes(N.id)).length,o=l.series.map((N,w)=>{const I=this.mutableConfig.useIndividualScale?(l.absoluteValues[w]+L)/C:this.ratioToMax(N),k=this.mutableConfig.useIndividualScale&&this.mutableConfig.isStacked?this.drawingArea.left+this.drawingArea.width/this.maxSeries*w:this.drawingArea.left+this.slot.bar*i+this.slot.bar*w*a-this.barSlot/2-i*this.barPeriodGap;return{yOffset:this.checkNaN(m),individualHeight:this.checkNaN(F),x:this.checkNaN(k),y:this.drawingArea.bottom-m-F*I,value:l.absoluteValues[w],zeroPosition:this.checkNaN(A),individualMax:this.checkNaN(C),comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[w]||""}}),s=l.absoluteValues.map(N=>b.min>=0?(N-Math.abs(b.min))/(b.max-Math.abs(b.min)):(N+Math.abs(b.min))/(b.max+Math.abs(b.min))),c=l.series.map((N,w)=>{const I=this.mutableConfig.useIndividualScale&&this.mutableConfig.isStacked?this.drawingArea.left+this.drawingArea.width/this.maxSeries*w:this.drawingArea.left-this.slot.bar/2+this.slot.bar*i+this.slot.bar*w*this.absoluteDataset.filter(k=>k.type==="bar").filter(k=>!this.segregatedSeries.includes(k.id)).length;return{yOffset:this.checkNaN(m),individualHeight:this.checkNaN(F),x:this.checkNaN(I),y:this.checkNaN(this.drawingArea.bottom-this.checkNaN(m)-(this.checkNaN(F)*s[w]||0)),value:l.absoluteValues[w],zeroPosition:this.checkNaN(A),individualMax:this.checkNaN(C),comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[w]||""}}),f=u.ticks.map(N=>({y:N>=0?A-F*(N/C):A+F*Math.abs(N)/C,value:N,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l})),S=b.ticks.map(N=>{const w=(N-b.min)/(b.max-b.min);return{y:N>=0?O-F*w:O+F*w,value:N,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l}});return this.scaleGroups[l.scaleLabel].name=l.name,this.scaleGroups[l.scaleLabel].groupName=l.scaleLabel,this.scaleGroups[l.scaleLabel].groupColor=this.FINAL_CONFIG.chart.grid.labels.yAxis.groupColor||l.color,this.scaleGroups[l.scaleLabel].color=l.color,this.scaleGroups[l.scaleLabel].scaleYLabels=l.autoScaling?S:f,this.scaleGroups[l.scaleLabel].zeroPosition=l.autoScaling?O:A,this.scaleGroups[l.scaleLabel].individualMax=l.autoScaling?y:C,this.scaleGroups[l.scaleLabel].scaleLabel=l.scaleLabel,this.scaleGroups[l.scaleLabel].id=l.id,this.scaleGroups[l.scaleLabel].yOffset=m,this.scaleGroups[l.scaleLabel].individualHeight=F,this.scaleGroups[l.scaleLabel].autoScaleYLabels=S,this.scaleGroups[l.scaleLabel].unique=this.activeSeriesWithStackRatios.filter(N=>N.scaleLabel===l.scaleLabel).length===1,{...l,yOffset:m,autoScaleYLabels:S,individualHeight:F,scaleYLabels:l.autoScaling?S:f,individualScale:l.autoScaling?b:u,individualMax:l.autoScaling?y:C,zeroPosition:l.autoScaling?O:A,plots:l.autoScaling?c:o,groupId:this.scaleGroups[l.scaleLabel].groupId}})},lineSet(){return this.activeSeriesWithStackRatios.filter(l=>l.type==="line").map(l=>{this.checkAutoScaleError(l);const i=this.scaleGroups[l.scaleLabel].min,n=this.scaleGroups[l.scaleLabel].max;l.absoluteValues.filter(I=>![null,void 0].includes(I)).map(I=>(I-i)/(n-i));const h={valueMin:i,valueMax:n},r={max:l.scaleMax||Math.max(...l.absoluteValues)||1,min:l.scaleMin||(Math.min(...l.absoluteValues)>0?0:Math.min(...l.absoluteValues))},e=l.scaleSteps||this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps,x=1.0000001,g=this.calculateNiceScaleWithExactExtremes(r.min,r.max===r.min?r.max*x:r.max,e),u=this.calculateNiceScaleWithExactExtremes(h.valueMin,h.valueMax===h.valueMin?h.valueMax*x:h.valueMax,e),b=g.min>=0?0:Math.abs(g.min),L=0,_=g.max+Math.abs(b),C=u.max+Math.abs(L),y=this.mutableConfig.isStacked?this.drawingArea.height*(1-l.cumulatedStackRatio):0,m=this.mutableConfig.isStacked?this.drawingArea.height*l.stackRatio-this.FINAL_CONFIG.chart.grid.labels.yAxis.gap:this.drawingArea.height,F=this.drawingArea.bottom-y-m*b/_,A=this.drawingArea.bottom-y-m*L/C,O=l.series.map((I,k)=>{const p=this.mutableConfig.useIndividualScale?(l.absoluteValues[k]+Math.abs(b))/_:this.ratioToMax(I);return{x:this.checkNaN(this.drawingArea.left+this.slot.line/2+this.slot.line*k),y:this.checkNaN(this.drawingArea.bottom-y-m*p),value:l.absoluteValues[k],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[k]||""}}),a=l.absoluteValues.map(I=>u.min>=0?(I-Math.abs(u.min))/(u.max-Math.abs(u.min)):(I+Math.abs(u.min))/(u.max+Math.abs(u.min))),o=l.series.map((I,k)=>[void 0,null].includes(l.absoluteValues[k])?{x:this.checkNaN(this.drawingArea.left+this.slot.line/2+this.slot.line*k),y:F,value:l.absoluteValues[k],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[k]||""}:{x:this.checkNaN(this.drawingArea.left+this.slot.line/2+this.slot.line*k),y:this.checkNaN(this.drawingArea.bottom-y-(m*a[k]||0)),value:l.absoluteValues[k],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[k]||""}),s=this.createSmoothPath(O.filter(I=>I.value!==null)),c=this.createSmoothPath(o.filter(I=>I.value!==null)),f=this.createStraightPath(O.filter(I=>I.value!==null)),S=this.createStraightPath(o.filter(I=>I.value!==null)),N=g.ticks.map(I=>({y:I>=0?F-m*(I/_):F+m*Math.abs(I)/_,value:I,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l})),w=u.ticks.map(I=>{const k=(I-u.min)/(u.max-u.min);return{y:I>=0?A-m*k:A+m*k,value:I,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l}});return this.scaleGroups[l.scaleLabel].name=l.name,this.scaleGroups[l.scaleLabel].groupName=l.scaleLabel,this.scaleGroups[l.scaleLabel].groupColor=this.FINAL_CONFIG.chart.grid.labels.yAxis.groupColor||l.color,this.scaleGroups[l.scaleLabel].color=l.color,this.scaleGroups[l.scaleLabel].scaleYLabels=l.autoScaling?w:N,this.scaleGroups[l.scaleLabel].zeroPosition=l.autoScaling?A:F,this.scaleGroups[l.scaleLabel].individualMax=l.autoScaling?C:_,this.scaleGroups[l.scaleLabel].scaleLabel=l.scaleLabel,this.scaleGroups[l.scaleLabel].id=l.id,this.scaleGroups[l.scaleLabel].yOffset=y,this.scaleGroups[l.scaleLabel].individualHeight=m,this.scaleGroups[l.scaleLabel].autoScaleYLabels=w,this.scaleGroups[l.scaleLabel].unique=this.activeSeriesWithStackRatios.filter(I=>I.scaleLabel===l.scaleLabel).length===1,{...l,yOffset:y,autoScaleYLabels:w,individualHeight:m,scaleYLabels:l.autoScaling?w:N,individualScale:l.autoScaling?u:g,individualMax:l.autoScaling?C:_,zeroPosition:l.autoScaling?A:F,curve:l.autoScaling?c:s,plots:l.autoScaling?o:O,area:l.useArea?this.mutableConfig.useIndividualScale?this.createIndividualArea(l.autoScaling?o:O,l.autoScaling?A:F):this.createArea(O):"",straight:l.autoScaling?S:f,groupId:this.scaleGroups[l.scaleLabel].groupId}})},plotSet(){return this.activeSeriesWithStackRatios.filter(l=>l.type==="plot").map(l=>{this.checkAutoScaleError(l);const i=this.scaleGroups[l.scaleLabel].min,n=this.scaleGroups[l.scaleLabel].max;l.absoluteValues.filter(f=>![null,void 0].includes(f)).map(f=>(f-i)/(n-i));const h={valueMin:i,valueMax:n},r={max:l.scaleMax||Math.max(...l.absoluteValues)||1,min:l.scaleMin||Math.min(...l.absoluteValues)>0?0:Math.min(...l.absoluteValues)},e=l.scaleSteps||this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps,x=1.0000001,g=this.calculateNiceScaleWithExactExtremes(r.min,r.max===r.min?r.max*x:r.max,e),u=this.calculateNiceScaleWithExactExtremes(h.valueMin,h.valueMax===h.valueMin?h.valueMax*x:h.valueMax,e),b=g.min>=0?0:Math.abs(g.min),L=0,_=g.max+b,C=u.max+Math.abs(L),y=this.mutableConfig.isStacked?this.drawingArea.height*(1-l.cumulatedStackRatio):0,m=this.mutableConfig.isStacked?this.drawingArea.height*l.stackRatio-this.FINAL_CONFIG.chart.grid.labels.yAxis.gap:this.drawingArea.height,F=this.drawingArea.bottom-y-m*b/_,A=this.drawingArea.bottom-y-m*L/C,O=l.series.map((f,S)=>{const N=this.mutableConfig.useIndividualScale?(l.absoluteValues[S]+Math.abs(b))/_:this.ratioToMax(f);return{x:this.checkNaN(this.drawingArea.left+this.slot.plot/2+this.slot.plot*S),y:this.checkNaN(this.drawingArea.bottom-y-m*N),value:l.absoluteValues[S],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[S]||""}}),a=l.absoluteValues.map(f=>u.min>=0?(f-Math.abs(u.min))/(u.max-Math.abs(u.min)):(f+Math.abs(u.min))/(u.max+Math.abs(u.min))),o=l.series.map((f,S)=>({x:this.checkNaN(this.drawingArea.left+this.slot.plot/2+this.slot.plot*S),y:this.checkNaN(this.drawingArea.bottom-y-(m*a[S]||0)),value:l.absoluteValues[S],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[S]||""})),s=g.ticks.map(f=>({y:f>=0?F-m*(f/_):F+m*Math.abs(f)/_,value:f,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l})),c=u.ticks.map(f=>{const S=(f-u.min)/(u.max-u.min);return{y:f>=0?A-m*S:A+m*S,value:f,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l}});return this.scaleGroups[l.scaleLabel].name=l.name,this.scaleGroups[l.scaleLabel].groupName=l.scaleLabel,this.scaleGroups[l.scaleLabel].groupColor=this.FINAL_CONFIG.chart.grid.labels.yAxis.groupColor||l.color,this.scaleGroups[l.scaleLabel].color=l.color,this.scaleGroups[l.scaleLabel].scaleYLabels=l.autoScaling?c:s,this.scaleGroups[l.scaleLabel].zeroPosition=l.autoScaling?A:F,this.scaleGroups[l.scaleLabel].individualMax=l.autoScaling?C:_,this.scaleGroups[l.scaleLabel].scaleLabel=l.scaleLabel,this.scaleGroups[l.scaleLabel].id=l.id,this.scaleGroups[l.scaleLabel].yOffset=y,this.scaleGroups[l.scaleLabel].individualHeight=m,this.scaleGroups[l.scaleLabel].autoScaleYLabels=c,this.scaleGroups[l.scaleLabel].unique=this.activeSeriesWithStackRatios.filter(f=>f.scaleLabel===l.scaleLabel).length===1,{...l,yOffset:y,autoScaleYLabels:c,individualHeight:m,scaleYLabels:l.autoScaling?c:s,individualScale:l.autoScaling?u:g,individualMax:l.autoScaling?C:_,zeroPosition:l.autoScaling?A:F,plots:l.autoScaling?o:O,groupId:this.scaleGroups[l.scaleLabel].groupId}})},drawingArea(){function l(h){const r=new Set;return h.forEach(e=>{const x=e.scaleLabel||"__noScaleLabel__";r.add(x)}),r.size}const i=l(this.absoluteDataset.filter(h=>!this.segregatedSeries.includes(h.id))),n=this.mutableConfig.useIndividualScale&&this.FINAL_CONFIG.chart.grid.labels.show?i*(this.mutableConfig.isStacked?0:this.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth):0;return{top:this.FINAL_CONFIG.chart.padding.top,right:this.width-this.FINAL_CONFIG.chart.padding.right,bottom:this.height-this.FINAL_CONFIG.chart.padding.bottom,left:this.FINAL_CONFIG.chart.padding.left+n,height:this.height-(this.FINAL_CONFIG.chart.padding.top+this.FINAL_CONFIG.chart.padding.bottom),width:this.width-(this.FINAL_CONFIG.chart.padding.right+this.FINAL_CONFIG.chart.padding.left+n)}},max(){return this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMax?this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMax:Math.max(...this.safeDataset.filter(l=>!this.segregatedSeries.includes(l.id)).map(l=>Math.max(...l.series)))},min(){if(this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin!==null)return this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin;const l=Math.min(...this.safeDataset.filter(i=>!this.segregatedSeries.includes(i.id)).map(i=>Math.min(...i.series)));return l>0?0:l},niceScale(){return this.calculateNiceScaleWithExactExtremes(this.min,this.max<0?0:this.max,this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps)},maxSeries(){return this.slicer.end-this.slicer.start},timeLabels(){const l=Math.max(...this.dataset.map(n=>this.largestTriangleThreeBucketsArray({data:n.series,threshold:this.FINAL_CONFIG.downsample.threshold}).length)),i=[];for(let n=0;n<l;n+=1)i.push({text:this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[n]||String(n),absoluteIndex:n});return i.slice(this.slicer.start,this.slicer.end)},slot(){return{bar:this.drawingArea.width/this.maxSeries/this.safeDataset.filter(l=>l.type==="bar").filter(l=>!this.segregatedSeries.includes(l.id)).length,plot:this.drawingArea.width/this.maxSeries,line:this.drawingArea.width/this.maxSeries}},barSlot(){const l=this.safeDataset.filter(i=>i.type==="bar").filter(i=>!this.segregatedSeries.includes(i.id)).length;return this.drawingArea.width/this.maxSeries/l-this.barPeriodGap*l},barPeriodGap(){return this.slot.line*this.FINAL_CONFIG.bar.periodGap},maxSlot(){return Math.max(...Object.values(this.slot).filter(l=>l!==1/0))},table(){if(this.safeDataset.length===0)return{head:[],body:[],config:{},columnNames:[]};const l=this.relativeDataset.map(n=>({label:n.name,color:n.color,type:n.type})),i=[];return this.timeLabels.forEach((n,h)=>{const r=[n.text];this.relativeDataset.forEach(e=>{r.push(this.canShowValue(e.absoluteValues[h])?Number(e.absoluteValues[h].toFixed(this.FINAL_CONFIG.table.rounding)):"")}),i.push(r)}),{head:l,body:i}},dataTable(){const l=this.FINAL_CONFIG.table.showSum;let i=[""].concat(this.relativeDataset.map(e=>e.name));l&&(i=i.concat(' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>'));let n=[];for(let e=0;e<this.maxSeries;e+=1){const x=this.relativeDataset.map(g=>g.absoluteValues[e]??0).reduce((g,u)=>g+u,0);n.push([this.timeLabels[e].text??"-"].concat(this.relativeDataset.map(g=>this.applyDataLabel(g.type==="line"?this.FINAL_CONFIG.line.labels.formatter:g.type==="bar"?this.FINAL_CONFIG.bar.labels.formatter:this.FINAL_CONFIG.plot.labels.formatter,g.absoluteValues[e]??0,this.dataLabel({p:g.prefix||this.FINAL_CONFIG.chart.labels.prefix,v:g.absoluteValues[e]??0,s:g.suffix||this.FINAL_CONFIG.chart.labels.suffix,r:this.FINAL_CONFIG.table.rounding})))).concat(l?(x??0).toFixed(this.FINAL_CONFIG.table.rounding):[]))}const h={th:{backgroundColor:this.FINAL_CONFIG.table.th.backgroundColor,color:this.FINAL_CONFIG.table.th.color,outline:this.FINAL_CONFIG.table.th.outline},td:{backgroundColor:this.FINAL_CONFIG.table.td.backgroundColor,color:this.FINAL_CONFIG.table.td.color,outline:this.FINAL_CONFIG.table.td.outline},breakpoint:this.FINAL_CONFIG.table.responsiveBreakpoint},r=[this.FINAL_CONFIG.table.columnNames.period].concat(this.relativeDataset.map(e=>e.name)).concat(this.FINAL_CONFIG.table.columnNames.total);return{head:i,body:n,config:h,colNames:r}},dataTooltipSlot(){return{datapoint:this.selectedSeries,seriesIndex:this.selectedSerieIndex,series:this.absoluteDataset,bars:this.barSet,lines:this.lineSet,plots:this.plotSet,config:this.FINAL_CONFIG}},selectedSeries(){return this.relativeDataset.map(l=>({slotAbsoluteIndex:l.slotAbsoluteIndex,shape:l.shape||null,name:l.name,color:l.color,type:l.type,value:l.absoluteValues.find((i,n)=>n===this.selectedSerieIndex),comments:l.comments||[],prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix}))},tooltipContent(){let l="",i=this.selectedSeries.map(r=>r.value).filter(r=>this.isSafeValue(r)&&r!==null).reduce((r,e)=>Math.abs(r)+Math.abs(e),0);const n=this.timeLabels[this.selectedSerieIndex],h=this.FINAL_CONFIG.chart.tooltip.customFormat;return this.isFunction(h)&&this.functionReturnsString(()=>h({seriesIndex:this.selectedSerieIndex,datapoint:this.selectedSeries,series:this.absoluteDataset,bars:this.barSet,lines:this.lineSet,plots:this.plotSet,config:this.FINAL_CONFIG}))?h({seriesIndex:this.selectedSerieIndex,datapoint:this.selectedSeries,series:this.absoluteDataset,bars:this.barSet,lines:this.lineSet,plots:this.plotSet,config:this.FINAL_CONFIG}):(n&&n.text&&this.FINAL_CONFIG.chart.tooltip.showTimeLabel&&(l+=`<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${this.FINAL_CONFIG.chart.tooltip.borderColor}; width:100%">${n.text}</div>`),this.selectedSeries.forEach(r=>{if(this.isSafeValue(r.value)){let e="",x="";switch(this.icons[r.type]){case"bar":e=`<svg viewBox="0 0 40 40" height="14" width="14">${this.$slots.pattern?`<rect x="0" y="0" rx="1" stroke="none" height="40" width="40" fill="${r.color}" />`:""}<rect x="0" y="0" rx="1" stroke="none" height="40" width="40" fill="${this.$slots.pattern?`url(#pattern_${this.uniqueId}_${r.slotAbsoluteIndex}`:r.color}" /></svg>`;break;case"line":!r.shape||!["star","triangle","square","diamond","pentagon","hexagon"].includes(r.shape)?x=`<circle cx="10" cy="8" r="4" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" fill="${r.color}" />`:r.shape==="triangle"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:3,rotation:.52}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="square"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:4,rotation:.8}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="diamond"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:4,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="pentagon"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:5,rotation:.95}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="hexagon"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:6,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="star"&&(x=`<polygon stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" fill="${r.color}" points="${d.createStar({plot:{x:10,y:8},radius:4})}" />`),e=`<svg viewBox="0 0 20 12" height="14" width="20"><rect rx="1.5" x="0" y="6.5" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" height="3" width="20" fill="${r.color}" />${x}</svg>`;break;case"plot":if(!r.shape||!["star","triangle","square","diamond","pentagon","hexagon"].includes(r.shape)){e=`<svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${r.color}" /></svg>`;break}if(r.shape==="star"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><polygon stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${r.color}" points="${d.createStar({plot:{x:6,y:6},radius:5})}" /></svg>`;break}if(r.shape==="triangle"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:6,sides:3,rotation:.52}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="square"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:6,sides:4,rotation:.8}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="diamond"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:5,sides:4,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="pentagon"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:5,sides:5,rotation:.95}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="hexagon"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:5,sides:6,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}}l+=`<div style="display:flex;flex-direction:row; align-items:center;gap:3px;"><div style="width:20px">${e}</div> ${r.name}: <b>${this.FINAL_CONFIG.chart.tooltip.showValue?this.applyDataLabel(r.type==="line"?this.FINAL_CONFIG.line.labels.formatter:r.type==="bar"?this.FINAL_CONFIG.bar.labels.formatter:this.FINAL_CONFIG.plot.labels.formatter,r.value,this.dataLabel({p:r.prefix,v:r.value,s:r.suffix,r:this.FINAL_CONFIG.chart.tooltip.roundingValue}),{datapoint:r}):""}</b> ${this.FINAL_CONFIG.chart.tooltip.showPercentage?`(${d.dataLabel({v:this.checkNaN(Math.abs(r.value)/i*100),s:"%",r:this.FINAL_CONFIG.chart.tooltip.roundingPercentage})})`:""}</div>`,this.FINAL_CONFIG.chart.comments.showInTooltip&&r.comments.length&&r.comments.slice(this.slicer.start,this.slicer.end)[this.selectedSerieIndex]&&(l+=`<div class="vue-data-ui-tooltip-comment" style="background:${r.color}20; padding: 6px; margin-bottom: 6px; border-left: 1px solid ${r.color}">${r.comments.slice(this.slicer.start,this.slicer.end)[this.selectedSerieIndex]}</div>`)}}),`<div style="border-radius:4px;padding:12px;font-variant-numeric: tabular-nums;color:${this.FINAL_CONFIG.chart.tooltip.color}">${l}</div>`)},svg(){return{height:this.height,width:this.width}},yLabels(){return this.niceScale.ticks.map(l=>({y:l>=0?this.zero-this.drawingArea.height*this.ratioToMax(l):this.zero+this.drawingArea.height*this.ratioToMax(Math.abs(l)),value:l,prefix:this.FINAL_CONFIG.chart.labels.prefix,suffix:this.FINAL_CONFIG.chart.labels.suffix}))},zero(){return this.drawingArea.bottom-this.drawingArea.height*this.ratioToMax(this.relativeZero)}},mounted(){this.svgRef=this.$refs.svgRef,this.prepareChart(),this.setupSlicer(),document.addEventListener("mousemove",l=>{this.clientPosition={x:l.clientX,y:l.clientY}}),document.addEventListener("scroll",this.hideTags)},beforeUnmount(){document.removeEventListener("scroll",this.hideTags)},methods:{abbreviate:d.abbreviate,adaptColorToBackground:d.adaptColorToBackground,applyDataLabel:d.applyDataLabel,assignStackRatios:d.assignStackRatios,calcLinearProgression:d.calcLinearProgression,calculateNiceScaleWithExactExtremes:d.calculateNiceScaleWithExactExtremes,checkNaN:d.checkNaN,closestDecimal:d.closestDecimal,convertColorToHex:d.convertColorToHex,convertConfigColors:d.convertConfigColors,convertCustomPalette:d.convertCustomPalette,createCsvContent:d.createCsvContent,createSmoothPath:d.createSmoothPath,createStraightPath:d.createStraightPath,createTSpans:d.createTSpans,dataLabel:d.dataLabel,downloadCsv:d.downloadCsv,error:d.error,forceValidValue:d.forceValidValue,functionReturnsString:d.functionReturnsString,hasDeepProperty:d.hasDeepProperty,isFunction:d.isFunction,isSafeValue:d.isSafeValue,largestTriangleThreeBucketsArray:d.largestTriangleThreeBucketsArray,objectIsEmpty:d.objectIsEmpty,setOpacity:d.setOpacity,shiftHue:d.shiftHue,translateSize:d.translateSize,treeShake:d.treeShake,useMouse:G.useMouse,useNestedProp:v.useNestedProp,createUid:d.createUid,placeXYTag:d.placeXYTag,hideTags(){const l=document.querySelectorAll(".vue-ui-xy-tag");l.length&&Array.from(l).forEach(i=>i.style.opacity="0")},setTagRef(l,i,n,h,r){n&&(this.tagRefs[`${l}_${i}_${h}_${r}`]=n)},setUserOptionsVisibility(l=!1){this.showUserOptionsOnChartHover&&(this.userOptionsVisible=l)},toggleAnnotator(){this.isAnnotator=!this.isAnnotator},selectTimeLabel(l,i){const n=this.relativeDataset.map(h=>({shape:h.shape||null,name:h.name,color:h.color,type:h.type,value:h.absoluteValues.find((r,e)=>e===i),comments:h.comments||[],prefix:h.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:h.suffix||this.FINAL_CONFIG.chart.labels.suffix}));this.$emit("selectTimeLabel",{datapoint:n,absoluteIndex:l.absoluteIndex,label:l.text})},getHighlightAreaPosition(l){const i=this.drawingArea.left+this.drawingArea.width/this.maxSeries*(l.from-this.slicer.start),n=this.drawingArea.width/(this.slicer.end-this.slicer.start)*l.span<0?1e-5:this.drawingArea.width/(this.slicer.end-this.slicer.start)*l.span;return{x:i<this.drawingArea.left?this.drawingArea.left:i,width:n}},prepareConfig(){const l=d.useConfig().vue_ui_xy;if(!Object.keys(this.config||{}).length)return l;const i=this.useNestedProp({userConfig:this.config,defaultConfig:l});return this.config&&this.hasDeepProperty(this.config,"chart.highlightArea")&&(Array.isArray(this.config.chart.highlightArea)?i.chart.highlightArea=this.config.chart.highlightArea:i.chart.highlightArea=[this.config.chart.highlightArea]),this.config&&this.hasDeepProperty(this.config,"chart.grid.labels.yAxis.scaleMin")?i.chart.grid.labels.yAxis.scaleMin=this.config.chart.grid.labels.yAxis.scaleMin:i.chart.grid.labels.yAxis.scaleMin=null,this.config&&this.hasDeepProperty(this.config,"chart.grid.labels.yAxis.scaleMax")?i.chart.grid.labels.yAxis.scaleMax=this.config.chart.grid.labels.yAxis.scaleMax:i.chart.grid.labels.yAxis.scaleMax=null,this.config&&this.hasDeepProperty(this.config,"chart.zoom.startIndex")?i.chart.zoom.startIndex=this.config.chart.zoom.startIndex:i.chart.zoom.startIndex=null,this.config&&this.hasDeepProperty(this.config,"chart.zoom.endIndex")?i.chart.zoom.endIndex=this.config.chart.zoom.endIndex:i.chart.zoom.endIndex=null,this.config&&this.hasDeepProperty(this.config,"chart.grid.labels.yAxis.groupColor")?i.chart.grid.labels.yAxis.groupColor=this.config.chart.grid.labels.yAxis.groupColor:i.chart.grid.labels.yAxis.groupColor=null,i.theme?{...v.useNestedProp({userConfig:this.themes.vue_ui_xy[i.theme]||this.config,defaultConfig:i}),customPalette:this.themePalettes[i.theme]||this.palette}:i},prepareChart(){if(this.objectIsEmpty(this.dataset)?this.error({componentName:"VueUiXy",type:"dataset"}):this.dataset.forEach((l,i)=>{[null,void 0].includes(l.name)&&this.error({componentName:"VueUiXy",type:"datasetSerieAttribute",property:"name (string)",index:i})}),this.FINAL_CONFIG.showWarnings&&this.dataset.forEach(l=>{l.series.forEach((i,n)=>{this.isSafeValue(i)||console.warn(`VueUiXy has detected an unsafe value in your dataset:
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("./index-FtxQWcA1.cjs"),B=require("./DataTable-B8Ui_Pd4.cjs"),E=require("./Title-CFmNnjPN.cjs"),G=require("./Tooltip-UBWsyt1M.cjs"),V=require("./usePrinter-BUMwWyWM.cjs"),z=require("./Shape-DomxDqtX.cjs"),M=require("./BaseIcon-BpdQLb-0.cjs"),T=require("./vue-ui-table-sparkline-idKvXcFK.cjs"),P=require("./vue-ui-skeleton-CX4m8kLi.cjs"),R=require("./Slicer-DlCXj2P9.cjs"),D=require("./vue-ui-accordion-BIBhKMbJ.cjs"),v=require("./useNestedProp-BIeXIQxH.cjs"),H=require("./PackageVersion-Da8iEjju.cjs"),q=require("./PenAndPaper-Dpjaroq-.cjs"),t=require("vue"),W=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Y=d.createUid(),X={name:"vue-ui-xy",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},components:{DataTable:B.DataTable,Shape:z._sfc_main,Title:E._sfc_main,Tooltip:G._sfc_main,UserOptions:V.UserOptions,BaseIcon:M.default,TableSparkline:T.default,Skeleton:P.default,Slicer:R.Slicer,Accordion:D.default,PackageVersion:H._sfc_main,PenAndPaper:q.PenAndPaper},data(){this.dataset.forEach((h,r)=>{[null,void 0].includes(h.series)&&this.error({componentName:"VueUiXy",type:"datasetSerieAttribute",property:"series (number[])",index:r})});const l=this.config.downsample&&this.config.downsample.threshold?this.config.downsample.threshold:500,i=Math.max(...this.dataset.map(h=>this.largestTriangleThreeBucketsArray({data:h.series,threshold:l}).length)),n={start:0,end:i};return{themePalettes:d.themePalettes,themes:d.themes,slicerStep:0,selectedScale:null,CTX:null,CANVAS:null,opacity:d.opacity,useSafeValues:!0,palette:d.palette,height:600,width:1e3,viewBox:"0 0 1000 600",clientPosition:{x:0,y:0},canvasClientPosition:{x:0,y:0},icons:{line:"line",bar:"bar",plot:"plot"},isAnnotator:!1,isFullscreen:!1,isPrinting:!1,isImaging:!1,isTooltip:!1,mutableConfig:{dataLabels:{show:!0},showTooltip:!0,showTable:!1,isStacked:!1,useIndividualScale:!1},selectedSerieIndex:null,selectedRowIndex:null,segregatedSeries:[],uniqueId:d.createUid(),step:0,tableStep:0,titleStep:0,slicer:n,__to__:null,maxX:i,showSparklineTable:!0,segregateStep:0,sliderId:Y,fontSizes:{xAxis:18,yAxis:12,dataLabels:20,plotLabels:10},plotRadii:{plot:3,line:3},selectedMinimapIndex:null,showUserOptionsOnChartHover:!1,keepUserOptionState:!0,userOptionsVisible:!0,svgRef:null,tagRefs:{}}},watch:{dataset:{handler(l,i){this.maxX=Math.max(...this.dataset.map(n=>this.largestTriangleThreeBucketsArray({data:n.series,threshold:this.FINAL_CONFIG.downsample.threshold}).length)),this.slicer={start:0,end:this.maxX},this.slicerStep+=1,this.segregateStep+=1},deep:!0},config:{handler(l,i){this.FINAL_CONFIG=this.prepareConfig(),this.prepareChart(),this.titleStep+=1,this.tableStep+=1,this.mutableConfig={dataLabels:{show:!0},showTooltip:this.FINAL_CONFIG.chart.tooltip.show===!0,showTable:this.FINAL_CONFIG.showTable===!0,isStacked:this.FINAL_CONFIG.chart.grid.labels.yAxis.stacked,useIndividualScale:this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale}},deep:!0}},computed:{chartAriaLabel(){const l=this.FINAL_CONFIG.chart.title.text||"Chart visualization",i=this.FINAL_CONFIG.chart.title.subtitle.text||"";return`${l}. ${i}`},optimize(){return{linePlot:this.maxSeries>this.FINAL_CONFIG.line.dot.hideAboveMaxSerieLength}},hasOptionsNoTitle(){return this.FINAL_CONFIG.chart.userOptions.show&&(!this.FINAL_CONFIG.chart.title.show||!this.FINAL_CONFIG.chart.title.text)},minimap(){if(!this.FINAL_CONFIG.chart.zoom.minimap.show)return[];const l=this.datasetWithIds.filter(r=>!this.segregatedSeries.includes(r.id)),i=Math.max(...l.map(r=>r.series.length)),n=[];for(let r=0;r<i;r+=1)n.push(l.map(e=>e.series[r]||0).reduce((e,x)=>(e||0)+(x||0),0));const h=Math.min(...n);return n.map(r=>r+(h<0?Math.abs(h):0))},customPalette(){return this.convertCustomPalette(this.FINAL_CONFIG.customPalette)},backgroundColor(){return this.FINAL_CONFIG.chart.backgroundColor},slicerColor(){return this.FINAL_CONFIG.chart.zoom.color},allScales(){const l=this.lineSet.map(e=>({name:e.name,color:e.color,scale:e.individualScale,scaleYLabels:e.scaleYLabels,zero:e.zeroPosition,max:e.individualMax,scaleLabel:e.scaleLabel||"",id:e.id,yOffset:e.yOffset||0,individualHeight:e.individualHeight||this.drawingArea.height,autoScaleYLabels:e.autoScaleYLabels})),i=this.barSet.map(e=>({name:e.name,color:e.color,scale:e.individualScale,scaleYLabels:e.scaleYLabels,zero:e.zeroPosition,max:e.individualMax,scaleLabel:e.scaleLabel||"",id:e.id,yOffset:e.yOffset||0,individualHeight:e.individualHeight||this.drawingArea.height})),n=this.plotSet.map(e=>({name:e.name,color:e.color,scale:e.individualScale,scaleYLabels:e.scaleYLabels,zero:e.zeroPosition,max:e.individualMax,scaleLabel:e.scaleLabel||"",id:e.id,yOffset:e.yOffset||0,individualHeight:e.individualHeight||this.drawingArea.height})),h=this.mutableConfig.useIndividualScale&&!this.mutableConfig.isStacked?Object.values(this.scaleGroups):[...l,...i,...n],r=h.flatMap(e=>e).length;return h.flatMap((e,x)=>({unique:e.unique,id:e.id,groupId:e.groupId,scaleLabel:e.scaleLabel,name:this.mutableConfig.useIndividualScale&&!this.mutableConfig.isStacked?e.unique?e.name:e.groupName:e.name,color:this.mutableConfig.useIndividualScale&&!this.mutableConfig.isStacked?e.unique?e.color:e.groupColor:e.color,scale:e.scale,yOffset:e.yOffset,individualHeight:e.individualHeight,x:this.mutableConfig.isStacked?this.drawingArea.left:this.drawingArea.left/r*(x+1),yLabels:e.scaleYLabels||e.scale.ticks.map(g=>({y:g>=0?e.zero-e.individualHeight*(g/e.max):e.zero+e.individualHeight*Math.abs(g)/e.max,value:g}))}))},isDataset(){return!!this.dataset&&this.dataset.length},chartFont(){const l=document.getElementById(`vue-ui-xy_${this.uniqueId}`);return window.getComputedStyle(l,null).getPropertyValue("font-family")},FINAL_CONFIG:{get:function(){return this.prepareConfig()},set:function(l){return l}},hasHighlightArea(){return Array.isArray(this.FINAL_CONFIG.chart.highlightArea)?this.FINAL_CONFIG.chart.highlightArea.some(l=>l.show):this.FINAL_CONFIG.chart.highlightArea&&this.FINAL_CONFIG.chart.highlightArea.show},highlightAreas(){if(Array.isArray(this.FINAL_CONFIG.chart.highlightArea))return this.FINAL_CONFIG.chart.highlightArea.map(i=>({...i,span:i.from===i.to?1:i.to<i.from?0:i.to-i.from+1}));const l=this.FINAL_CONFIG.chart.highlightArea;return[{...l,span:l.from===l.to?1:l.to<l.from?0:l.to-l.from+1}]},xPadding(){return this.FINAL_CONFIG.chart.grid.position==="middle"?0:this.drawingArea.width/this.maxSeries/2},relativeZero(){return[null,void 0].includes(this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin)?this.niceScale.min>=0?0:Math.abs(this.niceScale.min):-this.niceScale.min},absoluteMax(){return this.niceScale.max+this.relativeZero},datasetWithIds(){return this.useSafeValues?this.dataset.map((l,i)=>({...l,series:this.largestTriangleThreeBucketsArray({data:l.series,threshold:this.FINAL_CONFIG.downsample.threshold}),id:`uniqueId_${i}`})):this.dataset},safeDataset(){return this.useSafeValues?this.dataset.map((l,i)=>{const n=this.largestTriangleThreeBucketsArray({data:l.series,threshold:this.FINAL_CONFIG.downsample.threshold}),h=`uniqueId_${i}`;return{...l,slotAbsoluteIndex:i,series:n.map(r=>this.isSafeValue(r)?r:null).slice(this.slicer.start,this.slicer.end),color:this.convertColorToHex(l.color?l.color:this.customPalette[i]?this.customPalette[i]:this.palette[i]),id:h,scaleLabel:l.scaleLabel||h}}):this.dataset},relativeDataset(){return this.safeDataset.map((l,i)=>({...l,series:l.series.map(n=>n+this.relativeZero),absoluteValues:l.series})).filter(l=>!this.segregatedSeries.includes(l.id))},tableSparklineDataset(){return this.relativeDataset.map(l=>{const i=l.absoluteValues.map(n=>[void 0,null].includes(n)?0:n);return{id:l.id,name:l.name,color:l.color,values:this.fillArray(this.maxSeries,i)}})},tableSparklineConfig(){return{responsiveBreakpoint:this.FINAL_CONFIG.table.responsiveBreakpoint,roundingValues:this.FINAL_CONFIG.table.rounding,showAverage:!1,showMedian:!1,showTotal:!1,fontFamily:this.FINAL_CONFIG.chart.fontFamily,prefix:this.FINAL_CONFIG.chart.labels.prefix,suffix:this.FINAL_CONFIG.chart.labels.suffix,colNames:JSON.parse(JSON.stringify(this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values)),thead:{backgroundColor:this.FINAL_CONFIG.table.th.backgroundColor,color:this.FINAL_CONFIG.table.th.color,outline:this.FINAL_CONFIG.table.th.outline},tbody:{backgroundColor:this.FINAL_CONFIG.table.td.backgroundColor,color:this.FINAL_CONFIG.table.td.color,outline:this.FINAL_CONFIG.table.td.outline},userOptions:{show:!1}}},absoluteDataset(){return this.safeDataset.map((l,i)=>({absoluteIndex:i,...l,series:l.series.map(n=>n+this.relativeZero),absoluteValues:l.series,segregate:()=>this.segregate(l),isSegregated:this.segregatedSeries.includes(l.id)}))},activeSeriesLength(){return this.absoluteDataset.length},activeSeriesWithStackRatios(){return this.assignStackRatios(this.absoluteDataset.filter(l=>!this.segregatedSeries.includes(l.id)))},scaleGroups(){const l=Object.groupBy(this.activeSeriesWithStackRatios,n=>n.scaleLabel),i={};for(const[n,h]of Object.entries(l)){const r=h.flatMap(e=>e.absoluteValues);i[n]={min:Math.min(...r)||0,max:Math.max(...r)||1,groupId:`scale_group_${this.createUid()}`}}return i},barSet(){return this.activeSeriesWithStackRatios.filter(l=>l.type==="bar").map((l,i)=>{this.checkAutoScaleError(l);const n=this.scaleGroups[l.scaleLabel].min,h=this.scaleGroups[l.scaleLabel].max;l.absoluteValues.filter(N=>![null,void 0].includes(N)).map(N=>(N-n)/(h-n));const r={valueMin:n,valueMax:h<0?0:h},e={max:l.scaleMax||Math.max(...l.absoluteValues)||1,min:l.scaleMin||Math.min(...l.absoluteValues.filter(N=>![void 0,null].includes(N)))>0?0:Math.min(...l.absoluteValues.filter(N=>![null,void 0].includes(N)))},x=l.scaleSteps||this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps,g=1.0000001,u=this.calculateNiceScaleWithExactExtremes(e.min,e.max===e.min?e.max*g:e.max,x),b=this.calculateNiceScaleWithExactExtremes(r.valueMin,r.valueMax===r.valueMin?r.valueMax*g:r.valueMax,x),L=u.min>=0?0:Math.abs(u.min),_=0,C=u.max+L,y=b.max+Math.abs(_),m=this.mutableConfig.isStacked?this.drawingArea.height*(1-l.cumulatedStackRatio):0,F=this.mutableConfig.isStacked?this.drawingArea.height*l.stackRatio-this.FINAL_CONFIG.chart.grid.labels.yAxis.gap:this.drawingArea.height,A=this.drawingArea.bottom-m-F*L/C,O=this.drawingArea.bottom-m-F*_/y,a=this.absoluteDataset.filter(N=>N.type==="bar").filter(N=>!this.segregatedSeries.includes(N.id)).length,o=l.series.map((N,w)=>{const I=this.mutableConfig.useIndividualScale?(l.absoluteValues[w]+L)/C:this.ratioToMax(N),k=this.mutableConfig.useIndividualScale&&this.mutableConfig.isStacked?this.drawingArea.left+this.drawingArea.width/this.maxSeries*w:this.drawingArea.left+this.slot.bar*i+this.slot.bar*w*a-this.barSlot/2-i*this.barPeriodGap;return{yOffset:this.checkNaN(m),individualHeight:this.checkNaN(F),x:this.checkNaN(k),y:this.drawingArea.bottom-m-F*I,value:l.absoluteValues[w],zeroPosition:this.checkNaN(A),individualMax:this.checkNaN(C),comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[w]||""}}),s=l.absoluteValues.map(N=>b.min>=0?(N-Math.abs(b.min))/(b.max-Math.abs(b.min)):(N+Math.abs(b.min))/(b.max+Math.abs(b.min))),c=l.series.map((N,w)=>{const I=this.mutableConfig.useIndividualScale&&this.mutableConfig.isStacked?this.drawingArea.left+this.drawingArea.width/this.maxSeries*w:this.drawingArea.left-this.slot.bar/2+this.slot.bar*i+this.slot.bar*w*this.absoluteDataset.filter(k=>k.type==="bar").filter(k=>!this.segregatedSeries.includes(k.id)).length;return{yOffset:this.checkNaN(m),individualHeight:this.checkNaN(F),x:this.checkNaN(I),y:this.checkNaN(this.drawingArea.bottom-this.checkNaN(m)-(this.checkNaN(F)*s[w]||0)),value:l.absoluteValues[w],zeroPosition:this.checkNaN(A),individualMax:this.checkNaN(C),comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[w]||""}}),f=u.ticks.map(N=>({y:N>=0?A-F*(N/C):A+F*Math.abs(N)/C,value:N,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l})),S=b.ticks.map(N=>{const w=(N-b.min)/(b.max-b.min);return{y:N>=0?O-F*w:O+F*w,value:N,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l}});return this.scaleGroups[l.scaleLabel].name=l.name,this.scaleGroups[l.scaleLabel].groupName=l.scaleLabel,this.scaleGroups[l.scaleLabel].groupColor=this.FINAL_CONFIG.chart.grid.labels.yAxis.groupColor||l.color,this.scaleGroups[l.scaleLabel].color=l.color,this.scaleGroups[l.scaleLabel].scaleYLabels=l.autoScaling?S:f,this.scaleGroups[l.scaleLabel].zeroPosition=l.autoScaling?O:A,this.scaleGroups[l.scaleLabel].individualMax=l.autoScaling?y:C,this.scaleGroups[l.scaleLabel].scaleLabel=l.scaleLabel,this.scaleGroups[l.scaleLabel].id=l.id,this.scaleGroups[l.scaleLabel].yOffset=m,this.scaleGroups[l.scaleLabel].individualHeight=F,this.scaleGroups[l.scaleLabel].autoScaleYLabels=S,this.scaleGroups[l.scaleLabel].unique=this.activeSeriesWithStackRatios.filter(N=>N.scaleLabel===l.scaleLabel).length===1,{...l,yOffset:m,autoScaleYLabels:S,individualHeight:F,scaleYLabels:l.autoScaling?S:f,individualScale:l.autoScaling?b:u,individualMax:l.autoScaling?y:C,zeroPosition:l.autoScaling?O:A,plots:l.autoScaling?c:o,groupId:this.scaleGroups[l.scaleLabel].groupId}})},lineSet(){return this.activeSeriesWithStackRatios.filter(l=>l.type==="line").map(l=>{this.checkAutoScaleError(l);const i=this.scaleGroups[l.scaleLabel].min,n=this.scaleGroups[l.scaleLabel].max;l.absoluteValues.filter(I=>![null,void 0].includes(I)).map(I=>(I-i)/(n-i));const h={valueMin:i,valueMax:n},r={max:l.scaleMax||Math.max(...l.absoluteValues)||1,min:l.scaleMin||(Math.min(...l.absoluteValues)>0?0:Math.min(...l.absoluteValues))},e=l.scaleSteps||this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps,x=1.0000001,g=this.calculateNiceScaleWithExactExtremes(r.min,r.max===r.min?r.max*x:r.max,e),u=this.calculateNiceScaleWithExactExtremes(h.valueMin,h.valueMax===h.valueMin?h.valueMax*x:h.valueMax,e),b=g.min>=0?0:Math.abs(g.min),L=0,_=g.max+Math.abs(b),C=u.max+Math.abs(L),y=this.mutableConfig.isStacked?this.drawingArea.height*(1-l.cumulatedStackRatio):0,m=this.mutableConfig.isStacked?this.drawingArea.height*l.stackRatio-this.FINAL_CONFIG.chart.grid.labels.yAxis.gap:this.drawingArea.height,F=this.drawingArea.bottom-y-m*b/_,A=this.drawingArea.bottom-y-m*L/C,O=l.series.map((I,k)=>{const p=this.mutableConfig.useIndividualScale?(l.absoluteValues[k]+Math.abs(b))/_:this.ratioToMax(I);return{x:this.checkNaN(this.drawingArea.left+this.slot.line/2+this.slot.line*k),y:this.checkNaN(this.drawingArea.bottom-y-m*p),value:l.absoluteValues[k],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[k]||""}}),a=l.absoluteValues.map(I=>u.min>=0?(I-Math.abs(u.min))/(u.max-Math.abs(u.min)):(I+Math.abs(u.min))/(u.max+Math.abs(u.min))),o=l.series.map((I,k)=>[void 0,null].includes(l.absoluteValues[k])?{x:this.checkNaN(this.drawingArea.left+this.slot.line/2+this.slot.line*k),y:F,value:l.absoluteValues[k],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[k]||""}:{x:this.checkNaN(this.drawingArea.left+this.slot.line/2+this.slot.line*k),y:this.checkNaN(this.drawingArea.bottom-y-(m*a[k]||0)),value:l.absoluteValues[k],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[k]||""}),s=this.createSmoothPath(O.filter(I=>I.value!==null)),c=this.createSmoothPath(o.filter(I=>I.value!==null)),f=this.createStraightPath(O.filter(I=>I.value!==null)),S=this.createStraightPath(o.filter(I=>I.value!==null)),N=g.ticks.map(I=>({y:I>=0?F-m*(I/_):F+m*Math.abs(I)/_,value:I,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l})),w=u.ticks.map(I=>{const k=(I-u.min)/(u.max-u.min);return{y:I>=0?A-m*k:A+m*k,value:I,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l}});return this.scaleGroups[l.scaleLabel].name=l.name,this.scaleGroups[l.scaleLabel].groupName=l.scaleLabel,this.scaleGroups[l.scaleLabel].groupColor=this.FINAL_CONFIG.chart.grid.labels.yAxis.groupColor||l.color,this.scaleGroups[l.scaleLabel].color=l.color,this.scaleGroups[l.scaleLabel].scaleYLabels=l.autoScaling?w:N,this.scaleGroups[l.scaleLabel].zeroPosition=l.autoScaling?A:F,this.scaleGroups[l.scaleLabel].individualMax=l.autoScaling?C:_,this.scaleGroups[l.scaleLabel].scaleLabel=l.scaleLabel,this.scaleGroups[l.scaleLabel].id=l.id,this.scaleGroups[l.scaleLabel].yOffset=y,this.scaleGroups[l.scaleLabel].individualHeight=m,this.scaleGroups[l.scaleLabel].autoScaleYLabels=w,this.scaleGroups[l.scaleLabel].unique=this.activeSeriesWithStackRatios.filter(I=>I.scaleLabel===l.scaleLabel).length===1,{...l,yOffset:y,autoScaleYLabels:w,individualHeight:m,scaleYLabels:l.autoScaling?w:N,individualScale:l.autoScaling?u:g,individualMax:l.autoScaling?C:_,zeroPosition:l.autoScaling?A:F,curve:l.autoScaling?c:s,plots:l.autoScaling?o:O,area:l.useArea?this.mutableConfig.useIndividualScale?this.createIndividualArea(l.autoScaling?o:O,l.autoScaling?A:F):this.createArea(O):"",straight:l.autoScaling?S:f,groupId:this.scaleGroups[l.scaleLabel].groupId}})},plotSet(){return this.activeSeriesWithStackRatios.filter(l=>l.type==="plot").map(l=>{this.checkAutoScaleError(l);const i=this.scaleGroups[l.scaleLabel].min,n=this.scaleGroups[l.scaleLabel].max;l.absoluteValues.filter(f=>![null,void 0].includes(f)).map(f=>(f-i)/(n-i));const h={valueMin:i,valueMax:n},r={max:l.scaleMax||Math.max(...l.absoluteValues)||1,min:l.scaleMin||Math.min(...l.absoluteValues)>0?0:Math.min(...l.absoluteValues)},e=l.scaleSteps||this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps,x=1.0000001,g=this.calculateNiceScaleWithExactExtremes(r.min,r.max===r.min?r.max*x:r.max,e),u=this.calculateNiceScaleWithExactExtremes(h.valueMin,h.valueMax===h.valueMin?h.valueMax*x:h.valueMax,e),b=g.min>=0?0:Math.abs(g.min),L=0,_=g.max+b,C=u.max+Math.abs(L),y=this.mutableConfig.isStacked?this.drawingArea.height*(1-l.cumulatedStackRatio):0,m=this.mutableConfig.isStacked?this.drawingArea.height*l.stackRatio-this.FINAL_CONFIG.chart.grid.labels.yAxis.gap:this.drawingArea.height,F=this.drawingArea.bottom-y-m*b/_,A=this.drawingArea.bottom-y-m*L/C,O=l.series.map((f,S)=>{const N=this.mutableConfig.useIndividualScale?(l.absoluteValues[S]+Math.abs(b))/_:this.ratioToMax(f);return{x:this.checkNaN(this.drawingArea.left+this.slot.plot/2+this.slot.plot*S),y:this.checkNaN(this.drawingArea.bottom-y-m*N),value:l.absoluteValues[S],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[S]||""}}),a=l.absoluteValues.map(f=>u.min>=0?(f-Math.abs(u.min))/(u.max-Math.abs(u.min)):(f+Math.abs(u.min))/(u.max+Math.abs(u.min))),o=l.series.map((f,S)=>({x:this.checkNaN(this.drawingArea.left+this.slot.plot/2+this.slot.plot*S),y:this.checkNaN(this.drawingArea.bottom-y-(m*a[S]||0)),value:l.absoluteValues[S],comment:l.comments&&l.comments.slice(this.slicer.start,this.slicer.end)[S]||""})),s=g.ticks.map(f=>({y:f>=0?F-m*(f/_):F+m*Math.abs(f)/_,value:f,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l})),c=u.ticks.map(f=>{const S=(f-u.min)/(u.max-u.min);return{y:f>=0?A-m*S:A+m*S,value:f,prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix,datapoint:l}});return this.scaleGroups[l.scaleLabel].name=l.name,this.scaleGroups[l.scaleLabel].groupName=l.scaleLabel,this.scaleGroups[l.scaleLabel].groupColor=this.FINAL_CONFIG.chart.grid.labels.yAxis.groupColor||l.color,this.scaleGroups[l.scaleLabel].color=l.color,this.scaleGroups[l.scaleLabel].scaleYLabels=l.autoScaling?c:s,this.scaleGroups[l.scaleLabel].zeroPosition=l.autoScaling?A:F,this.scaleGroups[l.scaleLabel].individualMax=l.autoScaling?C:_,this.scaleGroups[l.scaleLabel].scaleLabel=l.scaleLabel,this.scaleGroups[l.scaleLabel].id=l.id,this.scaleGroups[l.scaleLabel].yOffset=y,this.scaleGroups[l.scaleLabel].individualHeight=m,this.scaleGroups[l.scaleLabel].autoScaleYLabels=c,this.scaleGroups[l.scaleLabel].unique=this.activeSeriesWithStackRatios.filter(f=>f.scaleLabel===l.scaleLabel).length===1,{...l,yOffset:y,autoScaleYLabels:c,individualHeight:m,scaleYLabels:l.autoScaling?c:s,individualScale:l.autoScaling?u:g,individualMax:l.autoScaling?C:_,zeroPosition:l.autoScaling?A:F,plots:l.autoScaling?o:O,groupId:this.scaleGroups[l.scaleLabel].groupId}})},drawingArea(){function l(h){const r=new Set;return h.forEach(e=>{const x=e.scaleLabel||"__noScaleLabel__";r.add(x)}),r.size}const i=l(this.absoluteDataset.filter(h=>!this.segregatedSeries.includes(h.id))),n=this.mutableConfig.useIndividualScale&&this.FINAL_CONFIG.chart.grid.labels.show?i*(this.mutableConfig.isStacked?0:this.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth):0;return{top:this.FINAL_CONFIG.chart.padding.top,right:this.width-this.FINAL_CONFIG.chart.padding.right,bottom:this.height-this.FINAL_CONFIG.chart.padding.bottom,left:this.FINAL_CONFIG.chart.padding.left+n,height:this.height-(this.FINAL_CONFIG.chart.padding.top+this.FINAL_CONFIG.chart.padding.bottom),width:this.width-(this.FINAL_CONFIG.chart.padding.right+this.FINAL_CONFIG.chart.padding.left+n)}},max(){return this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMax?this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMax:Math.max(...this.safeDataset.filter(l=>!this.segregatedSeries.includes(l.id)).map(l=>Math.max(...l.series)))},min(){if(this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin!==null)return this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin;const l=Math.min(...this.safeDataset.filter(i=>!this.segregatedSeries.includes(i.id)).map(i=>Math.min(...i.series)));return l>0?0:l},niceScale(){return this.calculateNiceScaleWithExactExtremes(this.min,this.max<0?0:this.max,this.FINAL_CONFIG.chart.grid.labels.yAxis.commonScaleSteps)},maxSeries(){return this.slicer.end-this.slicer.start},timeLabels(){const l=Math.max(...this.dataset.map(n=>this.largestTriangleThreeBucketsArray({data:n.series,threshold:this.FINAL_CONFIG.downsample.threshold}).length)),i=[];for(let n=0;n<l;n+=1)i.push({text:this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[n]||String(n),absoluteIndex:n});return i.slice(this.slicer.start,this.slicer.end)},slot(){return{bar:this.drawingArea.width/this.maxSeries/this.safeDataset.filter(l=>l.type==="bar").filter(l=>!this.segregatedSeries.includes(l.id)).length,plot:this.drawingArea.width/this.maxSeries,line:this.drawingArea.width/this.maxSeries}},barSlot(){const l=this.safeDataset.filter(i=>i.type==="bar").filter(i=>!this.segregatedSeries.includes(i.id)).length;return this.drawingArea.width/this.maxSeries/l-this.barPeriodGap*l},barPeriodGap(){return this.slot.line*this.FINAL_CONFIG.bar.periodGap},maxSlot(){return Math.max(...Object.values(this.slot).filter(l=>l!==1/0))},table(){if(this.safeDataset.length===0)return{head:[],body:[],config:{},columnNames:[]};const l=this.relativeDataset.map(n=>({label:n.name,color:n.color,type:n.type})),i=[];return this.timeLabels.forEach((n,h)=>{const r=[n.text];this.relativeDataset.forEach(e=>{r.push(this.canShowValue(e.absoluteValues[h])?Number(e.absoluteValues[h].toFixed(this.FINAL_CONFIG.table.rounding)):"")}),i.push(r)}),{head:l,body:i}},dataTable(){const l=this.FINAL_CONFIG.table.showSum;let i=[""].concat(this.relativeDataset.map(e=>e.name));l&&(i=i.concat(' <svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor" fill="none" stroke-linecap="round" stroke-linejoin="round"><path stroke="none" d="M0 0h24v24H0z" fill="none"/><path d="M18 16v2a1 1 0 0 1 -1 1h-11l6 -7l-6 -7h11a1 1 0 0 1 1 1v2" /></svg>'));let n=[];for(let e=0;e<this.maxSeries;e+=1){const x=this.relativeDataset.map(g=>g.absoluteValues[e]??0).reduce((g,u)=>g+u,0);n.push([this.timeLabels[e].text??"-"].concat(this.relativeDataset.map(g=>this.applyDataLabel(g.type==="line"?this.FINAL_CONFIG.line.labels.formatter:g.type==="bar"?this.FINAL_CONFIG.bar.labels.formatter:this.FINAL_CONFIG.plot.labels.formatter,g.absoluteValues[e]??0,this.dataLabel({p:g.prefix||this.FINAL_CONFIG.chart.labels.prefix,v:g.absoluteValues[e]??0,s:g.suffix||this.FINAL_CONFIG.chart.labels.suffix,r:this.FINAL_CONFIG.table.rounding})))).concat(l?(x??0).toFixed(this.FINAL_CONFIG.table.rounding):[]))}const h={th:{backgroundColor:this.FINAL_CONFIG.table.th.backgroundColor,color:this.FINAL_CONFIG.table.th.color,outline:this.FINAL_CONFIG.table.th.outline},td:{backgroundColor:this.FINAL_CONFIG.table.td.backgroundColor,color:this.FINAL_CONFIG.table.td.color,outline:this.FINAL_CONFIG.table.td.outline},breakpoint:this.FINAL_CONFIG.table.responsiveBreakpoint},r=[this.FINAL_CONFIG.table.columnNames.period].concat(this.relativeDataset.map(e=>e.name)).concat(this.FINAL_CONFIG.table.columnNames.total);return{head:i,body:n,config:h,colNames:r}},dataTooltipSlot(){return{datapoint:this.selectedSeries,seriesIndex:this.selectedSerieIndex,series:this.absoluteDataset,bars:this.barSet,lines:this.lineSet,plots:this.plotSet,config:this.FINAL_CONFIG}},selectedSeries(){return this.relativeDataset.map(l=>({slotAbsoluteIndex:l.slotAbsoluteIndex,shape:l.shape||null,name:l.name,color:l.color,type:l.type,value:l.absoluteValues.find((i,n)=>n===this.selectedSerieIndex),comments:l.comments||[],prefix:l.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:l.suffix||this.FINAL_CONFIG.chart.labels.suffix}))},tooltipContent(){let l="",i=this.selectedSeries.map(r=>r.value).filter(r=>this.isSafeValue(r)&&r!==null).reduce((r,e)=>Math.abs(r)+Math.abs(e),0);const n=this.timeLabels[this.selectedSerieIndex],h=this.FINAL_CONFIG.chart.tooltip.customFormat;return this.isFunction(h)&&this.functionReturnsString(()=>h({seriesIndex:this.selectedSerieIndex,datapoint:this.selectedSeries,series:this.absoluteDataset,bars:this.barSet,lines:this.lineSet,plots:this.plotSet,config:this.FINAL_CONFIG}))?h({seriesIndex:this.selectedSerieIndex,datapoint:this.selectedSeries,series:this.absoluteDataset,bars:this.barSet,lines:this.lineSet,plots:this.plotSet,config:this.FINAL_CONFIG}):(n&&n.text&&this.FINAL_CONFIG.chart.tooltip.showTimeLabel&&(l+=`<div style="padding-bottom: 6px; margin-bottom: 4px; border-bottom: 1px solid ${this.FINAL_CONFIG.chart.tooltip.borderColor}; width:100%">${n.text}</div>`),this.selectedSeries.forEach(r=>{if(this.isSafeValue(r.value)){let e="",x="";switch(this.icons[r.type]){case"bar":e=`<svg viewBox="0 0 40 40" height="14" width="14">${this.$slots.pattern?`<rect x="0" y="0" rx="1" stroke="none" height="40" width="40" fill="${r.color}" />`:""}<rect x="0" y="0" rx="1" stroke="none" height="40" width="40" fill="${this.$slots.pattern?`url(#pattern_${this.uniqueId}_${r.slotAbsoluteIndex}`:r.color}" /></svg>`;break;case"line":!r.shape||!["star","triangle","square","diamond","pentagon","hexagon"].includes(r.shape)?x=`<circle cx="10" cy="8" r="4" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" fill="${r.color}" />`:r.shape==="triangle"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:3,rotation:.52}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="square"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:4,rotation:.8}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="diamond"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:4,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="pentagon"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:5,rotation:.95}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="hexagon"?x=`<path d="${d.createPolygonPath({plot:{x:10,y:8},radius:4,sides:6,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" />`:r.shape==="star"&&(x=`<polygon stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" fill="${r.color}" points="${d.createStar({plot:{x:10,y:8},radius:4})}" />`),e=`<svg viewBox="0 0 20 12" height="14" width="20"><rect rx="1.5" x="0" y="6.5" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="0.5" height="3" width="20" fill="${r.color}" />${x}</svg>`;break;case"plot":if(!r.shape||!["star","triangle","square","diamond","pentagon","hexagon"].includes(r.shape)){e=`<svg viewBox="0 0 12 12" height="14" width="14"><circle cx="6" cy="6" r="6" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${r.color}" /></svg>`;break}if(r.shape==="star"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><polygon stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" fill="${r.color}" points="${d.createStar({plot:{x:6,y:6},radius:5})}" /></svg>`;break}if(r.shape==="triangle"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:6,sides:3,rotation:.52}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="square"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:6,sides:4,rotation:.8}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="diamond"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:5,sides:4,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="pentagon"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:5,sides:5,rotation:.95}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}if(r.shape==="hexagon"){e=`<svg viewBox="0 0 12 12" height="14" width="14"><path d="${d.createPolygonPath({plot:{x:6,y:6},radius:5,sides:6,rotation:0}).path}" fill="${r.color}" stroke="${this.FINAL_CONFIG.chart.tooltip.backgroundColor}" stroke-width="1" /></svg>`;break}}l+=`<div style="display:flex;flex-direction:row; align-items:center;gap:3px;"><div style="width:20px">${e}</div> ${r.name}: <b>${this.FINAL_CONFIG.chart.tooltip.showValue?this.applyDataLabel(r.type==="line"?this.FINAL_CONFIG.line.labels.formatter:r.type==="bar"?this.FINAL_CONFIG.bar.labels.formatter:this.FINAL_CONFIG.plot.labels.formatter,r.value,this.dataLabel({p:r.prefix,v:r.value,s:r.suffix,r:this.FINAL_CONFIG.chart.tooltip.roundingValue}),{datapoint:r}):""}</b> ${this.FINAL_CONFIG.chart.tooltip.showPercentage?`(${d.dataLabel({v:this.checkNaN(Math.abs(r.value)/i*100),s:"%",r:this.FINAL_CONFIG.chart.tooltip.roundingPercentage})})`:""}</div>`,this.FINAL_CONFIG.chart.comments.showInTooltip&&r.comments.length&&r.comments.slice(this.slicer.start,this.slicer.end)[this.selectedSerieIndex]&&(l+=`<div class="vue-data-ui-tooltip-comment" style="background:${r.color}20; padding: 6px; margin-bottom: 6px; border-left: 1px solid ${r.color}">${r.comments.slice(this.slicer.start,this.slicer.end)[this.selectedSerieIndex]}</div>`)}}),`<div style="border-radius:4px;padding:12px;font-variant-numeric: tabular-nums;color:${this.FINAL_CONFIG.chart.tooltip.color}">${l}</div>`)},svg(){return{height:this.height,width:this.width}},yLabels(){return this.niceScale.ticks.map(l=>({y:l>=0?this.zero-this.drawingArea.height*this.ratioToMax(l):this.zero+this.drawingArea.height*this.ratioToMax(Math.abs(l)),value:l,prefix:this.FINAL_CONFIG.chart.labels.prefix,suffix:this.FINAL_CONFIG.chart.labels.suffix}))},zero(){return this.drawingArea.bottom-this.drawingArea.height*this.ratioToMax(this.relativeZero)}},mounted(){this.svgRef=this.$refs.svgRef,this.prepareChart(),this.setupSlicer(),document.addEventListener("mousemove",l=>{this.clientPosition={x:l.clientX,y:l.clientY}}),document.addEventListener("scroll",this.hideTags)},beforeUnmount(){document.removeEventListener("scroll",this.hideTags)},methods:{abbreviate:d.abbreviate,adaptColorToBackground:d.adaptColorToBackground,applyDataLabel:d.applyDataLabel,assignStackRatios:d.assignStackRatios,calcLinearProgression:d.calcLinearProgression,calculateNiceScaleWithExactExtremes:d.calculateNiceScaleWithExactExtremes,checkNaN:d.checkNaN,closestDecimal:d.closestDecimal,convertColorToHex:d.convertColorToHex,convertConfigColors:d.convertConfigColors,convertCustomPalette:d.convertCustomPalette,createCsvContent:d.createCsvContent,createSmoothPath:d.createSmoothPath,createStraightPath:d.createStraightPath,createTSpans:d.createTSpans,dataLabel:d.dataLabel,downloadCsv:d.downloadCsv,error:d.error,forceValidValue:d.forceValidValue,functionReturnsString:d.functionReturnsString,hasDeepProperty:d.hasDeepProperty,isFunction:d.isFunction,isSafeValue:d.isSafeValue,largestTriangleThreeBucketsArray:d.largestTriangleThreeBucketsArray,objectIsEmpty:d.objectIsEmpty,setOpacity:d.setOpacity,shiftHue:d.shiftHue,translateSize:d.translateSize,treeShake:d.treeShake,useMouse:G.useMouse,useNestedProp:v.useNestedProp,createUid:d.createUid,placeXYTag:d.placeXYTag,hideTags(){const l=document.querySelectorAll(".vue-ui-xy-tag");l.length&&Array.from(l).forEach(i=>i.style.opacity="0")},setTagRef(l,i,n,h,r){n&&(this.tagRefs[`${l}_${i}_${h}_${r}`]=n)},setUserOptionsVisibility(l=!1){this.showUserOptionsOnChartHover&&(this.userOptionsVisible=l)},toggleAnnotator(){this.isAnnotator=!this.isAnnotator},selectTimeLabel(l,i){const n=this.relativeDataset.map(h=>({shape:h.shape||null,name:h.name,color:h.color,type:h.type,value:h.absoluteValues.find((r,e)=>e===i),comments:h.comments||[],prefix:h.prefix||this.FINAL_CONFIG.chart.labels.prefix,suffix:h.suffix||this.FINAL_CONFIG.chart.labels.suffix}));this.$emit("selectTimeLabel",{datapoint:n,absoluteIndex:l.absoluteIndex,label:l.text})},getHighlightAreaPosition(l){const i=this.drawingArea.left+this.drawingArea.width/this.maxSeries*(l.from-this.slicer.start),n=this.drawingArea.width/(this.slicer.end-this.slicer.start)*l.span<0?1e-5:this.drawingArea.width/(this.slicer.end-this.slicer.start)*l.span;return{x:i<this.drawingArea.left?this.drawingArea.left:i,width:n}},prepareConfig(){const l=d.useConfig().vue_ui_xy;if(!Object.keys(this.config||{}).length)return l;const i=this.useNestedProp({userConfig:this.config,defaultConfig:l});return this.config&&this.hasDeepProperty(this.config,"chart.highlightArea")&&(Array.isArray(this.config.chart.highlightArea)?i.chart.highlightArea=this.config.chart.highlightArea:i.chart.highlightArea=[this.config.chart.highlightArea]),this.config&&this.hasDeepProperty(this.config,"chart.grid.labels.yAxis.scaleMin")?i.chart.grid.labels.yAxis.scaleMin=this.config.chart.grid.labels.yAxis.scaleMin:i.chart.grid.labels.yAxis.scaleMin=null,this.config&&this.hasDeepProperty(this.config,"chart.grid.labels.yAxis.scaleMax")?i.chart.grid.labels.yAxis.scaleMax=this.config.chart.grid.labels.yAxis.scaleMax:i.chart.grid.labels.yAxis.scaleMax=null,this.config&&this.hasDeepProperty(this.config,"chart.zoom.startIndex")?i.chart.zoom.startIndex=this.config.chart.zoom.startIndex:i.chart.zoom.startIndex=null,this.config&&this.hasDeepProperty(this.config,"chart.zoom.endIndex")?i.chart.zoom.endIndex=this.config.chart.zoom.endIndex:i.chart.zoom.endIndex=null,this.config&&this.hasDeepProperty(this.config,"chart.grid.labels.yAxis.groupColor")?i.chart.grid.labels.yAxis.groupColor=this.config.chart.grid.labels.yAxis.groupColor:i.chart.grid.labels.yAxis.groupColor=null,i.theme?{...v.useNestedProp({userConfig:this.themes.vue_ui_xy[i.theme]||this.config,defaultConfig:i}),customPalette:this.themePalettes[i.theme]||this.palette}:i},prepareChart(){if(this.objectIsEmpty(this.dataset)?this.error({componentName:"VueUiXy",type:"dataset"}):this.dataset.forEach((l,i)=>{[null,void 0].includes(l.name)&&this.error({componentName:"VueUiXy",type:"datasetSerieAttribute",property:"name (string)",index:i})}),this.FINAL_CONFIG.showWarnings&&this.dataset.forEach(l=>{l.series.forEach((i,n)=>{this.isSafeValue(i)||console.warn(`VueUiXy has detected an unsafe value in your dataset:
|
|
2
2
|
-----> The serie '${l.name}' contains the value '${i}' at index ${n}.
|
|
3
3
|
'${i}' was converted to null to allow the chart to display.`)})}),this.showUserOptionsOnChartHover=this.FINAL_CONFIG.chart.userOptions.showOnChartHover,this.keepUserOptionState=this.FINAL_CONFIG.chart.userOptions.keepStateOnChartLeave,this.userOptionsVisible=!this.FINAL_CONFIG.chart.userOptions.showOnChartHover,this.mutableConfig={dataLabels:{show:!0},showTooltip:this.FINAL_CONFIG.chart.tooltip.show===!0,showTable:this.FINAL_CONFIG.showTable===!0,isStacked:this.FINAL_CONFIG.chart.grid.labels.yAxis.stacked,useIndividualScale:this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale},this.FINAL_CONFIG.responsive){const i=this.$refs.chart.parentNode,{height:n,width:h}=i.getBoundingClientRect();let r=null,e=0;this.FINAL_CONFIG.chart.title.show&&(r=this.$refs.chartTitle,e=r.getBoundingClientRect().height);let x=null,g=0;this.FINAL_CONFIG.chart.zoom.show&&this.maxX>6&&this.isDataset&&(x=this.$refs.chartSlicer.$el,g=x.getBoundingClientRect().height);let u=null,b=0;this.FINAL_CONFIG.chart.legend.show&&(u=this.$refs.chartLegend,b=u.getBoundingClientRect().height);let L=0;this.$refs.source&&(L=this.$refs.source.getBoundingClientRect().height);let _=0;this.$refs.noTitle&&(_=this.$refs.noTitle.getBoundingClientRect().height),this.height=n-e-b-g-L-_,this.width=h,this.viewBox=`0 0 ${this.width<0?10:this.width} ${this.height<0?10:this.height}`,this.convertSizes(),new ResizeObserver(y=>{for(const m of y)this.$refs.chartTitle&&(e=this.$refs.chartTitle.getBoundingClientRect().height),this.$refs.chartSlicer&&this.$refs.chartSlicer.$el&&(g=this.$refs.chartSlicer.$el.getBoundingClientRect().height),this.$refs.chartLegend&&(b=this.$refs.chartLegend.getBoundingClientRect().height),this.$refs.source&&(L=this.$refs.source.getBoundingClientRect().height),requestAnimationFrame(()=>{this.height=m.contentBoxSize[0].blockSize-e-b-g-L-24,this.width=m.contentBoxSize[0].inlineSize,this.viewBox=`0 0 ${this.width<0?10:this.width} ${this.height<0?10:this.height}`,this.convertSizes()})}).observe(i)}else this.height=this.FINAL_CONFIG.chart.height,this.width=this.FINAL_CONFIG.chart.width,this.viewBox=`0 0 ${this.width} ${this.height}`,this.fontSizes.dataLabels=this.FINAL_CONFIG.chart.grid.labels.fontSize,this.fontSizes.yAxis=this.FINAL_CONFIG.chart.grid.labels.axis.fontSize,this.fontSizes.xAxis=this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.fontSize,this.fontSizes.plotLabels=this.FINAL_CONFIG.chart.labels.fontSize,this.plotRadii.plot=this.FINAL_CONFIG.plot.radius,this.plotRadii.line=this.FINAL_CONFIG.line.radius},selectMinimapIndex(l){this.selectedMinimapIndex=l},convertSizes(){this.fontSizes.dataLabels=this.translateSize({relator:this.height,adjuster:400,source:this.FINAL_CONFIG.chart.grid.labels.fontSize,threshold:10,fallback:10}),this.fontSizes.yAxis=this.translateSize({relator:this.width,adjuster:1e3,source:this.FINAL_CONFIG.chart.grid.labels.axis.fontSize,threshold:10,fallback:10}),this.fontSizes.xAxis=this.translateSize({relator:this.width,adjuster:1e3,source:this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.fontSize,threshold:10,fallback:10}),this.fontSizes.plotLabels=this.translateSize({relator:this.width,adjuster:800,source:this.FINAL_CONFIG.chart.labels.fontSize,threshold:10,fallback:10}),this.plotRadii.plot=this.translateSize({relator:this.width,adjuster:800,source:this.FINAL_CONFIG.plot.radius,threshold:1,fallback:1}),this.plotRadii.line=this.translateSize({relator:this.width,adjuster:800,source:this.FINAL_CONFIG.line.radius,threshold:1,fallback:1})},toggleStack(){this.mutableConfig.isStacked=!this.mutableConfig.isStacked,this.mutableConfig.isStacked?this.mutableConfig.useIndividualScale=!0:this.mutableConfig.useIndividualScale=this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale},toggleTable(){this.mutableConfig.showTable=!this.mutableConfig.showTable},toggleLabels(){this.mutableConfig.dataLabels.show=!this.mutableConfig.dataLabels.show},toggleTooltip(){this.mutableConfig.showTooltip=!this.mutableConfig.showTooltip},checkAutoScaleError(l){l.autoScaling&&(this.FINAL_CONFIG.chart.grid.labels.yAxis.useIndividualScale||console.warn(`VueUiXy (datapoint: ${l.name}) : autoScaling only works when config.chart.grid.labels.yAxis.useIndividualScale is set to true`),this.FINAL_CONFIG.chart.grid.labels.yAxis.stacked||console.warn(`VueUiXy (datapoint: ${l.name}) : autoScaling only works when config.chart.grid.labels.yAxis.stacked is set to true`))},createArea(l){if(!l[0])return[-10,-10,"",-10,-10];const i={x:l[0].x,y:this.zero},n={x:l.at(-1).x,y:this.zero},h=[];return l.forEach(r=>{h.push(`${r.x},${r.y} `)}),[i.x,i.y,...h,n.x,n.y].toString()},createIndividualArea(l,i){if(!l[0])return[-10,-10,"",-10,-10];const n={x:l[0]?l[0].x:Math.min(...l.filter(e=>!!e).map(e=>e.x)),y:i},h={x:l.at(-1)?l.at(-1).x:Math.min(...l.filter(e=>!!e).map(e=>e.x)),y:i},r=[];return l.filter(e=>!!e).forEach(e=>{r.push(`${e.x},${e.y} `)}),[n.x,n.y,...r,h.x,h.y].toString()},createStar:d.createStar,createPolygonPath:d.createPolygonPath,fillArray(l,i){let n=Array(l).fill(0);for(let h=0;h<i.length&&h<l;h+=1)n[h]=i[h];return n},async setupSlicer(){(this.FINAL_CONFIG.chart.zoom.startIndex!==null||this.FINAL_CONFIG.chart.zoom.endIndex!==null)&&this.$refs.chartSlicer?(this.FINAL_CONFIG.chart.zoom.startIndex!==null&&(await this.$nextTick(),await this.$nextTick(),this.$refs.chartSlicer.setStartValue(this.FINAL_CONFIG.chart.zoom.startIndex)),this.FINAL_CONFIG.chart.zoom.endIndex!==null&&(await this.$nextTick(),await this.$nextTick(),this.$refs.chartSlicer.setEndValue(this.validSlicerEnd(this.FINAL_CONFIG.chart.zoom.endIndex+1)))):(this.slicer={start:0,end:Math.max(...this.dataset.map(l=>this.largestTriangleThreeBucketsArray({data:l.series,threshold:this.FINAL_CONFIG.downsample.threshold}).length))},this.slicerStep+=1)},refreshSlicer(){this.setupSlicer()},validSlicerEnd(l){const i=Math.max(...this.dataset.map(n=>this.largestTriangleThreeBucketsArray({data:n.series,threshold:this.FINAL_CONFIG.downsample.threshold}).length));return l>i?i:l<0||this.FINAL_CONFIG.chart.zoom.startIndex!==null&&l<this.FINAL_CONFIG.chart.zoom.startIndex?this.FINAL_CONFIG.chart.zoom.startIndex!==null?this.FINAL_CONFIG.chart.zoom.startIndex+1:1:l},calcRectHeight(l){const i=![null,void 0].includes(this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin)&&this.FINAL_CONFIG.chart.grid.labels.yAxis.scaleMin>0&&this.min>=0?this.drawingArea.bottom:this.zero;return l.value>=0?this.checkNaN(i-l.y<=0?1e-5:i-l.y):this.checkNaN(l.y-this.zero<=0?1e-5:l.y-this.zero)},calcIndividualHeight(l){return l.value>=0?this.checkNaN(l.zeroPosition-l.y<=0?1e-5:l.zeroPosition-l.y):this.checkNaN(l.y-l.zeroPosition<=0?1e-5:l.zeroPosition-l.y)},calcRectWidth(){return this.mutableConfig.useIndividualScale&&this.mutableConfig.isStacked?this.slot.line-this.drawingArea.width/this.maxSeries*.1:this.slot.bar},calcRectX(l){return this.mutableConfig.useIndividualScale&&this.mutableConfig.isStacked?l.x+this.drawingArea.width/this.maxSeries*.05:l.x+this.slot.bar/2},calcRectY(l){return l.value>=0?l.y:this.zero},calcIndividualRectY(l){return l.value>=0?l.y:[null,void 0,NaN,1/0,-1/0].includes(l.zeroPosition)?0:l.zeroPosition},canShowValue(l){return![null,void 0,NaN,1/0,-1/0].includes(l)},findClosestValue(l,i){let n=i[0],h=Math.abs(l-i[0]);for(let r=1;r<i.length;r+=1){const e=Math.abs(l-i[r]);e<h&&i[r]<l&&(n=i[r],h=e)}return n},ratioToMax(l){return l/(this.canShowValue(this.absoluteMax)?this.absoluteMax:1)},selectX(l){this.$emit("selectX",{dataset:this.relativeDataset.map(i=>({name:i.name,value:[null,void 0,NaN].includes(i.absoluteValues[l])?null:i.absoluteValues[l],color:i.color,type:i.type})),index:l,indexLabel:this.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[l]})},getData(){return this.absoluteDataset.map(l=>({values:l.absoluteValues,color:l.color,name:l.name,type:l.type}))},segregate(l){if(this.segregatedSeries.includes(l.id))this.segregatedSeries=this.segregatedSeries.filter(i=>i!==l.id);else{if(this.segregatedSeries.length+1===this.safeDataset.length)return;this.segregatedSeries.push(l.id)}this.$emit("selectLegend",this.relativeDataset.map(i=>({name:i.name,values:i.absoluteValues,color:i.color,type:i.type}))),this.segregateStep+=1},toggleTooltipVisibility(l,i=null){this.isTooltip=l,l?this.selectedSerieIndex=i:this.selectedSerieIndex=null},toggleFullscreen(l){this.isFullscreen=l,this.step+=1},showSpinnerPdf(){this.isPrinting=!0},async generatePdf(){this.showSpinnerPdf(),clearTimeout(this.__to__),this.isPrinting=!0,this.__to__=setTimeout(async()=>{try{const{default:l}=await Promise.resolve().then(()=>require("./pdf-BpXLKlRx.cjs"));await l({domElement:document.getElementById(`vue-ui-xy_${this.uniqueId}`),fileName:this.FINAL_CONFIG.chart.title.text||"vue-ui-xy",options:this.FINAL_CONFIG.chart.userOptions.print})}catch(l){console.error("Error generating PDF:",l)}finally{this.isPrinting=!1}},100)},generateCsv(){const l=[[this.FINAL_CONFIG.chart.title.text],[this.FINAL_CONFIG.chart.title.subtitle.text],[""]],i=["",...this.table.head.map(e=>e.label)],n=this.table.body,h=l.concat([i]).concat(n),r=this.createCsvContent(h);this.downloadCsv({csvContent:r,title:this.FINAL_CONFIG.chart.title.text||"vue-ui-xy"})},showSpinnerImage(){this.isImaging=!0},async generateImage(){this.showSpinnerImage(),clearTimeout(this.__to__),this.isImaging=!0,this.__to__=setTimeout(async()=>{try{const{default:l}=await Promise.resolve().then(()=>require("./img-D6uvziU0.cjs"));await l({domElement:document.getElementById(`vue-ui-xy_${this.uniqueId}`),fileName:this.FINAL_CONFIG.chart.title.text||"vue-ui-xy",format:"png",options:this.FINAL_CONFIG.chart.userOptions.print})}catch(l){console.error("Error generating image:",l)}finally{this.isImaging=!1}},100)}}},U=["id"],Z={key:1,ref:"noTitle",class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%; background:transparent"},J=["viewBox","aria-label"],K=["x","y","width","height"],Q={key:1},j={class:"vue-ui-xy-grid"},$=["stroke","x1","x2","y1","y2"],ee=["stroke","x1","x2","y1","y2"],te={key:1},le=["x1","x2","y1","y2","stroke"],re=["x1","x2","y1","y2","stroke"],ae=["x1","x2","y1","y2","stroke"],ie={key:3},se=["x1","x2","y1","y2","stroke"],oe=["id"],ne=["stop-color"],ce=["stop-color"],he=["stop-color"],de=["id"],ue=["stop-color"],ge=["stop-color"],me=["stop-color"],fe=["id"],Ne=["stop-color"],Ie=["stop-color"],xe=["id"],be=["stop-color"],Fe=["stop-color"],ke=["id"],_e=["stop-color"],ye=["stop-color"],Le=["x","y","height","width","fill"],Ce=["x","y","width"],Ae=["x","y","height","width","fill"],Se=["x","y","height","width","rx","fill","stroke","stroke-width"],we=["x","y","height","width","rx","fill","stroke","stroke-width"],Oe=["width","x","y"],Ge={key:0},ve=["id"],pe=["fill"],Be=["x1","x2","y1","y2","stroke","marker-end"],Ee=["x","y","font-size","fill"],Ve=["stroke","x1","x2","y1","y2"],ze={key:2},Me=["x1","x2","y1","y2","stroke","stroke-width","stroke-dasharray"],Te=["x","y","width","height","stroke","stroke-width","stroke-linecap","stroke-linejoin","stroke-dasharray"],Pe={key:4},Re=["x1","x2","y1","y2","stroke","stroke-width"],De=["fill","font-size","transform"],He=["x1","x2","y1","y2","stroke"],qe=["x","y","font-size","fill"],We=["x1","x2","y1","y2","stroke"],Ye=["x","y","font-size","fill"],Xe=["width","x","y"],Ue={style:{width:"100%"}},Ze={key:0},Je=["id"],Ke=["fill"],Qe=["x1","x2","y1","y2","stroke","marker-end"],je=["x","y","font-size","fill"],$e=["d","stroke","stroke-width","stroke-dasharray"],et=["d","stroke","stroke-width","stroke-dasharray"],tt={key:5},lt={key:0},rt=["d","fill"],at=["d","fill"],it=["d","fill"],st=["d","fill"],ot=["d","stroke","stroke-width","stroke-dasharray"],nt=["d","stroke","stroke-width","stroke-dasharray"],ct=["width","x","y"],ht={style:{width:"100%"}},dt={key:3},ut=["id"],gt=["fill"],mt=["x1","x2","y1","y2","stroke","marker-end"],ft=["x","y","font-size","fill"],Nt={key:6},It=["x","y","font-size","fill"],xt=["x","y","font-size","fill","font-weight"],bt={key:7},Ft=["x","y","font-size","fill"],kt={key:8},_t=["x","y"],yt=["innerHTML"],Lt=["x","y"],Ct=["innerHTML"],At=["x1","x2","y1","y2","stroke"],St={key:9},wt=["x","y","font-size","fill"],Ot={key:10},Gt=["x","y"],vt=["innerHTML"],pt=["x","y"],Bt=["innerHTML"],Et=["x1","x2","y1","y2","stroke"],Vt=["x","y","font-size","fill","innerHTML"],zt=["x","y","font-size","fill","innerHTML"],Mt=["x","y","font-size","fill","innerHTML"],Tt=["x","y","font-size","fill","innerHTML"],Pt=["id"],Rt=["stop-color"],Dt=["stop-color"],Ht=["x","y","width","height","fill","onMouseenter"],qt=["font-size","fill","transform"],Wt=["x","y","font-size","fill"],Yt={key:12},Xt=["text-anchor","font-size","fill","transform","onClick"],Ut=["x","y","height","width","onMouseenter","onClick"],Zt={key:13,style:{"pointer-events":"none"}},Jt=["x","y"],Kt=["cx","cy","r","fill"],Qt={key:5,class:"vue-data-ui-watermark"},jt={class:"vue-ui-xy-tag-arrow",height:"20",viewBox:"0 0 10 20",style:{position:"absolute",right:"100%",top:"50%",transform:"translateY(-50%)"}},$t=["fill"],el=["innerHTML"],tl={class:"vue-ui-xy-tag-arrow",height:"100%",viewBox:"0 0 10 20",style:{position:"absolute",left:"100%",top:"50%",transform:"translateY(-50%)"}},ll=["fill"],rl=["innerHTML"],al={class:"vue-ui-xy-tag-arrow",height:"20",viewBox:"0 0 10 20",style:{position:"absolute",right:"100%",top:"50%",transform:"translateY(-50%)"}},il=["fill"],sl=["innerHTML"],ol={class:"vue-ui-xy-tag-arrow",height:"100%",viewBox:"0 0 10 20",style:{position:"absolute",left:"100%",top:"50%",transform:"translateY(-50%)"}},nl=["fill"],cl=["innerHTML"],hl=["onClick"],dl={key:0,viewBox:"0 0 20 12",height:"14",width:"20"},ul=["stroke","fill"],gl={key:1,viewBox:"0 0 40 40",height:"14",width:"14"},ml=["fill"],fl=["fill"],Nl={key:2,viewBox:"0 0 12 12",height:"14",width:"14"},Il={key:9,ref:"chartLegend"},xl={key:10,ref:"source",dir:"auto"},bl={style:{display:"flex","flex-direction":"row",gap:"6px","align-items":"center","padding-left":"6px"},"data-html2canvas-ignore":""},Fl=["innerHTML"];function kl(l,i,n,h,r,e){const x=t.resolveComponent("PenAndPaper"),g=t.resolveComponent("Title"),u=t.resolveComponent("UserOptions"),b=t.resolveComponent("PackageVersion"),L=t.resolveComponent("Shape"),_=t.resolveComponent("Skeleton"),C=t.resolveComponent("Slicer"),y=t.resolveComponent("Tooltip"),m=t.resolveComponent("BaseIcon"),F=t.resolveComponent("TableSparkline"),A=t.resolveComponent("DataTable"),O=t.resolveComponent("Accordion");return t.openBlock(),t.createElementBlock("div",{id:`vue-ui-xy_${r.uniqueId}`,class:t.normalizeClass(`vue-ui-xy ${r.isFullscreen?"vue-data-ui-wrapper-fullscreen":""} ${e.FINAL_CONFIG.useCssAnimation?"":"vue-ui-dna"}`),ref:"chart",style:t.normalizeStyle(`background:${e.FINAL_CONFIG.chart.backgroundColor}; color:${e.FINAL_CONFIG.chart.color};width:100%;font-family:${e.FINAL_CONFIG.chart.fontFamily};${e.FINAL_CONFIG.responsive?"height: 100%":""}`),onMouseenter:i[7]||(i[7]=()=>e.setUserOptionsVisibility(!0)),onMouseleave:i[8]||(i[8]=()=>e.setUserOptionsVisibility(!1))},[e.FINAL_CONFIG.chart.userOptions.buttons.annotator?(t.openBlock(),t.createBlock(x,{key:0,svgRef:r.svgRef,backgroundColor:e.FINAL_CONFIG.chart.backgroundColor,color:e.FINAL_CONFIG.chart.color,active:r.isAnnotator,onClose:e.toggleAnnotator},null,8,["svgRef","backgroundColor","color","active","onClose"])):t.createCommentVNode("",!0),e.hasOptionsNoTitle?(t.openBlock(),t.createElementBlock("div",Z,null,512)):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.title.show?(t.openBlock(),t.createElementBlock("div",{key:2,ref:"chartTitle",class:"vue-ui-xy-title",style:t.normalizeStyle(`font-family:${e.FINAL_CONFIG.chart.fontFamily}`)},[(t.openBlock(),t.createBlock(g,{key:`title_${r.titleStep}`,config:{title:{cy:"xy-div-title",...e.FINAL_CONFIG.chart.title},subtitle:{cy:"xy-div-subtitle",...e.FINAL_CONFIG.chart.title.subtitle}}},null,8,["config"]))],4)):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.userOptions.show&&e.isDataset&&(r.keepUserOptionState||r.userOptionsVisible)?(t.openBlock(),t.createBlock(u,{ref:"defails",key:`user_options_${r.step}`,backgroundColor:e.FINAL_CONFIG.chart.backgroundColor,color:e.FINAL_CONFIG.chart.color,isPrinting:r.isPrinting,isImaging:r.isImaging,uid:r.uniqueId,hasTooltip:e.FINAL_CONFIG.chart.userOptions.buttons.tooltip&&e.FINAL_CONFIG.chart.tooltip.show,hasPdf:e.FINAL_CONFIG.chart.userOptions.buttons.pdf,hasXls:e.FINAL_CONFIG.chart.userOptions.buttons.csv,hasImg:e.FINAL_CONFIG.chart.userOptions.buttons.img,hasLabel:e.FINAL_CONFIG.chart.userOptions.buttons.labels,hasTable:e.FINAL_CONFIG.chart.userOptions.buttons.table,hasStack:n.dataset.length>1&&e.FINAL_CONFIG.chart.userOptions.buttons.stack,hasFullscreen:e.FINAL_CONFIG.chart.userOptions.buttons.fullscreen,isStacked:r.mutableConfig.isStacked,isFullscreen:r.isFullscreen,chartElement:l.$refs.chart,position:e.FINAL_CONFIG.chart.userOptions.position,isTooltip:r.mutableConfig.showTooltip,titles:{...e.FINAL_CONFIG.chart.userOptions.buttonTitles},hasAnnotator:e.FINAL_CONFIG.chart.userOptions.buttons.annotator,isAnnotation:r.isAnnotator,onToggleFullscreen:e.toggleFullscreen,onGeneratePdf:e.generatePdf,onGenerateCsv:e.generateCsv,onGenerateImage:e.generateImage,onToggleTable:e.toggleTable,onToggleLabels:e.toggleLabels,onToggleStack:e.toggleStack,onToggleTooltip:e.toggleTooltip,onToggleAnnotator:e.toggleAnnotator,style:t.normalizeStyle({visibility:r.keepUserOptionState?r.userOptionsVisible?"visible":"hidden":"visible"})},t.createSlots({_:2},[l.$slots.menuIcon?{name:"menuIcon",fn:t.withCtx(({isOpen:a,color:o})=>[t.renderSlot(l.$slots,"menuIcon",t.normalizeProps(t.guardReactiveProps({isOpen:a,color:o})),void 0,!0)]),key:"0"}:void 0,l.$slots.optionTooltip?{name:"optionTooltip",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionTooltip",{},void 0,!0)]),key:"1"}:void 0,l.$slots.optionPdf?{name:"optionPdf",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionPdf",{},void 0,!0)]),key:"2"}:void 0,l.$slots.optionCsv?{name:"optionCsv",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionCsv",{},void 0,!0)]),key:"3"}:void 0,l.$slots.optionImg?{name:"optionImg",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionImg",{},void 0,!0)]),key:"4"}:void 0,l.$slots.optionTable?{name:"optionTable",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionTable",{},void 0,!0)]),key:"5"}:void 0,l.$slots.optionLabels?{name:"optionLabels",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionLabels",{},void 0,!0)]),key:"6"}:void 0,l.$slots.optionStack?{name:"optionStack",fn:t.withCtx(()=>[t.renderSlot(l.$slots,"optionStack",{},void 0,!0)]),key:"7"}:void 0,l.$slots.optionFullscreen?{name:"optionFullscreen",fn:t.withCtx(({toggleFullscreen:a,isFullscreen:o})=>[t.renderSlot(l.$slots,"optionFullscreen",t.normalizeProps(t.guardReactiveProps({toggleFullscreen:a,isFullscreen:o})),void 0,!0)]),key:"8"}:void 0,l.$slots.optionAnnotator?{name:"optionAnnotator",fn:t.withCtx(({toggleAnnotator:a,isAnnotator:o})=>[t.renderSlot(l.$slots,"optionAnnotator",t.normalizeProps(t.guardReactiveProps({toggleAnnotator:a,isAnnotator:o})),void 0,!0)]),key:"9"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasXls","hasImg","hasLabel","hasTable","hasStack","hasFullscreen","isStacked","isFullscreen","chartElement","position","isTooltip","titles","hasAnnotator","isAnnotation","onToggleFullscreen","onGeneratePdf","onGenerateCsv","onGenerateImage","onToggleTable","onToggleLabels","onToggleStack","onToggleTooltip","onToggleAnnotator","style"])):t.createCommentVNode("",!0),e.isDataset?(t.openBlock(),t.createElementBlock("svg",{key:4,ref:"svgRef",xmlns:"http://www.w3.org/2000/svg",class:t.normalizeClass([{"vue-data-ui-fullscreen--on":r.isFullscreen,"vue-data-ui-fulscreen--off":!r.isFullscreen},"vue-ui-xy-svg"]),width:"100%",viewBox:r.viewBox,style:t.normalizeStyle(`background: transparent; color:${e.FINAL_CONFIG.chart.color}; font-family:${e.FINAL_CONFIG.chart.fontFamily}`),"aria-label":e.chartAriaLabel,role:"img","aria-live":"polite"},[t.createVNode(b),l.$slots["chart-background"]?(t.openBlock(),t.createElementBlock("foreignObject",{key:0,x:e.drawingArea.left+e.xPadding<0?0:e.drawingArea.left+e.xPadding,y:e.drawingArea.top,width:e.drawingArea.width-(e.FINAL_CONFIG.chart.grid.position==="middle"?0:e.drawingArea.width/e.maxSeries)<0?0:e.drawingArea.width-(e.FINAL_CONFIG.chart.grid.position==="middle"?0:e.drawingArea.width/e.maxSeries),height:e.drawingArea.height<0?0:e.drawingArea.height,style:{pointerEvents:"none"}},[t.renderSlot(l.$slots,"chart-background",{},void 0,!0)],8,K)):t.createCommentVNode("",!0),e.maxSeries>0?(t.openBlock(),t.createElementBlock("g",Q,[t.createElementVNode("g",j,[e.FINAL_CONFIG.chart.grid.labels.xAxis.showBaseline?(t.openBlock(),t.createElementBlock("line",{key:0,stroke:e.FINAL_CONFIG.chart.grid.stroke,"stroke-width":"1",x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.right-e.xPadding,y1:e.forceValidValue(e.drawingArea.bottom),y2:e.forceValidValue(e.drawingArea.bottom),"stroke-linecap":"round"},null,8,$)):t.createCommentVNode("",!0),r.mutableConfig.useIndividualScale?e.FINAL_CONFIG.chart.grid.showHorizontalLines?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:2},t.renderList(e.allScales,a=>(t.openBlock(),t.createElementBlock("g",null,[a.id===r.selectedScale&&a.yLabels.length?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(a.yLabels,o=>(t.openBlock(),t.createElementBlock("line",{x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.right-e.xPadding,y1:e.forceValidValue(o.y),y2:e.forceValidValue(o.y),stroke:a.color,"stroke-width":.5,"stroke-linecap":"round"},null,8,re))),256)):a.yLabels.length?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(a.yLabels,o=>(t.openBlock(),t.createElementBlock("line",{x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.right-e.xPadding,y1:e.forceValidValue(o.y),y2:e.forceValidValue(o.y),stroke:e.FINAL_CONFIG.chart.grid.stroke,"stroke-width":.5,"stroke-linecap":"round"},null,8,ae))),256)):t.createCommentVNode("",!0)]))),256)):t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[e.FINAL_CONFIG.chart.grid.labels.yAxis.showBaseline?(t.openBlock(),t.createElementBlock("line",{key:0,stroke:e.FINAL_CONFIG.chart.grid.stroke,"stroke-width":"1",x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.left+e.xPadding,y1:e.forceValidValue(e.drawingArea.top),y2:e.forceValidValue(e.drawingArea.bottom),"stroke-linecap":"round"},null,8,ee)):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.grid.showHorizontalLines?(t.openBlock(),t.createElementBlock("g",te,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.yLabels,a=>(t.openBlock(),t.createElementBlock("line",{x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.right-e.xPadding,y1:e.forceValidValue(a.y),y2:e.forceValidValue(a.y),stroke:e.FINAL_CONFIG.chart.grid.stroke,"stroke-width":.5,"stroke-linecap":"round"},null,8,le))),256))])):t.createCommentVNode("",!0)],64)),e.FINAL_CONFIG.chart.grid.showVerticalLines?(t.openBlock(),t.createElementBlock("g",ie,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.maxSeries+(e.FINAL_CONFIG.chart.grid.position==="middle"?1:0),(a,o)=>(t.openBlock(),t.createElementBlock("line",{key:`grid_vertical_line_${o}`,x1:e.drawingArea.width/e.maxSeries*o+e.drawingArea.left+e.xPadding,x2:e.drawingArea.width/e.maxSeries*o+e.drawingArea.left+e.xPadding,y1:e.forceValidValue(e.drawingArea.top),y2:e.forceValidValue(e.drawingArea.bottom),"stroke-width":"0.5",stroke:e.FINAL_CONFIG.chart.grid.stroke},null,8,se))),128))])):t.createCommentVNode("",!0)]),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.barSet,(a,o)=>(t.openBlock(),t.createElementBlock("defs",{key:`def_rect_${o}`},[t.createElementVNode("linearGradient",{id:`rectGradient_pos_${o}_${r.uniqueId}`,x2:"0%",y2:"100%"},[t.createElementVNode("stop",{offset:"0%","stop-color":a.color},null,8,ne),t.createElementVNode("stop",{offset:"62%","stop-color":`${e.shiftHue(a.color,.02)}`},null,8,ce),t.createElementVNode("stop",{offset:"100%","stop-color":`${e.shiftHue(a.color,.05)}`},null,8,he)],8,oe),t.createElementVNode("linearGradient",{id:`rectGradient_neg_${o}_${r.uniqueId}`,x2:"0%",y2:"100%"},[t.createElementVNode("stop",{offset:"0%","stop-color":`${e.shiftHue(a.color,.05)}`},null,8,ue),t.createElementVNode("stop",{offset:"38%","stop-color":`${e.shiftHue(a.color,.02)}`},null,8,ge),t.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,me)],8,de)]))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.plotSet,(a,o)=>(t.openBlock(),t.createElementBlock("defs",{key:`def_plot_${o}`},[t.createElementVNode("radialGradient",{id:`plotGradient_${o}_${r.uniqueId}`,cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%"},[t.createElementVNode("stop",{offset:"0%","stop-color":`${e.shiftHue(a.color,.05)}`},null,8,Ne),t.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,Ie)],8,fe)]))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock("defs",{key:`def_line_${o}`},[t.createElementVNode("radialGradient",{id:`lineGradient_${o}_${r.uniqueId}`,cx:"50%",cy:"50%",r:"50%",fx:"50%",fy:"50%"},[t.createElementVNode("stop",{offset:"0%","stop-color":`${e.shiftHue(a.color,.05)}`},null,8,be),t.createElementVNode("stop",{offset:"100%","stop-color":a.color},null,8,Fe)],8,xe),t.createElementVNode("linearGradient",{id:`areaGradient_${o}_${r.uniqueId}`,x1:"0%",x2:"100%",y1:"0%",y2:"0%"},[t.createElementVNode("stop",{offset:"0%","stop-color":`${e.setOpacity(e.shiftHue(a.color,.03),e.FINAL_CONFIG.line.area.opacity)}`},null,8,_e),t.createElementVNode("stop",{offset:"100%","stop-color":`${e.setOpacity(a.color,e.FINAL_CONFIG.line.area.opacity)}`},null,8,ye)],8,ke)]))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.highlightAreas,a=>(t.openBlock(),t.createElementBlock("g",null,[a.show?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(a.span,(o,s)=>(t.openBlock(),t.createElementBlock("g",null,[t.createElementVNode("rect",{style:t.normalizeStyle({transition:"none",opacity:a.from+s>=r.slicer.start&&a.from+s<=r.slicer.end-1?1:0}),x:e.drawingArea.left+e.drawingArea.width/e.maxSeries*(a.from+s-r.slicer.start),y:e.drawingArea.top,height:e.drawingArea.height<0?10:e.drawingArea.height,width:e.drawingArea.width/e.maxSeries<0?1e-5:e.drawingArea.width/e.maxSeries,fill:e.setOpacity(a.color,a.opacity)},null,12,Le),a.caption.text&&s===0?(t.openBlock(),t.createElementBlock("foreignObject",{key:0,x:e.drawingArea.left+e.drawingArea.width/e.maxSeries*(a.from+s-r.slicer.start)-(a.caption.width==="auto"?0:a.caption.width/2-e.drawingArea.width/e.maxSeries*a.span/2),y:e.drawingArea.top+a.caption.offsetY,style:t.normalizeStyle({overflow:"visible",opacity:a.to>=r.slicer.start&&a.from<r.slicer.end?1:0}),height:"1",width:a.caption.width==="auto"?e.drawingArea.width/e.maxSeries*a.span:a.caption.width},[t.createElementVNode("div",{style:t.normalizeStyle(`padding:${a.caption.padding}px;text-align:${a.caption.textAlign};font-size:${a.caption.fontSize}px;color:${a.caption.color};font-weight:${a.caption.bold?"bold":"normal"}`)},t.toDisplayString(a.caption.text),5)],12,Ce)):t.createCommentVNode("",!0)]))),256)):t.createCommentVNode("",!0)]))),256)),t.createElementVNode("g",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.maxSeries,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`tooltip_trap_highlighter_${o}`},[t.createElementVNode("rect",{x:e.drawingArea.left+e.drawingArea.width/e.maxSeries*o,y:e.drawingArea.top,height:e.drawingArea.height<0?10:e.drawingArea.height,width:e.drawingArea.width/e.maxSeries<0?1e-5:e.drawingArea.width/e.maxSeries,fill:[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(o)?e.setOpacity(e.FINAL_CONFIG.chart.highlighter.color,e.FINAL_CONFIG.chart.highlighter.opacity):"transparent"},null,8,Ae)]))),128))]),e.barSet.length?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(e.barSet,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`serie_bar_${o}`,class:t.normalizeClass(`serie_bar_${o}`),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock("g",{key:`bar_plot_${o}_${c}`},[e.canShowValue(s.value)?(t.openBlock(),t.createElementBlock("rect",{key:0,x:e.calcRectX(s),y:r.mutableConfig.useIndividualScale?e.calcIndividualRectY(s):e.calcRectY(s),height:r.mutableConfig.useIndividualScale?Math.abs(e.calcIndividualHeight(s)):Math.abs(e.calcRectHeight(s)),width:e.calcRectWidth()-(r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?0:e.barPeriodGap)<0?1e-5:e.calcRectWidth()-(r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?0:e.barPeriodGap),rx:e.FINAL_CONFIG.bar.borderRadius,fill:e.FINAL_CONFIG.bar.useGradient?s.value>=0?`url(#rectGradient_pos_${o}_${r.uniqueId})`:`url(#rectGradient_neg_${o}_${r.uniqueId})`:a.color,stroke:e.FINAL_CONFIG.bar.border.useSerieColor?a.color:e.FINAL_CONFIG.bar.border.stroke,"stroke-width":e.FINAL_CONFIG.bar.border.strokeWidth},null,8,Se)):t.createCommentVNode("",!0),e.canShowValue(s.value)&&l.$slots.pattern?(t.openBlock(),t.createElementBlock("rect",{key:1,x:e.calcRectX(s),y:r.mutableConfig.useIndividualScale?e.calcIndividualRectY(s):e.calcRectY(s),height:r.mutableConfig.useIndividualScale?Math.abs(e.calcIndividualHeight(s)):Math.abs(e.calcRectHeight(s)),width:e.calcRectWidth()-(r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?0:e.barPeriodGap)<0?1e-5:e.calcRectWidth()-(r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?0:e.barPeriodGap),rx:e.FINAL_CONFIG.bar.borderRadius,fill:`url(#pattern_${r.uniqueId}_${a.slotAbsoluteIndex})`,stroke:e.FINAL_CONFIG.bar.border.useSerieColor?a.color:e.FINAL_CONFIG.bar.border.stroke,"stroke-width":e.FINAL_CONFIG.bar.border.strokeWidth},null,8,we)):t.createCommentVNode("",!0),s.comment&&e.FINAL_CONFIG.chart.comments.show?(t.openBlock(),t.createElementBlock("foreignObject",{key:2,style:{overflow:"visible"},height:"12",width:(e.calcRectWidth()-(r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?0:e.barPeriodGap)<0?1e-5:e.calcRectWidth()-(r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?0:e.barPeriodGap)/2)+e.FINAL_CONFIG.chart.comments.width,x:e.calcRectX(s)-e.FINAL_CONFIG.chart.comments.width/2+e.FINAL_CONFIG.chart.comments.offsetX,y:e.checkNaN(s.y)+e.FINAL_CONFIG.chart.comments.offsetY+6},[t.renderSlot(l.$slots,"plot-comment",{plot:{...s,color:a.color,seriesIndex:o,datapointIndex:c}},void 0,!0)],8,Oe)):t.createCommentVNode("",!0)]))),128)),Object.hasOwn(a,"useProgression")&&a.useProgression===!0&&!isNaN(e.calcLinearProgression(a.plots).trend)?(t.openBlock(),t.createElementBlock("g",Ge,[t.createElementVNode("defs",null,[t.createElementVNode("marker",{id:`bar_arrow_${o}`,markerWidth:7,markerHeight:7,refX:"0",refY:7/2,orient:"auto"},[t.createElementVNode("polygon",{points:`0 0, 7 ${7/2}, 0 7`,fill:a.color},null,8,pe)],8,ve)]),a.plots.length>1?(t.openBlock(),t.createElementBlock("line",{key:0,x1:e.calcLinearProgression(a.plots).x1,x2:e.calcLinearProgression(a.plots).x2,y1:e.forceValidValue(e.calcLinearProgression(a.plots).y1),y2:e.forceValidValue(e.calcLinearProgression(a.plots).y2),"stroke-width":1,stroke:a.color,"stroke-dasharray":2,"marker-end":`url(#bar_arrow_${o})`},null,8,Be)):t.createCommentVNode("",!0),a.plots.length>1?(t.openBlock(),t.createElementBlock("text",{key:1,"text-anchor":"middle",x:e.calcLinearProgression(a.plots).x2,y:e.calcLinearProgression(a.plots).y2-6,"font-size":r.fontSizes.plotLabels,fill:a.color},t.toDisplayString(e.dataLabel({v:e.calcLinearProgression(a.plots).trend*100,s:"%",r:2})),9,Ee)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)],6))),128)):t.createCommentVNode("",!0),!r.mutableConfig.useIndividualScale&&e.FINAL_CONFIG.chart.grid.labels.zeroLine.show?(t.openBlock(),t.createElementBlock("line",{key:1,stroke:e.FINAL_CONFIG.chart.grid.stroke,"stroke-width":"1",x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.right-e.xPadding,y1:e.forceValidValue(e.zero),y2:e.forceValidValue(e.zero),"stroke-linecap":"round"},null,8,Ve)):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.highlighter.useLine&&(![null,void 0].includes(r.selectedSerieIndex)||![null,void 0].includes(r.selectedMinimapIndex))?(t.openBlock(),t.createElementBlock("g",ze,[t.createElementVNode("line",{x1:e.drawingArea.left+e.drawingArea.width/e.maxSeries*((r.selectedSerieIndex!==null?r.selectedSerieIndex:0)||(r.selectedMinimapIndex!==null?r.selectedMinimapIndex:0))+e.drawingArea.width/e.maxSeries/2,x2:e.drawingArea.left+e.drawingArea.width/e.maxSeries*((r.selectedSerieIndex!==null?r.selectedSerieIndex:0)||(r.selectedMinimapIndex!==null?r.selectedMinimapIndex:0))+e.drawingArea.width/e.maxSeries/2,y1:e.forceValidValue(e.drawingArea.top),y2:e.forceValidValue(e.drawingArea.bottom),stroke:e.FINAL_CONFIG.chart.highlighter.color,"stroke-width":e.FINAL_CONFIG.chart.highlighter.lineWidth,"stroke-dasharray":e.FINAL_CONFIG.chart.highlighter.lineDasharray,"stroke-linecap":"round",style:{transition:"none !important",animation:"none !important","pointer-events":"none"}},null,8,Me)])):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.grid.frame.show?(t.openBlock(),t.createElementBlock("rect",{key:3,style:{pointerEvents:"none",transition:"none"},x:e.drawingArea.left+e.xPadding<0?0:e.drawingArea.left+e.xPadding,y:e.drawingArea.top,width:e.drawingArea.width-(e.FINAL_CONFIG.chart.grid.position==="middle"?0:e.drawingArea.width/e.maxSeries)<0?0:e.drawingArea.width-(e.FINAL_CONFIG.chart.grid.position==="middle"?0:e.drawingArea.width/e.maxSeries),height:e.drawingArea.height<0?0:e.drawingArea.height,fill:"transparent",stroke:e.FINAL_CONFIG.chart.grid.frame.stroke,"stroke-width":e.FINAL_CONFIG.chart.grid.frame.strokeWidth,"stroke-linecap":e.FINAL_CONFIG.chart.grid.frame.strokeLinecap,"stroke-linejoin":e.FINAL_CONFIG.chart.grid.frame.strokeLinejoin,"stroke-dasharray":e.FINAL_CONFIG.chart.grid.frame.strokeDasharray},null,8,Te)):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.grid.labels.show?(t.openBlock(),t.createElementBlock("g",Pe,[r.mutableConfig.useIndividualScale?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.allScales,a=>(t.openBlock(),t.createElementBlock("g",null,[t.createElementVNode("line",{x1:a.x+e.xPadding,x2:a.x+e.xPadding,y1:r.mutableConfig.isStacked?e.forceValidValue(e.drawingArea.bottom-a.yOffset-a.individualHeight):e.forceValidValue(e.drawingArea.top),y2:r.mutableConfig.isStacked?e.forceValidValue(e.drawingArea.bottom-a.yOffset):e.forceValidValue(e.drawingArea.bottom),stroke:a.color,"stroke-width":e.FINAL_CONFIG.chart.grid.stroke,"stroke-linecap":"round",style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.3:1};transition:opacity 0.2s ease-in-out`)},null,12,Re)]))),256)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.allScales,a=>(t.openBlock(),t.createElementBlock("g",{style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.3:1};transition:opacity 0.2s ease-in-out`)},[t.createElementVNode("text",{fill:a.color,"font-size":r.fontSizes.dataLabels,"text-anchor":"middle",transform:`translate(${a.x-e.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth+5+e.xPadding+e.FINAL_CONFIG.chart.grid.labels.yAxis.scaleLabelOffsetX}, ${r.mutableConfig.isStacked?e.drawingArea.bottom-a.yOffset-a.individualHeight/2:e.drawingArea.top+e.drawingArea.height/2}) rotate(-90)`},t.toDisplayString(a.name)+" "+t.toDisplayString(a.scaleLabel&&a.unique&&a.scaleLabel!==a.id?`- ${a.scaleLabel}`:""),9,De),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.yLabels,(o,s)=>(t.openBlock(),t.createElementBlock("line",{x1:a.x-3+e.xPadding,x2:a.x+e.xPadding,y1:e.forceValidValue(o.y),y2:e.forceValidValue(o.y),stroke:a.color,"stroke-width":1,"stroke-linecap":"round"},null,8,He))),256)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.yLabels,(o,s)=>(t.openBlock(),t.createElementBlock("text",{x:a.x-5+e.xPadding+e.FINAL_CONFIG.chart.grid.labels.yAxis.scaleValueOffsetX,y:e.forceValidValue(o.y)+r.fontSizes.dataLabels/3,"font-size":r.fontSizes.dataLabels,"text-anchor":"end",fill:a.color},t.toDisplayString(e.applyDataLabel(e.FINAL_CONFIG.chart.grid.labels.yAxis.formatter,o.value,e.dataLabel({p:o.prefix,v:o.value,s:o.suffix,r:1}),{datapoint:o.datapoint,seriesIndex:s})),9,qe))),256))],4))),256))],64)):(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(e.yLabels,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`yLabel_${o}`},[e.canShowValue(a)&&a.value>=e.niceScale.min&&a.value<=e.niceScale.max?(t.openBlock(),t.createElementBlock("line",{key:0,x1:e.drawingArea.left+e.xPadding,x2:e.drawingArea.left-5+e.xPadding,y1:e.forceValidValue(a.y),y2:e.forceValidValue(a.y),stroke:e.FINAL_CONFIG.chart.grid.stroke,"stroke-width":"1","stroke-linecap":"round"},null,8,We)):t.createCommentVNode("",!0),a.value>=e.niceScale.min&&a.value<=e.niceScale.max?(t.openBlock(),t.createElementBlock("text",{key:1,x:e.drawingArea.left-7+e.xPadding,y:e.checkNaN(a.y+r.fontSizes.dataLabels/3),"font-size":r.fontSizes.dataLabels,"text-anchor":"end",fill:e.FINAL_CONFIG.chart.grid.labels.color},t.toDisplayString(e.canShowValue(a.value)?e.applyDataLabel(e.FINAL_CONFIG.chart.grid.labels.yAxis.formatter,a.value,e.dataLabel({p:a.prefix,v:a.value,s:a.suffix,r:1})):""),9,Ye)):t.createCommentVNode("",!0)]))),128))])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.plotSet,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`serie_plot_${o}`,class:t.normalizeClass(`serie_plot_${o}`),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock("g",{key:`circle_plot_${o}_${c}`},[s&&e.canShowValue(s.value)?(t.openBlock(),t.createBlock(L,{key:0,shape:["triangle","square","diamond","pentagon","hexagon","star"].includes(a.shape)?a.shape:"circle",color:e.FINAL_CONFIG.plot.useGradient?`url(#plotGradient_${o}_${r.uniqueId})`:e.FINAL_CONFIG.plot.dot.useSerieColor?a.color:e.FINAL_CONFIG.plot.dot.fill,plot:{x:e.checkNaN(s.x),y:e.checkNaN(s.y)},radius:r.selectedSerieIndex!==null&&r.selectedSerieIndex===c||r.selectedMinimapIndex!==null&&r.selectedMinimapIndex===c?(r.plotRadii.plot||6)*1.5:r.plotRadii.plot||6,stroke:e.FINAL_CONFIG.plot.dot.useSerieColor?e.FINAL_CONFIG.chart.backgroundColor:a.color,strokeWidth:e.FINAL_CONFIG.plot.dot.strokeWidth},null,8,["shape","color","plot","radius","stroke","strokeWidth"])):t.createCommentVNode("",!0),s.comment&&e.FINAL_CONFIG.chart.comments.show?(t.openBlock(),t.createElementBlock("foreignObject",{key:1,style:{overflow:"visible"},height:"12",width:e.FINAL_CONFIG.chart.comments.width,x:s.x-e.FINAL_CONFIG.chart.comments.width/2+e.FINAL_CONFIG.chart.comments.offsetX,y:s.y+e.FINAL_CONFIG.chart.comments.offsetY+6},[t.createElementVNode("div",Ue,[t.renderSlot(l.$slots,"plot-comment",{plot:{...s,color:a.color,seriesIndex:o,datapointIndex:c}},void 0,!0)])],8,Xe)):t.createCommentVNode("",!0)]))),128)),Object.hasOwn(a,"useProgression")&&a.useProgression===!0&&!isNaN(e.calcLinearProgression(a.plots).trend)?(t.openBlock(),t.createElementBlock("g",Ze,[t.createElementVNode("defs",null,[t.createElementVNode("marker",{id:`plot_arrow_${o}`,markerWidth:7,markerHeight:7,refX:"0",refY:7/2,orient:"auto"},[t.createElementVNode("polygon",{points:`0 0, 7 ${7/2}, 0 7`,fill:a.color},null,8,Ke)],8,Je)]),a.plots.length>1?(t.openBlock(),t.createElementBlock("line",{key:0,x1:e.calcLinearProgression(a.plots).x1,x2:e.calcLinearProgression(a.plots).x2,y1:e.forceValidValue(e.calcLinearProgression(a.plots).y1),y2:e.forceValidValue(e.calcLinearProgression(a.plots).y2),"stroke-width":1,stroke:a.color,"stroke-dasharray":2,"marker-end":`url(#plot_arrow_${o})`},null,8,Qe)):t.createCommentVNode("",!0),a.plots.length>1?(t.openBlock(),t.createElementBlock("text",{key:1,"text-anchor":"middle",x:e.calcLinearProgression(a.plots).x2,y:e.calcLinearProgression(a.plots).y2-6,"font-size":r.fontSizes.plotLabels,fill:a.color},t.toDisplayString(e.dataLabel({v:e.calcLinearProgression(a.plots).trend*100,s:"%",r:2})),9,je)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)],6))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`serie_line_${o}`,class:t.normalizeClass(`serie_line_${o}`),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[a.smooth&&a.plots.length>1?(t.openBlock(),t.createElementBlock("path",{key:0,d:`M${a.curve}`,stroke:e.FINAL_CONFIG.chart.backgroundColor,"stroke-width":e.FINAL_CONFIG.line.strokeWidth+1,"stroke-dasharray":a.dashed?e.FINAL_CONFIG.line.strokeWidth*2:0,fill:"none"},null,8,$e)):a.plots.length>1?(t.openBlock(),t.createElementBlock("path",{key:1,d:`M${a.straight}`,stroke:e.FINAL_CONFIG.chart.backgroundColor,"stroke-width":e.FINAL_CONFIG.line.strokeWidth+1,"stroke-dasharray":a.dashed?e.FINAL_CONFIG.line.strokeWidth*2:0,fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},null,8,et)):t.createCommentVNode("",!0)],6))),128)),l.$slots.pattern?(t.openBlock(),t.createElementBlock("defs",tt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.safeDataset,(a,o)=>t.renderSlot(l.$slots,"pattern",t.mergeProps({key:`serie_pattern_slot_${o}`,ref_for:!0},{...a,seriesIndex:a.slotAbsoluteIndex,patternId:`pattern_${r.uniqueId}_${o}`}),void 0,!0)),128))])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`serie_line_${o}`,class:t.normalizeClass(`serie_line_${o}`),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[a.useArea&&a.plots.length>1?(t.openBlock(),t.createElementBlock("g",lt,[a.smooth?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createElementVNode("path",{d:`M ${a.plots[0]?a.plots[0].x:Math.min(...a.plots.filter(s=>!!s).map(s=>s.x))},${r.mutableConfig.isStacked?e.drawingArea.bottom-a.yOffset:e.drawingArea.bottom} ${a.curve} L ${a.plots.at(-1)?a.plots.at(-1).x:e.drawingArea.left+e.slot.line*o+e.slot.line/2},${r.mutableConfig.isStacked?e.drawingArea.bottom-a.yOffset:e.drawingArea.bottom} Z`,fill:e.FINAL_CONFIG.line.area.useGradient?`url(#areaGradient_${o}_${r.uniqueId})`:e.setOpacity(a.color,e.FINAL_CONFIG.line.area.opacity)},null,8,rt),l.$slots.pattern?(t.openBlock(),t.createElementBlock("path",{key:0,d:`M ${a.plots[0]?a.plots[0].x:Math.min(...a.plots.filter(s=>!!s).map(s=>s.x))},${r.mutableConfig.isStacked?e.drawingArea.bottom-a.yOffset:e.drawingArea.bottom} ${a.curve} L ${a.plots.at(-1)?a.plots.at(-1).x:e.drawingArea.left+e.slot.line*o+e.slot.line/2},${r.mutableConfig.isStacked?e.drawingArea.bottom-a.yOffset:e.drawingArea.bottom} Z`,fill:`url(#pattern_${r.uniqueId}_${a.slotAbsoluteIndex})`},null,8,at)):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createElementVNode("path",{d:`M${a.area}Z`,fill:e.FINAL_CONFIG.line.area.useGradient?`url(#areaGradient_${o}_${r.uniqueId})`:e.setOpacity(a.color,e.FINAL_CONFIG.line.area.opacity)},null,8,it),l.$slots.pattern?(t.openBlock(),t.createElementBlock("path",{key:0,d:`M${a.area}Z`,fill:`url(#pattern_${r.uniqueId}_${a.slotAbsoluteIndex})`},null,8,st)):t.createCommentVNode("",!0)],64))])):t.createCommentVNode("",!0),a.smooth&&a.plots.length>1?(t.openBlock(),t.createElementBlock("path",{key:1,d:`M${a.curve}`,stroke:a.color,"stroke-width":e.FINAL_CONFIG.line.strokeWidth,"stroke-dasharray":a.dashed?e.FINAL_CONFIG.line.strokeWidth*2:0,fill:"none","stroke-linecap":"round"},null,8,ot)):a.plots.length>1?(t.openBlock(),t.createElementBlock("path",{key:2,d:`M${a.straight}`,stroke:a.color,"stroke-width":e.FINAL_CONFIG.line.strokeWidth,"stroke-dasharray":a.dashed?e.FINAL_CONFIG.line.strokeWidth*2:0,fill:"none","stroke-linecap":"round","stroke-linejoin":"round"},null,8,nt)):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`circle_line_${o}_${c}`},[!e.optimize.linePlot&&s&&e.canShowValue(s.value)||e.optimize.linePlot&&s&&e.canShowValue(s.value)&&(r.selectedSerieIndex!==null&&r.selectedSerieIndex===c||r.selectedMinimapIndex!==null&&r.selectedMinimapIndex===c)?(t.openBlock(),t.createBlock(L,{key:0,shape:["triangle","square","diamond","pentagon","hexagon","star"].includes(a.shape)?a.shape:"circle",color:e.FINAL_CONFIG.line.useGradient?`url(#lineGradient_${o}_${r.uniqueId})`:e.FINAL_CONFIG.line.dot.useSerieColor?a.color:e.FINAL_CONFIG.line.dot.fill,plot:{x:e.checkNaN(s.x),y:e.checkNaN(s.y)},radius:r.selectedSerieIndex!==null&&r.selectedSerieIndex===c||r.selectedMinimapIndex!==null&&r.selectedMinimapIndex===c?(r.plotRadii.line||6)*1.5:r.plotRadii.line||6,stroke:e.FINAL_CONFIG.line.dot.useSerieColor?e.FINAL_CONFIG.chart.backgroundColor:a.color,strokeWidth:e.FINAL_CONFIG.line.dot.strokeWidth},null,8,["shape","color","plot","radius","stroke","strokeWidth"])):t.createCommentVNode("",!0),s.comment&&e.FINAL_CONFIG.chart.comments.show?(t.openBlock(),t.createElementBlock("foreignObject",{key:1,style:{overflow:"visible"},height:"12",width:e.FINAL_CONFIG.chart.comments.width,x:s.x-e.FINAL_CONFIG.chart.comments.width/2+e.FINAL_CONFIG.chart.comments.offsetX,y:s.y+e.FINAL_CONFIG.chart.comments.offsetY+6},[t.createElementVNode("div",ht,[t.renderSlot(l.$slots,"plot-comment",{plot:{...s,color:a.color,seriesIndex:o,datapointIndex:c}},void 0,!0)])],8,ct)):t.createCommentVNode("",!0)],64))),128)),Object.hasOwn(a,"useProgression")&&a.useProgression===!0&&!isNaN(e.calcLinearProgression(a.plots).trend)?(t.openBlock(),t.createElementBlock("g",dt,[t.createElementVNode("defs",null,[t.createElementVNode("marker",{id:`line_arrow_${o}`,markerWidth:7,markerHeight:7,refX:"0",refY:7/2,orient:"auto"},[t.createElementVNode("polygon",{points:`0 0, 7 ${7/2}, 0 7`,fill:a.color},null,8,gt)],8,ut)]),a.plots.length>1?(t.openBlock(),t.createElementBlock("line",{key:0,x1:e.calcLinearProgression(a.plots).x1,x2:e.calcLinearProgression(a.plots).x2,y1:e.forceValidValue(e.calcLinearProgression(a.plots).y1),y2:e.forceValidValue(e.calcLinearProgression(a.plots).y2),"stroke-width":1,stroke:a.color,"stroke-dasharray":2,"marker-end":`url(#line_arrow_${o})`},null,8,mt)):t.createCommentVNode("",!0),a.plots.length>1?(t.openBlock(),t.createElementBlock("text",{key:1,"text-anchor":"middle",x:e.calcLinearProgression(a.plots).x2,y:e.calcLinearProgression(a.plots).y2-6,"font-size":r.fontSizes.plotLabels,fill:a.color},t.toDisplayString(e.dataLabel({v:e.calcLinearProgression(a.plots).trend*100,s:"%",r:2})),9,ft)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)],6))),128)),(e.FINAL_CONFIG.bar.labels.show||e.FINAL_CONFIG.bar.serieName.show)&&r.mutableConfig.dataLabels.show?(t.openBlock(),t.createElementBlock("g",Nt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.barSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_bar_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_bar_${o}_${c}`},[s&&(!Object.hasOwn(a,"dataLabels")||a.dataLabels===!0||r.selectedSerieIndex!==null&&r.selectedSerieIndex===c||r.selectedMinimapIndex!==null&&r.selectedMinimapIndex===c)&&e.FINAL_CONFIG.bar.labels.show?(t.openBlock(),t.createElementBlock("text",{key:0,x:r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?s.x+e.slot.line/2:e.calcRectX(s)+e.calcRectWidth()/2-e.barPeriodGap/2,y:e.checkNaN(s.y)+(s.value>=0?e.FINAL_CONFIG.bar.labels.offsetY:-e.FINAL_CONFIG.bar.labels.offsetY*3),"text-anchor":"middle","font-size":r.fontSizes.plotLabels,fill:e.FINAL_CONFIG.bar.labels.color,style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},t.toDisplayString(e.canShowValue(s.value)?e.applyDataLabel(e.FINAL_CONFIG.bar.labels.formatter,s.value,e.dataLabel({p:a.prefix||e.FINAL_CONFIG.chart.labels.prefix,v:s.value,s:a.suffix||e.FINAL_CONFIG.chart.labels.suffix,r:e.FINAL_CONFIG.bar.labels.rounding}),{datapoint:s,serie:a}):""),13,It)):t.createCommentVNode("",!0),s&&e.FINAL_CONFIG.bar.serieName.show?(t.openBlock(),t.createElementBlock("text",{key:1,x:r.mutableConfig.useIndividualScale&&r.mutableConfig.isStacked?s.x+e.slot.line/2:s.x+e.calcRectWidth()*1.1,y:s.y+(s.value>0?e.FINAL_CONFIG.bar.serieName.offsetY:-e.FINAL_CONFIG.bar.serieName.offsetY*3),"text-anchor":"middle","font-size":r.fontSizes.plotLabels,fill:e.FINAL_CONFIG.bar.serieName.useSerieColor?a.color:e.FINAL_CONFIG.bar.serieName.color,"font-weight":e.FINAL_CONFIG.bar.serieName.bold?"bold":"normal",style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},t.toDisplayString(e.FINAL_CONFIG.bar.serieName.useAbbreviation?e.abbreviate({source:a.name,length:e.FINAL_CONFIG.bar.serieName.abbreviationSize}):a.name),13,xt)):t.createCommentVNode("",!0)],64))),128))],64))),128))])):t.createCommentVNode("",!0),e.FINAL_CONFIG.plot.labels.show&&r.mutableConfig.dataLabels.show?(t.openBlock(),t.createElementBlock("g",bt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.plotSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_plot_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_plot_${o}_${c}`},[s&&!Object.hasOwn(a,"dataLabels")||a.dataLabels===!0||r.selectedSerieIndex!==null&&r.selectedSerieIndex===c||r.selectedMinimapIndex!==null&&r.selectedMinimapIndex===c?(t.openBlock(),t.createElementBlock("text",{key:0,x:s.x,y:s.y+e.FINAL_CONFIG.plot.labels.offsetY,"text-anchor":"middle","font-size":r.fontSizes.plotLabels,fill:e.FINAL_CONFIG.plot.labels.color,style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},t.toDisplayString(e.canShowValue(s.value)?e.applyDataLabel(e.FINAL_CONFIG.plot.labels.formatter,s.value,e.dataLabel({p:a.prefix||e.FINAL_CONFIG.chart.labels.prefix,v:s.value,s:a.suffix||e.FINAL_CONFIG.chart.labels.suffix,r:e.FINAL_CONFIG.plot.labels.rounding}),{datapoint:s,serie:a}):""),13,Ft)):t.createCommentVNode("",!0)],64))),128))],64))),128))])):(t.openBlock(),t.createElementBlock("g",kt,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.plotSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_plot_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_plot_${o}_${c}`},[e.FINAL_CONFIG.plot.tag.followValue?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(c)&&a.useTag?(t.openBlock(),t.createElementBlock("line",{key:0,class:"vue-ui-xy-tag-plot",x1:e.drawingArea.left,x2:e.drawingArea.right,y1:s.y,y2:s.y,"stroke-width":1,"stroke-linecap":"round","stroke-dasharray":"2",stroke:a.color},null,8,At)):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[s&&c===0&&a.useTag&&a.useTag==="start"?(t.openBlock(),t.createElementBlock("foreignObject",{key:0,x:s.x,y:s.y-20,height:24,width:"150",style:t.normalizeStyle(`overflow: visible; opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[t.createElementVNode("div",{style:t.normalizeStyle(`padding: 3px; background:${e.setOpacity(a.color,80)};color:${e.adaptColorToBackground(a.color)};width:fit-content;font-size:${r.fontSizes.plotLabels}px;border-radius: 2px;`),innerHTML:e.applyDataLabel(e.FINAL_CONFIG.plot.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,12,yt)],12,_t)):t.createCommentVNode("",!0),s&&c===a.plots.length-1&&a.useTag&&a.useTag==="end"?(t.openBlock(),t.createElementBlock("foreignObject",{key:1,x:s.x-a.name.length*(r.fontSizes.plotLabels/2),y:s.y-20,height:24,width:"150",style:t.normalizeStyle(`overflow: visible; opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[t.createElementVNode("div",{style:t.normalizeStyle(`padding: 3px; background:${e.setOpacity(a.color,80)};color:${e.adaptColorToBackground(a.color)};width:fit-content;font-size:${r.fontSizes.plotLabels}px;border-radius: 2px;`),innerHTML:e.applyDataLabel(e.FINAL_CONFIG.plot.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,12,Ct)],12,Lt)):t.createCommentVNode("",!0)],64))],64))),128))],64))),128))])),e.FINAL_CONFIG.line.labels.show&&r.mutableConfig.dataLabels.show?(t.openBlock(),t.createElementBlock("g",St,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_line_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_line_${o}_${c}`},[s&&!Object.hasOwn(a,"dataLabels")||a.dataLabels===!0||r.selectedSerieIndex!==null&&r.selectedSerieIndex===c||r.selectedMinimapIndex!==null&&r.selectedMinimapIndex===c?(t.openBlock(),t.createElementBlock("text",{key:0,x:s.x,y:s.y+(s.value>=0?e.FINAL_CONFIG.line.labels.offsetY:-e.FINAL_CONFIG.line.labels.offsetY*3),"text-anchor":"middle","font-size":r.fontSizes.plotLabels,fill:e.FINAL_CONFIG.line.labels.color,style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},t.toDisplayString(e.canShowValue(s.value)?e.applyDataLabel(e.FINAL_CONFIG.line.labels.formatter,s.value,e.dataLabel({p:a.prefix||e.FINAL_CONFIG.chart.labels.prefix,v:s.value,s:a.suffix||e.FINAL_CONFIG.chart.labels.suffix,r:e.FINAL_CONFIG.line.labels.rounding}),{datapoint:s,serie:a}):""),13,wt)):t.createCommentVNode("",!0)],64))),128))],64))),128))])):(t.openBlock(),t.createElementBlock("g",Ot,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_line_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_line_${o}_${c}`},[e.FINAL_CONFIG.line.tag.followValue?(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(c)&&a.useTag?(t.openBlock(),t.createElementBlock("line",{key:0,class:"vue-ui-xy-tag-line",x1:e.drawingArea.left,x2:e.drawingArea.right,y1:s.y,y2:s.y,"stroke-width":1,"stroke-linecap":"round","stroke-dasharray":"2",stroke:a.color},null,8,Et)):t.createCommentVNode("",!0)],64)):(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[s&&c===0&&a.useTag&&a.useTag==="start"?(t.openBlock(),t.createElementBlock("foreignObject",{key:0,x:s.x,y:s.y-20,height:24,width:"150",style:t.normalizeStyle(`overflow: visible; opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[t.createElementVNode("div",{style:t.normalizeStyle(`padding: 3px; background:${e.setOpacity(a.color,80)};color:${e.adaptColorToBackground(a.color)};width:fit-content;font-size:${r.fontSizes.plotLabels}px;border-radius: 2px;`),innerHTML:e.applyDataLabel(e.FINAL_CONFIG.line.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,12,vt)],12,Gt)):t.createCommentVNode("",!0),s&&c===a.plots.length-1&&a.useTag&&a.useTag==="end"?(t.openBlock(),t.createElementBlock("foreignObject",{key:1,x:s.x,y:s.y-20,height:24,width:"150",style:t.normalizeStyle(`overflow: visible; opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},[t.createElementVNode("div",{style:t.normalizeStyle(`padding: 3px; background:${e.setOpacity(a.color,80)};color:${e.adaptColorToBackground(a.color)};width:fit-content;font-size:${r.fontSizes.plotLabels}px;border-radius: 2px;`),innerHTML:e.applyDataLabel(e.FINAL_CONFIG.line.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,12,Bt)],12,pt)):t.createCommentVNode("",!0)],64))],64))),128))],64))),128))])),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_line_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_line_${o}_${c}`},[s&&c===0&&a.showSerieName&&a.showSerieName==="start"?(t.openBlock(),t.createElementBlock("text",{key:0,x:s.x-r.fontSizes.plotLabels,y:s.y,"font-size":r.fontSizes.plotLabels,"text-anchor":"end",fill:a.color,innerHTML:e.createTSpans({content:a.name,fontSize:r.fontSizes.plotLabels,fill:a.color,x:s.x-r.fontSizes.plotLabels,y:s.y,maxWords:2}),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},null,12,Vt)):t.createCommentVNode("",!0),s&&c===a.plots.length-1&&a.showSerieName&&a.showSerieName==="end"?(t.openBlock(),t.createElementBlock("text",{key:1,x:s.x+r.fontSizes.plotLabels,y:s.y,"font-size":r.fontSizes.plotLabels,"text-anchor":"start",fill:a.color,innerHTML:e.createTSpans({content:a.name,fontSize:r.fontSizes.plotLabels,fill:a.color,x:s.x+r.fontSizes.plotLabels,y:s.y,maxWords:2}),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},null,12,zt)):t.createCommentVNode("",!0)],64))),128))],64))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.plotSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_plot_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`xLabel_plot_${o}_${c}`},[s&&c===0&&a.showSerieName&&a.showSerieName==="start"?(t.openBlock(),t.createElementBlock("text",{key:0,x:s.x-r.fontSizes.plotLabels,y:s.y,"font-size":r.fontSizes.plotLabels,"text-anchor":"end",fill:a.color,innerHTML:e.createTSpans({content:a.name,fontSize:r.fontSizes.plotLabels,fill:a.color,x:s.x-r.fontSizes.plotLabels,y:s.y,maxWords:2}),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},null,12,Mt)):t.createCommentVNode("",!0),s&&c===a.plots.length-1&&a.showSerieName&&a.showSerieName==="end"?(t.openBlock(),t.createElementBlock("text",{key:1,x:s.x+r.fontSizes.plotLabels,y:s.y,"font-size":r.fontSizes.plotLabels,"text-anchor":"start",fill:a.color,innerHTML:e.createTSpans({content:a.name,fontSize:r.fontSizes.plotLabels,fill:a.color,x:s.x+r.fontSizes.plotLabels,y:s.y,maxWords:2}),style:t.normalizeStyle(`opacity:${r.selectedScale?r.selectedScale===a.groupId?1:.2:1};transition:opacity 0.2s ease-in-out`)},null,12,Tt)):t.createCommentVNode("",!0)],64))),128))],64))),128)),r.mutableConfig.useIndividualScale&&!r.mutableConfig.isStacked?(t.openBlock(),t.createElementBlock(t.Fragment,{key:11},[t.createElementVNode("defs",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.allScales,(a,o)=>(t.openBlock(),t.createElementBlock("linearGradient",{id:`individual_scale_gradient_${r.uniqueId}_${o}`,x1:"0%",x2:"100%",y1:"0%",y2:"0%"},[t.createElementVNode("stop",{offset:"0%","stop-color":e.FINAL_CONFIG.chart.backgroundColor,"stop-opacity":"0"},null,8,Rt),t.createElementVNode("stop",{offset:"100%","stop-color":a.color,"stop-opacity":"0.2"},null,8,Dt)],8,Pt))),256))]),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.allScales,(a,o)=>(t.openBlock(),t.createElementBlock("rect",{x:a.x-e.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth+e.xPadding,y:e.drawingArea.top,width:e.FINAL_CONFIG.chart.grid.labels.yAxis.labelWidth,height:e.drawingArea.height<0?10:e.drawingArea.height,fill:r.selectedScale===a.groupId?`url(#individual_scale_gradient_${r.uniqueId}_${o})`:"transparent",onMouseenter:s=>r.selectedScale=a.groupId,onMouseleave:i[0]||(i[0]=s=>r.selectedScale=null)},null,40,Ht))),256))],64)):t.createCommentVNode("",!0),t.createElementVNode("g",null,[e.FINAL_CONFIG.chart.grid.labels.axis.yLabel&&!r.mutableConfig.useIndividualScale?(t.openBlock(),t.createElementBlock("text",{key:0,"font-size":r.fontSizes.yAxis,fill:e.FINAL_CONFIG.chart.grid.labels.color,transform:`translate(${r.fontSizes.yAxis+e.FINAL_CONFIG.chart.grid.labels.axis.yLabelOffsetX}, ${e.drawingArea.top+e.drawingArea.height/2}) rotate(-90)`,"text-anchor":"middle",style:{transition:"none"}},t.toDisplayString(e.FINAL_CONFIG.chart.grid.labels.axis.yLabel),9,qt)):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.grid.labels.axis.xLabel?(t.openBlock(),t.createElementBlock("text",{key:1,"text-anchor":"middle",x:r.width/2,y:e.drawingArea.bottom+r.fontSizes.yAxis+r.fontSizes.xAxis*1.3+e.FINAL_CONFIG.chart.grid.labels.axis.xLabelOffsetY,"font-size":r.fontSizes.yAxis,fill:e.FINAL_CONFIG.chart.grid.labels.color},t.toDisplayString(e.FINAL_CONFIG.chart.grid.labels.axis.xLabel),9,Wt)):t.createCommentVNode("",!0)]),i[9]||(i[9]=t.createTextVNode('v-for="(label, i) in timeLabels" :key="`time_label_${i}`" ')),e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.show?(t.openBlock(),t.createElementBlock("g",Yt,[l.$slots["time-label"]?(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:0},t.renderList(e.timeLabels,(a,o)=>t.renderSlot(l.$slots,"time-label",t.mergeProps({key:`time_label_${o}`,ref_for:!0},{x:e.drawingArea.left+e.drawingArea.width/e.maxSeries*o+e.drawingArea.width/e.maxSeries/2,y:e.drawingArea.bottom+r.fontSizes.xAxis*1.3+e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.yOffset,fontSize:r.fontSizes.xAxis,fill:e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.color,transform:`translate(${e.drawingArea.left+e.drawingArea.width/e.maxSeries*o+e.drawingArea.width/e.maxSeries/2}, ${e.drawingArea.bottom+r.fontSizes.xAxis*1.3+e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.yOffset}), rotate(${e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation})`,absoluteIndex:a.absoluteIndex,content:a.text,textAnchor:e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation>0?"start":e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation<0?"end":"middle",show:a&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo||a&&e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&(o===0||o===e.timeLabels.length-1)&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo||a&&e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&r.selectedSerieIndex===o&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo||a&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo&&o%Math.floor((this.slicer.end-this.slicer.start)/e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.modulo)===0}),void 0,!0)),128)):(t.openBlock(!0),t.createElementBlock(t.Fragment,{key:1},t.renderList(e.timeLabels,(a,o)=>(t.openBlock(),t.createElementBlock("g",{key:`time_label_${o}`},[a&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo||a&&e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&(o===0||o===e.timeLabels.length-1)&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo||a&&e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&r.selectedSerieIndex===o&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo||a&&!e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyFirstAndLast&&e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.showOnlyAtModulo&&o%Math.floor((this.slicer.end-this.slicer.start)/e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.modulo)===0?(t.openBlock(),t.createElementBlock("text",{key:0,"text-anchor":e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation>0?"start":e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation<0?"end":"middle","font-size":r.fontSizes.xAxis,fill:e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.color,transform:`translate(${e.drawingArea.left+e.drawingArea.width/e.maxSeries*o+e.drawingArea.width/e.maxSeries/2}, ${e.drawingArea.bottom+r.fontSizes.xAxis*1.3+e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.yOffset}), rotate(${e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.rotation})`,style:{cursor:"pointer"},onClick:()=>e.selectTimeLabel(a,o)},t.toDisplayString(a.text||""),9,Xt)):t.createCommentVNode("",!0)]))),128))])):t.createCommentVNode("",!0),t.createElementVNode("g",null,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.maxSeries,(a,o)=>(t.openBlock(),t.createElementBlock("rect",{key:`tooltip_trap_${o}`,x:e.drawingArea.left+e.drawingArea.width/e.maxSeries*o,y:e.drawingArea.top,height:e.drawingArea.height<0?10:e.drawingArea.height,width:e.drawingArea.width/e.maxSeries<0?1e-5:e.drawingArea.width/e.maxSeries,fill:"transparent",onMouseenter:s=>e.toggleTooltipVisibility(!0,o),onMouseleave:i[1]||(i[1]=s=>e.toggleTooltipVisibility(!1)),onClick:s=>e.selectX(o)},null,40,Ut))),128))]),e.FINAL_CONFIG.chart.timeTag.show&&(![null,void 0].includes(r.selectedSerieIndex)||![null,void 0].includes(r.selectedMinimapIndex))?(t.openBlock(),t.createElementBlock("g",Zt,[(t.openBlock(),t.createElementBlock("foreignObject",{x:e.drawingArea.left+e.drawingArea.width/e.maxSeries*((r.selectedSerieIndex!==null?r.selectedSerieIndex:0)||(r.selectedMinimapIndex!==null?r.selectedMinimapIndex:0))-100+e.drawingArea.width/e.maxSeries/2,y:e.drawingArea.bottom,width:"200",height:"40",style:{overflow:"visible !important"}},[t.createElementVNode("div",{class:"vue-ui-xy-time-tag",style:t.normalizeStyle(`width: fit-content;margin: 0 auto;text-align:center;padding:3px 12px;background:${e.FINAL_CONFIG.chart.timeTag.backgroundColor};color:${e.FINAL_CONFIG.chart.timeTag.color};font-size:${e.FINAL_CONFIG.chart.timeTag.fontSize}px`)},t.toDisplayString(e.timeLabels[(r.selectedSerieIndex!==null?r.selectedSerieIndex:0)||(r.selectedMinimapIndex!==null?r.selectedMinimapIndex:0)].text||(r.selectedSerieIndex!==null?r.selectedSerieIndex:0)||(r.selectedMinimapIndex!==null?r.selectedMinimapIndex:0)),5)],8,Jt)),t.createElementVNode("circle",{cx:e.drawingArea.left+e.drawingArea.width/e.maxSeries*((r.selectedSerieIndex!==null?r.selectedSerieIndex:0)||(r.selectedMinimapIndex!==null?r.selectedMinimapIndex:0))+e.drawingArea.width/e.maxSeries/2,cy:e.drawingArea.bottom,r:e.FINAL_CONFIG.chart.timeTag.circleMarker.radius,fill:e.FINAL_CONFIG.chart.timeTag.circleMarker.color},null,8,Kt)])):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),t.renderSlot(l.$slots,"svg",{svg:e.svg},void 0,!0)],14,J)):t.createCommentVNode("",!0),l.$slots.watermark?(t.openBlock(),t.createElementBlock("div",Qt,[t.renderSlot(l.$slots,"watermark",t.normalizeProps(t.guardReactiveProps({isPrinting:r.isPrinting||r.isImaging})),void 0,!0)])):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.lineSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`tag_line_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`tag_line_${o}_${c}`},[[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(c)&&a.useTag&&a.useTag==="end"&&e.FINAL_CONFIG.line.tag.followValue?(t.openBlock(),t.createElementBlock("div",{key:0,ref_for:!0,ref:f=>e.setTagRef(o,c,f,"right","line"),class:"vue-ui-xy-tag","data-tag":"right",style:t.normalizeStyle({position:"fixed",top:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.right+e.FINAL_CONFIG.line.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_right_line`],position:"right"}).top+"px",left:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.right+e.FINAL_CONFIG.line.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_right_line`],position:"right"}).left+"px",height:"fit-content",width:"fit-content",background:a.color,color:e.adaptColorToBackground(a.color),padding:"0 6px",fontSize:e.FINAL_CONFIG.line.tag.fontSize+"px",opacity:1})},[(t.openBlock(),t.createElementBlock("svg",jt,[t.createElementVNode("path",{d:"M 0,10 10,0 10,20 Z",fill:a.color,stroke:"none"},null,8,$t)])),t.createElementVNode("div",{class:"vue-ui-xy-tag-content",innerHTML:e.applyDataLabel(e.FINAL_CONFIG.line.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,8,el)],4)):t.createCommentVNode("",!0),[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(c)&&a.useTag&&a.useTag==="start"&&e.FINAL_CONFIG.line.tag.followValue?(t.openBlock(),t.createElementBlock("div",{key:1,ref_for:!0,ref:f=>e.setTagRef(o,c,f,"left","line"),class:"vue-ui-xy-tag","data-tag":"left",style:t.normalizeStyle({position:"fixed",top:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.left-e.FINAL_CONFIG.line.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_left_line`],position:"left"}).top+"px",left:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.left-e.FINAL_CONFIG.line.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_left_line`],position:"left"}).left+"px",height:"fit-content",width:"fit-content",background:a.color,color:e.adaptColorToBackground(a.color),padding:"0 6px",fontSize:e.FINAL_CONFIG.line.tag.fontSize+"px",opacity:1})},[(t.openBlock(),t.createElementBlock("svg",tl,[t.createElementVNode("path",{d:"M 0,0 10,10 0,20 Z",fill:a.color,stroke:"none"},null,8,ll)])),t.createElementVNode("div",{class:"vue-ui-xy-tag-content",innerHTML:e.applyDataLabel(e.FINAL_CONFIG.line.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,8,rl)],4)):t.createCommentVNode("",!0)],64))),128))],64))),128)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.plotSet,(a,o)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`tag_plot_${o}`},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(a.plots,(s,c)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:`tag_plot_${o}_${c}`},[[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(c)&&a.useTag&&a.useTag==="end"&&e.FINAL_CONFIG.plot.tag.followValue?(t.openBlock(),t.createElementBlock("div",{key:0,ref_for:!0,ref:f=>e.setTagRef(o,c,f,"right","plot"),class:"vue-ui-xy-tag","data-tag":"right",style:t.normalizeStyle({position:"fixed",top:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.right+e.FINAL_CONFIG.plot.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_right_plot`],position:"right"}).top+"px",left:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.right+e.FINAL_CONFIG.plot.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_right_plot`],position:"right"}).left+"px",height:"fit-content",width:"fit-content",background:a.color,color:e.adaptColorToBackground(a.color),padding:"0 6px",fontSize:e.FINAL_CONFIG.plot.tag.fontSize+"px",opacity:1})},[(t.openBlock(),t.createElementBlock("svg",al,[t.createElementVNode("path",{d:"M 0,10 10,0 10,20 Z",fill:a.color,stroke:"none"},null,8,il)])),t.createElementVNode("div",{class:"vue-ui-xy-tag-content",innerHTML:e.applyDataLabel(e.FINAL_CONFIG.plot.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,8,sl)],4)):t.createCommentVNode("",!0),[r.selectedMinimapIndex,r.selectedSerieIndex,r.selectedRowIndex].includes(c)&&a.useTag&&a.useTag==="start"&&e.FINAL_CONFIG.plot.tag.followValue?(t.openBlock(),t.createElementBlock("div",{key:1,ref_for:!0,ref:f=>e.setTagRef(o,c,f,"left","plot"),class:"vue-ui-xy-tag","data-tag":"left",style:t.normalizeStyle({position:"fixed",top:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.left-e.FINAL_CONFIG.plot.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_left_plot`],position:"left"}).top+"px",left:e.placeXYTag({svgElement:r.svgRef,x:e.drawingArea.left-e.FINAL_CONFIG.plot.tag.fontSize/1.5,y:s.y,element:r.tagRefs[`${o}_${c}_left_plot`],position:"left"}).left+"px",height:"fit-content",width:"fit-content",background:a.color,color:e.adaptColorToBackground(a.color),padding:"0 6px",fontSize:e.FINAL_CONFIG.plot.tag.fontSize+"px",opacity:1})},[(t.openBlock(),t.createElementBlock("svg",ol,[t.createElementVNode("path",{d:"M 0,0 10,10 0,20 Z",fill:a.color,stroke:"none"},null,8,nl)])),t.createElementVNode("div",{class:"vue-ui-xy-tag-content",innerHTML:e.applyDataLabel(e.FINAL_CONFIG.plot.tag.formatter,s.value,a.name,{datapoint:s,seriesIndex:c,serieName:a.name})},null,8,cl)],4)):t.createCommentVNode("",!0)],64))),128))],64))),128)),e.isDataset?t.createCommentVNode("",!0):(t.openBlock(),t.createBlock(_,{key:6,config:{type:"line",style:{backgroundColor:e.FINAL_CONFIG.chart.backgroundColor,line:{axis:{color:e.FINAL_CONFIG.chart.grid.stroke},path:{color:e.FINAL_CONFIG.chart.grid.stroke,strokeWidth:.5}}}}},null,8,["config"])),e.FINAL_CONFIG.chart.zoom.show&&r.maxX>6&&e.isDataset?(t.openBlock(),t.createBlock(C,{ref:"chartSlicer",key:`slicer_${r.slicerStep}`,background:e.FINAL_CONFIG.chart.zoom.color,fontSize:e.FINAL_CONFIG.chart.zoom.fontSize,useResetSlot:e.FINAL_CONFIG.chart.zoom.useResetSlot,labelLeft:e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[r.slicer.start],labelRight:e.FINAL_CONFIG.chart.grid.labels.xAxisLabels.values[r.slicer.end-1],textColor:e.FINAL_CONFIG.chart.color,inputColor:e.FINAL_CONFIG.chart.zoom.color,selectColor:e.FINAL_CONFIG.chart.zoom.highlightColor,borderColor:e.FINAL_CONFIG.chart.backgroundColor,minimap:e.minimap,smoothMinimap:e.FINAL_CONFIG.chart.zoom.minimap.smooth,minimapSelectedColor:e.FINAL_CONFIG.chart.zoom.minimap.selectedColor,minimapSelectionRadius:e.FINAL_CONFIG.chart.zoom.minimap.selectionRadius,minimapLineColor:e.FINAL_CONFIG.chart.zoom.minimap.lineColor,minimapSelectedColorOpacity:e.FINAL_CONFIG.chart.zoom.minimap.selectedColorOpacity,minimapSelectedIndex:r.selectedSerieIndex,minimapIndicatorColor:e.FINAL_CONFIG.chart.zoom.minimap.indicatorColor,verticalHandles:e.FINAL_CONFIG.chart.zoom.minimap.verticalHandles,max:r.maxX,min:0,valueStart:r.slicer.start,valueEnd:r.slicer.end,start:r.slicer.start,"onUpdate:start":i[2]||(i[2]=a=>r.slicer.start=a),end:r.slicer.end,"onUpdate:end":i[3]||(i[3]=a=>r.slicer.end=a),refreshStartPoint:e.FINAL_CONFIG.chart.zoom.startIndex!==null?e.FINAL_CONFIG.chart.zoom.startIndex:0,refreshEndPoint:e.FINAL_CONFIG.chart.zoom.endIndex!==null?e.FINAL_CONFIG.chart.zoom.endIndex+1:Math.max(...n.dataset.map(a=>e.largestTriangleThreeBucketsArray({data:a.series,threshold:e.FINAL_CONFIG.downsample.threshold}).length)),enableRangeHandles:e.FINAL_CONFIG.chart.zoom.enableRangeHandles,enableSelectionDrag:e.FINAL_CONFIG.chart.zoom.enableSelectionDrag,onReset:e.refreshSlicer,onTrapMouse:e.selectMinimapIndex},{"reset-action":t.withCtx(({reset:a})=>[t.renderSlot(l.$slots,"reset-action",t.normalizeProps(t.guardReactiveProps({reset:a})),void 0,!0)]),_:3},8,["background","fontSize","useResetSlot","labelLeft","labelRight","textColor","inputColor","selectColor","borderColor","minimap","smoothMinimap","minimapSelectedColor","minimapSelectionRadius","minimapLineColor","minimapSelectedColorOpacity","minimapSelectedIndex","minimapIndicatorColor","verticalHandles","max","valueStart","valueEnd","start","end","refreshStartPoint","refreshEndPoint","enableRangeHandles","enableSelectionDrag","onReset","onTrapMouse"])):t.createCommentVNode("",!0),e.FINAL_CONFIG.chart.legend.show?(t.openBlock(),t.createElementBlock("div",{key:8,ref:"chartLegend",class:"vue-ui-xy-legend",style:t.normalizeStyle(`font-size:${e.FINAL_CONFIG.chart.legend.fontSize}px`)},[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.absoluteDataset,(a,o)=>(t.openBlock(),t.createElementBlock("div",{key:`div_legend_item_${o}`,onClick:s=>e.segregate(a),class:t.normalizeClass({"vue-ui-xy-legend-item":!0,"vue-ui-xy-legend-item-segregated":r.segregatedSeries.includes(a.id)})},[r.icons[a.type]==="line"?(t.openBlock(),t.createElementBlock("svg",dl,[t.createElementVNode("rect",{x:"0",y:"7.5",rx:"1.5",stroke:e.FINAL_CONFIG.chart.backgroundColor,"stroke-width":.5,height:"3",width:"20",fill:a.color},null,8,ul),t.createVNode(L,{plot:{x:10,y:9},radius:4,color:a.color,shape:["triangle","square","diamond","pentagon","hexagon","star"].includes(a.shape)?a.shape:"circle",stroke:e.FINAL_CONFIG.chart.backgroundColor,strokeWidth:.5},null,8,["color","shape","stroke"])])):r.icons[a.type]==="bar"?(t.openBlock(),t.createElementBlock("svg",gl,[r.icons[a.type]==="bar"&&l.$slots.pattern?(t.openBlock(),t.createElementBlock("rect",{key:0,x:"0",y:"0",rx:"1",height:"40",width:"40",stroke:"none",fill:a.color},null,8,ml)):t.createCommentVNode("",!0),r.icons[a.type]==="bar"?(t.openBlock(),t.createElementBlock("rect",{key:1,x:"0",y:"0",rx:"1",height:"40",width:"40",stroke:"none",fill:l.$slots.pattern?`url(#pattern_${r.uniqueId}_${a.slotAbsoluteIndex})`:a.color},null,8,fl)):t.createCommentVNode("",!0)])):(t.openBlock(),t.createElementBlock("svg",Nl,[t.createVNode(L,{plot:{x:6,y:6},radius:5,color:a.color,shape:["triangle","square","diamond","pentagon","hexagon","star"].includes(a.shape)?a.shape:"circle"},null,8,["color","shape"])])),t.createElementVNode("span",{style:t.normalizeStyle(`color:${e.FINAL_CONFIG.chart.legend.color}`)},t.toDisplayString(a.name),5)],10,hl))),128))],4)):(t.openBlock(),t.createElementBlock("div",Il,[t.renderSlot(l.$slots,"legend",{legend:e.absoluteDataset},void 0,!0)],512)),l.$slots.source?(t.openBlock(),t.createElementBlock("div",xl,[t.renderSlot(l.$slots,"source",{},void 0,!0)],512)):t.createCommentVNode("",!0),t.createVNode(y,{show:r.mutableConfig.showTooltip&&r.isTooltip,backgroundColor:e.FINAL_CONFIG.chart.tooltip.backgroundColor,color:e.FINAL_CONFIG.chart.tooltip.color,fontSize:e.FINAL_CONFIG.chart.tooltip.fontSize,borderRadius:e.FINAL_CONFIG.chart.tooltip.borderRadius,borderColor:e.FINAL_CONFIG.chart.tooltip.borderColor,borderWidth:e.FINAL_CONFIG.chart.tooltip.borderWidth,backgroundOpacity:e.FINAL_CONFIG.chart.tooltip.backgroundOpacity,position:e.FINAL_CONFIG.chart.tooltip.position,offsetY:e.FINAL_CONFIG.chart.tooltip.offsetY,parent:l.$refs.chart,content:e.tooltipContent,isFullscreen:r.isFullscreen,isCustom:e.FINAL_CONFIG.chart.tooltip.customFormat&&typeof e.FINAL_CONFIG.chart.tooltip.customFormat=="function"},{"tooltip-before":t.withCtx(()=>[t.renderSlot(l.$slots,"tooltip-before",t.normalizeProps(t.guardReactiveProps({...e.dataTooltipSlot})),void 0,!0)]),"tooltip-after":t.withCtx(()=>[t.renderSlot(l.$slots,"tooltip-after",t.normalizeProps(t.guardReactiveProps({...e.dataTooltipSlot})),void 0,!0)]),_:3},8,["show","backgroundColor","color","fontSize","borderRadius","borderColor","borderWidth","backgroundOpacity","position","offsetY","parent","content","isFullscreen","isCustom"]),e.isDataset?(t.openBlock(),t.createBlock(O,{key:11,hideDetails:"",config:{open:r.mutableConfig.showTable,maxHeight:1e4,body:{backgroundColor:e.FINAL_CONFIG.chart.backgroundColor,color:e.FINAL_CONFIG.chart.color},head:{backgroundColor:e.FINAL_CONFIG.chart.backgroundColor,color:e.FINAL_CONFIG.chart.color}}},{content:t.withCtx(()=>[t.createElementVNode("div",{style:t.normalizeStyle(`${r.isPrinting?"":"max-height:400px"};overflow:auto;width:100%;margin-top:48px`)},[t.createElementVNode("div",bl,[t.withDirectives(t.createElementVNode("input",{type:"checkbox","onUpdate:modelValue":i[4]||(i[4]=a=>r.showSparklineTable=a)},null,512),[[t.vModelCheckbox,r.showSparklineTable]]),t.createElementVNode("div",{onClick:i[5]||(i[5]=a=>r.showSparklineTable=!r.showSparklineTable),style:{cursor:"pointer"}},[t.createVNode(m,{name:"chartLine",size:20,stroke:e.FINAL_CONFIG.chart.color},null,8,["stroke"])])]),r.showSparklineTable?(t.openBlock(),t.createBlock(F,{key:`sparkline_${r.segregateStep}`,dataset:e.tableSparklineDataset,config:e.tableSparklineConfig},null,8,["dataset","config"])):(t.openBlock(),t.createBlock(A,{key:`table_${r.tableStep}`,colNames:e.dataTable.colNames,head:e.dataTable.head,body:e.dataTable.body,config:e.dataTable.config,title:`${e.FINAL_CONFIG.chart.title.text}${e.FINAL_CONFIG.chart.title.subtitle.text?` : ${e.FINAL_CONFIG.chart.title.subtitle.text}`:""}`,onClose:i[6]||(i[6]=a=>r.mutableConfig.showTable=!1)},{th:t.withCtx(({th:a})=>[t.createElementVNode("div",{innerHTML:a},null,8,Fl)]),td:t.withCtx(({td:a})=>[t.createTextVNode(t.toDisplayString(isNaN(Number(a))?a:e.dataLabel({p:e.FINAL_CONFIG.chart.labels.prefix,v:a,s:e.FINAL_CONFIG.chart.labels.suffix,r:e.FINAL_CONFIG.table.rounding})),1)]),_:1},8,["colNames","head","body","config","title"]))],4)]),_:1},8,["config"])):t.createCommentVNode("",!0)],46,U)}const _l=W._export_sfc(X,[["render",kl],["__scopeId","data-v-0ccd7c1c"]]);exports.default=_l;
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),t="2.6.44-beta.0",n={"aria-hidden":"true"},s={__name:"PackageVersion",setup(c){return(r,o)=>(e.openBlock(),e.createElementBlock("desc",n,"Composed with Vue Data UI "+e.toDisplayString(e.unref(t)),1))}};exports._sfc_main=s;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),s=require("./index-hcakVXU6.cjs"),Fe=require("./Title-DRo5NxnS.cjs"),xe=require("./usePrinter-Dv0RMCX1.cjs"),Ie=require("./Tooltip-Cbjcw6Jz.cjs"),De=require("./Legend-DpeobB-J.cjs"),qe=require("./vue-ui-skeleton-FXF7pMM8.cjs"),Me=require("./DataTable-ChXRV1c1.cjs"),He=require("./vue-ui-accordion-BfFg-sVJ.cjs"),Te=require("./useResponsive-N8jl0-aC.cjs"),Se=require("./useNestedProp-DCfCPrTU.cjs"),Ue=require("./PackageVersion-C9u9Pwxk.cjs"),We=require("./PenAndPaper-B3u1FDG_.cjs"),Ge=require("./useUserOptionState-BgepsfED.cjs"),je=require("./useChartAccessibility-Cm7nkzTG.cjs"),Xe=require("./BaseIcon-CNr0ynIA.cjs"),Ye=require("./_plugin-vue_export-helper-BHFhmbuH.cjs");function $e(r,c){const i=r.length;if(i===0)throw new Error(`Max aspect ratio cannot be computed: ${r} is an empty array`);{let d=1/0,u=-1/0,v=0;for(let p=0;p<i;p+=1){const f=r[p].normalizedValue;f<d&&(d=f),f>u&&(u=f),v+=f}return Math.max(c**2*u/v**2,v**2/(c**2*d))}}function Be(r){const{xOffset:c,yOffset:i,width:d,height:u}=r;return{x0:c,y0:i,x1:c+d,y1:i+u}}function Ze(r,c,i){if(r.length===0)return!0;{const d=r.concat(c),u=$e(r,i),v=$e(d,i);return u>=v}}function Je(r){const c=[],i=r.length;for(let d=0;d<i;d+=1){const u=r[d],v=u.length;for(let h=0;h<v;h+=1)c.push(u[h])}return c}function Ke(r,c){const i={...c,children:r};return Oe(i)}function Qe(r){return(r.x1-r.x0)*(r.y1-r.y0)}function Ne(r,c){const{width:i,height:d,xOffset:u,yOffset:v}=J(c),h=r.length,p=r.map(y=>y.normalizedValue||0).reduce((y,g)=>y+g,0),f=p/d,x=p/i;let C=u,T=v;const b=[];if(i>=d){for(let y=0;y<h;y+=1){const g=r[y],k=T+g.normalizedValue/f,O={x0:C,y0:T,x1:C+f,y1:k},S=Object.assign({},g,O);T=k,b.push(S)}return b}else{for(let y=0;y<h;y+=1){const g=r[y],k=C+g.normalizedValue/x,O={x0:C,y0:T,x1:k,y1:T+x},S=Object.assign({},g,O);C=k,b.push(S)}return b}}function et(r){const c=J(r),i=c.width,d=c.height;return Math.min(i,d)}function tt(r,c){const i=r.length,d=r.map(f=>f.value??0).reduce((f,x)=>f+x,0),u=c/d,v=[];let h,p;for(let f=0;f<i;f+=1)p=r[f],h=Object.assign({},p,{normalizedValue:p.value*(u||0)}),v.push(h);return v}function J(r){const{x0:c,y0:i,x1:d,y1:u}=r;return{xOffset:c,yOffset:i,width:d-c,height:u-i}}function ot(r,c,i,d){let u=r,v=c,h=i,p=d;for(;;){const f=u.length;if(f===0){const b=Ne(v,h);return p.concat(b)}const x=et(h),C=u[0],T=u.slice(1,f);if(Ze(v,C,x)){const b=v.concat(C);u=T,v=b,h=h,p=p}else{const b=v.length;let y=0;for(let S=0;S<b;S+=1)y+=v[S].normalizedValue;const g=lt(h,y),k=Ne(v,h),O=p.concat(k);u=u,v=[],h=g,p=O}}}function Oe(r){if(typeof r.children>"u"||!r.children.length)return[r];{const c=tt(r.children,Qe(r)),i=ot(c,[],r,[]),d=i.length,u=[];for(let h=0;h<d;h+=1)u.push(Oe(i[h]));return Je(u)}}function lt(r,c){const{width:i,height:d,xOffset:u,yOffset:v}=J(r);if(i>=d){const h=c/d,p=i-h,f={xOffset:u+h,yOffset:v,width:p,height:d};return Be(f)}else{const h=c/i,p=d-h,f={xOffset:u,yOffset:v+h,width:i,height:p};return Be(f)}}const at=["id"],nt={key:4,class:"vue-ui-treemap-breadcrumbs","data-html2canvas-ignore":""},rt=["onClick","data-last-crumb"],st={class:"vue-ui-treemap-crumb-unit"},ut={class:"vue-ui-treemap-crumb-unit-label"},it={key:0,style:{width:"24px",display:"flex","align-items":"center"}},ct={key:0,class:"vue-ui-treemap-crumb-unit-arrow"},dt=["xmlns","viewBox"],vt={key:0},ht=["id"],pt=["stop-color"],ft=["stop-color"],mt=["x","y","height","width","fill","rx","stroke","stroke-width","onClick","onMouseenter"],gt=["x","y","height","width"],yt={style:{width:"100%",height:"100%"},class:"vue-ui-treemap-cell"},bt={key:6,class:"vue-data-ui-watermark"},kt=["onClick"],Ct={key:0},wt={key:1},xt=["innerHTML"],Tt={__name:"vue-ui-treemap",props:{config:{type:Object,default(){return{}}},dataset:{type:Array,default(){return[]}}},emits:["selectLegend","selectDatapoint"],setup(r,{expose:c,emit:i}){const{vue_ui_treemap:d}=s.useConfig(),u=r,v=i,h=e.useSlots();e.onMounted(()=>{h["chart-background"]&&console.warn("VueUiTreemap does not support the #chart-background slot.")});const p=e.computed(()=>!!u.dataset&&u.dataset.length),f=e.computed(()=>/^((?!chrome|android).)*safari/i.test(navigator.userAgent)),x=e.ref(s.createUid()),C=e.ref(!1),T=e.ref(""),b=e.ref(!1),y=e.ref(0),g=e.ref([]),k=e.ref(null),O=e.ref(null),S=e.ref(null),K=e.ref(null),Q=e.ref(null),ee=e.ref(0),te=e.ref(0),oe=e.ref(0),t=e.computed({get:()=>re(),set:o=>o}),{userOptionsVisible:X,setUserOptionsVisibility:le,keepUserOptionState:ae}=Ge.useUserOptionState({config:t.value}),{svgRef:ne}=je.useChartAccessibility({config:t.value.style.chart.title});function re(){const o=Se.useNestedProp({userConfig:u.config,defaultConfig:d});return o.theme?{...Se.useNestedProp({userConfig:s.themes.vue_ui_treemap[o.theme]||u.config,defaultConfig:o}),customPalette:s.themePalettes[o.theme]||s.palette}:o}e.watch(()=>u.config,o=>{t.value=re(),X.value=!t.value.userOptions.showOnChartHover,ee.value+=1,te.value+=1,oe.value+=1,$.value.showTable=t.value.table.show,$.value.showTooltip=t.value.style.chart.tooltip.show},{deep:!0});const{isPrinting:se,isImaging:ue,generatePdf:ie,generateImage:ce}=xe.usePrinter({elementId:`treemap_${x.value}`,fileName:t.value.style.chart.title.text||"vue-ui-treemap",options:t.value.userOptions.print}),_e=e.computed(()=>t.value.userOptions.show&&!t.value.style.chart.title.text),H=e.computed(()=>s.convertCustomPalette(t.value.customPalette)),$=e.ref({showTable:t.value.table.show,showTooltip:t.value.style.chart.tooltip.show}),_=e.ref({height:t.value.style.chart.height,width:t.value.style.chart.width}),z=e.computed(()=>({bottom:_.value.height-t.value.style.chart.padding.bottom,height:_.value.height-t.value.style.chart.padding.top-t.value.style.chart.padding.bottom,left:t.value.style.chart.padding.left,right:_.value.width-t.value.style.chart.padding.right,top:t.value.style.chart.padding.top,vbHeight:_.value.height,vbWidth:_.value.width,width:_.value.width-t.value.style.chart.padding.left-t.value.style.chart.padding.right}));function de(o){o.forEach((a,l)=>{a.id=s.createUid(),a.color=s.convertColorToHex(a.color)||H.value[l]||s.palette[l]||s.palette[l%s.palette.length],a.children&&(a.children.forEach(n=>{n.parentId=a.id,n.color=a.color}),de(a.children))})}const P=e.ref(u.dataset),U=e.ref(null);e.onMounted(()=>{Pe()});function Pe(){if(s.objectIsEmpty(u.dataset)&&s.error({componentName:"VueUiTreemap",type:"dataset"}),de(P.value),t.value.responsive){const o=Te.throttle(()=>{const{width:a,height:l}=Te.useResponsive({chart:k.value,title:t.value.style.chart.title.text?O.value:null,legend:t.value.style.chart.legend.show?S.value:null,source:K.value,noTitle:Q.value});requestAnimationFrame(()=>{_.value.width=a,_.value.height=l})});U.value=new ResizeObserver(o),U.value.observe(k.value.parentNode)}}e.onBeforeUnmount(()=>{U.value&&U.value.disconnect()});const A=e.ref(P.value),D=e.computed(()=>A.value.map((o,a)=>({...o,color:s.convertColorToHex(o.color)||H.value[a]||s.palette[a]||s.palette[a%s.palette.length]})).filter(o=>!g.value.includes(o.id))),L=e.computed(()=>P.value.filter(o=>!g.value.includes(o.id)).map(o=>o.value||0).reduce((o,a)=>o+a,0)),ve=e.computed({get(){let o=[...D.value];return t.value.style.chart.layout.sorted&&(o=[...D.value].sort((a,l)=>l.value-a.value)),o.map(a=>({...a}))},set(o){return o}});function he(o,a){return o.value/a}function Ve(o,a,l){const n=t.value.style.chart.layout.rects.colorRatio-he(a,l);return s.lightenHexColor(o,n<0?0:n)}function pe(o,a,l,n){return o.map((m,V)=>{const j=Ve(s.convertColorToHex(a)||H.value[V]||s.palette[V]||s.palette[V%s.palette.length],m,n),Le=he(m,n);return{...m,color:j,proportion:Le,parentName:l,children:m.children?pe(m.children,j,m.name,n):void 0}})}const q=e.computed(()=>Ke(ve.value.map((o,a)=>{const l=o.children?o.children.reduce((n,m)=>n+m.value,0):o.value;return{value:o.value,id:o.id,children:o.children?pe(o.children.sort((n,m)=>m.value-n.value),o.color,o.name,l):void 0,color:o.color,name:o.name}}),{x0:z.value.left*2,y0:z.value.top,x1:z.value.width,y1:z.value.height}));function fe({y0:o,y1:a}){return a-o<=0?1e-4:a-o}function me({x0:o,x1:a}){return a-o<=0?1e-4:a-o}function E(o){const a=t.value.style.chart.layout.labels.fontSize*(o.proportion*2>1?1:o.proportion*2);return a<t.value.style.chart.layout.labels.minFontSize?t.value.style.chart.layout.labels.minFontSize:a}function ze(o){b.value=o,y.value+=1}const F=e.computed(()=>({startX:0,startY:0,width:z.value.vbWidth,height:z.value.vbHeight}));function I(o,a=P.value){for(const l of a){if(l.id===o)return l;if(l.children){const n=I(o,l.children);if(n)return n}}return null}const w=e.ref([]),R=e.computed(()=>w.value.length>0);function ge(o){var l;if(!o){A.value=P.value.slice(),v("selectDatapoint",void 0),w.value=[];return}const a=I(o.id);if(a&&((l=a.children)!=null&&l.length))w.value.push(a.id),A.value=a.children.slice(),v("selectDatapoint",o);else if(o.parentId){w.value.push(o.parentId);const n=I(o.parentId);A.value=n.children.slice(),v("selectDatapoint",o)}else if(w.value.length>0){w.value.pop();const n=w.value[w.value.length-1];if(n){const m=I(n);A.value=m.children.slice()}else A.value=P.value.slice(),w.value=[],v("selectDatapoint",void 0)}}const M=e.computed(()=>{const o=[{id:null,label:"All"}];if(w.value.length>0){let a=I(w.value[w.value.length-1]);const l=[];for(;a;)l.unshift(a),a=a.parentId?I(a.parentId):null;for(const n of l)o.push({id:n.id,label:n.name,node:n})}return o}),B=e.ref(null),ye=e.computed(()=>P.value.map((o,a)=>({...o,color:s.convertColorToHex(o.color)||H.value[a]||s.palette[a]||s.palette[a%s.palette.length],shape:"square"})).sort((o,a)=>a.value-o.value).map((o,a)=>({...o,proportion:o.value/P.value.map(l=>l.value).reduce((l,n)=>l+n,0),opacity:g.value.includes(o.id)?.5:1}))),Ee=e.computed(()=>({cy:"treemap-div-legend",backgroundColor:t.value.style.chart.legend.backgroundColor,color:t.value.style.chart.legend.color,fontSize:t.value.style.chart.legend.fontSize,paddingBottom:12,fontWeight:t.value.style.chart.legend.bold?"bold":""}));function be(o){R.value=!1,B.value=null,g.value.includes(o.id)?g.value=g.value.filter(a=>a!==o.id):g.value.length<u.dataset.length-1&&g.value.push(o.id),v("selectLegend",ve.value)}const Y=e.ref(null);function Re({datapoint:o,seriesIndex:a}){B.value=o,Y.value={datapoint:o,seriesIndex:a,config:t.value,series:D.value};const l=t.value.style.chart.tooltip.customFormat;if(s.isFunction(l)&&s.functionReturnsString(()=>l({seriesIndex:a,datapoint:o,series:D.value,config:t.value})))T.value=l({seriesIndex:a,datapoint:o,series:D.value,config:t.value});else{let n="";n+=`<div style="width:100%;text-align:center;border-bottom:1px solid ${t.value.style.chart.tooltip.borderColor};padding-bottom:6px;margin-bottom:3px;">${o.name}</div>`,n+=`<div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><rect x="0" y="0" height="12" width="12" stroke="none" fill="${o.color}"/></svg>`,n+=`<b>${s.applyDataLabel(t.value.style.chart.layout.labels.formatter,o.value,s.dataLabel({p:t.value.style.chart.layout.labels.prefix,v:o.value,s:t.value.style.chart.layout.labels.suffix,r:t.value.style.chart.tooltip.roundingValue}),{datapoint:o,seriesIndex:a})}</b>`,T.value=`<div>${n}</div>`}C.value=!0}const N=e.computed(()=>{const o=q.value.map(l=>({name:l.name,color:l.color})),a=q.value.map(l=>l.value);return{head:o,body:a}});function ke(){e.nextTick(()=>{const o=N.value.head.map((n,m)=>[[n.name],[N.value.body[m]],[isNaN(N.value.body[m]/L.value)?"-":N.value.body[m]/L.value*100]]),a=[[t.value.style.chart.title.text],[t.value.style.chart.title.subtitle.text],[[""],["val"],["%"]]].concat(o),l=s.createCsvContent(a);s.downloadCsv({csvContent:l,title:t.value.style.chart.title.text||"vue-ui-treemap"})})}const W=e.computed(()=>{const o=[t.value.table.columnNames.series,t.value.table.columnNames.value,t.value.table.columnNames.percentage],a=N.value.head.map((m,V)=>{const j=s.applyDataLabel(t.value.style.chart.layout.labels.formatter,N.value.body[V],s.dataLabel({p:t.value.style.chart.layout.labels.prefix,v:N.value.body[V],s:t.value.style.chart.layout.labels.suffix,r:t.value.table.td.roundingValue}));return[{color:m.color,name:m.name,shape:"square"},j,isNaN(N.value.body[V]/L.value)?"-":s.dataLabel({v:N.value.body[V]/L.value*100,s:"%",r:t.value.table.td.roundingPercentage})]}),l={th:{backgroundColor:t.value.table.th.backgroundColor,color:t.value.table.th.color,outline:t.value.table.th.outline},td:{backgroundColor:t.value.table.td.backgroundColor,color:t.value.table.td.color,outline:t.value.table.td.outline},breakpoint:t.value.table.responsiveBreakpoint};return{colNames:[t.value.table.columnNames.series,t.value.table.columnNames.value],head:o,body:a,config:l}});function Ae(){return q.value}function Ce(){$.value.showTable=!$.value.showTable}function we(){$.value.showTooltip=!$.value.showTooltip}const G=e.ref(!1);function Z(){G.value=!G.value}return c({getData:Ae,generateCsv:ke,generateImage:ce,generatePdf:ie,toggleTable:Ce,toggleTooltip:we,toggleAnnotator:Z}),(o,a)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"treemapChart",ref:k,class:e.normalizeClass(`vue-ui-treemap ${b.value?"vue-data-ui-wrapper-fullscreen":""} ${t.value.useCssAnimation?"":"vue-ui-dna"}`),style:e.normalizeStyle(`font-family:${t.value.style.fontFamily};width:100%; ${t.value.responsive?"height: 100%;":""} text-align:center;background:${t.value.style.chart.backgroundColor}`),id:`treemap_${x.value}`,onMouseenter:a[3]||(a[3]=()=>e.unref(le)(!0)),onMouseleave:a[4]||(a[4]=()=>e.unref(le)(!1))},[t.value.userOptions.buttons.annotator?(e.openBlock(),e.createBlock(We.PenAndPaper,{key:0,svgRef:e.unref(ne),backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,active:G.value,onClose:Z},null,8,["svgRef","backgroundColor","color","active"])):e.createCommentVNode("",!0),_e.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"noTitle",ref:Q,class:"vue-data-ui-no-title-space",style:"height:36px; width: 100%;background:transparent"},null,512)):e.createCommentVNode("",!0),t.value.style.chart.title.text?(e.openBlock(),e.createElementBlock("div",{key:2,ref_key:"chartTitle",ref:O,style:e.normalizeStyle(`width:100%;background:${t.value.style.chart.backgroundColor};padding-bottom:6px`)},[(e.openBlock(),e.createBlock(Fe._sfc_main,{key:`title_${ee.value}`,config:{title:{cy:"treemap-div-title",...t.value.style.chart.title},subtitle:{cy:"treemap-div-subtitle",...t.value.style.chart.title.subtitle}}},null,8,["config"]))],4)):e.createCommentVNode("",!0),t.value.userOptions.show&&p.value&&(e.unref(ae)||e.unref(X))?(e.openBlock(),e.createBlock(xe.UserOptions,{ref:"details",key:`user_option_${y.value}`,backgroundColor:t.value.style.chart.backgroundColor,color:t.value.style.chart.color,isPrinting:e.unref(se),isImaging:e.unref(ue),uid:x.value,hasTooltip:t.value.userOptions.buttons.tooltip&&t.value.style.chart.tooltip.show,hasPdf:t.value.userOptions.buttons.pdf,hasXls:t.value.userOptions.buttons.csv,hasImg:t.value.userOptions.buttons.img,hasTable:t.value.userOptions.buttons.table,hasFullscreen:t.value.userOptions.buttons.fullscreen,isFullscreen:b.value,isTooltip:$.value.showTooltip,titles:{...t.value.userOptions.buttonTitles},chartElement:k.value,position:t.value.userOptions.position,hasAnnotator:t.value.userOptions.buttons.annotator,isAnnotation:G.value,onToggleFullscreen:ze,onGeneratePdf:e.unref(ie),onGenerateCsv:ke,onGenerateImage:e.unref(ce),onToggleTable:Ce,onToggleTooltip:we,onToggleAnnotator:Z,style:e.normalizeStyle({visibility:e.unref(ae)?e.unref(X)?"visible":"hidden":"visible"})},e.createSlots({_:2},[o.$slots.menuIcon?{name:"menuIcon",fn:e.withCtx(({isOpen:l,color:n})=>[e.renderSlot(o.$slots,"menuIcon",e.normalizeProps(e.guardReactiveProps({isOpen:l,color:n})),void 0,!0)]),key:"0"}:void 0,o.$slots.optionTooltip?{name:"optionTooltip",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTooltip",{},void 0,!0)]),key:"1"}:void 0,o.$slots.optionPdf?{name:"optionPdf",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionPdf",{},void 0,!0)]),key:"2"}:void 0,o.$slots.optionCsv?{name:"optionCsv",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionCsv",{},void 0,!0)]),key:"3"}:void 0,o.$slots.optionImg?{name:"optionImg",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionImg",{},void 0,!0)]),key:"4"}:void 0,o.$slots.optionTable?{name:"optionTable",fn:e.withCtx(()=>[e.renderSlot(o.$slots,"optionTable",{},void 0,!0)]),key:"5"}:void 0,o.$slots.optionFullscreen?{name:"optionFullscreen",fn:e.withCtx(({toggleFullscreen:l,isFullscreen:n})=>[e.renderSlot(o.$slots,"optionFullscreen",e.normalizeProps(e.guardReactiveProps({toggleFullscreen:l,isFullscreen:n})),void 0,!0)]),key:"6"}:void 0,o.$slots.optionAnnotator?{name:"optionAnnotator",fn:e.withCtx(({toggleAnnotator:l,isAnnotator:n})=>[e.renderSlot(o.$slots,"optionAnnotator",e.normalizeProps(e.guardReactiveProps({toggleAnnotator:l,isAnnotator:n})),void 0,!0)]),key:"7"}:void 0]),1032,["backgroundColor","color","isPrinting","isImaging","uid","hasTooltip","hasPdf","hasXls","hasImg","hasTable","hasFullscreen","isFullscreen","isTooltip","titles","chartElement","position","hasAnnotator","isAnnotation","onGeneratePdf","onGenerateImage","style"])):e.createCommentVNode("",!0),M.value.length>1?(e.openBlock(),e.createElementBlock("nav",nt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(M.value,(l,n)=>(e.openBlock(),e.createElementBlock("span",{key:l.id||"root",onClick:m=>n===M.value.length-1?()=>{}:ge(l.node),class:"vue-ui-treemap-crumb","data-last-crumb":n===M.value.length-1,style:e.normalizeStyle({color:t.value.style.chart.color})},[e.createElementVNode("span",st,[e.createElementVNode("span",ut,[e.renderSlot(o.$slots,"breadcrumb-label",e.mergeProps({ref_for:!0},{crumb:l,isRoot:n===0}),()=>[n===0?(e.openBlock(),e.createElementBlock("div",it,[e.createVNode(Xe.default,{name:"home",stroke:t.value.style.chart.color},null,8,["stroke"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(l.label),1)],64))],!0)]),n<M.value.length-1?(e.openBlock(),e.createElementBlock("span",ct,[e.renderSlot(o.$slots,"breadcrumb-arrow",{},()=>[a[5]||(a[5]=e.createTextVNode(" › "))],!0)])):e.createCommentVNode("",!0)])],12,rt))),128))])):e.createCommentVNode("",!0),p.value?(e.openBlock(),e.createElementBlock("svg",{key:5,ref_key:"svgRef",ref:ne,xmlns:e.unref(s.XMLNS),class:e.normalizeClass({"vue-data-ui-fullscreen--on":b.value,"vue-data-ui-fulscreen--off":!b.value,"vue-data-ui-zoom-plus":!R.value,"vue-data-ui-zoom-minus":R.value}),viewBox:`${F.value.startX} ${F.value.startY} ${F.value.width<=0?10:F.value.width} ${F.value.height<=0?10:F.value.height}`,style:e.normalizeStyle(`max-width:100%; overflow: hidden; background:transparent;color:${t.value.style.chart.color}`)},[e.createVNode(Ue._sfc_main),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(q.value,(l,n)=>(e.openBlock(),e.createElementBlock("g",null,[t.value.style.chart.layout.rects.gradient.show?(e.openBlock(),e.createElementBlock("defs",vt,[e.createElementVNode("radialGradient",{id:`tgrad_${l.id}`,gradientTransform:"translate(-1, -1.000001) scale(2, 2)"},[e.createElementVNode("stop",{offset:"18%","stop-color":l.color},null,8,pt),e.createElementVNode("stop",{offset:"100%","stop-color":e.unref(s.lightenHexColor)(l.color,t.value.style.chart.layout.rects.gradient.intensity/100)},null,8,ft)],8,ht)])):e.createCommentVNode("",!0)]))),256)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(q.value,(l,n)=>(e.openBlock(),e.createElementBlock("g",null,[e.createElementVNode("rect",{x:l.x0,y:l.y0,height:fe(l),width:me(l),fill:f.value?l.color:t.value.style.chart.layout.rects.gradient.show?`url(#tgrad_${l.id})`:l.color,rx:t.value.style.chart.layout.rects.borderRadius,stroke:B.value&&B.value.id===l.id?t.value.style.chart.layout.rects.selected.stroke:t.value.style.chart.layout.rects.stroke,"stroke-width":B.value&&B.value.id===l.id?t.value.style.chart.layout.rects.selected.strokeWidth:t.value.style.chart.layout.rects.strokeWidth,onClick:e.withModifiers(m=>ge(l),["stop"]),onMouseenter:()=>Re({datapoint:l,seriesIndex:n}),onMouseleave:a[0]||(a[0]=m=>{B.value=null,C.value=!1}),style:e.normalizeStyle(`opacity:${B.value?B.value.id===l.id?1:t.value.style.chart.layout.rects.selected.unselectedOpacity:1}`),class:"vue-ui-treemap-rect"},null,44,mt),(e.openBlock(),e.createElementBlock("foreignObject",{x:l.x0,y:l.y0,height:fe(l),width:me(l),class:"vue-ui-treemap-cell-foreignObject"},[e.createElementVNode("div",yt,[t.value.style.chart.layout.labels.showDefaultLabels&&(l.proportion>t.value.style.chart.layout.labels.hideUnderProportion||R.value)?(e.openBlock(),e.createElementBlock("div",{key:0,class:"vue-ui-treemap-cell-default",style:e.normalizeStyle(`width:calc(100% - ${E(l)/1.5}px);text-align:left;line-height:${E(l)<14?14:E(l)}px;padding:${E(l)/3}px; color:${e.unref(s.adaptColorToBackground)(l.color)}`)},[e.createElementVNode("span",{style:e.normalizeStyle(`width:100%;font-size:${E(l)}px;`)},e.toDisplayString(l.name),5),a[6]||(a[6]=e.createElementVNode("br",null,null,-1)),e.createElementVNode("span",{style:e.normalizeStyle(`width:100%;font-size:${E(l)}px;`)},e.toDisplayString(e.unref(s.applyDataLabel)(t.value.style.chart.layout.labels.formatter,l.value,e.unref(s.dataLabel)({p:t.value.style.chart.layout.labels.prefix,v:l.value,s:t.value.style.chart.layout.labels.suffix,r:t.value.style.chart.layout.labels.rounding}),{datapoint:l})),5)],4)):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"rect",e.mergeProps({ref_for:!0},{rect:l,shouldShow:l.proportion>t.value.style.chart.layout.labels.hideUnderProportion||R.value,fontSize:E(l),isZoom:R.value,textColor:e.unref(s.adaptColorToBackground)(l.color)}),void 0,!0)])],8,gt))]))),256)),e.renderSlot(o.$slots,"svg",e.normalizeProps(e.guardReactiveProps({svg:z.value,isZoom:R.value,rect:B.value,config:t.value})),void 0,!0)],14,dt)):e.createCommentVNode("",!0),o.$slots.watermark?(e.openBlock(),e.createElementBlock("div",bt,[e.renderSlot(o.$slots,"watermark",e.normalizeProps(e.guardReactiveProps({isPrinting:e.unref(se)||e.unref(ue)})),void 0,!0)])):e.createCommentVNode("",!0),p.value?e.createCommentVNode("",!0):(e.openBlock(),e.createBlock(qe.default,{key:7,config:{type:"treemap",style:{backgroundColor:t.value.style.chart.backgroundColor,treemap:{color:"#CCCCCC"}}}},null,8,["config"])),e.createElementVNode("div",{ref_key:"chartLegend",ref:S},[t.value.style.chart.legend.show?(e.openBlock(),e.createBlock(De.Legend,{key:`legend_${oe.value}`,legendSet:ye.value,config:Ee.value,id:`treemap_legend_${x.value}`,onClickMarker:a[1]||(a[1]=({legend:l})=>be(l))},{item:e.withCtx(({legend:l,index:n})=>[e.createElementVNode("div",{onClick:m=>be(l),style:e.normalizeStyle(`opacity:${g.value.includes(l.id)?.5:1}`)},[e.createTextVNode(e.toDisplayString(l.name)+": "+e.toDisplayString(e.unref(s.applyDataLabel)(t.value.style.chart.layout.labels.formatter,l.value,e.unref(s.dataLabel)({p:t.value.style.chart.layout.labels.prefix,v:l.value,s:t.value.style.chart.layout.labels.suffix,r:t.value.style.chart.legend.roundingValue}),{datapoint:l}))+" ",1),g.value.includes(l.id)?(e.openBlock(),e.createElementBlock("span",wt," ( - % ) ")):(e.openBlock(),e.createElementBlock("span",Ct," ("+e.toDisplayString(isNaN(l.value/L.value)?"-":(l.value/L.value*100).toFixed(t.value.style.chart.legend.roundingPercentage))+"%) ",1))],12,kt)]),_:1},8,["legendSet","config","id"])):e.renderSlot(o.$slots,"legend",{key:1,legend:ye.value},void 0,!0)],512),o.$slots.source?(e.openBlock(),e.createElementBlock("div",{key:8,ref_key:"source",ref:K,dir:"auto"},[e.renderSlot(o.$slots,"source",{},void 0,!0)],512)):e.createCommentVNode("",!0),e.createVNode(Ie._sfc_main,{show:$.value.showTooltip&&C.value,backgroundColor:t.value.style.chart.tooltip.backgroundColor,color:t.value.style.chart.tooltip.color,fontSize:t.value.style.chart.tooltip.fontSize,borderRadius:t.value.style.chart.tooltip.borderRadius,borderColor:t.value.style.chart.tooltip.borderColor,borderWidth:t.value.style.chart.tooltip.borderWidth,backgroundOpacity:t.value.style.chart.tooltip.backgroundOpacity,position:t.value.style.chart.tooltip.position,offsetY:t.value.style.chart.tooltip.offsetY,parent:k.value,content:T.value,isFullscreen:b.value,isCustom:e.unref(s.isFunction)(t.value.style.chart.tooltip.customFormat)},{"tooltip-before":e.withCtx(()=>[e.renderSlot(o.$slots,"tooltip-before",e.normalizeProps(e.guardReactiveProps({...Y.value})),void 0,!0)]),"tooltip-after":e.withCtx(()=>[e.renderSlot(o.$slots,"tooltip-after",e.normalizeProps(e.guardReactiveProps({...Y.value})),void 0,!0)]),_:3},8,["show","backgroundColor","color","fontSize","borderRadius","borderColor","borderWidth","backgroundOpacity","position","offsetY","parent","content","isFullscreen","isCustom"]),p.value?(e.openBlock(),e.createBlock(He.default,{key:9,hideDetails:"",config:{open:$.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(Me.DataTable,{key:`table_${te.value}`,colNames:W.value.colNames,head:W.value.head,body:W.value.body,config:W.value.config,title:`${t.value.style.chart.title.text}${t.value.style.chart.title.subtitle.text?` : ${t.value.style.chart.title.subtitle.text}`:""}`,onClose:a[2]||(a[2]=l=>$.value.showTable=!1)},{th:e.withCtx(({th:l})=>[e.createElementVNode("div",{innerHTML:l,style:{display:"flex","align-items":"center"}},null,8,xt)]),td:e.withCtx(({td:l})=>[e.createTextVNode(e.toDisplayString(l.name||l),1)]),_:1},8,["colNames","head","body","config","title"]))]),_:1},8,["config"])):e.createCommentVNode("",!0)],46,at))}},St=Ye._export_sfc(Tt,[["__scopeId","data-v-a6058301"]]);exports.default=St;
|