apexcharts 8.2.0 → 8.3.1
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/README.md +7 -7
- package/dist/apexcharts.common.js +2 -2
- package/dist/apexcharts.core.js +19793 -19713
- package/dist/apexcharts.core.min.js +2 -2
- package/dist/apexcharts.css +38 -8
- package/dist/apexcharts.esm.js +1882 -1625
- package/dist/apexcharts.full.js +22044 -21634
- package/dist/apexcharts.full.min.js +2 -2
- package/dist/apexcharts.js +21414 -21124
- package/dist/apexcharts.min.js +2 -2
- package/dist/apexcharts.ssr.common.js +2 -2
- package/dist/apexcharts.ssr.esm.js +21413 -21123
- package/dist/area.common.js +2 -2
- package/dist/area.esm.js +91 -40
- package/dist/bar.common.js +2 -2
- package/dist/bar.esm.js +478 -406
- package/dist/bar.js +2 -2
- package/dist/boxPlot.common.js +2 -2
- package/dist/boxPlot.esm.js +409 -334
- package/dist/bubble.common.js +2 -2
- package/dist/bubble.esm.js +91 -40
- package/dist/candlestick.common.js +2 -2
- package/dist/candlestick.esm.js +409 -334
- package/dist/candlestick.js +2 -2
- package/dist/column.common.js +2 -2
- package/dist/column.esm.js +478 -406
- package/dist/core.common.js +2 -2
- package/dist/core.esm.js +19793 -19713
- package/dist/donut.common.js +2 -2
- package/dist/donut.esm.js +3 -9
- package/dist/dumbbell.common.js +2 -2
- package/dist/dumbbell.esm.js +478 -406
- package/dist/features/all.common.js +2 -2
- package/dist/features/all.esm.js +442 -324
- package/dist/features/annotations.common.js +2 -2
- package/dist/features/annotations.esm.js +65 -48
- package/dist/features/annotations.js +2 -2
- package/dist/features/context-menu.common.js +1 -1
- package/dist/features/context-menu.esm.js +1 -1
- package/dist/features/context-menu.js +1 -1
- package/dist/features/drilldown.common.js +2 -2
- package/dist/features/drilldown.esm.js +4 -2
- package/dist/features/drilldown.js +2 -2
- package/dist/features/dumbbell.common.js +1 -1
- package/dist/features/dumbbell.esm.js +1 -1
- package/dist/features/dumbbell.js +1 -1
- package/dist/features/exports.common.js +2 -2
- package/dist/features/exports.esm.js +10 -4
- package/dist/features/exports.js +2 -2
- package/dist/features/facet.common.js +1 -1
- package/dist/features/facet.esm.js +1 -1
- package/dist/features/facet.js +1 -1
- package/dist/features/highlight-filter.common.js +2 -2
- package/dist/features/highlight-filter.esm.js +14 -9
- package/dist/features/highlight-filter.js +2 -2
- package/dist/features/history.common.js +1 -1
- package/dist/features/history.esm.js +1 -1
- package/dist/features/history.js +1 -1
- package/dist/features/ink.common.js +1 -1
- package/dist/features/ink.esm.js +1 -1
- package/dist/features/ink.js +1 -1
- package/dist/features/keyboard.common.js +2 -2
- package/dist/features/keyboard.esm.js +97 -145
- package/dist/features/keyboard.js +2 -2
- package/dist/features/legend.common.js +2 -2
- package/dist/features/legend.esm.js +64 -44
- package/dist/features/legend.js +2 -2
- package/dist/features/link.common.js +1 -1
- package/dist/features/link.esm.js +1 -1
- package/dist/features/link.js +1 -1
- package/dist/features/marks.common.js +1 -1
- package/dist/features/marks.esm.js +1 -1
- package/dist/features/marks.js +1 -1
- package/dist/features/measure.common.js +1 -1
- package/dist/features/measure.esm.js +1 -1
- package/dist/features/measure.js +1 -1
- package/dist/features/morph.common.js +2 -2
- package/dist/features/morph.esm.js +9 -5
- package/dist/features/morph.js +2 -2
- package/dist/features/perspectives.common.js +2 -2
- package/dist/features/perspectives.esm.js +4 -1
- package/dist/features/perspectives.js +2 -2
- package/dist/features/raincloud.common.js +2 -2
- package/dist/features/raincloud.esm.js +26 -27
- package/dist/features/raincloud.js +2 -2
- package/dist/features/renderer-canvas.common.js +2 -2
- package/dist/features/renderer-canvas.esm.js +2 -1
- package/dist/features/renderer-canvas.js +2 -2
- package/dist/features/stats.common.js +2 -2
- package/dist/features/stats.esm.js +52 -59
- package/dist/features/stats.js +2 -2
- package/dist/features/storyboard.common.js +2 -2
- package/dist/features/storyboard.esm.js +4 -1
- package/dist/features/storyboard.js +2 -2
- package/dist/features/streamgraph.common.js +2 -2
- package/dist/features/streamgraph.esm.js +48 -14
- package/dist/features/streamgraph.js +2 -2
- package/dist/features/toolbar.common.js +2 -2
- package/dist/features/toolbar.esm.js +148 -18
- package/dist/features/toolbar.js +2 -2
- package/dist/features/trellis.common.js +2 -2
- package/dist/features/trellis.esm.js +150 -63
- package/dist/features/trellis.js +2 -2
- package/dist/features/waterfall.common.js +1 -1
- package/dist/features/waterfall.esm.js +1 -1
- package/dist/features/waterfall.js +1 -1
- package/dist/features/weave.common.js +2 -2
- package/dist/features/weave.esm.js +13 -12
- package/dist/features/weave.js +2 -2
- package/dist/full.common.js +2 -2
- package/dist/full.esm.js +1068 -842
- package/dist/heatmap.common.js +2 -2
- package/dist/heatmap.esm.js +3 -17
- package/dist/heatmap.js +2 -2
- package/dist/histogram.common.js +2 -2
- package/dist/histogram.esm.js +529 -464
- package/dist/icicle.common.js +2 -2
- package/dist/icicle.esm.js +80 -46
- package/dist/icicle.js +2 -2
- package/dist/line.common.js +2 -2
- package/dist/line.esm.js +91 -40
- package/dist/line.js +2 -2
- package/dist/locales/en.json +2 -1
- package/dist/locales/ro.json +3 -2
- package/dist/pictograms.common.js +1 -1
- package/dist/pictograms.esm.js +1 -1
- package/dist/pictograms.js +1 -1
- package/dist/pie.common.js +2 -2
- package/dist/pie.esm.js +3 -9
- package/dist/pie.js +2 -2
- package/dist/polarArea.common.js +2 -2
- package/dist/polarArea.esm.js +3 -9
- package/dist/radar.common.js +2 -2
- package/dist/radar.esm.js +5 -4
- package/dist/radar.js +2 -2
- package/dist/radialBar.common.js +2 -2
- package/dist/radialBar.esm.js +5 -12
- package/dist/radialBar.js +2 -2
- package/dist/raincloud.common.js +2 -2
- package/dist/raincloud.esm.js +97 -52
- package/dist/rangeArea.common.js +2 -2
- package/dist/rangeArea.esm.js +91 -40
- package/dist/rangeBar.common.js +2 -2
- package/dist/rangeBar.esm.js +478 -406
- package/dist/scatter.common.js +2 -2
- package/dist/scatter.esm.js +91 -40
- package/dist/streamgraph.common.js +2 -2
- package/dist/streamgraph.esm.js +138 -53
- package/dist/sunburst.common.js +2 -2
- package/dist/sunburst.esm.js +116 -94
- package/dist/sunburst.js +2 -2
- package/dist/treemap.common.js +2 -2
- package/dist/treemap.esm.js +138 -104
- package/dist/treemap.js +2 -2
- package/dist/unit-shapes.common.js +1 -1
- package/dist/unit-shapes.esm.js +1 -1
- package/dist/unit-shapes.js +1 -1
- package/dist/unit.common.js +2 -2
- package/dist/unit.esm.js +280 -202
- package/dist/unit.js +2 -2
- package/dist/violin.common.js +2 -2
- package/dist/violin.esm.js +72 -26
- package/dist/violin.js +2 -2
- package/dist/waterfall.common.js +2 -2
- package/dist/waterfall.esm.js +477 -405
- package/package.json +1 -1
- package/src/apexcharts.js +40 -59
- package/src/assets/apexcharts.css +38 -8
- package/src/charts/Bar.js +62 -55
- package/src/charts/BarStacked.js +80 -88
- package/src/charts/BoxCandleStick.js +28 -31
- package/src/charts/Icicle.js +68 -47
- package/src/charts/Line.js +118 -42
- package/src/charts/Pie.js +2 -8
- package/src/charts/Radar.js +5 -7
- package/src/charts/Radial.js +2 -6
- package/src/charts/RangeBar.js +47 -43
- package/src/charts/Sunburst.js +101 -98
- package/src/charts/Treemap.js +150 -88
- package/src/charts/Unit.js +368 -250
- package/src/charts/Violin.js +48 -30
- package/src/charts/common/Breadcrumb.js +2 -2
- package/src/charts/common/Hierarchy.js +32 -11
- package/src/charts/common/Jitter.js +32 -7
- package/src/charts/common/Stats.js +30 -23
- package/src/charts/common/bar/DataLabels.js +76 -81
- package/src/charts/common/bar/Helpers.js +43 -7
- package/src/charts/common/line/Helpers.js +12 -15
- package/src/charts/common/partition/NodeTooltip.js +29 -7
- package/src/charts/common/partition/Partition.js +33 -1
- package/src/charts/common/treemap/Helpers.js +3 -11
- package/src/charts/common/treemap/Nested.js +2 -3
- package/src/features/raincloud.js +16 -10
- package/src/features/stats.js +67 -62
- package/src/locales/en.json +2 -1
- package/src/locales/ro.json +3 -2
- package/src/modules/Animations.js +102 -95
- package/src/modules/AxisMapping.js +47 -12
- package/src/modules/Core.js +4 -0
- package/src/modules/CoreUtils.js +18 -42
- package/src/modules/Data.js +23 -24
- package/src/modules/DataLabels.js +6 -6
- package/src/modules/Exports.js +12 -5
- package/src/modules/Fill.js +17 -8
- package/src/modules/Filters.js +50 -50
- package/src/modules/Graphics.js +69 -51
- package/src/modules/Markers.js +3 -1
- package/src/modules/MorphTypeChange.js +13 -7
- package/src/modules/Range.js +44 -29
- package/src/modules/RendererController.js +17 -3
- package/src/modules/Scales.js +32 -9
- package/src/modules/Series.js +41 -19
- package/src/modules/Theme.js +1 -1
- package/src/modules/Toolbar.js +3 -2
- package/src/modules/UnitMarkRegistry.js +0 -5
- package/src/modules/ZoomPanSelection.js +123 -2
- package/src/modules/accessibility/KeyboardNavigation.js +114 -186
- package/src/modules/animations/Easing.js +2 -1
- package/src/modules/animations/LengthTransition.js +22 -2
- package/src/modules/annotations/Helpers.js +68 -52
- package/src/modules/axes/Grid.js +21 -7
- package/src/modules/axes/YAxis.js +8 -9
- package/src/modules/dimensions/Dimensions.js +9 -3
- package/src/modules/dimensions/Grid.js +2 -2
- package/src/modules/dimensions/XAxis.js +2 -5
- package/src/modules/drilldown/Breadcrumb.js +5 -2
- package/src/modules/helpers/Destroy.js +1 -1
- package/src/modules/helpers/UpdateHelpers.js +33 -15
- package/src/modules/highlightFilter/HighlightFilter.js +8 -9
- package/src/modules/highlightFilter/TreemapPart.js +2 -2
- package/src/modules/legend/HeatmapGradientLegend.js +76 -45
- package/src/modules/legend/Helpers.js +8 -1
- package/src/modules/legend/Legend.js +11 -12
- package/src/modules/license/LicenseEnforcer.js +5 -0
- package/src/modules/settings/Defaults.js +28 -56
- package/src/modules/settings/Globals.js +5 -0
- package/src/modules/settings/Options.js +7 -7
- package/src/modules/settings/TypeAliases.js +33 -16
- package/src/modules/streamgraph/StreamLabels.js +1 -0
- package/src/modules/tooltip/Labels.js +73 -76
- package/src/modules/tooltip/Marker.js +25 -21
- package/src/modules/tooltip/Position.js +88 -51
- package/src/modules/tooltip/Tooltip.js +242 -255
- package/src/modules/tooltip/Utils.js +71 -130
- package/src/modules/tooltip/constants.js +5 -5
- package/src/modules/trellis/Trellis.js +6 -0
- package/src/modules/trellis/TrellisChrome.js +18 -7
- package/src/modules/trellis/TrellisSync.js +2 -0
- package/src/modules/trellis/TrellisTooltip.js +2 -11
- package/src/modules/weave/WeaveHost.js +18 -12
- package/src/renderers/canvas/CanvasGraphics.js +1 -0
- package/src/ssr/DOMShim.js +10 -0
- package/src/svg/SVGFilter.js +26 -17
- package/src/types/internal.d.ts +9 -3
- package/src/utils/Utils.js +0 -14
- package/types/apexcharts.d.ts +33 -12
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v8.
|
|
2
|
+
* ApexCharts v8.3.1
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
|
-
"use strict";var t=Object.defineProperty,e=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable,s=(e,r,i)=>r in e?t(e,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[r]=i,n=(t,n)=>{for(var a in n||(n={}))r.call(n,a)&&s(t,a,n[a]);if(e)for(var a of e(n))i.call(n,a)&&s(t,a,n[a]);return t};Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function a(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const r in t)if("default"!==r){const i=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,i.get?i:{enumerable:!0,get:()=>t[r]})}return e.default=t,Object.freeze(e)}const l=a(require("apexcharts/core")),o=l.__apex_Environment_Environment,h=l.__apex_BrowserAPIs_BrowserAPIs,c=l.__apex_Animations_prefersReducedMotion,u=l.__apex_PathMorphing_parsePath;function p(t,e){if(!(e>0))return[];if(1===e)return[n({},t)];const r=t.width>=t.height,i=r?t.width:t.height,s=r?t.height:t.width,a=s>0?i/s:e;let l=Math.max(1,Math.ceil(Math.sqrt(a*e)));l>e&&(l=e);const o=Math.floor(e/l);let h=e-o*l;const c=[],u=i/l;let p=0;for(let e=0;e<l;e++){const e=o+(h>0?1:0);h>0&&h--;const i=e>0?s/e:0;for(let s=0;s<e;s++)c.push(r?{x:t.x+p,y:t.y+s*i,width:u,height:i}:{x:t.x+s*i,y:t.y+p,width:i,height:u});p+=u}return c}function d(t,e,r){if(!(e>0))return[];const i=t.width>=t.height,s=i?t.width:t.height,n=i?t.height:t.width,a=i?t.y:t.x,l=a+n,o=n>0?s/n:e;let h=Math.max(Math.ceil(Math.sqrt(o*e)),Math.ceil(s/16));h>=1||(h=1),h>e&&(h=e);const c=Math.floor(e/h);let u=e-c*h;const p=[],d=s/h;let f=i?t.x:t.y;for(let t=0;t<h;t++){const t=c+(u>0?1:0);u>0&&u--;const e=[],s=r(f,f+d,i);if(Array.isArray(s))for(let t=0;t<s.length;t++){const r=s[t];if(!r)continue;const i=Math.max(a,Math.min(r[0],r[1])),n=Math.min(l,Math.max(r[0],r[1]));n>i&&e.push([i,n])}e.length||e.push([a,l]);const n=e.reduce((t,e)=>t+(e[1]-e[0]),0),o=e.map(r=>n>0?(r[1]-r[0])/n*t:t/e.length),h=o.map(t=>Math.floor(t));let g=h.reduce((t,e)=>t+e,0);const y=o.map((t,e)=>({i:e,frac:t-Math.floor(t)})).sort((t,e)=>e.frac-t.frac);for(let e=0;g<t;e++,g++)h[y[e%y.length].i]++;for(let t=0;t<e.length;t++){const r=h[t];if(r<=0)continue;const s=e[t][0],n=(e[t][1]-s)/r;for(let t=0;t<r;t++)p.push(i?{x:f,y:s+t*n,width:d,height:n}:{x:s+t*n,y:f,width:n,height:d})}f+=d}return p}function f(t,e,r,i,s,n){let a=s===r?0:Math.round((t-r)/(s-r)*32767),l=n===i?0:Math.round((e-i)/(n-i)*32767),o=0;for(let t=32768;t>=1;t/=2){const e=(a&t)>0?1:0,r=(l&t)>0?1:0;if(o+=t*t*(3*e^r),0===r){1===e&&(a=t-1-a,l=t-1-l);const r=a;a=l,l=r}}return o}function g(t,e){let r=1/0,i=1/0,s=-1/0,n=-1/0;const a=t.map(t=>{const[a,l]=e(t);return a<r&&(r=a),a>s&&(s=a),l<i&&(i=l),l>n&&(n=l),[a,l]});return t.map((t,e)=>({item:t,d:f(a[e][0],a[e][1],r,i,s,n)})).sort((t,e)=>t.d-e.d).map(t=>t.item)}function y(t){if(!t||"string"!=typeof t)return null;const e=t.trim();if("#"===e[0]){const t=e.slice(1);return 3===t.length?[parseInt(t[0]+t[0],16),parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),1]:6===t.length||8===t.length?[parseInt(t.slice(0,2),16),parseInt(t.slice(2,4),16),parseInt(t.slice(4,6),16),8===t.length?parseInt(t.slice(6,8),16)/255:1]:null}const r=e.match(/^rgba?\(([^)]+)\)$/i);if(r){const t=r[1].split(",").map(t=>parseFloat(t));return t.length<3||t.some(t=>!isFinite(t))?null:[t[0],t[1],t[2],t.length>3?t[3]:1]}return null}function m(t,e){const r=y(t),i=y(e);return r&&i?t=>{const e=Math.round(r[0]+(i[0]-r[0])*t),s=Math.round(r[1]+(i[1]-r[1])*t),n=Math.round(r[2]+(i[2]-r[2])*t),a=r[3]+(i[3]-r[3])*t;return a>=1?`rgb(${e},${s},${n})`:`rgba(${e},${s},${n},${a})`}:null}function x(t){return t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2}const b=new Set(["bar","funnel","pyramid","histogram"]),A=new Set(["pie","donut","polarArea","radialBar","gauge"]),_=new Set(["unit","waffle"]),w=new Set(["treemap","sunburst"]),$=new Set(["boxPlot","violin"]);let v=0;const M=1500,S=t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")};function P(t){return b.has(t)?"bar":A.has(t)?"radial":_.has(t)?"unit":w.has(t)?"partition":$.has(t)?"summary":null}l.default.registerFeatures({morphTypeChange:class{constructor(t,e){this.w=t,this.ctx=e,this._snapshot=null,this._shown=!1,this._ghost=null,this._pieceLayer=null,this._pieceCancel=null,this._ghostTimer=void 0}canMorphTypes(t,e){if(t===e)return!1;const r=P(t),i=P(e);return!(!r||!i)&&("partition"===r==("partition"===i)||"unit"!==r&&"unit"!==i)}isCompatibleSeriesShape(t,e,r){if(!Array.isArray(r)||0===r.length)return!1;const i=P(t),s=P(e);return"unit"===s?!!r.every(t=>"number"==typeof t)||r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):"partition"===s||("radial"===s?!!r.every(t=>"number"==typeof t)||1===r.length&&r[0]&&"object"==typeof r[0]&&Array.isArray(r[0].data):"bar"===s||"summary"===s?r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):null!==i&&null!==s)}captureBeforeDestroy({fromType:t,toType:e,newSeries:r}){var i;if(this._snapshot=null,this._shown=!1,this._removeGhost(),this._cancelPieces(),!o.isBrowser())return!1;const s=this.w.config.chart.animations;if(!s||!1===s.enabled)return!1;if(s.chartTypeMorph&&!1===s.chartTypeMorph.enabled)return!1;if(s.respectReducedMotion&&c())return!1;if(!this.canMorphTypes(t,e))return!1;if(!this.isCompatibleSeriesShape(t,e,r))return!1;const{marks:n,branches:a,unitDots:l}=this._captureFromDOM(t);if(!n.length)return!1;const h=this._buildMapping(n,t,e,r,a);if(0===h.size)return!1;const u=this.w.globals,p=null==(i=this.w.dom.elGraphical)?void 0:i.node,d=u.layoutTween&&!u.layoutTween.done&&u.layoutTween.graphical===p?u.layoutTween.rect:null,f=u.circleTween,g=f&&!f.done&&(null==p?void 0:p.contains(f.node))?f:null,y=g?g.circle.r/g.target.r:1;this._snapshot={fromType:t,toType:e,mapping:h,oldLayout:{translateX:d?d.x:this.w.layout.translateX||0,translateY:d?d.y:this.w.layout.translateY||0,scale:y,shiftX:g?g.circle.cx-y*g.target.cx:0,shiftY:g?g.circle.cy-y*g.target.cy:0}};const m=P(t),x=P(e),b=this._canProbePaths();if("unit"===x&&("bar"===m||"summary"===m||"radial"===m&&b)){const t=this._countUnitSeries(r);this._snapshot.pieceOut=t>0&&t<=M}else if("unit"===m&&("bar"===x||"summary"===x||"radial"===x&&b&&!/^(radialBar|gauge)$/.test(e))){let t=0;l.forEach(e=>{t+=e.length}),t>0&&t<=M&&(this._snapshot.pieceIn=!0,this._snapshot.sourceDots=l,this._snapshot.keyOrder=this._targetKeys(x,r))}return!this._needsGhost(t,e)||this._snapshot.pieceOut||this._snapshot.pieceIn||this._captureGhost(),this.w.globals.previousPaths=[],!0}_needsGhost(t,e){return"unit"===P(t)||"unit"===P(e)}_captureGhost(){var t,e;const r=null==(t=this.w.dom)?void 0:t.Paper,i=r&&r.node;if(!i||"function"!=typeof i.cloneNode)return;const s=i.cloneNode(!0),n=[".apexcharts-xaxis",".apexcharts-yaxis",".apexcharts-grid",".apexcharts-legend",".apexcharts-title-text",".apexcharts-subtitle-text",".apexcharts-annotations",".apexcharts-zoom-rect",".apexcharts-selection-rect",".apexcharts-xcrosshairs",".apexcharts-ycrosshairs"];if("function"==typeof s.querySelectorAll&&n.forEach(t=>{s.querySelectorAll(t).forEach(t=>{t.remove()})}),"function"==typeof s.querySelectorAll){const t="-ghost"+ ++v,e=new Set;s.querySelectorAll("[id]").forEach(r=>{e.add(r.id),r.id+=t}),s.querySelectorAll("*").forEach(r=>{for(const i of r.attributes){const r=i.value.replace(/(url\(['"]?#|^#)([^'")\s]+)/g,(r,i,s)=>e.has(s)?i+s+t:r);r!==i.value&&(i.value=r)}})}null==(e=s.removeAttribute)||e.call(s,"id"),this._ghost=s}_mountGhost(){var t,e,r;const i=this._ghost;if(!i||!o.isBrowser())return;const s=null==(t=this.w.dom)?void 0:t.elWrap;if(!s||"function"!=typeof s.appendChild)return void(this._ghost=null);const n=i.style;n&&(n.position="absolute",n.left="0",n.top="0",n.background="transparent",n.pointerEvents="none",n.opacity="1"),null==(e=i.setAttribute)||e.call(i,"aria-hidden","true"),null==(r=i.setAttribute)||r.call(i,"class","apexcharts-morph-ghost"),s.appendChild(i);const a=this.getSpeed(),l=Math.max(120,Math.round(.55*a));h.requestAnimationFrame(()=>{n&&(n.transition=`opacity ${l}ms ease-in`,n.opacity="0")}),this._ghostTimer=setTimeout(()=>this._removeGhost(),l+60)}_removeGhost(){clearTimeout(this._ghostTimer);const t=this._ghost;this._ghost=null,null==t||t.remove()}_countUnitSeries(t){if(!Array.isArray(t))return 0;let e=0;for(const r of t){if(!r||"object"!=typeof r||!Array.isArray(r.data))return 0;e+=r.data.length}return e}usesPieceTakeover(){return!(!this._snapshot||!this._snapshot.pieceOut)}claimsTargetMark(t,e){return!!(this._snapshot&&this._snapshot.pieceIn&&this._snapshot.mapping.has(`${t}:${e}`))}_makePieceLayer(){var t,e;const r=null==(t=this.w.dom)?void 0:t.elGraphical,i=r&&r.node;if(!i||"function"!=typeof i.appendChild)return null;const s=h.createElementNS("http://www.w3.org/2000/svg","g");if(!s)return null;s.setAttribute("class","apexcharts-morph-pieces"),s.setAttribute("pointer-events","none");const n=null==(e=this.w.globals)?void 0:e.cuid;return n&&s.setAttribute("clip-path",`url(#gridRectBarMask${n})`),i.appendChild(s),this._pieceLayer=s,s}_revealPieceHidden(){var t;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;e&&"function"==typeof e.querySelectorAll&&e.querySelectorAll("[data-piece-hidden]").forEach(S)}_cancelPieces(){this._pieceCancel&&(this._pieceCancel(),this._pieceCancel=null);const t=this._pieceLayer;this._pieceLayer=null,null==t||t.remove(),this._revealPieceHidden()}_canProbePaths(){if(!o.isBrowser())return!1;const t=h.createElementNS("http://www.w3.org/2000/svg","path");return!!t&&"function"==typeof t.isPointInFill}_makeExtentProber(t,e,r){const i=r.ownerDocument.createElementNS("http://www.w3.org/2000/svg","path");i.setAttribute("d",t),i.setAttribute("fill","#000"),i.setAttribute("stroke","#000"),i.setAttribute("stroke-width","3"),i.setAttribute("visibility","hidden"),r.appendChild(i);const s=i.ownerSVGElement;if("function"!=typeof i.isPointInFill||!s||"function"!=typeof s.createSVGPoint)return r.removeChild(i),null;const n=s.createSVGPoint(),a=(t,e)=>{n.x=t,n.y=e;const r=i;return r.isPointInFill(n)||"function"==typeof r.isPointInStroke&&r.isPointInStroke(n)},l=48;return{intervalsAt:(t,r,i)=>{const s=i?e.y:e.x,n=s+(i?e.height:e.width);if(!(n>s))return null;const o=(t,e)=>i?a(e,t):a(t,e),h=[t+.1*(r-t),(t+r)/2,r-.1*(r-t)],c=(t,e,r)=>{let i=e,s=t;for(let t=0;t<6;t++){const t=(i+s)/2;o(t,r)?s=t:i=t}return(i+s)/2},u=(n-s)/l,p=new Array(49).fill(null);let d=!1;for(const t of h)for(let e=0;e<=l;e++)null===p[e]&&o(s+e*u,t)&&(p[e]=t,d=!0);if(!d)return null;const f=[];let g=-1;for(let t=0;t<=49;t++){const e=t<=l&&null!==p[t];if(e&&g<0&&(g=t),!e&&g>=0){const e=t-1,r=p[g],i=0===g?s:c(s+g*u,s+(g-1)*u,r),a=e===l?n:c(s+e*u,s+(e+1)*u,p[e]);a>i&&f.push([i,a]),g=-1}}return f.length?f:null},dispose:()=>{i.remove()}}}_separatePieces(){var t;const e=this._snapshot,r=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||!r)return this._revealPieceHidden();const i=this._readUnitDots(r,new Map);let s=0;if(i.forEach(t=>{s+=t.length}),0===s||s>M)return this._revealPieceHidden();const n=this._makePieceLayer();if(!n)return this._revealPieceHidden();const a=[],l=n.ownerDocument,o=P(e.fromType),h="summary"===o||"radial"===o;if(Array.from(i.keys()).sort((t,e)=>t-e).forEach(t=>{var r;const s=i.get(t),o=this.getInitialBBoxFor(t),c=e.mapping.get(`${t}:0`);if(!o||!c)return void s.forEach(t=>S(t.el));const u=c.fill&&0!==c.fill.indexOf("url(")?c.fill:(null==(r=this.w.globals.colors)?void 0:r[t])||s[0].fill;let f=null;if(h){const e=this.getInitialPathFor(t,0);e&&(f=this._makeExtentProber(e,o,n))}const y=f?d(o,s.length,f.intervalsAt):p(o,s.length);f&&f.dispose();const x=g(y,t=>[t.x+t.width/2,t.y+t.height/2]),b=g(s,t=>[t.x,t.y]);for(let e=0;e<b.length;e++){const r=x[e],i=b[e],s=l.createElementNS("http://www.w3.org/2000/svg","rect");s.setAttribute("data-i",String(t)),s.setAttribute("data-key",i.el.getAttribute("data-key")),s.setAttribute("x",String(r.x)),s.setAttribute("y",String(r.y)),s.setAttribute("width",String(r.width)),s.setAttribute("height",String(r.height)),s.setAttribute("rx","0"),s.setAttribute("fill",String(u)),n.appendChild(s),a.push({el:s,from:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},to:{x:i.x-i.r,y:i.y-i.r,width:2*i.r,height:2*i.r,rx:i.r},fill:m(u,i.fill),fillEnd:i.fill,delay:0,meta:{dotEl:i.el}})}}),!a.length)return this._cancelPieces();this._runPieces(a,t=>{S(t.meta.dotEl),t.el.remove()})}_readUnitDots(t,e){return t.querySelectorAll(".apexcharts-unit-area").forEach(t=>{var r;const i=parseInt(null!=(r=t.getAttribute("i"))?r:"",10);if(isNaN(i))return;const s=e=>parseFloat(t.getAttribute(e)),n=t.getAttribute("cx"),a=s("width")||0,l=s("height")||0,o=null!=n?parseFloat(n):s("x")+a/2,h=null!=n?s("cy"):s("y")+l/2,c=(null!=n?s("r"):Math.max(a,l)/2)||3;if(!isFinite(o)||!isFinite(h))return;let u=e.get(i);u||e.set(i,u=[]),u.push({el:t,x:o,y:h,r:c,fill:t.getAttribute("fill")})}),e}_combinePieces(){var t,e;const r=this._snapshot,i=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!(r&&r.sourceDots&&r.keyOrder&&i))return this._revealPieceHidden();const s=this._collectTargetMarks(r.toType);if(!s.size)return this._revealPieceHidden();const{dx:n,dy:a}=this._oldToNew(),l=Array.from(r.sourceDots.keys()).sort((t,e)=>t-e),o=this._makePieceLayer();if(!o)return this._revealPieceHidden();const h=o.ownerDocument,c=[],u=P(r.toType),f="summary"===u||"radial"===u;for(let t=0;t<l.length;t++){const i=r.sourceDots.get(l[t]),u=r.keyOrder[l[t]],y=u?s.get(u):null,x=y&&this._markD(y),b=x&&this._pathBBox(x);if(!b||!i||!i.length){y&&y.els.forEach(S);continue}const A={x:b.minX,y:b.minY,width:b.maxX-b.minX,height:b.maxY-b.minY},_=y.fill&&0!==y.fill.indexOf("url(")?y.fill:(null==(e=this.w.globals.colors)?void 0:e[y.realIndex])||i[0].fill,w=f?this._makeExtentProber(x,A,o):null,$=w?d(A,i.length,w.intervalsAt):p(A,i.length);w&&w.dispose();const v=g($,t=>[t.x+t.width/2,t.y+t.height/2]),M=g(i,t=>[t.x,t.y]),P={remaining:M.length,els:y.els,g:o.appendChild(h.createElementNS("http://www.w3.org/2000/svg","g"))};for(let t=0;t<M.length;t++){const e=M[t],r=v[t],i=h.createElementNS("http://www.w3.org/2000/svg","rect"),s=e.x+n-e.r,l=e.y+a-e.r;i.setAttribute("data-key",u),i.setAttribute("x",String(s)),i.setAttribute("y",String(l)),i.setAttribute("width",String(2*e.r)),i.setAttribute("height",String(2*e.r)),i.setAttribute("rx",String(e.r)),i.setAttribute("fill",String(e.fill||_)),P.g.appendChild(i),c.push({el:i,from:{x:s,y:l,width:2*e.r,height:2*e.r,rx:e.r},to:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},fill:m(e.fill,_),fillEnd:String(_),delay:0,meta:{markState:P}})}}if(!c.length)return this._cancelPieces();this._runPieces(c,t=>{const e=t.meta.markState;e.remaining--,0===e.remaining&&(e.els.forEach(S),e.g.remove())})}_markD(t){return t.d||t.els.map(t=>t.getAttribute("pathTo")||t.getAttribute("d")).filter(Boolean).join(" ")}_runPieces(t,e){const r=this.getSpeed(),i=Math.min(300,.35*r),s=Math.max(180,r-i);for(let e=0;e<t.length;e++)t[e].delay=t.length>1?e/(t.length-1)*i:0;this._pieceCancel=function({pieces:t,duration:e,onPieceDone:r,onAllDone:i,alive:s}){let n=!1;const a=Date.now(),l=Math.max(1,e),o=(t,e)=>{const r=t.from,i=t.to,s=t.el;s.setAttribute("x",String(r.x+(i.x-r.x)*e)),s.setAttribute("y",String(r.y+(i.y-r.y)*e)),s.setAttribute("width",String(Math.max(0,r.width+(i.width-r.width)*e))),s.setAttribute("height",String(Math.max(0,r.height+(i.height-r.height)*e))),s.setAttribute("rx",String(Math.max(0,r.rx+(i.rx-r.rx)*e))),t.fill?s.setAttribute("fill",t.fill(e)):e>=1&&t.fillEnd&&s.setAttribute("fill",t.fillEnd)},c=()=>{if(n||s&&!s())return;const e=Date.now()-a;let u=!1;for(let i=0;i<t.length;i++){const s=t[i];if(s._done)continue;const n=(e-s.delay)/l;if(n<1&&(u=!0),n<=0)continue;const a=Math.min(1,n);o(s,x(a)),a>=1&&(s._done=!0,r&&r(s))}u?h.requestAnimationFrame(c):i&&i()};return h.requestAnimationFrame(c),()=>{n=!0}}({pieces:t,duration:s,onPieceDone:e,alive:()=>!this.w.globals.isDestroyed,onAllDone:()=>{this._pieceCancel=null,this._cancelPieces()}})}_collectTargetMarks(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl,i=new Map;if(!r)return i;const s=P(t);if("radial"===s)return r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("data:pathFinal")||t.getAttribute("d");r&&r.trim()&&i.set(`${e}:0`,{realIndex:e,d:r,fill:t.getAttribute("fill"),els:[t]})}),i;const n="summary"===s?`.apexcharts-${t}-series`:".apexcharts-bar-series";return r.querySelectorAll(`${n} .apexcharts-series`).forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10)||0;let s=0;t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach(t=>{var e;const n=t.getAttribute("pathTo")||t.getAttribute("d");if(!n||!n.trim())return;const a=parseInt(null!=(e=t.getAttribute("j"))?e:"",10),l=isNaN(a)?s++:a,o=`${r}:${l}`,h=i.get(o);h?h.els.push(t):i.set(o,{realIndex:r,fill:t.getAttribute("fill"),els:[t]})})}),i}_captureFromDOM(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl;if(!r)return{marks:[],branches:[],unitDots:new Map};const i=[],s=[],n=new Map,a=P(t);if("bar"===a){r.querySelectorAll(".apexcharts-bar-series .apexcharts-series").forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10);t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach((t,e)=>{const s=t.getAttribute("d")||t.getAttribute("pathTo");s&&i.push({realIndex:r,j:e,d:s,fill:t.getAttribute("fill")})})})}else if("summary"===a){const e=new Map;r.querySelectorAll(`.apexcharts-${t}-area`).forEach(t=>{var r,i;const s=parseInt(null!=(r=t.getAttribute("j"))?r:"",10);if(isNaN(s))return;const n=t.getAttribute("d")||t.getAttribute("pathTo");if(!n||!n.trim())return;const a="function"==typeof t.closest?t.closest(".apexcharts-series"):null,l=parseInt(null!=(i=null==a?void 0:a.getAttribute("data:realIndex"))?i:"0",10)||0,o=`${l}:${s}`,h=e.get(o);h?h.d+=` ${n}`:e.set(o,{realIndex:l,j:s,d:n,fill:t.getAttribute("fill")})}),Array.from(e.values()).sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j).forEach(t=>i.push(t))}else if("partition"===a)if("treemap"===t){const t=t=>{var e,r,i,s;const n=parseFloat(null!=(e=t.getAttribute("x"))?e:""),a=parseFloat(null!=(r=t.getAttribute("y"))?r:""),l=parseFloat(null!=(i=t.getAttribute("width"))?i:""),o=parseFloat(null!=(s=t.getAttribute("height"))?s:"");return[n,a,l,o].every(t=>isFinite(t))?`M ${n} ${a} L ${n+l} ${a} L ${n+l} ${a+o} L ${n} ${a+o} Z`:null};r.querySelectorAll(".apexcharts-treemap-rect").forEach(e=>{var r,s;const n=t(e);n&&i.push({realIndex:parseInt(null!=(r=e.getAttribute("i"))?r:"0",10)||0,j:parseInt(null!=(s=e.getAttribute("j"))?s:"0",10)||0,d:n,fill:e.getAttribute("fill"),key:e.getAttribute("data:key")||null})});r.querySelectorAll(".apexcharts-treemap-parent-rect").forEach(e=>{const r=t(e),i=e.getAttribute("data:key");r&&i&&s.push({key:i,d:r,fill:e.getAttribute("fill")})})}else{const t=r.querySelectorAll(".apexcharts-sunburst-arc"),e=[];t.forEach(t=>{"true"===t.getAttribute("data:leaf")&&e.push(t)});(e.length?e:Array.from(t)).forEach((t,e)=>{const r=t.getAttribute("d");r&&r.trim()&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill"),key:t.getAttribute("data:key")||null})}),t.forEach(t=>{if("true"===t.getAttribute("data:leaf"))return;const e=t.getAttribute("d"),r=t.getAttribute("data:key");e&&e.trim()&&r&&s.push({key:r,d:e,fill:t.getAttribute("fill")})})}else if("unit"===a)this._readUnitDots(r,n),Array.from(n.keys()).sort((t,e)=>t-e).forEach(t=>{const e=n.get(t),r=e.map(t=>t.x),s=e.map(t=>t.y),a=Math.min(...r)-2,l=Math.min(...s)-2,o=Math.max(...r)+2,h=Math.max(...s)+2;i.push({realIndex:t,j:0,d:`M ${a} ${l} L ${o} ${l} L ${o} ${h} L ${a} ${h} Z`,fill:e[0].fill})});else if("radial"===a)if("radialBar"===t||"gauge"===t){const t=this.w.globals.circleGeometry,e=t?t.cx:this.w.layout.gridWidth/2,s=t?t.cy:this.w.layout.gridHeight/2;r.querySelectorAll(".apexcharts-radial-series .apexcharts-radialbar-area").forEach(t=>{var r;const n=t.parentElement,a=parseInt(null!=(r=null==n?void 0:n.getAttribute("data:realIndex"))?r:"0",10),l=t.getAttribute("d");if(!l)return;const o=parseFloat(t.getAttribute("stroke-width")||"0"),h=o>1&&this._radialArcToFilledSegment(l,o,e,s)||l;i.push({realIndex:a,j:0,d:h,fill:t.getAttribute("stroke")})})}else{r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("d");r&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill")})})}return{marks:i,branches:s,unitDots:n}}_radialArcToFilledSegment(t,e,r,i){const s=t.match(/M\s*(-?[\d.]+)\s+(-?[\d.]+)\s+A\s*(-?[\d.]+)\s+(?:-?[\d.]+)\s+(?:-?[\d.]+)\s+(\d)\s+(\d)\s+(-?[\d.]+)\s+(-?[\d.]+)/);if(!s)return null;const n=parseFloat(s[1]),a=parseFloat(s[2]),l=parseFloat(s[3]),o=parseInt(s[4],10),h=parseInt(s[5],10),c=parseFloat(s[6]),u=parseFloat(s[7]);if(!isFinite(l)||l<=0)return null;const p=e/2,d=l+p,f=Math.max(0,l-p),g=(t,e,s)=>{const n=t-r,a=e-i,l=Math.sqrt(n*n+a*a);if(0===l)return{x:r,y:i};const o=s/l;return{x:r+n*o,y:i+a*o}},y=g(n,a,d),m=g(c,u,d),x=g(n,a,f),b=g(c,u,f),A=h?0:1;return`M ${y.x} ${y.y} A ${d} ${d} 0 ${o} ${h} ${m.x} ${m.y} L ${b.x} ${b.y} A ${f} ${f} 0 ${o} ${A} ${x.x} ${x.y} Z`}buildRingSegmentPath(t,e,r,i,s,n){const a=i/2,l=r+a,o=Math.max(0,r-a),h=(s-90)*Math.PI/180,c=(n-90)*Math.PI/180,u=t+l*Math.cos(h),p=e+l*Math.sin(h),d=t+l*Math.cos(c),f=e+l*Math.sin(c),g=t+o*Math.cos(h),y=e+o*Math.sin(h),m=t+o*Math.cos(c),x=e+o*Math.sin(c),b=n>s?1:0,A=Math.abs(n-s)>180?1:0;return`M ${u} ${p} A ${l} ${l} 0 ${A} ${b} ${d} ${f} L ${m} ${x} A ${o} ${o} 0 ${A} ${1-b} ${g} ${y} Z`}getFromType(){return this._snapshot?this._snapshot.fromType:null}_buildMapping(t,e,r,i,s){const n=new Map,a=P(r),l=t.slice().sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j);if("partition"===a&&s&&s.length){const t=l.filter(t=>t.key);t.length===l.length&&(t.forEach(t=>{n.set(`key:${t.key}`,{d:t.d,fill:t.fill})}),s.forEach(t=>{n.set(`key:${t.key}`,{d:t.d,fill:t.fill})}))}const o="unit"===P(e);if("radial"===a||"unit"===a||"partition"===a)return l.forEach((t,e)=>{n.set(`${o?t.realIndex:e}:0`,{d:t.d,fill:t.fill})}),n;if("bar"===a||"summary"===a){const t=this._targetKeys(a,i);l.forEach((e,r)=>{const i=t[o?e.realIndex:r];i&&n.set(i,{d:e.d,fill:e.fill})})}return n}_targetKeys(t,e){var r;const i=[],s=Array.isArray(e)?e:[];if("radial"===t){const t=1===s.length&&Array.isArray(null==(r=s[0])?void 0:r.data)?s[0].data.length:s.length;for(let e=0;e<t;e++)i.push(`${e}:0`)}else s.forEach((t,e)=>{const r=t&&Array.isArray(t.data)?t.data:[];for(let t=0;t<r.length;t++)i.push(`${e}:${t}`)});return i}isActive(){return null!==this._snapshot}getInitialPathFor(t,e){if(!this._snapshot)return null;const r=this._snapshot.mapping.get(`${t}:${e}`);if(!r)return null;const{k:i,dx:s,dy:n}=this._oldToNew();return 1===i&&0===s&&0===n?r.d:this._translatePathD(r.d,s,n,i)}_oldToNew(){var t,e,r;const i=this._snapshot.oldLayout;return{k:null!=(t=i.scale)?t:1,dx:i.translateX+(null!=(e=i.shiftX)?e:0)-(this.w.layout.translateX||0),dy:i.translateY+(null!=(r=i.shiftY)?r:0)-(this.w.layout.translateY||0)}}_translatePathD(t,e,r,i=1){if(0===e&&0===r&&1===i)return t;const s=u(t),n=t=>t*i+e,a=t=>t*i+r;return s.map(t=>{const e=t[0];return"Z"===e?"Z":"M"===e||"L"===e||"T"===e?`${e} ${n(t[1])} ${a(t[2])}`:"H"===e?`${e} ${n(t[1])}`:"V"===e?`${e} ${a(t[1])}`:"C"===e?`${e} ${n(t[1])} ${a(t[2])} ${n(t[3])} ${a(t[4])} ${n(t[5])} ${a(t[6])}`:"S"===e||"Q"===e?`${e} ${n(t[1])} ${a(t[2])} ${n(t[3])} ${a(t[4])}`:"A"===e?`${e} ${t[1]*i} ${t[2]*i} ${t[3]} ${t[4]} ${t[5]} ${n(t[6])} ${a(t[7])}`:t.join(" ")}).join(" ")}getInitialCenterFor(t){const e=this.getInitialBBoxFor(t);return e?{x:e.x+e.width/2,y:e.y+e.height/2}:null}getInitialPathAt(t){return this.getInitialPathFor(t,0)}getInitialPathForKey(t){return this._snapshot&&t?this.getInitialPathFor("key",t):null}hasKeyedMarks(){if(!this._snapshot)return!1;for(const t of this._snapshot.mapping.keys())if("string"==typeof t&&t.startsWith("key:"))return!0;return!1}getInitialSlotFor(t,e,r){const i=this.getInitialBBoxFor(t);if(!i)return null;const s=i.x+i.width/2,n=i.y+i.height/2;if(!(r>1&&e>=0))return{x:s,y:n};const a=(Math.min(e,r-1)+.5)/r;return i.height>=i.width?{x:s,y:i.y+i.height*(1-a)}:{x:i.x+i.width*a,y:n}}getInitialBBoxFor(t){if(!this._snapshot)return null;const e=this._snapshot.mapping.get(`${t}:0`);if(!e)return null;const r=this._pathBBox(e.d);if(!r)return null;const{k:i,dx:s,dy:n}=this._oldToNew();return{x:r.minX*i+s,y:r.minY*i+n,width:(r.maxX-r.minX)*i,height:(r.maxY-r.minY)*i}}_pathBBox(t){let e=1/0,r=1/0,i=-1/0,s=-1/0,n=0,a=0,l=0,o=0;const h=(t,n)=>{isFinite(t)&&isFinite(n)&&(t<e&&(e=t),t>i&&(i=t),n<r&&(r=n),n>s&&(s=n))};return u(t).forEach(t=>{const e=t[0];if("Z"===e)return n=l,void(a=o);const r=t.length,i="H"===e?t[1]:"V"===e?n:t[r-2],s="H"===e?a:"V"===e?t[1]:t[r-1];if("A"===e){if(t[1]){const e=(n-i)/2,r=(a-s)/2,l=(t[4]===t[5]?-1:1)*Math.sqrt(Math.max(0,t[1]*t[1]/(e*e+r*r)-1)),o=n-e+l*r,c=a-r-l*e,u=Math.hypot(n-o,a-c),p=Math.atan2(a-c,n-o),d=2*Math.PI;let f=Math.atan2(s-c,i-o)-p;t[5]&&f<0?f+=d:!t[5]&&f>0&&(f-=d);for(let t=0;t<d;t+=Math.PI/2){((f>0?t-p:p-t)%d+d)%d<=Math.abs(f)&&h(o+u*Math.cos(t),c+u*Math.sin(t))}}}else if("H"!==e&&"V"!==e)for(let e=1;e+1<r;e+=2)h(t[e],t[e+1]);h(i,s),n=i,a=s,"M"===e&&(l=i,o=s)}),e>i?null:{minX:e,minY:r,maxX:i,maxY:s}}getSpeed(){const t=this.w.config.chart.animations;return t.chartTypeMorph&&t.chartTypeMorph.speed||t.speed||600}applyChromeFade(){var t;if(!this._snapshot||!o.isBrowser())return;this._shown=!0;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||this._snapshot.resume)return;this._snapshot.pieceOut?this._separatePieces():this._snapshot.pieceIn?this._combinePieces():this._mountGhost();const r=this.getSpeed(),i=Array.from(e.querySelectorAll(".apexcharts-xaxis,.apexcharts-yaxis,.apexcharts-grid,.apexcharts-legend,.apexcharts-title-text,.apexcharts-subtitle-text")).filter(t=>t.style),s=(t,e)=>i.forEach(r=>{r.style.opacity=t,null!=e&&(r.style.transition=e)});s("0",`opacity ${r}ms ease-out`);const n=()=>this.w.globals.isDestroyed;h.requestAnimationFrame(()=>n()||s("1")),setTimeout(()=>n()||s("",""),r+80);const a=this._snapshot;setTimeout(()=>{n()||this._snapshot&&this._snapshot!==a||this.cleanup()},r+100)}retire(){const t=this._snapshot;if(!t||!this._shown)return;const e=this._pieceLayer;this.ctx._unitPieces=t.pieceOut&&e;const r=new Map;null==e||e.querySelectorAll("g").forEach(t=>{const e=t.firstChild&&t.getBBox();e&&r.set(t.firstChild.getAttribute("data-key"),{d:`M${e.x} ${e.y}H${e.x+e.width}V${e.y+e.height}H${e.x}Z`})}),this.cleanup(!0),r.size&&(this._collectTargetMarks(t.toType).forEach((t,e)=>{r.has(e)||r.set(e,{d:this._markD(t)})}),this.w.globals.previousPaths=[],this._snapshot=Object.assign(t,{mapping:r,pieceIn:!1,resume:!0,oldLayout:n({},this.w.layout)}),h.requestAnimationFrame(()=>{this._snapshot===t&&(this._shown=!0)}))}cleanup(t){this._snapshot=null,this._shown=!1,t||this._removeGhost(),this._cancelPieces()}}}),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>l.default});
|
|
5
|
+
"use strict";var t=Object.defineProperty,e=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable,s=(e,r,i)=>r in e?t(e,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[r]=i,n=(t,n)=>{for(var a in n||(n={}))r.call(n,a)&&s(t,a,n[a]);if(e)for(var a of e(n))i.call(n,a)&&s(t,a,n[a]);return t};Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function a(t){if(t&&t.__esModule)return t;const e=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const r in t)if("default"!==r){const i=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(e,r,i.get?i:{enumerable:!0,get:()=>t[r]})}return e.default=t,Object.freeze(e)}const l=a(require("apexcharts/core")),o=l.__apex_Environment_Environment,h=l.__apex_BrowserAPIs_BrowserAPIs,c=l.__apex_Animations_prefersReducedMotion,u=l.__apex_PathMorphing_parsePath;function p(t,e){if(!(e>0))return[];if(1===e)return[n({},t)];const r=t.width>=t.height,i=r?t.width:t.height,s=r?t.height:t.width,a=s>0?i/s:e;let l=Math.max(1,Math.ceil(Math.sqrt(a*e)));l>e&&(l=e);const o=Math.floor(e/l);let h=e-o*l;const c=[],u=i/l;let p=0;for(let e=0;e<l;e++){const e=o+(h>0?1:0);h>0&&h--;const i=e>0?s/e:0;for(let s=0;s<e;s++)c.push(r?{x:t.x+p,y:t.y+s*i,width:u,height:i}:{x:t.x+s*i,y:t.y+p,width:i,height:u});p+=u}return c}function d(t,e,r){if(!(e>0))return[];const i=t.width>=t.height,s=i?t.width:t.height,n=i?t.height:t.width,a=i?t.y:t.x,l=a+n,o=n>0?s/n:e;let h=Math.max(Math.ceil(Math.sqrt(o*e)),Math.ceil(s/16));h>=1||(h=1),h>e&&(h=e);const c=Math.floor(e/h);let u=e-c*h;const p=[],d=s/h;let f=i?t.x:t.y;for(let t=0;t<h;t++){const t=c+(u>0?1:0);u>0&&u--;const e=[],s=r(f,f+d,i);if(Array.isArray(s))for(let t=0;t<s.length;t++){const r=s[t];if(!r)continue;const i=Math.max(a,Math.min(r[0],r[1])),n=Math.min(l,Math.max(r[0],r[1]));n>i&&e.push([i,n])}e.length||e.push([a,l]);const n=e.reduce((t,e)=>t+(e[1]-e[0]),0),o=e.map(r=>n>0?(r[1]-r[0])/n*t:t/e.length),h=o.map(t=>Math.floor(t));let g=h.reduce((t,e)=>t+e,0);const y=o.map((t,e)=>({i:e,frac:t-Math.floor(t)})).sort((t,e)=>e.frac-t.frac);for(let e=0;g<t;e++,g++)h[y[e%y.length].i]++;for(let t=0;t<e.length;t++){const r=h[t];if(r<=0)continue;const s=e[t][0],n=(e[t][1]-s)/r;for(let t=0;t<r;t++)p.push(i?{x:f,y:s+t*n,width:d,height:n}:{x:s+t*n,y:f,width:n,height:d})}f+=d}return p}function f(t,e,r,i,s,n){let a=s===r?0:Math.round((t-r)/(s-r)*32767),l=n===i?0:Math.round((e-i)/(n-i)*32767),o=0;for(let t=32768;t>=1;t/=2){const e=(a&t)>0?1:0,r=(l&t)>0?1:0;if(o+=t*t*(3*e^r),0===r){1===e&&(a=t-1-a,l=t-1-l);const r=a;a=l,l=r}}return o}function g(t,e){let r=1/0,i=1/0,s=-1/0,n=-1/0;const a=t.map(t=>{const[a,l]=e(t);return a<r&&(r=a),a>s&&(s=a),l<i&&(i=l),l>n&&(n=l),[a,l]});return t.map((t,e)=>({item:t,d:f(a[e][0],a[e][1],r,i,s,n)})).sort((t,e)=>t.d-e.d).map(t=>t.item)}function y(t){if(!t||"string"!=typeof t)return null;const e=t.trim();if("#"===e[0]){const t=e.slice(1);return 3===t.length?[parseInt(t[0]+t[0],16),parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),1]:6===t.length||8===t.length?[parseInt(t.slice(0,2),16),parseInt(t.slice(2,4),16),parseInt(t.slice(4,6),16),8===t.length?parseInt(t.slice(6,8),16)/255:1]:null}const r=e.match(/^rgba?\(([^)]+)\)$/i);if(r){const t=r[1].split(",").map(t=>parseFloat(t));return t.length<3||t.some(t=>!isFinite(t))?null:[t[0],t[1],t[2],t.length>3?t[3]:1]}return null}function m(t,e){const r=y(t),i=y(e);return r&&i?t=>{const e=Math.round(r[0]+(i[0]-r[0])*t),s=Math.round(r[1]+(i[1]-r[1])*t),n=Math.round(r[2]+(i[2]-r[2])*t),a=r[3]+(i[3]-r[3])*t;return a>=1?`rgb(${e},${s},${n})`:`rgba(${e},${s},${n},${a})`}:null}function x(t){return t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2}const b=new Set(["bar","funnel","pyramid","histogram"]),A=new Set(["pie","donut","polarArea","radialBar","gauge"]),_=new Set(["unit","waffle"]),w=new Set(["treemap","sunburst"]),$=new Set(["boxPlot","violin"]);let v=0;const M=1500,S=t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")};function P(t){return b.has(t)?"bar":A.has(t)?"radial":_.has(t)?"unit":w.has(t)?"partition":$.has(t)?"summary":null}l.default.registerFeatures({morphTypeChange:class{constructor(t,e){this.w=t,this.ctx=e,this._snapshot=null,this._shown=!1,this._ghost=null,this._pieceLayer=null,this._pieceCancel=null,this._ghostTimer=void 0}canMorphTypes(t,e){if(t===e)return!1;const r=P(t),i=P(e);return!(!r||!i)&&("partition"===r==("partition"===i)||"unit"!==r&&"unit"!==i)}isCompatibleSeriesShape(t,e,r){if(!Array.isArray(r)||0===r.length)return!1;const i=P(t),s=P(e);return"unit"===s?!!r.every(t=>"number"==typeof t)||r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):"partition"===s||("radial"===s?!!r.every(t=>"number"==typeof t)||1===r.length&&r[0]&&"object"==typeof r[0]&&Array.isArray(r[0].data):"bar"===s||"summary"===s?r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):null!==i&&null!==s)}captureBeforeDestroy({fromType:t,toType:e,newSeries:r}){var i;if(this._snapshot=null,this._shown=!1,this._removeGhost(),this._cancelPieces(),!o.isBrowser())return!1;const s=this.w.config.chart.animations;if(!s||!1===s.enabled)return!1;if(s.chartTypeMorph&&!1===s.chartTypeMorph.enabled)return!1;if(s.respectReducedMotion&&c())return!1;if(!this.canMorphTypes(t,e))return!1;if(!this.isCompatibleSeriesShape(t,e,r))return!1;const{marks:n,branches:a,unitDots:l}=this._captureFromDOM(t);if(!n.length)return!1;const h=this._buildMapping(n,t,e,r,a);if(0===h.size)return!1;const u=this.w.globals,p=null==(i=this.w.dom.elGraphical)?void 0:i.node,d=u.layoutTween&&!u.layoutTween.done&&u.layoutTween.graphical===p?u.layoutTween.rect:null,f=u.circleTween,g=f&&!f.done&&(null==p?void 0:p.contains(f.node))?f:null,y=g?g.circle.r/g.target.r:1;this._snapshot={fromType:t,toType:e,mapping:h,oldLayout:{translateX:d?d.x:this.w.layout.translateX||0,translateY:d?d.y:this.w.layout.translateY||0,scale:y,shiftX:g?g.circle.cx-y*g.target.cx:0,shiftY:g?g.circle.cy-y*g.target.cy:0}};const m=P(t),x=P(e),b=this._canProbePaths();if("unit"===x&&("bar"===m||"summary"===m||"radial"===m&&b)){const t=this._countUnitSeries(r);this._snapshot.pieceOut=t>0&&t<=M}else if("unit"===m&&("bar"===x||"summary"===x||"radial"===x&&b&&!/^(radialBar|gauge)$/.test(e))){let t=0;l.forEach(e=>{t+=e.length}),t>0&&t<=M&&(this._snapshot.pieceIn=!0,this._snapshot.sourceDots=l,this._snapshot.keyOrder=this._targetKeys(x,r))}return!this._needsGhost(t,e)||this._snapshot.pieceOut||this._snapshot.pieceIn||this._captureGhost(),this.w.globals.previousPaths=[],!0}_needsGhost(t,e){return"unit"===P(t)||"unit"===P(e)}_captureGhost(){var t,e;const r=null==(t=this.w.dom)?void 0:t.Paper,i=r&&r.node;if(!i||"function"!=typeof i.cloneNode)return;const s=i.cloneNode(!0),n=[".apexcharts-xaxis",".apexcharts-yaxis",".apexcharts-grid",".apexcharts-legend",".apexcharts-title-text",".apexcharts-subtitle-text",".apexcharts-annotations",".apexcharts-zoom-rect",".apexcharts-selection-rect",".apexcharts-xcrosshairs",".apexcharts-ycrosshairs"];if("function"==typeof s.querySelectorAll&&n.forEach(t=>{s.querySelectorAll(t).forEach(t=>{t.remove()})}),"function"==typeof s.querySelectorAll){const t="-ghost"+ ++v,e=new Set;s.querySelectorAll("[id]").forEach(r=>{e.add(r.id),r.id+=t}),s.querySelectorAll("*").forEach(r=>{for(const i of r.attributes){const r=i.value.replace(/(url\(['"]?#|^#)([^'")\s]+)/g,(r,i,s)=>e.has(s)?i+s+t:r);r!==i.value&&(i.value=r)}})}null==(e=s.removeAttribute)||e.call(s,"id"),this._ghost=s}_mountGhost(){var t,e,r;const i=this._ghost;if(!i||!o.isBrowser())return;const s=null==(t=this.w.dom)?void 0:t.elWrap;if(!s||"function"!=typeof s.appendChild)return void(this._ghost=null);const n=i.style;n&&(n.position="absolute",n.left="0",n.top="0",n.background="transparent",n.pointerEvents="none",n.opacity="1"),null==(e=i.setAttribute)||e.call(i,"aria-hidden","true"),null==(r=i.setAttribute)||r.call(i,"class","apexcharts-morph-ghost"),s.appendChild(i);const a=this.getSpeed(),l=Math.max(120,Math.round(.55*a));h.requestAnimationFrame(()=>{n&&(n.transition=`opacity ${l}ms ease-in`,n.opacity="0")}),this._ghostTimer=setTimeout(()=>this._removeGhost(),l+60)}_removeGhost(){clearTimeout(this._ghostTimer);const t=this._ghost;this._ghost=null,null==t||t.remove()}_countUnitSeries(t){if(!Array.isArray(t))return 0;let e=0;for(const r of t){if(!r||"object"!=typeof r||!Array.isArray(r.data))return 0;e+=r.data.length}return e}usesPieceTakeover(){return!(!this._snapshot||!this._snapshot.pieceOut)}claimsTargetMark(t,e){return!!(this._snapshot&&this._snapshot.pieceIn&&this._snapshot.mapping.has(`${t}:${e}`))}_makePieceLayer(){var t,e;const r=null==(t=this.w.dom)?void 0:t.elGraphical,i=r&&r.node;if(!i||"function"!=typeof i.appendChild)return null;const s=h.createElementNS("http://www.w3.org/2000/svg","g");if(!s)return null;s.setAttribute("class","apexcharts-morph-pieces"),s.setAttribute("pointer-events","none");const n=null==(e=this.w.globals)?void 0:e.cuid;return n&&s.setAttribute("clip-path",`url(#gridRectBarMask${n})`),i.appendChild(s),this._pieceLayer=s,s}_revealPieceHidden(){var t;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;e&&"function"==typeof e.querySelectorAll&&e.querySelectorAll("[data-piece-hidden]").forEach(S)}_cancelPieces(){this._pieceCancel&&(this._pieceCancel(),this._pieceCancel=null);const t=this._pieceLayer;this._pieceLayer=null,null==t||t.remove(),this._revealPieceHidden()}_canProbePaths(){if(!o.isBrowser())return!1;const t=h.createElementNS("http://www.w3.org/2000/svg","path");return!!t&&"function"==typeof t.isPointInFill}_makeExtentProber(t,e,r){const i=r.ownerDocument.createElementNS("http://www.w3.org/2000/svg","path");i.setAttribute("d",t),i.setAttribute("fill","#000"),i.setAttribute("stroke","#000"),i.setAttribute("stroke-width","3"),i.setAttribute("visibility","hidden"),r.appendChild(i);const s=i.ownerSVGElement;if("function"!=typeof i.isPointInFill||!s||"function"!=typeof s.createSVGPoint)return i.remove(),null;const n=s.createSVGPoint(),a=(t,e)=>{n.x=t,n.y=e;const r=i;return r.isPointInFill(n)||r.isPointInStroke(n)},l=48;return{intervalsAt:(t,r,i)=>{const s=i?e.y:e.x,n=s+(i?e.height:e.width);if(!(n>s))return null;const o=(t,e)=>i?a(e,t):a(t,e),h=[t+.1*(r-t),(t+r)/2,r-.1*(r-t)],c=(t,e,r)=>{let i=e,s=t;for(let t=0;t<6;t++){const t=(i+s)/2;o(t,r)?s=t:i=t}return(i+s)/2},u=(n-s)/l,p=new Array(49).fill(null);let d=!1;for(const t of h)for(let e=0;e<=l;e++)null===p[e]&&o(s+e*u,t)&&(p[e]=t,d=!0);if(!d)return null;const f=[];let g=-1;for(let t=0;t<=49;t++){const e=t<=l&&null!==p[t];if(e&&g<0&&(g=t),!e&&g>=0){const e=t-1,r=p[g],i=0===g?s:c(s+g*u,s+(g-1)*u,r),a=e===l?n:c(s+e*u,s+(e+1)*u,p[e]);a>i&&f.push([i,a]),g=-1}}return f.length?f:null},dispose:()=>{i.remove()}}}_separatePieces(){var t;const e=this._snapshot,r=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||!r)return this._revealPieceHidden();const i=this._readUnitDots(r,new Map);let s=0;if(i.forEach(t=>{s+=t.length}),0===s||s>M)return this._revealPieceHidden();const n=this._makePieceLayer();if(!n)return this._revealPieceHidden();const a=[],l=n.ownerDocument,o=l.createDocumentFragment(),h=P(e.fromType),c="summary"===h||"radial"===h;if(Array.from(i.keys()).sort((t,e)=>t-e).forEach(t=>{var r;const s=i.get(t),h=this.getInitialBBoxFor(t),u=e.mapping.get(`${t}:0`);if(!h||!u)return void s.forEach(t=>S(t.el));const f=u.fill&&0!==u.fill.indexOf("url(")?u.fill:(null==(r=this.w.globals.colors)?void 0:r[t])||s[0].fill;let y=null;if(c){const e=this.getInitialPathFor(t,0);e&&(y=this._makeExtentProber(e,h,n))}const x=y?d(h,s.length,y.intervalsAt):p(h,s.length);y&&y.dispose();const b=g(x,t=>[t.x+t.width/2,t.y+t.height/2]),A=g(s,t=>[t.x,t.y]);for(let e=0;e<A.length;e++){const r=b[e],i=A[e],s=l.createElementNS("http://www.w3.org/2000/svg","rect");s.setAttribute("data-i",String(t)),s.setAttribute("data-key",i.el.getAttribute("data-key")),s.setAttribute("x",String(r.x)),s.setAttribute("y",String(r.y)),s.setAttribute("width",String(r.width)),s.setAttribute("height",String(r.height)),s.setAttribute("rx","0"),s.setAttribute("fill",String(f)),o.appendChild(s),a.push({el:s,from:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},to:{x:i.x-i.r,y:i.y-i.r,width:2*i.r,height:2*i.r,rx:i.r},fill:m(f,i.fill),fillEnd:i.fill,delay:0,meta:{dotEl:i.el}})}}),n.appendChild(o),!a.length)return this._cancelPieces();this._runPieces(a,t=>{S(t.meta.dotEl),t.el.remove()})}_readUnitDots(t,e){return t.querySelectorAll(".apexcharts-unit-area").forEach(t=>{var r;const i=parseInt(null!=(r=t.getAttribute("i"))?r:"",10);if(isNaN(i))return;const s=e=>parseFloat(t.getAttribute(e)),n=t.getAttribute("cx"),a=s("width")||0,l=s("height")||0,o=null!=n?parseFloat(n):s("x")+a/2,h=null!=n?s("cy"):s("y")+l/2,c=(null!=n?s("r"):Math.max(a,l)/2)||3;if(!isFinite(o)||!isFinite(h))return;let u=e.get(i);u||e.set(i,u=[]),u.push({el:t,x:o,y:h,r:c,fill:t.getAttribute("fill")})}),e}_combinePieces(){var t,e;const r=this._snapshot,i=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!(r&&r.sourceDots&&r.keyOrder&&i))return this._revealPieceHidden();const s=this._collectTargetMarks(r.toType);if(!s.size)return this._revealPieceHidden();const{dx:n,dy:a}=this._oldToNew(),l=Array.from(r.sourceDots.keys()).sort((t,e)=>t-e),o=this._makePieceLayer();if(!o)return this._revealPieceHidden();const h=o.ownerDocument,c=h.createDocumentFragment(),u=[],f=P(r.toType),y="summary"===f||"radial"===f;for(let t=0;t<l.length;t++){const i=r.sourceDots.get(l[t]),f=r.keyOrder[l[t]],x=f?s.get(f):null,b=x&&this._markD(x),A=b&&this._pathBBox(b);if(!A||!i||!i.length){x&&x.els.forEach(S);continue}const _={x:A.minX,y:A.minY,width:A.maxX-A.minX,height:A.maxY-A.minY},w=x.fill&&0!==x.fill.indexOf("url(")?x.fill:(null==(e=this.w.globals.colors)?void 0:e[x.realIndex])||i[0].fill,$=y?this._makeExtentProber(b,_,o):null,v=$?d(_,i.length,$.intervalsAt):p(_,i.length);$&&$.dispose();const M=g(v,t=>[t.x+t.width/2,t.y+t.height/2]),P=g(i,t=>[t.x,t.y]),I={remaining:P.length,els:x.els,g:c.appendChild(h.createElementNS("http://www.w3.org/2000/svg","g"))};for(let t=0;t<P.length;t++){const e=P[t],r=M[t],i=h.createElementNS("http://www.w3.org/2000/svg","rect"),s=e.x+n-e.r,l=e.y+a-e.r;i.setAttribute("data-key",f),i.setAttribute("x",String(s)),i.setAttribute("y",String(l)),i.setAttribute("width",String(2*e.r)),i.setAttribute("height",String(2*e.r)),i.setAttribute("rx",String(e.r)),i.setAttribute("fill",String(e.fill||w)),I.g.appendChild(i),u.push({el:i,from:{x:s,y:l,width:2*e.r,height:2*e.r,rx:e.r},to:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},fill:m(e.fill,w),fillEnd:String(w),delay:0,meta:{markState:I}})}}if(o.appendChild(c),!u.length)return this._cancelPieces();this._runPieces(u,t=>{const e=t.meta.markState;e.remaining--,0===e.remaining&&(e.els.forEach(S),e.g.remove())})}_markD(t){return t.d||t.els.map(t=>t.getAttribute("pathTo")||t.getAttribute("d")).filter(Boolean).join(" ")}_runPieces(t,e){const r=this.getSpeed(),i=Math.min(300,.35*r),s=Math.max(180,r-i);for(let e=0;e<t.length;e++)t[e].delay=t.length>1?e/(t.length-1)*i:0;this._pieceCancel=function({pieces:t,duration:e,onPieceDone:r,onAllDone:i,alive:s}){let n=!1;const a=Date.now(),l=Math.max(1,e),o=(t,e)=>{const r=t.from,i=t.to,s=t.el;s.setAttribute("x",String(r.x+(i.x-r.x)*e)),s.setAttribute("y",String(r.y+(i.y-r.y)*e)),s.setAttribute("width",String(Math.max(0,r.width+(i.width-r.width)*e))),s.setAttribute("height",String(Math.max(0,r.height+(i.height-r.height)*e))),s.setAttribute("rx",String(Math.max(0,r.rx+(i.rx-r.rx)*e))),t.fill?s.setAttribute("fill",t.fill(e)):e>=1&&t.fillEnd&&s.setAttribute("fill",t.fillEnd)},c=()=>{if(n||s&&!s())return;const e=Date.now()-a;let u=!1;for(let i=0;i<t.length;i++){const s=t[i];if(s._done)continue;const n=(e-s.delay)/l;if(n<1&&(u=!0),n<=0)continue;const a=Math.min(1,n);o(s,x(a)),a>=1&&(s._done=!0,r&&r(s))}u?h.requestAnimationFrame(c):i&&i()};return h.requestAnimationFrame(c),()=>{n=!0}}({pieces:t,duration:s,onPieceDone:e,alive:()=>!this.w.globals.isDestroyed,onAllDone:()=>{this._pieceCancel=null,this._cancelPieces()}})}_collectTargetMarks(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl,i=new Map;if(!r)return i;const s=P(t);if("radial"===s)return r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("data:pathFinal")||t.getAttribute("d");r&&r.trim()&&i.set(`${e}:0`,{realIndex:e,d:r,fill:t.getAttribute("fill"),els:[t]})}),i;const n="summary"===s?`.apexcharts-${t}-series`:".apexcharts-bar-series";return r.querySelectorAll(`${n} .apexcharts-series`).forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10)||0;let s=0;t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach(t=>{var e;const n=t.getAttribute("pathTo")||t.getAttribute("d");if(!n||!n.trim())return;const a=parseInt(null!=(e=t.getAttribute("j"))?e:"",10),l=isNaN(a)?s++:a,o=`${r}:${l}`,h=i.get(o);h?h.els.push(t):i.set(o,{realIndex:r,fill:t.getAttribute("fill"),els:[t]})})}),i}_captureFromDOM(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl;if(!r)return{marks:[],branches:[],unitDots:new Map};const i=[],s=[],n=new Map,a=P(t);if("bar"===a){r.querySelectorAll(".apexcharts-bar-series .apexcharts-series").forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10);t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach((t,e)=>{const s=t.getAttribute("d")||t.getAttribute("pathTo");s&&i.push({realIndex:r,j:e,d:s,fill:t.getAttribute("fill")})})})}else if("summary"===a){const e=new Map;r.querySelectorAll(`.apexcharts-${t}-area`).forEach(t=>{var r,i;const s=parseInt(null!=(r=t.getAttribute("j"))?r:"",10);if(isNaN(s))return;const n=t.getAttribute("d")||t.getAttribute("pathTo");if(!n||!n.trim())return;const a="function"==typeof t.closest?t.closest(".apexcharts-series"):null,l=parseInt(null!=(i=null==a?void 0:a.getAttribute("data:realIndex"))?i:"0",10)||0,o=`${l}:${s}`,h=e.get(o);h?h.d+=` ${n}`:e.set(o,{realIndex:l,j:s,d:n,fill:t.getAttribute("fill")})}),Array.from(e.values()).sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j).forEach(t=>i.push(t))}else if("partition"===a)if("treemap"===t){const t=t=>{var e,r,i,s;const n=parseFloat(null!=(e=t.getAttribute("x"))?e:""),a=parseFloat(null!=(r=t.getAttribute("y"))?r:""),l=parseFloat(null!=(i=t.getAttribute("width"))?i:""),o=parseFloat(null!=(s=t.getAttribute("height"))?s:"");return[n,a,l,o].every(t=>isFinite(t))?`M ${n} ${a} L ${n+l} ${a} L ${n+l} ${a+o} L ${n} ${a+o} Z`:null};r.querySelectorAll(".apexcharts-treemap-rect").forEach(e=>{var r,s;const n=t(e);n&&i.push({realIndex:parseInt(null!=(r=e.getAttribute("i"))?r:"0",10)||0,j:parseInt(null!=(s=e.getAttribute("j"))?s:"0",10)||0,d:n,fill:e.getAttribute("fill"),key:e.getAttribute("data:key")||null})});r.querySelectorAll(".apexcharts-treemap-parent-rect").forEach(e=>{const r=t(e),i=e.getAttribute("data:key");r&&i&&s.push({key:i,d:r,fill:e.getAttribute("fill")})})}else{const t=r.querySelectorAll(".apexcharts-sunburst-arc"),e=[];t.forEach(t=>{"true"===t.getAttribute("data:leaf")&&e.push(t)});(e.length?e:Array.from(t)).forEach((t,e)=>{const r=t.getAttribute("d");r&&r.trim()&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill"),key:t.getAttribute("data:key")||null})}),t.forEach(t=>{if("true"===t.getAttribute("data:leaf"))return;const e=t.getAttribute("d"),r=t.getAttribute("data:key");e&&e.trim()&&r&&s.push({key:r,d:e,fill:t.getAttribute("fill")})})}else if("unit"===a)this._readUnitDots(r,n),Array.from(n.keys()).sort((t,e)=>t-e).forEach(t=>{const e=n.get(t),r=e.map(t=>t.x),s=e.map(t=>t.y),a=Math.min(...r)-2,l=Math.min(...s)-2,o=Math.max(...r)+2,h=Math.max(...s)+2;i.push({realIndex:t,j:0,d:`M ${a} ${l} L ${o} ${l} L ${o} ${h} L ${a} ${h} Z`,fill:e[0].fill})});else if("radial"===a)if("radialBar"===t||"gauge"===t){const t=this.w.globals.circleGeometry,e=t?t.cx:this.w.layout.gridWidth/2,s=t?t.cy:this.w.layout.gridHeight/2;r.querySelectorAll(".apexcharts-radial-series .apexcharts-radialbar-area").forEach(t=>{var r;const n=t.parentElement,a=parseInt(null!=(r=null==n?void 0:n.getAttribute("data:realIndex"))?r:"0",10),l=t.getAttribute("d");if(!l)return;const o=parseFloat(t.getAttribute("stroke-width")||"0"),h=o>1&&this._radialArcToFilledSegment(l,o,e,s)||l;i.push({realIndex:a,j:0,d:h,fill:t.getAttribute("stroke")})})}else{r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("d");r&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill")})})}return{marks:i,branches:s,unitDots:n}}_radialArcToFilledSegment(t,e,r,i){const s=t.match(/M\s*(-?[\d.]+)\s+(-?[\d.]+)\s+A\s*(-?[\d.]+)\s+(?:-?[\d.]+)\s+(?:-?[\d.]+)\s+(\d)\s+(\d)\s+(-?[\d.]+)\s+(-?[\d.]+)/);if(!s)return null;const n=parseFloat(s[1]),a=parseFloat(s[2]),l=parseFloat(s[3]),o=parseInt(s[4],10),h=parseInt(s[5],10),c=parseFloat(s[6]),u=parseFloat(s[7]);if(!isFinite(l)||l<=0)return null;const p=e/2,d=l+p,f=Math.max(0,l-p),g=(t,e,s)=>{const n=t-r,a=e-i,l=Math.sqrt(n*n+a*a);if(0===l)return{x:r,y:i};const o=s/l;return{x:r+n*o,y:i+a*o}},y=g(n,a,d),m=g(c,u,d),x=g(n,a,f),b=g(c,u,f),A=h?0:1;return`M ${y.x} ${y.y} A ${d} ${d} 0 ${o} ${h} ${m.x} ${m.y} L ${b.x} ${b.y} A ${f} ${f} 0 ${o} ${A} ${x.x} ${x.y} Z`}buildRingSegmentPath(t,e,r,i,s,n){const a=i/2,l=r+a,o=Math.max(0,r-a),h=(s-90)*Math.PI/180,c=(n-90)*Math.PI/180,u=t+l*Math.cos(h),p=e+l*Math.sin(h),d=t+l*Math.cos(c),f=e+l*Math.sin(c),g=t+o*Math.cos(h),y=e+o*Math.sin(h),m=t+o*Math.cos(c),x=e+o*Math.sin(c),b=n>s?1:0,A=Math.abs(n-s)>180?1:0;return`M ${u} ${p} A ${l} ${l} 0 ${A} ${b} ${d} ${f} L ${m} ${x} A ${o} ${o} 0 ${A} ${1-b} ${g} ${y} Z`}getFromType(){return this._snapshot?this._snapshot.fromType:null}_buildMapping(t,e,r,i,s){const n=new Map,a=P(r),l=t.slice().sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j);if("partition"===a&&s&&s.length){const t=l.filter(t=>t.key);t.length===l.length&&(t.forEach(t=>{n.set(`key:${t.key}`,{d:t.d,fill:t.fill})}),s.forEach(t=>{n.set(`key:${t.key}`,{d:t.d,fill:t.fill})}))}const o="unit"===P(e);if("radial"===a||"unit"===a||"partition"===a)return l.forEach((t,e)=>{n.set(`${o?t.realIndex:e}:0`,{d:t.d,fill:t.fill})}),n;if("bar"===a||"summary"===a){const t=this._targetKeys(a,i);l.forEach((e,r)=>{const i=t[o?e.realIndex:r];i&&n.set(i,{d:e.d,fill:e.fill})})}return n}_targetKeys(t,e){var r;const i=[],s=Array.isArray(e)?e:[];if("radial"===t){const t=1===s.length&&Array.isArray(null==(r=s[0])?void 0:r.data)?s[0].data.length:s.length;for(let e=0;e<t;e++)i.push(`${e}:0`)}else s.forEach((t,e)=>{const r=t&&Array.isArray(t.data)?t.data:[];for(let t=0;t<r.length;t++)i.push(`${e}:${t}`)});return i}isActive(){return null!==this._snapshot}getInitialPathFor(t,e){if(!this._snapshot)return null;const r=this._snapshot.mapping.get(`${t}:${e}`);if(!r)return null;const{k:i,dx:s,dy:n}=this._oldToNew();return 1===i&&0===s&&0===n?r.d:this._translatePathD(r.d,s,n,i)}_oldToNew(){var t,e,r;const i=this._snapshot.oldLayout;return{k:null!=(t=i.scale)?t:1,dx:i.translateX+(null!=(e=i.shiftX)?e:0)-(this.w.layout.translateX||0),dy:i.translateY+(null!=(r=i.shiftY)?r:0)-(this.w.layout.translateY||0)}}_translatePathD(t,e,r,i=1){if(0===e&&0===r&&1===i)return t;const s=u(t),n=t=>t*i+e,a=t=>t*i+r;return s.map(t=>{const e=t[0];return"Z"===e?"Z":"M"===e||"L"===e||"T"===e?`${e} ${n(t[1])} ${a(t[2])}`:"H"===e?`${e} ${n(t[1])}`:"V"===e?`${e} ${a(t[1])}`:"C"===e?`${e} ${n(t[1])} ${a(t[2])} ${n(t[3])} ${a(t[4])} ${n(t[5])} ${a(t[6])}`:"S"===e||"Q"===e?`${e} ${n(t[1])} ${a(t[2])} ${n(t[3])} ${a(t[4])}`:"A"===e?`${e} ${t[1]*i} ${t[2]*i} ${t[3]} ${t[4]} ${t[5]} ${n(t[6])} ${a(t[7])}`:t.join(" ")}).join(" ")}getInitialCenterFor(t){const e=this.getInitialBBoxFor(t);return e?{x:e.x+e.width/2,y:e.y+e.height/2}:null}getInitialPathAt(t){return this.getInitialPathFor(t,0)}getInitialPathForKey(t){return this._snapshot&&t?this.getInitialPathFor("key",t):null}hasKeyedMarks(){if(!this._snapshot)return!1;for(const t of this._snapshot.mapping.keys())if("string"==typeof t&&t.startsWith("key:"))return!0;return!1}getInitialSlotFor(t,e,r){const i=this.getInitialBBoxFor(t);if(!i)return null;const s=i.x+i.width/2,n=i.y+i.height/2;if(!(r>1&&e>=0))return{x:s,y:n};const a=(Math.min(e,r-1)+.5)/r;return i.height>=i.width?{x:s,y:i.y+i.height*(1-a)}:{x:i.x+i.width*a,y:n}}getInitialBBoxFor(t){if(!this._snapshot)return null;const e=this._snapshot.mapping.get(`${t}:0`);if(!e)return null;const r=this._pathBBox(e.d);if(!r)return null;const{k:i,dx:s,dy:n}=this._oldToNew();return{x:r.minX*i+s,y:r.minY*i+n,width:(r.maxX-r.minX)*i,height:(r.maxY-r.minY)*i}}_pathBBox(t){let e=1/0,r=1/0,i=-1/0,s=-1/0,n=0,a=0,l=0,o=0;const h=(t,n)=>{isFinite(t)&&isFinite(n)&&(t<e&&(e=t),t>i&&(i=t),n<r&&(r=n),n>s&&(s=n))};return u(t).forEach(t=>{const e=t[0];if("Z"===e)return n=l,void(a=o);const r=t.length,i="H"===e?t[1]:"V"===e?n:t[r-2],s="H"===e?a:"V"===e?t[1]:t[r-1];if("A"===e){if(t[1]){const e=(n-i)/2,r=(a-s)/2,l=(t[4]===t[5]?-1:1)*Math.sqrt(Math.max(0,t[1]*t[1]/(e*e+r*r)-1)),o=n-e+l*r,c=a-r-l*e,u=Math.hypot(n-o,a-c),p=Math.atan2(a-c,n-o),d=2*Math.PI;let f=Math.atan2(s-c,i-o)-p;t[5]&&f<0?f+=d:!t[5]&&f>0&&(f-=d);for(let t=0;t<d;t+=Math.PI/2){((f>0?t-p:p-t)%d+d)%d<=Math.abs(f)&&h(o+u*Math.cos(t),c+u*Math.sin(t))}}}else if("H"!==e&&"V"!==e)for(let e=1;e+1<r;e+=2)h(t[e],t[e+1]);h(i,s),n=i,a=s,"M"===e&&(l=i,o=s)}),e>i?null:{minX:e,minY:r,maxX:i,maxY:s}}getSpeed(){const t=this.w.config.chart.animations;return t.chartTypeMorph&&t.chartTypeMorph.speed||t.speed||600}applyChromeFade(){var t;if(!this._snapshot||!o.isBrowser())return;this._shown=!0;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||this._snapshot.resume)return;this._snapshot.pieceOut?this._separatePieces():this._snapshot.pieceIn?this._combinePieces():this._mountGhost();const r=this.getSpeed(),i=Array.from(e.querySelectorAll(".apexcharts-xaxis,.apexcharts-yaxis,.apexcharts-grid,.apexcharts-legend,.apexcharts-title-text,.apexcharts-subtitle-text")).filter(t=>t.style),s=(t,e)=>i.forEach(r=>{r.style.opacity=t,null!=e&&(r.style.transition=e)});s("0",`opacity ${r}ms ease-out`);const n=()=>this.w.globals.isDestroyed;h.requestAnimationFrame(()=>n()||s("1")),setTimeout(()=>n()||s("",""),r+80);const a=this._snapshot;setTimeout(()=>{n()||this._snapshot&&this._snapshot!==a||this.cleanup()},r+100)}retire(){const t=this._snapshot;if(!t||!this._shown)return;const e=this._pieceLayer;this.ctx._unitPieces=t.pieceOut&&e;const r=new Map;null==e||e.querySelectorAll("g").forEach(t=>{const e=t.firstChild&&t.getBBox();e&&r.set(t.firstChild.getAttribute("data-key"),{d:`M${e.x} ${e.y}H${e.x+e.width}V${e.y+e.height}H${e.x}Z`})}),this.cleanup(!0),r.size&&(this._collectTargetMarks(t.toType).forEach((t,e)=>{r.has(e)||r.set(e,{d:this._markD(t)})}),this.w.globals.previousPaths=[],this._snapshot=Object.assign(t,{mapping:r,pieceIn:!1,resume:!0,oldLayout:n({},this.w.layout)}),h.requestAnimationFrame(()=>{this._snapshot===t&&(this._shown=!0)}))}cleanup(t){this._snapshot=null,this._shown=!1,t||this._removeGhost(),this._cancelPieces()}}}),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>l.default});
|
|
@@ -15,7 +15,7 @@ var __spreadValues = (a, b) => {
|
|
|
15
15
|
return a;
|
|
16
16
|
};
|
|
17
17
|
/*!
|
|
18
|
-
* ApexCharts v8.
|
|
18
|
+
* ApexCharts v8.3.1
|
|
19
19
|
* (c) 2018-2026 ApexCharts
|
|
20
20
|
*/
|
|
21
21
|
import * as _core from "apexcharts/core";
|
|
@@ -685,7 +685,7 @@ class MorphTypeChange {
|
|
|
685
685
|
const svg = probe.ownerSVGElement;
|
|
686
686
|
if (typeof /** @type {any} */
|
|
687
687
|
probe.isPointInFill !== "function" || !svg || typeof svg.createSVGPoint !== "function") {
|
|
688
|
-
|
|
688
|
+
probe.remove();
|
|
689
689
|
return null;
|
|
690
690
|
}
|
|
691
691
|
const pt = svg.createSVGPoint();
|
|
@@ -696,7 +696,7 @@ class MorphTypeChange {
|
|
|
696
696
|
/** @type {any} */
|
|
697
697
|
probe
|
|
698
698
|
);
|
|
699
|
-
return p.isPointInFill(pt) ||
|
|
699
|
+
return p.isPointInFill(pt) || p.isPointInStroke(pt);
|
|
700
700
|
};
|
|
701
701
|
const SCAN = 48;
|
|
702
702
|
const intervalsAt = (bandLo, bandHi, horizontal) => {
|
|
@@ -785,6 +785,7 @@ class MorphTypeChange {
|
|
|
785
785
|
if (!layer) return this._revealPieceHidden();
|
|
786
786
|
const pieces = [];
|
|
787
787
|
const doc = layer.ownerDocument;
|
|
788
|
+
const staged = doc.createDocumentFragment();
|
|
788
789
|
const sourceFam = familyOf(snap.fromType);
|
|
789
790
|
const shapedSource = sourceFam === "summary" || sourceFam === "radial";
|
|
790
791
|
Array.from(byCluster.keys()).sort((a, b) => a - b).forEach((i) => {
|
|
@@ -824,7 +825,7 @@ class MorphTypeChange {
|
|
|
824
825
|
el.setAttribute("height", String(cell.height));
|
|
825
826
|
el.setAttribute("rx", "0");
|
|
826
827
|
el.setAttribute("fill", String(markFill));
|
|
827
|
-
|
|
828
|
+
staged.appendChild(el);
|
|
828
829
|
pieces.push({
|
|
829
830
|
el,
|
|
830
831
|
from: { x: cell.x, y: cell.y, width: cell.width, height: cell.height, rx: 0 },
|
|
@@ -842,6 +843,7 @@ class MorphTypeChange {
|
|
|
842
843
|
});
|
|
843
844
|
}
|
|
844
845
|
});
|
|
846
|
+
layer.appendChild(staged);
|
|
845
847
|
if (!pieces.length) return this._cancelPieces();
|
|
846
848
|
this._runPieces(pieces, (piece) => {
|
|
847
849
|
reveal(piece.meta.dotEl);
|
|
@@ -895,6 +897,7 @@ class MorphTypeChange {
|
|
|
895
897
|
const layer = this._makePieceLayer();
|
|
896
898
|
if (!layer) return this._revealPieceHidden();
|
|
897
899
|
const doc = layer.ownerDocument;
|
|
900
|
+
const staged = doc.createDocumentFragment();
|
|
898
901
|
const pieces = [];
|
|
899
902
|
const targetFam = familyOf(snap.toType);
|
|
900
903
|
const shapedTarget = targetFam === "summary" || targetFam === "radial";
|
|
@@ -927,7 +930,7 @@ class MorphTypeChange {
|
|
|
927
930
|
const markState = {
|
|
928
931
|
remaining: ordered.length,
|
|
929
932
|
els: target.els,
|
|
930
|
-
g:
|
|
933
|
+
g: staged.appendChild(doc.createElementNS("http://www.w3.org/2000/svg", "g"))
|
|
931
934
|
};
|
|
932
935
|
for (let m = 0; m < ordered.length; m++) {
|
|
933
936
|
const dot = ordered[m];
|
|
@@ -954,6 +957,7 @@ class MorphTypeChange {
|
|
|
954
957
|
});
|
|
955
958
|
}
|
|
956
959
|
}
|
|
960
|
+
layer.appendChild(staged);
|
|
957
961
|
if (!pieces.length) return this._cancelPieces();
|
|
958
962
|
this._runPieces(pieces, (piece) => {
|
|
959
963
|
const state = piece.meta.markState;
|
package/dist/features/morph.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v8.
|
|
2
|
+
* ApexCharts v8.3.1
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
|
-
!function(t){var e="undefined"!=typeof globalThis?globalThis:self,r=e.ApexCharts;if(r&&r.__internals)return t.call(e);if(r)throw new Error("ApexCharts: dist/features/morph.js cannot register: the ApexCharts on this page has no add-on surface (a script before 7.0, or a bundled apexcharts/core class). Load apexcharts.min.js, apexcharts.core.min.js or apexcharts.full.min.js.");if("function"==typeof define&&define.amd)return t.call(e);if("object"==typeof exports&&"undefined"!=typeof module||"undefined"==typeof window||"undefined"==typeof document)throw new Error("ApexCharts: dist/features/morph.js is a script-tag add-on and needs the ApexCharts script on the page. A bundler imports the matching apexcharts/ sub-path instead.");var i={file:"dist/features/morph.js",run:t,done:!1},s=e.__apexcharts_pending_addons__||(e.__apexcharts_pending_addons__=[]);s.push(i),"complete"!==document.readyState&&window.addEventListener("load",function(){if(!i.done){var r=e.ApexCharts;if(r)if(r.__internals){i.done=!0;var a=s.indexOf(i);-1!==a&&s.splice(a,1);try{t.call(e),r.__drainsAddons||e.console.warn("ApexCharts: dist/features/morph.js loaded before the ApexCharts script, which is older than 8.0 and does not pick up add-ons loaded first, so it registered only when the page finished loading. Put its tag after the ApexCharts script.")}catch(t){e.console.error("ApexCharts: dist/features/morph.js could not register with the ApexCharts script on this page: "+(t&&t.message))}}else e.console.error("ApexCharts: dist/features/morph.js cannot register: the ApexCharts on this page has no add-on surface (a script before 7.0, or a bundled apexcharts/core class). Load apexcharts.min.js, apexcharts.core.min.js or apexcharts.full.min.js.");else e.console.warn("ApexCharts: dist/features/morph.js is waiting for the ApexCharts script, which had not loaded when the page finished loading. It registers when an ApexCharts 8.0 or later script loads; if the page has none, add apexcharts.min.js (or apexcharts.core.min.js, or apexcharts.full.min.js).")}})}(function(){var t,e;t=this,e=function(t){"use strict";var e=Object.defineProperty,r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,a=(t,r,i)=>r in t?e(t,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[r]=i,n=(t,e)=>{for(var n in e||(e={}))i.call(e,n)&&a(t,n,e[n]);if(r)for(var n of r(e))s.call(e,n)&&a(t,n,e[n]);return t};const o=globalThis.ApexCharts,l=globalThis.ApexCharts.__internals.__apex_Environment_Environment,h=globalThis.ApexCharts.__internals.__apex_BrowserAPIs_BrowserAPIs,c=globalThis.ApexCharts.__internals;c.__apex_Animations,c.__apex_Animations_computeStagger,c.__apex_Animations_applyAnimationPolicy;const u=c.__apex_Animations_prefersReducedMotion;c.__apex_Animations_applyProgressiveReveal;const p=globalThis.ApexCharts.__internals,d=p.__apex_PathMorphing_parsePath;function f(t,e){if(!(e>0))return[];if(1===e)return[n({},t)];const r=t.width>=t.height,i=r?t.width:t.height,s=r?t.height:t.width,a=s>0?i/s:e;let o=Math.max(1,Math.ceil(Math.sqrt(a*e)));o>e&&(o=e);const l=Math.floor(e/o);let h=e-l*o;const c=[],u=i/o;let p=0;for(let e=0;e<o;e++){const e=l+(h>0?1:0);h>0&&h--;const i=e>0?s/e:0;for(let s=0;s<e;s++)c.push(r?{x:t.x+p,y:t.y+s*i,width:u,height:i}:{x:t.x+s*i,y:t.y+p,width:i,height:u});p+=u}return c}function g(t,e,r){if(!(e>0))return[];const i=t.width>=t.height,s=i?t.width:t.height,a=i?t.height:t.width,n=i?t.y:t.x,o=n+a,l=a>0?s/a:e;let h=Math.max(Math.ceil(Math.sqrt(l*e)),Math.ceil(s/16));h>=1||(h=1),h>e&&(h=e);const c=Math.floor(e/h);let u=e-c*h;const p=[],d=s/h;let f=i?t.x:t.y;for(let t=0;t<h;t++){const t=c+(u>0?1:0);u>0&&u--;const e=[],s=r(f,f+d,i);if(Array.isArray(s))for(let t=0;t<s.length;t++){const r=s[t];if(!r)continue;const i=Math.max(n,Math.min(r[0],r[1])),a=Math.min(o,Math.max(r[0],r[1]));a>i&&e.push([i,a])}e.length||e.push([n,o]);const a=e.reduce((t,e)=>t+(e[1]-e[0]),0),l=e.map(r=>a>0?(r[1]-r[0])/a*t:t/e.length),h=l.map(t=>Math.floor(t));let g=h.reduce((t,e)=>t+e,0);const y=l.map((t,e)=>({i:e,frac:t-Math.floor(t)})).sort((t,e)=>e.frac-t.frac);for(let e=0;g<t;e++,g++)h[y[e%y.length].i]++;for(let t=0;t<e.length;t++){const r=h[t];if(r<=0)continue;const s=e[t][0],a=(e[t][1]-s)/r;for(let t=0;t<r;t++)p.push(i?{x:f,y:s+t*a,width:d,height:a}:{x:s+t*a,y:f,width:a,height:d})}f+=d}return p}function y(t,e,r,i,s,a){let n=s===r?0:Math.round((t-r)/(s-r)*32767),o=a===i?0:Math.round((e-i)/(a-i)*32767),l=0;for(let t=32768;t>=1;t/=2){const e=(n&t)>0?1:0,r=(o&t)>0?1:0;if(l+=t*t*(3*e^r),0===r){1===e&&(n=t-1-n,o=t-1-o);const r=n;n=o,o=r}}return l}function m(t,e){let r=1/0,i=1/0,s=-1/0,a=-1/0;const n=t.map(t=>{const[n,o]=e(t);return n<r&&(r=n),n>s&&(s=n),o<i&&(i=o),o>a&&(a=o),[n,o]});return t.map((t,e)=>({item:t,d:y(n[e][0],n[e][1],r,i,s,a)})).sort((t,e)=>t.d-e.d).map(t=>t.item)}function x(t){if(!t||"string"!=typeof t)return null;const e=t.trim();if("#"===e[0]){const t=e.slice(1);return 3===t.length?[parseInt(t[0]+t[0],16),parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),1]:6===t.length||8===t.length?[parseInt(t.slice(0,2),16),parseInt(t.slice(2,4),16),parseInt(t.slice(4,6),16),8===t.length?parseInt(t.slice(6,8),16)/255:1]:null}const r=e.match(/^rgba?\(([^)]+)\)$/i);if(r){const t=r[1].split(",").map(t=>parseFloat(t));return t.length<3||t.some(t=>!isFinite(t))?null:[t[0],t[1],t[2],t.length>3?t[3]:1]}return null}function _(t,e){const r=x(t),i=x(e);return r&&i?t=>{const e=Math.round(r[0]+(i[0]-r[0])*t),s=Math.round(r[1]+(i[1]-r[1])*t),a=Math.round(r[2]+(i[2]-r[2])*t),n=r[3]+(i[3]-r[3])*t;return n>=1?`rgb(${e},${s},${a})`:`rgba(${e},${s},${a},${n})`}:null}function A(t){return t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2}p.__apex_PathMorphing_morphPaths,p.__apex_PathMorphing_pathBbox,p.__apex_PathMorphing_arrayToPath;const b=new Set(["bar","funnel","pyramid","histogram"]),w=new Set(["pie","donut","polarArea","radialBar","gauge"]),$=new Set(["unit","waffle"]),v=new Set(["treemap","sunburst"]),M=new Set(["boxPlot","violin"]);let S=0;const P=1500,I=t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")};function E(t){return b.has(t)?"bar":w.has(t)?"radial":$.has(t)?"unit":v.has(t)?"partition":M.has(t)?"summary":null}o.registerFeatures({morphTypeChange:class{constructor(t,e){this.w=t,this.ctx=e,this._snapshot=null,this._shown=!1,this._ghost=null,this._pieceLayer=null,this._pieceCancel=null,this._ghostTimer=void 0}canMorphTypes(t,e){if(t===e)return!1;const r=E(t),i=E(e);return!(!r||!i)&&("partition"===r==("partition"===i)||"unit"!==r&&"unit"!==i)}isCompatibleSeriesShape(t,e,r){if(!Array.isArray(r)||0===r.length)return!1;const i=E(t),s=E(e);return"unit"===s?!!r.every(t=>"number"==typeof t)||r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):"partition"===s||("radial"===s?!!r.every(t=>"number"==typeof t)||1===r.length&&r[0]&&"object"==typeof r[0]&&Array.isArray(r[0].data):"bar"===s||"summary"===s?r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):null!==i&&null!==s)}captureBeforeDestroy({fromType:t,toType:e,newSeries:r}){var i;if(this._snapshot=null,this._shown=!1,this._removeGhost(),this._cancelPieces(),!l.isBrowser())return!1;const s=this.w.config.chart.animations;if(!s||!1===s.enabled)return!1;if(s.chartTypeMorph&&!1===s.chartTypeMorph.enabled)return!1;if(s.respectReducedMotion&&u())return!1;if(!this.canMorphTypes(t,e))return!1;if(!this.isCompatibleSeriesShape(t,e,r))return!1;const{marks:a,branches:n,unitDots:o}=this._captureFromDOM(t);if(!a.length)return!1;const h=this._buildMapping(a,t,e,r,n);if(0===h.size)return!1;const c=this.w.globals,p=null==(i=this.w.dom.elGraphical)?void 0:i.node,d=c.layoutTween&&!c.layoutTween.done&&c.layoutTween.graphical===p?c.layoutTween.rect:null,f=c.circleTween,g=f&&!f.done&&(null==p?void 0:p.contains(f.node))?f:null,y=g?g.circle.r/g.target.r:1;this._snapshot={fromType:t,toType:e,mapping:h,oldLayout:{translateX:d?d.x:this.w.layout.translateX||0,translateY:d?d.y:this.w.layout.translateY||0,scale:y,shiftX:g?g.circle.cx-y*g.target.cx:0,shiftY:g?g.circle.cy-y*g.target.cy:0}};const m=E(t),x=E(e),_=this._canProbePaths();if("unit"===x&&("bar"===m||"summary"===m||"radial"===m&&_)){const t=this._countUnitSeries(r);this._snapshot.pieceOut=t>0&&t<=P}else if("unit"===m&&("bar"===x||"summary"===x||"radial"===x&&_&&!/^(radialBar|gauge)$/.test(e))){let t=0;o.forEach(e=>{t+=e.length}),t>0&&t<=P&&(this._snapshot.pieceIn=!0,this._snapshot.sourceDots=o,this._snapshot.keyOrder=this._targetKeys(x,r))}return!this._needsGhost(t,e)||this._snapshot.pieceOut||this._snapshot.pieceIn||this._captureGhost(),this.w.globals.previousPaths=[],!0}_needsGhost(t,e){return"unit"===E(t)||"unit"===E(e)}_captureGhost(){var t,e;const r=null==(t=this.w.dom)?void 0:t.Paper,i=r&&r.node;if(!i||"function"!=typeof i.cloneNode)return;const s=i.cloneNode(!0),a=[".apexcharts-xaxis",".apexcharts-yaxis",".apexcharts-grid",".apexcharts-legend",".apexcharts-title-text",".apexcharts-subtitle-text",".apexcharts-annotations",".apexcharts-zoom-rect",".apexcharts-selection-rect",".apexcharts-xcrosshairs",".apexcharts-ycrosshairs"];if("function"==typeof s.querySelectorAll&&a.forEach(t=>{s.querySelectorAll(t).forEach(t=>{t.remove()})}),"function"==typeof s.querySelectorAll){const t="-ghost"+ ++S,e=new Set;s.querySelectorAll("[id]").forEach(r=>{e.add(r.id),r.id+=t}),s.querySelectorAll("*").forEach(r=>{for(const i of r.attributes){const r=i.value.replace(/(url\(['"]?#|^#)([^'")\s]+)/g,(r,i,s)=>e.has(s)?i+s+t:r);r!==i.value&&(i.value=r)}})}null==(e=s.removeAttribute)||e.call(s,"id"),this._ghost=s}_mountGhost(){var t,e,r;const i=this._ghost;if(!i||!l.isBrowser())return;const s=null==(t=this.w.dom)?void 0:t.elWrap;if(!s||"function"!=typeof s.appendChild)return void(this._ghost=null);const a=i.style;a&&(a.position="absolute",a.left="0",a.top="0",a.background="transparent",a.pointerEvents="none",a.opacity="1"),null==(e=i.setAttribute)||e.call(i,"aria-hidden","true"),null==(r=i.setAttribute)||r.call(i,"class","apexcharts-morph-ghost"),s.appendChild(i);const n=this.getSpeed(),o=Math.max(120,Math.round(.55*n));h.requestAnimationFrame(()=>{a&&(a.transition=`opacity ${o}ms ease-in`,a.opacity="0")}),this._ghostTimer=setTimeout(()=>this._removeGhost(),o+60)}_removeGhost(){clearTimeout(this._ghostTimer);const t=this._ghost;this._ghost=null,null==t||t.remove()}_countUnitSeries(t){if(!Array.isArray(t))return 0;let e=0;for(const r of t){if(!r||"object"!=typeof r||!Array.isArray(r.data))return 0;e+=r.data.length}return e}usesPieceTakeover(){return!(!this._snapshot||!this._snapshot.pieceOut)}claimsTargetMark(t,e){return!!(this._snapshot&&this._snapshot.pieceIn&&this._snapshot.mapping.has(`${t}:${e}`))}_makePieceLayer(){var t,e;const r=null==(t=this.w.dom)?void 0:t.elGraphical,i=r&&r.node;if(!i||"function"!=typeof i.appendChild)return null;const s=h.createElementNS("http://www.w3.org/2000/svg","g");if(!s)return null;s.setAttribute("class","apexcharts-morph-pieces"),s.setAttribute("pointer-events","none");const a=null==(e=this.w.globals)?void 0:e.cuid;return a&&s.setAttribute("clip-path",`url(#gridRectBarMask${a})`),i.appendChild(s),this._pieceLayer=s,s}_revealPieceHidden(){var t;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;e&&"function"==typeof e.querySelectorAll&&e.querySelectorAll("[data-piece-hidden]").forEach(I)}_cancelPieces(){this._pieceCancel&&(this._pieceCancel(),this._pieceCancel=null);const t=this._pieceLayer;this._pieceLayer=null,null==t||t.remove(),this._revealPieceHidden()}_canProbePaths(){if(!l.isBrowser())return!1;const t=h.createElementNS("http://www.w3.org/2000/svg","path");return!!t&&"function"==typeof t.isPointInFill}_makeExtentProber(t,e,r){const i=r.ownerDocument.createElementNS("http://www.w3.org/2000/svg","path");i.setAttribute("d",t),i.setAttribute("fill","#000"),i.setAttribute("stroke","#000"),i.setAttribute("stroke-width","3"),i.setAttribute("visibility","hidden"),r.appendChild(i);const s=i.ownerSVGElement;if("function"!=typeof i.isPointInFill||!s||"function"!=typeof s.createSVGPoint)return r.removeChild(i),null;const a=s.createSVGPoint(),n=(t,e)=>{a.x=t,a.y=e;const r=i;return r.isPointInFill(a)||"function"==typeof r.isPointInStroke&&r.isPointInStroke(a)},o=48;return{intervalsAt:(t,r,i)=>{const s=i?e.y:e.x,a=s+(i?e.height:e.width);if(!(a>s))return null;const l=(t,e)=>i?n(e,t):n(t,e),h=[t+.1*(r-t),(t+r)/2,r-.1*(r-t)],c=(t,e,r)=>{let i=e,s=t;for(let t=0;t<6;t++){const t=(i+s)/2;l(t,r)?s=t:i=t}return(i+s)/2},u=(a-s)/o,p=new Array(49).fill(null);let d=!1;for(const t of h)for(let e=0;e<=o;e++)null===p[e]&&l(s+e*u,t)&&(p[e]=t,d=!0);if(!d)return null;const f=[];let g=-1;for(let t=0;t<=49;t++){const e=t<=o&&null!==p[t];if(e&&g<0&&(g=t),!e&&g>=0){const e=t-1,r=p[g],i=0===g?s:c(s+g*u,s+(g-1)*u,r),n=e===o?a:c(s+e*u,s+(e+1)*u,p[e]);n>i&&f.push([i,n]),g=-1}}return f.length?f:null},dispose:()=>{i.remove()}}}_separatePieces(){var t;const e=this._snapshot,r=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||!r)return this._revealPieceHidden();const i=this._readUnitDots(r,new Map);let s=0;if(i.forEach(t=>{s+=t.length}),0===s||s>P)return this._revealPieceHidden();const a=this._makePieceLayer();if(!a)return this._revealPieceHidden();const n=[],o=a.ownerDocument,l=E(e.fromType),h="summary"===l||"radial"===l;if(Array.from(i.keys()).sort((t,e)=>t-e).forEach(t=>{var r;const s=i.get(t),l=this.getInitialBBoxFor(t),c=e.mapping.get(`${t}:0`);if(!l||!c)return void s.forEach(t=>I(t.el));const u=c.fill&&0!==c.fill.indexOf("url(")?c.fill:(null==(r=this.w.globals.colors)?void 0:r[t])||s[0].fill;let p=null;if(h){const e=this.getInitialPathFor(t,0);e&&(p=this._makeExtentProber(e,l,a))}const d=p?g(l,s.length,p.intervalsAt):f(l,s.length);p&&p.dispose();const y=m(d,t=>[t.x+t.width/2,t.y+t.height/2]),x=m(s,t=>[t.x,t.y]);for(let e=0;e<x.length;e++){const r=y[e],i=x[e],s=o.createElementNS("http://www.w3.org/2000/svg","rect");s.setAttribute("data-i",String(t)),s.setAttribute("data-key",i.el.getAttribute("data-key")),s.setAttribute("x",String(r.x)),s.setAttribute("y",String(r.y)),s.setAttribute("width",String(r.width)),s.setAttribute("height",String(r.height)),s.setAttribute("rx","0"),s.setAttribute("fill",String(u)),a.appendChild(s),n.push({el:s,from:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},to:{x:i.x-i.r,y:i.y-i.r,width:2*i.r,height:2*i.r,rx:i.r},fill:_(u,i.fill),fillEnd:i.fill,delay:0,meta:{dotEl:i.el}})}}),!n.length)return this._cancelPieces();this._runPieces(n,t=>{I(t.meta.dotEl),t.el.remove()})}_readUnitDots(t,e){return t.querySelectorAll(".apexcharts-unit-area").forEach(t=>{var r;const i=parseInt(null!=(r=t.getAttribute("i"))?r:"",10);if(isNaN(i))return;const s=e=>parseFloat(t.getAttribute(e)),a=t.getAttribute("cx"),n=s("width")||0,o=s("height")||0,l=null!=a?parseFloat(a):s("x")+n/2,h=null!=a?s("cy"):s("y")+o/2,c=(null!=a?s("r"):Math.max(n,o)/2)||3;if(!isFinite(l)||!isFinite(h))return;let u=e.get(i);u||e.set(i,u=[]),u.push({el:t,x:l,y:h,r:c,fill:t.getAttribute("fill")})}),e}_combinePieces(){var t,e;const r=this._snapshot,i=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!(r&&r.sourceDots&&r.keyOrder&&i))return this._revealPieceHidden();const s=this._collectTargetMarks(r.toType);if(!s.size)return this._revealPieceHidden();const{dx:a,dy:n}=this._oldToNew(),o=Array.from(r.sourceDots.keys()).sort((t,e)=>t-e),l=this._makePieceLayer();if(!l)return this._revealPieceHidden();const h=l.ownerDocument,c=[],u=E(r.toType),p="summary"===u||"radial"===u;for(let t=0;t<o.length;t++){const i=r.sourceDots.get(o[t]),u=r.keyOrder[o[t]],d=u?s.get(u):null,y=d&&this._markD(d),x=y&&this._pathBBox(y);if(!x||!i||!i.length){d&&d.els.forEach(I);continue}const A={x:x.minX,y:x.minY,width:x.maxX-x.minX,height:x.maxY-x.minY},b=d.fill&&0!==d.fill.indexOf("url(")?d.fill:(null==(e=this.w.globals.colors)?void 0:e[d.realIndex])||i[0].fill,w=p?this._makeExtentProber(y,A,l):null,$=w?g(A,i.length,w.intervalsAt):f(A,i.length);w&&w.dispose();const v=m($,t=>[t.x+t.width/2,t.y+t.height/2]),M=m(i,t=>[t.x,t.y]),S={remaining:M.length,els:d.els,g:l.appendChild(h.createElementNS("http://www.w3.org/2000/svg","g"))};for(let t=0;t<M.length;t++){const e=M[t],r=v[t],i=h.createElementNS("http://www.w3.org/2000/svg","rect"),s=e.x+a-e.r,o=e.y+n-e.r;i.setAttribute("data-key",u),i.setAttribute("x",String(s)),i.setAttribute("y",String(o)),i.setAttribute("width",String(2*e.r)),i.setAttribute("height",String(2*e.r)),i.setAttribute("rx",String(e.r)),i.setAttribute("fill",String(e.fill||b)),S.g.appendChild(i),c.push({el:i,from:{x:s,y:o,width:2*e.r,height:2*e.r,rx:e.r},to:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},fill:_(e.fill,b),fillEnd:String(b),delay:0,meta:{markState:S}})}}if(!c.length)return this._cancelPieces();this._runPieces(c,t=>{const e=t.meta.markState;e.remaining--,0===e.remaining&&(e.els.forEach(I),e.g.remove())})}_markD(t){return t.d||t.els.map(t=>t.getAttribute("pathTo")||t.getAttribute("d")).filter(Boolean).join(" ")}_runPieces(t,e){const r=this.getSpeed(),i=Math.min(300,.35*r),s=Math.max(180,r-i);for(let e=0;e<t.length;e++)t[e].delay=t.length>1?e/(t.length-1)*i:0;this._pieceCancel=function({pieces:t,duration:e,onPieceDone:r,onAllDone:i,alive:s}){let a=!1;const n=Date.now(),o=Math.max(1,e),l=(t,e)=>{const r=t.from,i=t.to,s=t.el;s.setAttribute("x",String(r.x+(i.x-r.x)*e)),s.setAttribute("y",String(r.y+(i.y-r.y)*e)),s.setAttribute("width",String(Math.max(0,r.width+(i.width-r.width)*e))),s.setAttribute("height",String(Math.max(0,r.height+(i.height-r.height)*e))),s.setAttribute("rx",String(Math.max(0,r.rx+(i.rx-r.rx)*e))),t.fill?s.setAttribute("fill",t.fill(e)):e>=1&&t.fillEnd&&s.setAttribute("fill",t.fillEnd)},c=()=>{if(a||s&&!s())return;const e=Date.now()-n;let u=!1;for(let i=0;i<t.length;i++){const s=t[i];if(s._done)continue;const a=(e-s.delay)/o;if(a<1&&(u=!0),a<=0)continue;const n=Math.min(1,a);l(s,A(n)),n>=1&&(s._done=!0,r&&r(s))}u?h.requestAnimationFrame(c):i&&i()};return h.requestAnimationFrame(c),()=>{a=!0}}({pieces:t,duration:s,onPieceDone:e,alive:()=>!this.w.globals.isDestroyed,onAllDone:()=>{this._pieceCancel=null,this._cancelPieces()}})}_collectTargetMarks(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl,i=new Map;if(!r)return i;const s=E(t);if("radial"===s)return r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("data:pathFinal")||t.getAttribute("d");r&&r.trim()&&i.set(`${e}:0`,{realIndex:e,d:r,fill:t.getAttribute("fill"),els:[t]})}),i;const a="summary"===s?`.apexcharts-${t}-series`:".apexcharts-bar-series";return r.querySelectorAll(`${a} .apexcharts-series`).forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10)||0;let s=0;t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach(t=>{var e;const a=t.getAttribute("pathTo")||t.getAttribute("d");if(!a||!a.trim())return;const n=parseInt(null!=(e=t.getAttribute("j"))?e:"",10),o=isNaN(n)?s++:n,l=`${r}:${o}`,h=i.get(l);h?h.els.push(t):i.set(l,{realIndex:r,fill:t.getAttribute("fill"),els:[t]})})}),i}_captureFromDOM(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl;if(!r)return{marks:[],branches:[],unitDots:new Map};const i=[],s=[],a=new Map,n=E(t);if("bar"===n)r.querySelectorAll(".apexcharts-bar-series .apexcharts-series").forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10);t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach((t,e)=>{const s=t.getAttribute("d")||t.getAttribute("pathTo");s&&i.push({realIndex:r,j:e,d:s,fill:t.getAttribute("fill")})})});else if("summary"===n){const e=new Map;r.querySelectorAll(`.apexcharts-${t}-area`).forEach(t=>{var r,i;const s=parseInt(null!=(r=t.getAttribute("j"))?r:"",10);if(isNaN(s))return;const a=t.getAttribute("d")||t.getAttribute("pathTo");if(!a||!a.trim())return;const n="function"==typeof t.closest?t.closest(".apexcharts-series"):null,o=parseInt(null!=(i=null==n?void 0:n.getAttribute("data:realIndex"))?i:"0",10)||0,l=`${o}:${s}`,h=e.get(l);h?h.d+=` ${a}`:e.set(l,{realIndex:o,j:s,d:a,fill:t.getAttribute("fill")})}),Array.from(e.values()).sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j).forEach(t=>i.push(t))}else if("partition"===n)if("treemap"===t){const t=t=>{var e,r,i,s;const a=parseFloat(null!=(e=t.getAttribute("x"))?e:""),n=parseFloat(null!=(r=t.getAttribute("y"))?r:""),o=parseFloat(null!=(i=t.getAttribute("width"))?i:""),l=parseFloat(null!=(s=t.getAttribute("height"))?s:"");return[a,n,o,l].every(t=>isFinite(t))?`M ${a} ${n} L ${a+o} ${n} L ${a+o} ${n+l} L ${a} ${n+l} Z`:null};r.querySelectorAll(".apexcharts-treemap-rect").forEach(e=>{var r,s;const a=t(e);a&&i.push({realIndex:parseInt(null!=(r=e.getAttribute("i"))?r:"0",10)||0,j:parseInt(null!=(s=e.getAttribute("j"))?s:"0",10)||0,d:a,fill:e.getAttribute("fill"),key:e.getAttribute("data:key")||null})}),r.querySelectorAll(".apexcharts-treemap-parent-rect").forEach(e=>{const r=t(e),i=e.getAttribute("data:key");r&&i&&s.push({key:i,d:r,fill:e.getAttribute("fill")})})}else{const t=r.querySelectorAll(".apexcharts-sunburst-arc"),e=[];t.forEach(t=>{"true"===t.getAttribute("data:leaf")&&e.push(t)}),(e.length?e:Array.from(t)).forEach((t,e)=>{const r=t.getAttribute("d");r&&r.trim()&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill"),key:t.getAttribute("data:key")||null})}),t.forEach(t=>{if("true"===t.getAttribute("data:leaf"))return;const e=t.getAttribute("d"),r=t.getAttribute("data:key");e&&e.trim()&&r&&s.push({key:r,d:e,fill:t.getAttribute("fill")})})}else if("unit"===n)this._readUnitDots(r,a),Array.from(a.keys()).sort((t,e)=>t-e).forEach(t=>{const e=a.get(t),r=e.map(t=>t.x),s=e.map(t=>t.y),n=Math.min(...r)-2,o=Math.min(...s)-2,l=Math.max(...r)+2,h=Math.max(...s)+2;i.push({realIndex:t,j:0,d:`M ${n} ${o} L ${l} ${o} L ${l} ${h} L ${n} ${h} Z`,fill:e[0].fill})});else if("radial"===n)if("radialBar"===t||"gauge"===t){const t=this.w.globals.circleGeometry,e=t?t.cx:this.w.layout.gridWidth/2,s=t?t.cy:this.w.layout.gridHeight/2;r.querySelectorAll(".apexcharts-radial-series .apexcharts-radialbar-area").forEach(t=>{var r;const a=t.parentElement,n=parseInt(null!=(r=null==a?void 0:a.getAttribute("data:realIndex"))?r:"0",10),o=t.getAttribute("d");if(!o)return;const l=parseFloat(t.getAttribute("stroke-width")||"0"),h=l>1&&this._radialArcToFilledSegment(o,l,e,s)||o;i.push({realIndex:n,j:0,d:h,fill:t.getAttribute("stroke")})})}else r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("d");r&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill")})});return{marks:i,branches:s,unitDots:a}}_radialArcToFilledSegment(t,e,r,i){const s=t.match(/M\s*(-?[\d.]+)\s+(-?[\d.]+)\s+A\s*(-?[\d.]+)\s+(?:-?[\d.]+)\s+(?:-?[\d.]+)\s+(\d)\s+(\d)\s+(-?[\d.]+)\s+(-?[\d.]+)/);if(!s)return null;const a=parseFloat(s[1]),n=parseFloat(s[2]),o=parseFloat(s[3]),l=parseInt(s[4],10),h=parseInt(s[5],10),c=parseFloat(s[6]),u=parseFloat(s[7]);if(!isFinite(o)||o<=0)return null;const p=e/2,d=o+p,f=Math.max(0,o-p),g=(t,e,s)=>{const a=t-r,n=e-i,o=Math.sqrt(a*a+n*n);if(0===o)return{x:r,y:i};const l=s/o;return{x:r+a*l,y:i+n*l}},y=g(a,n,d),m=g(c,u,d),x=g(a,n,f),_=g(c,u,f),A=h?0:1;return`M ${y.x} ${y.y} A ${d} ${d} 0 ${l} ${h} ${m.x} ${m.y} L ${_.x} ${_.y} A ${f} ${f} 0 ${l} ${A} ${x.x} ${x.y} Z`}buildRingSegmentPath(t,e,r,i,s,a){const n=i/2,o=r+n,l=Math.max(0,r-n),h=(s-90)*Math.PI/180,c=(a-90)*Math.PI/180,u=t+o*Math.cos(h),p=e+o*Math.sin(h),d=t+o*Math.cos(c),f=e+o*Math.sin(c),g=t+l*Math.cos(h),y=e+l*Math.sin(h),m=t+l*Math.cos(c),x=e+l*Math.sin(c),_=a>s?1:0,A=Math.abs(a-s)>180?1:0;return`M ${u} ${p} A ${o} ${o} 0 ${A} ${_} ${d} ${f} L ${m} ${x} A ${l} ${l} 0 ${A} ${1-_} ${g} ${y} Z`}getFromType(){return this._snapshot?this._snapshot.fromType:null}_buildMapping(t,e,r,i,s){const a=new Map,n=E(r),o=t.slice().sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j);if("partition"===n&&s&&s.length){const t=o.filter(t=>t.key);t.length===o.length&&(t.forEach(t=>{a.set(`key:${t.key}`,{d:t.d,fill:t.fill})}),s.forEach(t=>{a.set(`key:${t.key}`,{d:t.d,fill:t.fill})}))}const l="unit"===E(e);if("radial"===n||"unit"===n||"partition"===n)return o.forEach((t,e)=>{a.set(`${l?t.realIndex:e}:0`,{d:t.d,fill:t.fill})}),a;if("bar"===n||"summary"===n){const t=this._targetKeys(n,i);o.forEach((e,r)=>{const i=t[l?e.realIndex:r];i&&a.set(i,{d:e.d,fill:e.fill})})}return a}_targetKeys(t,e){var r;const i=[],s=Array.isArray(e)?e:[];if("radial"===t){const t=1===s.length&&Array.isArray(null==(r=s[0])?void 0:r.data)?s[0].data.length:s.length;for(let e=0;e<t;e++)i.push(`${e}:0`)}else s.forEach((t,e)=>{const r=t&&Array.isArray(t.data)?t.data:[];for(let t=0;t<r.length;t++)i.push(`${e}:${t}`)});return i}isActive(){return null!==this._snapshot}getInitialPathFor(t,e){if(!this._snapshot)return null;const r=this._snapshot.mapping.get(`${t}:${e}`);if(!r)return null;const{k:i,dx:s,dy:a}=this._oldToNew();return 1===i&&0===s&&0===a?r.d:this._translatePathD(r.d,s,a,i)}_oldToNew(){var t,e,r;const i=this._snapshot.oldLayout;return{k:null!=(t=i.scale)?t:1,dx:i.translateX+(null!=(e=i.shiftX)?e:0)-(this.w.layout.translateX||0),dy:i.translateY+(null!=(r=i.shiftY)?r:0)-(this.w.layout.translateY||0)}}_translatePathD(t,e,r,i=1){if(0===e&&0===r&&1===i)return t;const s=d(t),a=t=>t*i+e,n=t=>t*i+r;return s.map(t=>{const e=t[0];return"Z"===e?"Z":"M"===e||"L"===e||"T"===e?`${e} ${a(t[1])} ${n(t[2])}`:"H"===e?`${e} ${a(t[1])}`:"V"===e?`${e} ${n(t[1])}`:"C"===e?`${e} ${a(t[1])} ${n(t[2])} ${a(t[3])} ${n(t[4])} ${a(t[5])} ${n(t[6])}`:"S"===e||"Q"===e?`${e} ${a(t[1])} ${n(t[2])} ${a(t[3])} ${n(t[4])}`:"A"===e?`${e} ${t[1]*i} ${t[2]*i} ${t[3]} ${t[4]} ${t[5]} ${a(t[6])} ${n(t[7])}`:t.join(" ")}).join(" ")}getInitialCenterFor(t){const e=this.getInitialBBoxFor(t);return e?{x:e.x+e.width/2,y:e.y+e.height/2}:null}getInitialPathAt(t){return this.getInitialPathFor(t,0)}getInitialPathForKey(t){return this._snapshot&&t?this.getInitialPathFor("key",t):null}hasKeyedMarks(){if(!this._snapshot)return!1;for(const t of this._snapshot.mapping.keys())if("string"==typeof t&&t.startsWith("key:"))return!0;return!1}getInitialSlotFor(t,e,r){const i=this.getInitialBBoxFor(t);if(!i)return null;const s=i.x+i.width/2,a=i.y+i.height/2;if(!(r>1&&e>=0))return{x:s,y:a};const n=(Math.min(e,r-1)+.5)/r;return i.height>=i.width?{x:s,y:i.y+i.height*(1-n)}:{x:i.x+i.width*n,y:a}}getInitialBBoxFor(t){if(!this._snapshot)return null;const e=this._snapshot.mapping.get(`${t}:0`);if(!e)return null;const r=this._pathBBox(e.d);if(!r)return null;const{k:i,dx:s,dy:a}=this._oldToNew();return{x:r.minX*i+s,y:r.minY*i+a,width:(r.maxX-r.minX)*i,height:(r.maxY-r.minY)*i}}_pathBBox(t){let e=1/0,r=1/0,i=-1/0,s=-1/0,a=0,n=0,o=0,l=0;const h=(t,a)=>{isFinite(t)&&isFinite(a)&&(t<e&&(e=t),t>i&&(i=t),a<r&&(r=a),a>s&&(s=a))};return d(t).forEach(t=>{const e=t[0];if("Z"===e)return a=o,void(n=l);const r=t.length,i="H"===e?t[1]:"V"===e?a:t[r-2],s="H"===e?n:"V"===e?t[1]:t[r-1];if("A"===e){if(t[1]){const e=(a-i)/2,r=(n-s)/2,o=(t[4]===t[5]?-1:1)*Math.sqrt(Math.max(0,t[1]*t[1]/(e*e+r*r)-1)),l=a-e+o*r,c=n-r-o*e,u=Math.hypot(a-l,n-c),p=Math.atan2(n-c,a-l),d=2*Math.PI;let f=Math.atan2(s-c,i-l)-p;t[5]&&f<0?f+=d:!t[5]&&f>0&&(f-=d);for(let t=0;t<d;t+=Math.PI/2)((f>0?t-p:p-t)%d+d)%d<=Math.abs(f)&&h(l+u*Math.cos(t),c+u*Math.sin(t))}}else if("H"!==e&&"V"!==e)for(let e=1;e+1<r;e+=2)h(t[e],t[e+1]);h(i,s),a=i,n=s,"M"===e&&(o=i,l=s)}),e>i?null:{minX:e,minY:r,maxX:i,maxY:s}}getSpeed(){const t=this.w.config.chart.animations;return t.chartTypeMorph&&t.chartTypeMorph.speed||t.speed||600}applyChromeFade(){var t;if(!this._snapshot||!l.isBrowser())return;this._shown=!0;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||this._snapshot.resume)return;this._snapshot.pieceOut?this._separatePieces():this._snapshot.pieceIn?this._combinePieces():this._mountGhost();const r=this.getSpeed(),i=Array.from(e.querySelectorAll(".apexcharts-xaxis,.apexcharts-yaxis,.apexcharts-grid,.apexcharts-legend,.apexcharts-title-text,.apexcharts-subtitle-text")).filter(t=>t.style),s=(t,e)=>i.forEach(r=>{r.style.opacity=t,null!=e&&(r.style.transition=e)});s("0",`opacity ${r}ms ease-out`);const a=()=>this.w.globals.isDestroyed;h.requestAnimationFrame(()=>a()||s("1")),setTimeout(()=>a()||s("",""),r+80);const n=this._snapshot;setTimeout(()=>{a()||this._snapshot&&this._snapshot!==n||this.cleanup()},r+100)}retire(){const t=this._snapshot;if(!t||!this._shown)return;const e=this._pieceLayer;this.ctx._unitPieces=t.pieceOut&&e;const r=new Map;null==e||e.querySelectorAll("g").forEach(t=>{const e=t.firstChild&&t.getBBox();e&&r.set(t.firstChild.getAttribute("data-key"),{d:`M${e.x} ${e.y}H${e.x+e.width}V${e.y+e.height}H${e.x}Z`})}),this.cleanup(!0),r.size&&(this._collectTargetMarks(t.toType).forEach((t,e)=>{r.has(e)||r.set(e,{d:this._markD(t)})}),this.w.globals.previousPaths=[],this._snapshot=Object.assign(t,{mapping:r,pieceIn:!1,resume:!0,oldLayout:n({},this.w.layout)}),h.requestAnimationFrame(()=>{this._snapshot===t&&(this._shown=!0)}))}cleanup(t){this._snapshot=null,this._shown=!1,t||this._removeGhost(),this._cancelPieces()}}}),t.default=o,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})},"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).ApexMorph={})});
|
|
5
|
+
!function(t){var e="undefined"!=typeof globalThis?globalThis:self,r=e.ApexCharts;if(r&&r.__internals)return t.call(e);if(r)throw new Error("ApexCharts: dist/features/morph.js cannot register: the ApexCharts on this page has no add-on surface (a script before 7.0, or a bundled apexcharts/core class). Load apexcharts.min.js, apexcharts.core.min.js or apexcharts.full.min.js.");if("function"==typeof define&&define.amd)return t.call(e);if("object"==typeof exports&&"undefined"!=typeof module||"undefined"==typeof window||"undefined"==typeof document)throw new Error("ApexCharts: dist/features/morph.js is a script-tag add-on and needs the ApexCharts script on the page. A bundler imports the matching apexcharts/ sub-path instead.");var i={file:"dist/features/morph.js",run:t,done:!1},s=e.__apexcharts_pending_addons__||(e.__apexcharts_pending_addons__=[]);s.push(i),"complete"!==document.readyState&&window.addEventListener("load",function(){if(!i.done){var r=e.ApexCharts;if(r)if(r.__internals){i.done=!0;var a=s.indexOf(i);-1!==a&&s.splice(a,1);try{t.call(e),r.__drainsAddons||e.console.warn("ApexCharts: dist/features/morph.js loaded before the ApexCharts script, which is older than 8.0 and does not pick up add-ons loaded first, so it registered only when the page finished loading. Put its tag after the ApexCharts script.")}catch(t){e.console.error("ApexCharts: dist/features/morph.js could not register with the ApexCharts script on this page: "+(t&&t.message))}}else e.console.error("ApexCharts: dist/features/morph.js cannot register: the ApexCharts on this page has no add-on surface (a script before 7.0, or a bundled apexcharts/core class). Load apexcharts.min.js, apexcharts.core.min.js or apexcharts.full.min.js.");else e.console.warn("ApexCharts: dist/features/morph.js is waiting for the ApexCharts script, which had not loaded when the page finished loading. It registers when an ApexCharts 8.0 or later script loads; if the page has none, add apexcharts.min.js (or apexcharts.core.min.js, or apexcharts.full.min.js).")}})}(function(){var t,e;t=this,e=function(t){"use strict";var e=Object.defineProperty,r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,s=Object.prototype.propertyIsEnumerable,a=(t,r,i)=>r in t?e(t,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[r]=i,n=(t,e)=>{for(var n in e||(e={}))i.call(e,n)&&a(t,n,e[n]);if(r)for(var n of r(e))s.call(e,n)&&a(t,n,e[n]);return t};const o=globalThis.ApexCharts,l=globalThis.ApexCharts.__internals.__apex_Environment_Environment,h=globalThis.ApexCharts.__internals.__apex_BrowserAPIs_BrowserAPIs,c=globalThis.ApexCharts.__internals;c.__apex_Animations,c.__apex_Animations_computeStagger,c.__apex_Animations_applyAnimationPolicy;const u=c.__apex_Animations_prefersReducedMotion;c.__apex_Animations_applyProgressiveReveal;const p=globalThis.ApexCharts.__internals,d=p.__apex_PathMorphing_parsePath;function f(t,e){if(!(e>0))return[];if(1===e)return[n({},t)];const r=t.width>=t.height,i=r?t.width:t.height,s=r?t.height:t.width,a=s>0?i/s:e;let o=Math.max(1,Math.ceil(Math.sqrt(a*e)));o>e&&(o=e);const l=Math.floor(e/o);let h=e-l*o;const c=[],u=i/o;let p=0;for(let e=0;e<o;e++){const e=l+(h>0?1:0);h>0&&h--;const i=e>0?s/e:0;for(let s=0;s<e;s++)c.push(r?{x:t.x+p,y:t.y+s*i,width:u,height:i}:{x:t.x+s*i,y:t.y+p,width:i,height:u});p+=u}return c}function g(t,e,r){if(!(e>0))return[];const i=t.width>=t.height,s=i?t.width:t.height,a=i?t.height:t.width,n=i?t.y:t.x,o=n+a,l=a>0?s/a:e;let h=Math.max(Math.ceil(Math.sqrt(l*e)),Math.ceil(s/16));h>=1||(h=1),h>e&&(h=e);const c=Math.floor(e/h);let u=e-c*h;const p=[],d=s/h;let f=i?t.x:t.y;for(let t=0;t<h;t++){const t=c+(u>0?1:0);u>0&&u--;const e=[],s=r(f,f+d,i);if(Array.isArray(s))for(let t=0;t<s.length;t++){const r=s[t];if(!r)continue;const i=Math.max(n,Math.min(r[0],r[1])),a=Math.min(o,Math.max(r[0],r[1]));a>i&&e.push([i,a])}e.length||e.push([n,o]);const a=e.reduce((t,e)=>t+(e[1]-e[0]),0),l=e.map(r=>a>0?(r[1]-r[0])/a*t:t/e.length),h=l.map(t=>Math.floor(t));let g=h.reduce((t,e)=>t+e,0);const y=l.map((t,e)=>({i:e,frac:t-Math.floor(t)})).sort((t,e)=>e.frac-t.frac);for(let e=0;g<t;e++,g++)h[y[e%y.length].i]++;for(let t=0;t<e.length;t++){const r=h[t];if(r<=0)continue;const s=e[t][0],a=(e[t][1]-s)/r;for(let t=0;t<r;t++)p.push(i?{x:f,y:s+t*a,width:d,height:a}:{x:s+t*a,y:f,width:a,height:d})}f+=d}return p}function y(t,e,r,i,s,a){let n=s===r?0:Math.round((t-r)/(s-r)*32767),o=a===i?0:Math.round((e-i)/(a-i)*32767),l=0;for(let t=32768;t>=1;t/=2){const e=(n&t)>0?1:0,r=(o&t)>0?1:0;if(l+=t*t*(3*e^r),0===r){1===e&&(n=t-1-n,o=t-1-o);const r=n;n=o,o=r}}return l}function m(t,e){let r=1/0,i=1/0,s=-1/0,a=-1/0;const n=t.map(t=>{const[n,o]=e(t);return n<r&&(r=n),n>s&&(s=n),o<i&&(i=o),o>a&&(a=o),[n,o]});return t.map((t,e)=>({item:t,d:y(n[e][0],n[e][1],r,i,s,a)})).sort((t,e)=>t.d-e.d).map(t=>t.item)}function x(t){if(!t||"string"!=typeof t)return null;const e=t.trim();if("#"===e[0]){const t=e.slice(1);return 3===t.length?[parseInt(t[0]+t[0],16),parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),1]:6===t.length||8===t.length?[parseInt(t.slice(0,2),16),parseInt(t.slice(2,4),16),parseInt(t.slice(4,6),16),8===t.length?parseInt(t.slice(6,8),16)/255:1]:null}const r=e.match(/^rgba?\(([^)]+)\)$/i);if(r){const t=r[1].split(",").map(t=>parseFloat(t));return t.length<3||t.some(t=>!isFinite(t))?null:[t[0],t[1],t[2],t.length>3?t[3]:1]}return null}function _(t,e){const r=x(t),i=x(e);return r&&i?t=>{const e=Math.round(r[0]+(i[0]-r[0])*t),s=Math.round(r[1]+(i[1]-r[1])*t),a=Math.round(r[2]+(i[2]-r[2])*t),n=r[3]+(i[3]-r[3])*t;return n>=1?`rgb(${e},${s},${a})`:`rgba(${e},${s},${a},${n})`}:null}function A(t){return t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2}p.__apex_PathMorphing_morphPaths,p.__apex_PathMorphing_pathBbox,p.__apex_PathMorphing_arrayToPath;const b=new Set(["bar","funnel","pyramid","histogram"]),w=new Set(["pie","donut","polarArea","radialBar","gauge"]),$=new Set(["unit","waffle"]),v=new Set(["treemap","sunburst"]),M=new Set(["boxPlot","violin"]);let S=0;const P=1500,I=t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")};function E(t){return b.has(t)?"bar":w.has(t)?"radial":$.has(t)?"unit":v.has(t)?"partition":M.has(t)?"summary":null}o.registerFeatures({morphTypeChange:class{constructor(t,e){this.w=t,this.ctx=e,this._snapshot=null,this._shown=!1,this._ghost=null,this._pieceLayer=null,this._pieceCancel=null,this._ghostTimer=void 0}canMorphTypes(t,e){if(t===e)return!1;const r=E(t),i=E(e);return!(!r||!i)&&("partition"===r==("partition"===i)||"unit"!==r&&"unit"!==i)}isCompatibleSeriesShape(t,e,r){if(!Array.isArray(r)||0===r.length)return!1;const i=E(t),s=E(e);return"unit"===s?!!r.every(t=>"number"==typeof t)||r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):"partition"===s||("radial"===s?!!r.every(t=>"number"==typeof t)||1===r.length&&r[0]&&"object"==typeof r[0]&&Array.isArray(r[0].data):"bar"===s||"summary"===s?r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):null!==i&&null!==s)}captureBeforeDestroy({fromType:t,toType:e,newSeries:r}){var i;if(this._snapshot=null,this._shown=!1,this._removeGhost(),this._cancelPieces(),!l.isBrowser())return!1;const s=this.w.config.chart.animations;if(!s||!1===s.enabled)return!1;if(s.chartTypeMorph&&!1===s.chartTypeMorph.enabled)return!1;if(s.respectReducedMotion&&u())return!1;if(!this.canMorphTypes(t,e))return!1;if(!this.isCompatibleSeriesShape(t,e,r))return!1;const{marks:a,branches:n,unitDots:o}=this._captureFromDOM(t);if(!a.length)return!1;const h=this._buildMapping(a,t,e,r,n);if(0===h.size)return!1;const c=this.w.globals,p=null==(i=this.w.dom.elGraphical)?void 0:i.node,d=c.layoutTween&&!c.layoutTween.done&&c.layoutTween.graphical===p?c.layoutTween.rect:null,f=c.circleTween,g=f&&!f.done&&(null==p?void 0:p.contains(f.node))?f:null,y=g?g.circle.r/g.target.r:1;this._snapshot={fromType:t,toType:e,mapping:h,oldLayout:{translateX:d?d.x:this.w.layout.translateX||0,translateY:d?d.y:this.w.layout.translateY||0,scale:y,shiftX:g?g.circle.cx-y*g.target.cx:0,shiftY:g?g.circle.cy-y*g.target.cy:0}};const m=E(t),x=E(e),_=this._canProbePaths();if("unit"===x&&("bar"===m||"summary"===m||"radial"===m&&_)){const t=this._countUnitSeries(r);this._snapshot.pieceOut=t>0&&t<=P}else if("unit"===m&&("bar"===x||"summary"===x||"radial"===x&&_&&!/^(radialBar|gauge)$/.test(e))){let t=0;o.forEach(e=>{t+=e.length}),t>0&&t<=P&&(this._snapshot.pieceIn=!0,this._snapshot.sourceDots=o,this._snapshot.keyOrder=this._targetKeys(x,r))}return!this._needsGhost(t,e)||this._snapshot.pieceOut||this._snapshot.pieceIn||this._captureGhost(),this.w.globals.previousPaths=[],!0}_needsGhost(t,e){return"unit"===E(t)||"unit"===E(e)}_captureGhost(){var t,e;const r=null==(t=this.w.dom)?void 0:t.Paper,i=r&&r.node;if(!i||"function"!=typeof i.cloneNode)return;const s=i.cloneNode(!0),a=[".apexcharts-xaxis",".apexcharts-yaxis",".apexcharts-grid",".apexcharts-legend",".apexcharts-title-text",".apexcharts-subtitle-text",".apexcharts-annotations",".apexcharts-zoom-rect",".apexcharts-selection-rect",".apexcharts-xcrosshairs",".apexcharts-ycrosshairs"];if("function"==typeof s.querySelectorAll&&a.forEach(t=>{s.querySelectorAll(t).forEach(t=>{t.remove()})}),"function"==typeof s.querySelectorAll){const t="-ghost"+ ++S,e=new Set;s.querySelectorAll("[id]").forEach(r=>{e.add(r.id),r.id+=t}),s.querySelectorAll("*").forEach(r=>{for(const i of r.attributes){const r=i.value.replace(/(url\(['"]?#|^#)([^'")\s]+)/g,(r,i,s)=>e.has(s)?i+s+t:r);r!==i.value&&(i.value=r)}})}null==(e=s.removeAttribute)||e.call(s,"id"),this._ghost=s}_mountGhost(){var t,e,r;const i=this._ghost;if(!i||!l.isBrowser())return;const s=null==(t=this.w.dom)?void 0:t.elWrap;if(!s||"function"!=typeof s.appendChild)return void(this._ghost=null);const a=i.style;a&&(a.position="absolute",a.left="0",a.top="0",a.background="transparent",a.pointerEvents="none",a.opacity="1"),null==(e=i.setAttribute)||e.call(i,"aria-hidden","true"),null==(r=i.setAttribute)||r.call(i,"class","apexcharts-morph-ghost"),s.appendChild(i);const n=this.getSpeed(),o=Math.max(120,Math.round(.55*n));h.requestAnimationFrame(()=>{a&&(a.transition=`opacity ${o}ms ease-in`,a.opacity="0")}),this._ghostTimer=setTimeout(()=>this._removeGhost(),o+60)}_removeGhost(){clearTimeout(this._ghostTimer);const t=this._ghost;this._ghost=null,null==t||t.remove()}_countUnitSeries(t){if(!Array.isArray(t))return 0;let e=0;for(const r of t){if(!r||"object"!=typeof r||!Array.isArray(r.data))return 0;e+=r.data.length}return e}usesPieceTakeover(){return!(!this._snapshot||!this._snapshot.pieceOut)}claimsTargetMark(t,e){return!!(this._snapshot&&this._snapshot.pieceIn&&this._snapshot.mapping.has(`${t}:${e}`))}_makePieceLayer(){var t,e;const r=null==(t=this.w.dom)?void 0:t.elGraphical,i=r&&r.node;if(!i||"function"!=typeof i.appendChild)return null;const s=h.createElementNS("http://www.w3.org/2000/svg","g");if(!s)return null;s.setAttribute("class","apexcharts-morph-pieces"),s.setAttribute("pointer-events","none");const a=null==(e=this.w.globals)?void 0:e.cuid;return a&&s.setAttribute("clip-path",`url(#gridRectBarMask${a})`),i.appendChild(s),this._pieceLayer=s,s}_revealPieceHidden(){var t;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;e&&"function"==typeof e.querySelectorAll&&e.querySelectorAll("[data-piece-hidden]").forEach(I)}_cancelPieces(){this._pieceCancel&&(this._pieceCancel(),this._pieceCancel=null);const t=this._pieceLayer;this._pieceLayer=null,null==t||t.remove(),this._revealPieceHidden()}_canProbePaths(){if(!l.isBrowser())return!1;const t=h.createElementNS("http://www.w3.org/2000/svg","path");return!!t&&"function"==typeof t.isPointInFill}_makeExtentProber(t,e,r){const i=r.ownerDocument.createElementNS("http://www.w3.org/2000/svg","path");i.setAttribute("d",t),i.setAttribute("fill","#000"),i.setAttribute("stroke","#000"),i.setAttribute("stroke-width","3"),i.setAttribute("visibility","hidden"),r.appendChild(i);const s=i.ownerSVGElement;if("function"!=typeof i.isPointInFill||!s||"function"!=typeof s.createSVGPoint)return i.remove(),null;const a=s.createSVGPoint(),n=(t,e)=>{a.x=t,a.y=e;const r=i;return r.isPointInFill(a)||r.isPointInStroke(a)},o=48;return{intervalsAt:(t,r,i)=>{const s=i?e.y:e.x,a=s+(i?e.height:e.width);if(!(a>s))return null;const l=(t,e)=>i?n(e,t):n(t,e),h=[t+.1*(r-t),(t+r)/2,r-.1*(r-t)],c=(t,e,r)=>{let i=e,s=t;for(let t=0;t<6;t++){const t=(i+s)/2;l(t,r)?s=t:i=t}return(i+s)/2},u=(a-s)/o,p=new Array(49).fill(null);let d=!1;for(const t of h)for(let e=0;e<=o;e++)null===p[e]&&l(s+e*u,t)&&(p[e]=t,d=!0);if(!d)return null;const f=[];let g=-1;for(let t=0;t<=49;t++){const e=t<=o&&null!==p[t];if(e&&g<0&&(g=t),!e&&g>=0){const e=t-1,r=p[g],i=0===g?s:c(s+g*u,s+(g-1)*u,r),n=e===o?a:c(s+e*u,s+(e+1)*u,p[e]);n>i&&f.push([i,n]),g=-1}}return f.length?f:null},dispose:()=>{i.remove()}}}_separatePieces(){var t;const e=this._snapshot,r=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||!r)return this._revealPieceHidden();const i=this._readUnitDots(r,new Map);let s=0;if(i.forEach(t=>{s+=t.length}),0===s||s>P)return this._revealPieceHidden();const a=this._makePieceLayer();if(!a)return this._revealPieceHidden();const n=[],o=a.ownerDocument,l=o.createDocumentFragment(),h=E(e.fromType),c="summary"===h||"radial"===h;if(Array.from(i.keys()).sort((t,e)=>t-e).forEach(t=>{var r;const s=i.get(t),h=this.getInitialBBoxFor(t),u=e.mapping.get(`${t}:0`);if(!h||!u)return void s.forEach(t=>I(t.el));const p=u.fill&&0!==u.fill.indexOf("url(")?u.fill:(null==(r=this.w.globals.colors)?void 0:r[t])||s[0].fill;let d=null;if(c){const e=this.getInitialPathFor(t,0);e&&(d=this._makeExtentProber(e,h,a))}const y=d?g(h,s.length,d.intervalsAt):f(h,s.length);d&&d.dispose();const x=m(y,t=>[t.x+t.width/2,t.y+t.height/2]),A=m(s,t=>[t.x,t.y]);for(let e=0;e<A.length;e++){const r=x[e],i=A[e],s=o.createElementNS("http://www.w3.org/2000/svg","rect");s.setAttribute("data-i",String(t)),s.setAttribute("data-key",i.el.getAttribute("data-key")),s.setAttribute("x",String(r.x)),s.setAttribute("y",String(r.y)),s.setAttribute("width",String(r.width)),s.setAttribute("height",String(r.height)),s.setAttribute("rx","0"),s.setAttribute("fill",String(p)),l.appendChild(s),n.push({el:s,from:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},to:{x:i.x-i.r,y:i.y-i.r,width:2*i.r,height:2*i.r,rx:i.r},fill:_(p,i.fill),fillEnd:i.fill,delay:0,meta:{dotEl:i.el}})}}),a.appendChild(l),!n.length)return this._cancelPieces();this._runPieces(n,t=>{I(t.meta.dotEl),t.el.remove()})}_readUnitDots(t,e){return t.querySelectorAll(".apexcharts-unit-area").forEach(t=>{var r;const i=parseInt(null!=(r=t.getAttribute("i"))?r:"",10);if(isNaN(i))return;const s=e=>parseFloat(t.getAttribute(e)),a=t.getAttribute("cx"),n=s("width")||0,o=s("height")||0,l=null!=a?parseFloat(a):s("x")+n/2,h=null!=a?s("cy"):s("y")+o/2,c=(null!=a?s("r"):Math.max(n,o)/2)||3;if(!isFinite(l)||!isFinite(h))return;let u=e.get(i);u||e.set(i,u=[]),u.push({el:t,x:l,y:h,r:c,fill:t.getAttribute("fill")})}),e}_combinePieces(){var t,e;const r=this._snapshot,i=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!(r&&r.sourceDots&&r.keyOrder&&i))return this._revealPieceHidden();const s=this._collectTargetMarks(r.toType);if(!s.size)return this._revealPieceHidden();const{dx:a,dy:n}=this._oldToNew(),o=Array.from(r.sourceDots.keys()).sort((t,e)=>t-e),l=this._makePieceLayer();if(!l)return this._revealPieceHidden();const h=l.ownerDocument,c=h.createDocumentFragment(),u=[],p=E(r.toType),d="summary"===p||"radial"===p;for(let t=0;t<o.length;t++){const i=r.sourceDots.get(o[t]),p=r.keyOrder[o[t]],y=p?s.get(p):null,x=y&&this._markD(y),A=x&&this._pathBBox(x);if(!A||!i||!i.length){y&&y.els.forEach(I);continue}const b={x:A.minX,y:A.minY,width:A.maxX-A.minX,height:A.maxY-A.minY},w=y.fill&&0!==y.fill.indexOf("url(")?y.fill:(null==(e=this.w.globals.colors)?void 0:e[y.realIndex])||i[0].fill,$=d?this._makeExtentProber(x,b,l):null,v=$?g(b,i.length,$.intervalsAt):f(b,i.length);$&&$.dispose();const M=m(v,t=>[t.x+t.width/2,t.y+t.height/2]),S=m(i,t=>[t.x,t.y]),P={remaining:S.length,els:y.els,g:c.appendChild(h.createElementNS("http://www.w3.org/2000/svg","g"))};for(let t=0;t<S.length;t++){const e=S[t],r=M[t],i=h.createElementNS("http://www.w3.org/2000/svg","rect"),s=e.x+a-e.r,o=e.y+n-e.r;i.setAttribute("data-key",p),i.setAttribute("x",String(s)),i.setAttribute("y",String(o)),i.setAttribute("width",String(2*e.r)),i.setAttribute("height",String(2*e.r)),i.setAttribute("rx",String(e.r)),i.setAttribute("fill",String(e.fill||w)),P.g.appendChild(i),u.push({el:i,from:{x:s,y:o,width:2*e.r,height:2*e.r,rx:e.r},to:{x:r.x,y:r.y,width:r.width,height:r.height,rx:0},fill:_(e.fill,w),fillEnd:String(w),delay:0,meta:{markState:P}})}}if(l.appendChild(c),!u.length)return this._cancelPieces();this._runPieces(u,t=>{const e=t.meta.markState;e.remaining--,0===e.remaining&&(e.els.forEach(I),e.g.remove())})}_markD(t){return t.d||t.els.map(t=>t.getAttribute("pathTo")||t.getAttribute("d")).filter(Boolean).join(" ")}_runPieces(t,e){const r=this.getSpeed(),i=Math.min(300,.35*r),s=Math.max(180,r-i);for(let e=0;e<t.length;e++)t[e].delay=t.length>1?e/(t.length-1)*i:0;this._pieceCancel=function({pieces:t,duration:e,onPieceDone:r,onAllDone:i,alive:s}){let a=!1;const n=Date.now(),o=Math.max(1,e),l=(t,e)=>{const r=t.from,i=t.to,s=t.el;s.setAttribute("x",String(r.x+(i.x-r.x)*e)),s.setAttribute("y",String(r.y+(i.y-r.y)*e)),s.setAttribute("width",String(Math.max(0,r.width+(i.width-r.width)*e))),s.setAttribute("height",String(Math.max(0,r.height+(i.height-r.height)*e))),s.setAttribute("rx",String(Math.max(0,r.rx+(i.rx-r.rx)*e))),t.fill?s.setAttribute("fill",t.fill(e)):e>=1&&t.fillEnd&&s.setAttribute("fill",t.fillEnd)},c=()=>{if(a||s&&!s())return;const e=Date.now()-n;let u=!1;for(let i=0;i<t.length;i++){const s=t[i];if(s._done)continue;const a=(e-s.delay)/o;if(a<1&&(u=!0),a<=0)continue;const n=Math.min(1,a);l(s,A(n)),n>=1&&(s._done=!0,r&&r(s))}u?h.requestAnimationFrame(c):i&&i()};return h.requestAnimationFrame(c),()=>{a=!0}}({pieces:t,duration:s,onPieceDone:e,alive:()=>!this.w.globals.isDestroyed,onAllDone:()=>{this._pieceCancel=null,this._cancelPieces()}})}_collectTargetMarks(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl,i=new Map;if(!r)return i;const s=E(t);if("radial"===s)return r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("data:pathFinal")||t.getAttribute("d");r&&r.trim()&&i.set(`${e}:0`,{realIndex:e,d:r,fill:t.getAttribute("fill"),els:[t]})}),i;const a="summary"===s?`.apexcharts-${t}-series`:".apexcharts-bar-series";return r.querySelectorAll(`${a} .apexcharts-series`).forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10)||0;let s=0;t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach(t=>{var e;const a=t.getAttribute("pathTo")||t.getAttribute("d");if(!a||!a.trim())return;const n=parseInt(null!=(e=t.getAttribute("j"))?e:"",10),o=isNaN(n)?s++:n,l=`${r}:${o}`,h=i.get(l);h?h.els.push(t):i.set(l,{realIndex:r,fill:t.getAttribute("fill"),els:[t]})})}),i}_captureFromDOM(t){var e;const r=null==(e=this.w.globals.dom)?void 0:e.baseEl;if(!r)return{marks:[],branches:[],unitDots:new Map};const i=[],s=[],a=new Map,n=E(t);if("bar"===n)r.querySelectorAll(".apexcharts-bar-series .apexcharts-series").forEach(t=>{var e;const r=parseInt(null!=(e=t.getAttribute("data:realIndex"))?e:"0",10);t.querySelectorAll("path[pathTo]:not(.apexcharts-highlight-part)").forEach((t,e)=>{const s=t.getAttribute("d")||t.getAttribute("pathTo");s&&i.push({realIndex:r,j:e,d:s,fill:t.getAttribute("fill")})})});else if("summary"===n){const e=new Map;r.querySelectorAll(`.apexcharts-${t}-area`).forEach(t=>{var r,i;const s=parseInt(null!=(r=t.getAttribute("j"))?r:"",10);if(isNaN(s))return;const a=t.getAttribute("d")||t.getAttribute("pathTo");if(!a||!a.trim())return;const n="function"==typeof t.closest?t.closest(".apexcharts-series"):null,o=parseInt(null!=(i=null==n?void 0:n.getAttribute("data:realIndex"))?i:"0",10)||0,l=`${o}:${s}`,h=e.get(l);h?h.d+=` ${a}`:e.set(l,{realIndex:o,j:s,d:a,fill:t.getAttribute("fill")})}),Array.from(e.values()).sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j).forEach(t=>i.push(t))}else if("partition"===n)if("treemap"===t){const t=t=>{var e,r,i,s;const a=parseFloat(null!=(e=t.getAttribute("x"))?e:""),n=parseFloat(null!=(r=t.getAttribute("y"))?r:""),o=parseFloat(null!=(i=t.getAttribute("width"))?i:""),l=parseFloat(null!=(s=t.getAttribute("height"))?s:"");return[a,n,o,l].every(t=>isFinite(t))?`M ${a} ${n} L ${a+o} ${n} L ${a+o} ${n+l} L ${a} ${n+l} Z`:null};r.querySelectorAll(".apexcharts-treemap-rect").forEach(e=>{var r,s;const a=t(e);a&&i.push({realIndex:parseInt(null!=(r=e.getAttribute("i"))?r:"0",10)||0,j:parseInt(null!=(s=e.getAttribute("j"))?s:"0",10)||0,d:a,fill:e.getAttribute("fill"),key:e.getAttribute("data:key")||null})}),r.querySelectorAll(".apexcharts-treemap-parent-rect").forEach(e=>{const r=t(e),i=e.getAttribute("data:key");r&&i&&s.push({key:i,d:r,fill:e.getAttribute("fill")})})}else{const t=r.querySelectorAll(".apexcharts-sunburst-arc"),e=[];t.forEach(t=>{"true"===t.getAttribute("data:leaf")&&e.push(t)}),(e.length?e:Array.from(t)).forEach((t,e)=>{const r=t.getAttribute("d");r&&r.trim()&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill"),key:t.getAttribute("data:key")||null})}),t.forEach(t=>{if("true"===t.getAttribute("data:leaf"))return;const e=t.getAttribute("d"),r=t.getAttribute("data:key");e&&e.trim()&&r&&s.push({key:r,d:e,fill:t.getAttribute("fill")})})}else if("unit"===n)this._readUnitDots(r,a),Array.from(a.keys()).sort((t,e)=>t-e).forEach(t=>{const e=a.get(t),r=e.map(t=>t.x),s=e.map(t=>t.y),n=Math.min(...r)-2,o=Math.min(...s)-2,l=Math.max(...r)+2,h=Math.max(...s)+2;i.push({realIndex:t,j:0,d:`M ${n} ${o} L ${l} ${o} L ${l} ${h} L ${n} ${h} Z`,fill:e[0].fill})});else if("radial"===n)if("radialBar"===t||"gauge"===t){const t=this.w.globals.circleGeometry,e=t?t.cx:this.w.layout.gridWidth/2,s=t?t.cy:this.w.layout.gridHeight/2;r.querySelectorAll(".apexcharts-radial-series .apexcharts-radialbar-area").forEach(t=>{var r;const a=t.parentElement,n=parseInt(null!=(r=null==a?void 0:a.getAttribute("data:realIndex"))?r:"0",10),o=t.getAttribute("d");if(!o)return;const l=parseFloat(t.getAttribute("stroke-width")||"0"),h=l>1&&this._radialArcToFilledSegment(o,l,e,s)||o;i.push({realIndex:n,j:0,d:h,fill:t.getAttribute("stroke")})})}else r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("d");r&&i.push({realIndex:e,j:0,d:r,fill:t.getAttribute("fill")})});return{marks:i,branches:s,unitDots:a}}_radialArcToFilledSegment(t,e,r,i){const s=t.match(/M\s*(-?[\d.]+)\s+(-?[\d.]+)\s+A\s*(-?[\d.]+)\s+(?:-?[\d.]+)\s+(?:-?[\d.]+)\s+(\d)\s+(\d)\s+(-?[\d.]+)\s+(-?[\d.]+)/);if(!s)return null;const a=parseFloat(s[1]),n=parseFloat(s[2]),o=parseFloat(s[3]),l=parseInt(s[4],10),h=parseInt(s[5],10),c=parseFloat(s[6]),u=parseFloat(s[7]);if(!isFinite(o)||o<=0)return null;const p=e/2,d=o+p,f=Math.max(0,o-p),g=(t,e,s)=>{const a=t-r,n=e-i,o=Math.sqrt(a*a+n*n);if(0===o)return{x:r,y:i};const l=s/o;return{x:r+a*l,y:i+n*l}},y=g(a,n,d),m=g(c,u,d),x=g(a,n,f),_=g(c,u,f),A=h?0:1;return`M ${y.x} ${y.y} A ${d} ${d} 0 ${l} ${h} ${m.x} ${m.y} L ${_.x} ${_.y} A ${f} ${f} 0 ${l} ${A} ${x.x} ${x.y} Z`}buildRingSegmentPath(t,e,r,i,s,a){const n=i/2,o=r+n,l=Math.max(0,r-n),h=(s-90)*Math.PI/180,c=(a-90)*Math.PI/180,u=t+o*Math.cos(h),p=e+o*Math.sin(h),d=t+o*Math.cos(c),f=e+o*Math.sin(c),g=t+l*Math.cos(h),y=e+l*Math.sin(h),m=t+l*Math.cos(c),x=e+l*Math.sin(c),_=a>s?1:0,A=Math.abs(a-s)>180?1:0;return`M ${u} ${p} A ${o} ${o} 0 ${A} ${_} ${d} ${f} L ${m} ${x} A ${l} ${l} 0 ${A} ${1-_} ${g} ${y} Z`}getFromType(){return this._snapshot?this._snapshot.fromType:null}_buildMapping(t,e,r,i,s){const a=new Map,n=E(r),o=t.slice().sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j);if("partition"===n&&s&&s.length){const t=o.filter(t=>t.key);t.length===o.length&&(t.forEach(t=>{a.set(`key:${t.key}`,{d:t.d,fill:t.fill})}),s.forEach(t=>{a.set(`key:${t.key}`,{d:t.d,fill:t.fill})}))}const l="unit"===E(e);if("radial"===n||"unit"===n||"partition"===n)return o.forEach((t,e)=>{a.set(`${l?t.realIndex:e}:0`,{d:t.d,fill:t.fill})}),a;if("bar"===n||"summary"===n){const t=this._targetKeys(n,i);o.forEach((e,r)=>{const i=t[l?e.realIndex:r];i&&a.set(i,{d:e.d,fill:e.fill})})}return a}_targetKeys(t,e){var r;const i=[],s=Array.isArray(e)?e:[];if("radial"===t){const t=1===s.length&&Array.isArray(null==(r=s[0])?void 0:r.data)?s[0].data.length:s.length;for(let e=0;e<t;e++)i.push(`${e}:0`)}else s.forEach((t,e)=>{const r=t&&Array.isArray(t.data)?t.data:[];for(let t=0;t<r.length;t++)i.push(`${e}:${t}`)});return i}isActive(){return null!==this._snapshot}getInitialPathFor(t,e){if(!this._snapshot)return null;const r=this._snapshot.mapping.get(`${t}:${e}`);if(!r)return null;const{k:i,dx:s,dy:a}=this._oldToNew();return 1===i&&0===s&&0===a?r.d:this._translatePathD(r.d,s,a,i)}_oldToNew(){var t,e,r;const i=this._snapshot.oldLayout;return{k:null!=(t=i.scale)?t:1,dx:i.translateX+(null!=(e=i.shiftX)?e:0)-(this.w.layout.translateX||0),dy:i.translateY+(null!=(r=i.shiftY)?r:0)-(this.w.layout.translateY||0)}}_translatePathD(t,e,r,i=1){if(0===e&&0===r&&1===i)return t;const s=d(t),a=t=>t*i+e,n=t=>t*i+r;return s.map(t=>{const e=t[0];return"Z"===e?"Z":"M"===e||"L"===e||"T"===e?`${e} ${a(t[1])} ${n(t[2])}`:"H"===e?`${e} ${a(t[1])}`:"V"===e?`${e} ${n(t[1])}`:"C"===e?`${e} ${a(t[1])} ${n(t[2])} ${a(t[3])} ${n(t[4])} ${a(t[5])} ${n(t[6])}`:"S"===e||"Q"===e?`${e} ${a(t[1])} ${n(t[2])} ${a(t[3])} ${n(t[4])}`:"A"===e?`${e} ${t[1]*i} ${t[2]*i} ${t[3]} ${t[4]} ${t[5]} ${a(t[6])} ${n(t[7])}`:t.join(" ")}).join(" ")}getInitialCenterFor(t){const e=this.getInitialBBoxFor(t);return e?{x:e.x+e.width/2,y:e.y+e.height/2}:null}getInitialPathAt(t){return this.getInitialPathFor(t,0)}getInitialPathForKey(t){return this._snapshot&&t?this.getInitialPathFor("key",t):null}hasKeyedMarks(){if(!this._snapshot)return!1;for(const t of this._snapshot.mapping.keys())if("string"==typeof t&&t.startsWith("key:"))return!0;return!1}getInitialSlotFor(t,e,r){const i=this.getInitialBBoxFor(t);if(!i)return null;const s=i.x+i.width/2,a=i.y+i.height/2;if(!(r>1&&e>=0))return{x:s,y:a};const n=(Math.min(e,r-1)+.5)/r;return i.height>=i.width?{x:s,y:i.y+i.height*(1-n)}:{x:i.x+i.width*n,y:a}}getInitialBBoxFor(t){if(!this._snapshot)return null;const e=this._snapshot.mapping.get(`${t}:0`);if(!e)return null;const r=this._pathBBox(e.d);if(!r)return null;const{k:i,dx:s,dy:a}=this._oldToNew();return{x:r.minX*i+s,y:r.minY*i+a,width:(r.maxX-r.minX)*i,height:(r.maxY-r.minY)*i}}_pathBBox(t){let e=1/0,r=1/0,i=-1/0,s=-1/0,a=0,n=0,o=0,l=0;const h=(t,a)=>{isFinite(t)&&isFinite(a)&&(t<e&&(e=t),t>i&&(i=t),a<r&&(r=a),a>s&&(s=a))};return d(t).forEach(t=>{const e=t[0];if("Z"===e)return a=o,void(n=l);const r=t.length,i="H"===e?t[1]:"V"===e?a:t[r-2],s="H"===e?n:"V"===e?t[1]:t[r-1];if("A"===e){if(t[1]){const e=(a-i)/2,r=(n-s)/2,o=(t[4]===t[5]?-1:1)*Math.sqrt(Math.max(0,t[1]*t[1]/(e*e+r*r)-1)),l=a-e+o*r,c=n-r-o*e,u=Math.hypot(a-l,n-c),p=Math.atan2(n-c,a-l),d=2*Math.PI;let f=Math.atan2(s-c,i-l)-p;t[5]&&f<0?f+=d:!t[5]&&f>0&&(f-=d);for(let t=0;t<d;t+=Math.PI/2)((f>0?t-p:p-t)%d+d)%d<=Math.abs(f)&&h(l+u*Math.cos(t),c+u*Math.sin(t))}}else if("H"!==e&&"V"!==e)for(let e=1;e+1<r;e+=2)h(t[e],t[e+1]);h(i,s),a=i,n=s,"M"===e&&(o=i,l=s)}),e>i?null:{minX:e,minY:r,maxX:i,maxY:s}}getSpeed(){const t=this.w.config.chart.animations;return t.chartTypeMorph&&t.chartTypeMorph.speed||t.speed||600}applyChromeFade(){var t;if(!this._snapshot||!l.isBrowser())return;this._shown=!0;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e||this._snapshot.resume)return;this._snapshot.pieceOut?this._separatePieces():this._snapshot.pieceIn?this._combinePieces():this._mountGhost();const r=this.getSpeed(),i=Array.from(e.querySelectorAll(".apexcharts-xaxis,.apexcharts-yaxis,.apexcharts-grid,.apexcharts-legend,.apexcharts-title-text,.apexcharts-subtitle-text")).filter(t=>t.style),s=(t,e)=>i.forEach(r=>{r.style.opacity=t,null!=e&&(r.style.transition=e)});s("0",`opacity ${r}ms ease-out`);const a=()=>this.w.globals.isDestroyed;h.requestAnimationFrame(()=>a()||s("1")),setTimeout(()=>a()||s("",""),r+80);const n=this._snapshot;setTimeout(()=>{a()||this._snapshot&&this._snapshot!==n||this.cleanup()},r+100)}retire(){const t=this._snapshot;if(!t||!this._shown)return;const e=this._pieceLayer;this.ctx._unitPieces=t.pieceOut&&e;const r=new Map;null==e||e.querySelectorAll("g").forEach(t=>{const e=t.firstChild&&t.getBBox();e&&r.set(t.firstChild.getAttribute("data-key"),{d:`M${e.x} ${e.y}H${e.x+e.width}V${e.y+e.height}H${e.x}Z`})}),this.cleanup(!0),r.size&&(this._collectTargetMarks(t.toType).forEach((t,e)=>{r.has(e)||r.set(e,{d:this._markD(t)})}),this.w.globals.previousPaths=[],this._snapshot=Object.assign(t,{mapping:r,pieceIn:!1,resume:!0,oldLayout:n({},this.w.layout)}),h.requestAnimationFrame(()=>{this._snapshot===t&&(this._shown=!0)}))}cleanup(t){this._snapshot=null,this._shown=!1,t||this._removeGhost(),this._cancelPieces()}}}),t.default=o,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})},"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).ApexMorph={})});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v8.
|
|
2
|
+
* ApexCharts v8.3.1
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
|
-
"use strict";var e=Object.defineProperty,t=Object.defineProperties,n=Object.getOwnPropertyDescriptors,i=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable,a=(t,n,i)=>n in t?e(t,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[n]=i,o=(e,t)=>{for(var n in t||(t={}))s.call(t,n)&&a(e,n,t[n]);if(i)for(var n of i(t))r.call(t,n)&&a(e,n,t[n]);return e},l=(e,i)=>t(e,n(i));Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function c(e){if(e&&e.__esModule)return e;const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const n in e)if("default"!==n){const i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,i.get?i:{enumerable:!0,get:()=>e[n]})}return t.default=e,Object.freeze(t)}const d=c(require("apexcharts/core")),u=d.__apex_Utils,h=d.__apex_Environment_Environment;function p(e,t){const n=null!=e,i=null!=t;return n||i?{min:n?e:null,max:i?t:null}:null}function f(e){return Array.isArray(e)?e.map(e=>Array.isArray(e)?e.slice():e):[]}function m(e,t){return"function"==typeof e&&t?e===t.addXaxisAnnotation?"xaxis":e===t.addYaxisAnnotation?"yaxis":e===t.addPointAnnotation?"point":null:null}function y(e,t){const n=e.config.annotations?u.clone(e.config.annotations):null,i=[],s=e.globals.memory&&e.globals.memory.methodsToExec||[];for(const e of s){if(!e||"addAnnotation"!==e.label)continue;const n=m(e.method,t);n&&i.push({kind:n,params:u.clone(e.params)})}return{static:n,dynamic:i}}function g(e){const t=e&&e.measure;if(!t||"function"!=typeof t.getPins)return null;const n=t.getPins();return Array.isArray(n)&&n.length?{pins:n}:null}function v(e,t,{animate:n=!0,mergeOptions:i}={}){var s,r;if(!e||!t)return;"number"==typeof t.v&&t.v>1&&console.warn(`[apexcharts] ViewState v${t.v} is newer than this build understands (v1); applying best-effort.`),e.clearAnnotations();const a=i?u.clone(i):{},o=t.window&&t.window.xaxis;a.xaxis=Object.assign({},a.xaxis,o?{min:null!=(s=o.min)?s:void 0,max:null!=(r=o.max)?r:void 0}:{min:void 0,max:void 0});const l=t.window&&t.window.yaxis;if(Array.isArray(l)&&(a.yaxis=l.map(e=>{var t,n;return e?{min:null!=(t=e.min)?t:void 0,max:null!=(n=e.max)?n:void 0}:{}})),t.theme){const e={};null!=t.theme.mode&&(e.mode=t.theme.mode),null!=t.theme.palette&&(e.palette=t.theme.palette),Object.keys(e).length&&(a.theme=Object.assign({},a.theme,e))}t.annotations&&t.annotations.static&&(a.annotations=u.clone(t.annotations.static)),e.updateOptions(a,!1,n,!1,!1),function(e,t){if(!e||!t)return;const n=e.w;n.interact.zoomed=!!t.zoomed,function(e,t,n){const i=e.w;if(null==t&&null==n)return;const s=i.globals.seriesNames||[],r=new Set([...t||[],...n||[]]),a=new Set([...i.globals.collapsedSeriesIndices||[],...i.globals.ancillaryCollapsedSeriesIndices||[]]);for(let t=0;t<s.length;t++){const n=s[t];if(null==n)continue;const i=r.has(t),o=a.has(t);i&&!o?e.hideSeries(n):!i&&o&&e.showSeries(n)}}(e,t.collapsed,t.ancillaryCollapsed),t.annotations&&Array.isArray(t.annotations.dynamic)&&t.annotations.dynamic.forEach(t=>{const n=function(e){switch(e){case"xaxis":return"addXaxisAnnotation";case"yaxis":return"addYaxisAnnotation";case"point":return"addPointAnnotation";default:return null}}(t.kind);n&&"function"==typeof e[n]&&e[n](t.params,!0)});(function(e,t){Array.isArray(t)&&(e.w.interact.selectedDataPoints=f(t))})(e,t.selectedDataPoints),t.locale&&t.locale!==n.config.chart.defaultLocale&&e.setLocale(t.locale);e.measure&&"function"==typeof e.measure.setPins&&e.measure.setPins(t.measure&&t.measure.pins||[])}(e,t)}const b=globalThis.console;function w(e,...t){b.error(e,...t)}function x(e){b.warn(e)}const A="APEX-",_=new Date("2027-07-31T00:00:00Z"),S="__apex_license_v1__";function O(){const e=globalThis;let t=e[S];return t||(t={key:null,listeners:new Set,result:null},e[S]=t),t}const k=class{static get licenseKey(){return O().key}static set licenseKey(e){O().key=e}static get listeners(){return O().listeners}static get validationResult(){return O().result}static set validationResult(e){O().result=e}static getKey(){return this.licenseKey}static getLicenseStatus(){return this.licenseKey?(this.validationResult=this.validateKey(this.licenseKey),this.validationResult):{expired:!1,signatureVerified:!1,valid:!1}}static isKeyValid(e){return!!e&&this.validateKey(e).valid}static isLicenseValid(){return this.getLicenseStatus().valid}static onChange(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}static setLicense(e){var t,n;if(!e)return this.licenseKey=null,void this.publish({expired:!1,signatureVerified:!1,valid:!1});const i=this.validateKey(e);i.valid||e===this.licenseKey||!(null==(n=this.validationResult)?void 0:n.valid)?(this.licenseKey=e,this.publish(i),i.valid||w(`[Apex] ${i.message}`)):x(`[Apex] Ignoring license key: ${null!=(t=i.message)?t:"it is not valid"} A valid license is already active on this page.`)}static validateKey(e){const t=this.parseKey(e),n=this.validateStructure(e,t);if(!n.valid||!(null==t?void 0:t.signature))return n;const i=this.verdicts.get(e);return!1===i?{data:t.data,expired:!1,message:"Invalid license key. The license signature does not verify.",signatureVerified:!0,valid:!1}:(void 0===i&&this.verifySignature(e,t,n),l(o({},n),{signatureVerified:!0===i}))}static _resetSignatureState(){this.verdicts.clear(),this.verifying.clear(),this.warnedUnverifiable=!1,this.epoch++}static base64ToBytes(e){const t=e.replace(/-/g,"+").replace(/_/g,"/"),n=t.padEnd(4*Math.ceil(t.length/4),"="),i=globalThis.atob;if("function"!=typeof i)throw new Error("no base64 decoder available");const s=i(n),r=new Uint8Array(s.length);for(let e=0;e<s.length;e++)r[e]=s.charCodeAt(e);return r}static canonicalPayload(e){const t=e.domains&&e.domains.length>0?e.domains.join(","):"";return`v1|${e.issueDate}|${e.expiryDate}|${e.plan}|${t}`}static notify(e){for(const t of this.listeners)try{t(e)}catch(e){}}static parseKey(e){if("string"!=typeof e||!e.startsWith(A))return null;const t=e.slice(5);if(!t)return null;try{const e=(new TextDecoder).decode(this.base64ToBytes(t)),n=JSON.parse(e);return n.issueDate&&n.expiryDate&&n.plan?{data:{domains:Array.isArray(n.domains)?n.domains:void 0,expiryDate:n.expiryDate,issueDate:n.issueDate,plan:n.plan,valid:!0},signature:"string"==typeof n.sig&&n.sig?n.sig:null}:null}catch(e){return null}}static publish(e){this.validationResult=e,this.notify(e)}static validateStructure(e,t){const n=e=>({expired:!1,message:e,signatureVerified:!1,valid:!1});if("string"!=typeof e||!e.startsWith(A))return n('Invalid license key format. License key must start with "APEX-".');if(!t)return n("Invalid license key. Unable to decode license data.");const{data:i,signature:s}=t;if(!s&&new Date>=_)return n("This license key is in the old unsigned format, which is no longer accepted. Please request a replacement key.");if(new Date(i.expiryDate)<new Date)return{data:i,expired:!0,message:`License expired on ${i.expiryDate}. Please renew your license.`,signatureVerified:!1,valid:!1};if(i.domains&&i.domains.length>0){const e="undefined"==typeof location?"":location.hostname;if(!i.domains.some(t=>e===t||e.endsWith(`.${t}`)))return{data:i,expired:!1,message:`License is not valid for this domain (${e}). Allowed domains: ${i.domains.join(", ")}.`,signatureVerified:!1,valid:!1}}return{data:i,expired:!1,signatureVerified:!1,valid:!0}}static verifySignature(e,t,n){return i=this,s=null,r=function*(){var i;if(this.verifying.has(e)||this.verdicts.has(e))return;this.verifying.add(e);const s=this.epoch,r=null==(i=globalThis.crypto)?void 0:i.subtle;if(!r||0===this.publicKeysSpki.length)return this.verifying.delete(e),void(this.warnedUnverifiable||(this.warnedUnverifiable=!0,x(r?"[Apex] No license signing key is configured in this build, so license signatures cannot be verified.":"[Apex] Web Crypto is unavailable (a secure context is required), so the license signature cannot be verified.")));const a=(new TextEncoder).encode(this.canonicalPayload(t.data));let c=!1;for(const e of this.publicKeysSpki){try{const n=yield r.importKey("spki",this.base64ToBytes(e),{name:"ECDSA",namedCurve:"P-256"},!1,["verify"]);c=yield r.verify({hash:"SHA-256",name:"ECDSA"},n,this.base64ToBytes(t.signature),a)}catch(e){c=!1}if(c)break}if(this.verifying.delete(e),this.epoch!==s)return;if(this.verdicts.set(e,c),c){const t=l(o({},n),{signatureVerified:!0});return void(this.licenseKey===e?this.publish(t):this.notify(t))}const d="Invalid license key. The license signature does not verify.",u={data:t.data,expired:!1,message:d,signatureVerified:!0,valid:!1};this.licenseKey===e?this.publish(u):this.notify(u),w(`[Apex] ${d}`)},new Promise((e,t)=>{var n=e=>{try{o(r.next(e))}catch(e){t(e)}},a=e=>{try{o(r.throw(e))}catch(e){t(e)}},o=t=>t.done?e(t.value):Promise.resolve(t.value).then(n,a);o((r=r.apply(i,s)).next())});var i,s,r}};k.publicKeysSpki=["MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEQIaK9UMD6n0oR/FIy8QdL0uSzKMQlf1BB+tOrji4/WuHsyRNxeDhVykoSsNURozMi1xhmqWvBH1L//xIfugTPA=="],k.verdicts=new Map,k.verifying=new Set,k.warnedUnverifiable=!1,k.epoch=0;let T=k;const R=class{static applyStyles(e){Object.assign(e.style,this.CRITICAL_STYLES,{backgroundImage:this.createWatermarkPattern(),backgroundRepeat:"repeat"})}static node(e){return e?e.querySelector(`[${this.WATERMARK_ATTR}]`):null}static add(e,t){return e&&"undefined"!=typeof document?(this.setManaged(e,t),this.paint(e)):null}static exists(e){return!!this.node(e)}static remove(e,t){e&&(this.setManaged(e,t),this.erase(e))}static untrack(e){this.managed.delete(e)}static createWatermarkPattern(){const e=this.WATERMARK_TEXT;return`url("data:image/svg+xml,${encodeURIComponent(`\n <svg xmlns="http://www.w3.org/2000/svg" width="300" height="200">\n <text\n x="50%"\n y="50%"\n dominant-baseline="middle"\n text-anchor="middle"\n font-family="-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Arial, sans-serif"\n font-size="18"\n font-weight="600"\n fill="rgba(134, 134, 134, 0.1)"\n transform="rotate(-35, 100, 60)"\n >${e}</text>\n </svg>\n `.trim())}")`}static erase(e){var t;null==(t=this.node(e))||t.remove()}static paint(e){let t=this.node(e);return t||(t=document.createElement("div"),t.setAttribute(this.WATERMARK_ATTR,""),e.appendChild(t)),this.applyStyles(t),"function"==typeof getComputedStyle&&"static"===getComputedStyle(e).position&&(e.style.position="relative"),t}static reconcile(){const e=T.isLicenseValid();for(const t of this.managed)t.isConnected?e?this.erase(t):this.paint(t):this.managed.delete(t)}static setManaged(e,t){!1!==(null==t?void 0:t.manage)?this.track(e):this.managed.delete(e)}static track(e){this.managed.add(e),this.subscribed||(this.subscribed=!0,T.onChange(()=>{this.reconcile()}))}};R.WATERMARK_ATTR="data-apexcharts-watermark",R.WATERMARK_TEXT="APEXCHARTS",R.ATTR="data-apexcharts-watermark",R.CRITICAL_STYLES={bottom:"0",display:"block",left:"0",msUserSelect:"none",opacity:"1",pointerEvents:"none",position:"absolute",right:"0",top:"0",userSelect:"none",visibility:"visible",webkitUserSelect:"none",zIndex:"10000"},R.managed=new Set,R.subscribed=!1;let D=R;const K="https://apexcharts.com/pricing",P="__apexcharts_license_enforcer_v1__";globalThis[P]||(globalThis[P]={perspectivesTokenDecoded:!1,enforced:new Set});const C=globalThis[P],E=C.enforced;function $(){C.perspectivesTokenDecoded=!0,W()}const I=new Set(["premium","enterprise"]);function L(e,t){const n=D.add(t,{manage:!1});if(!n||"undefined"==typeof MutationObserver)return;if(e._wmNodeObserver&&e._wmObservedNode===n)return;e._wmNodeObserver&&e._wmNodeObserver.disconnect();const i=new MutationObserver(()=>{const e=D.node(t);e&&(i.disconnect(),D.applyStyles(e),i.takeRecords(),i.observe(e,{attributes:!0,attributeFilter:["style"]}))});i.observe(n,{attributes:!0,attributeFilter:["style"]}),e._wmNodeObserver=i,e._wmObservedNode=n}function j(e,t){e._wmWrapObserver&&(e._wmWrapObserver.disconnect(),e._wmWrapObserver=null),e._wmNodeObserver&&(e._wmNodeObserver.disconnect(),e._wmNodeObserver=null),e._wmObservedNode=null,e._wmObservedWrap=null;const n=t||e.w&&e.w.dom&&e.w.dom.elWrap;n&&D.remove(n,{manage:!1})}function M(e,t){try{if(!h.isBrowser())return;if(e&&e.globals&&e.globals.isDestroyed)return void E.delete(t);const n=e&&e.dom&&e.dom.elWrap;if(!n)return;const i=function(e,t){var n;const i=e&&e.config&&e.config.chart||{},s=[];"unit"===i.type&&s.push("unit"),"raincloud"===i.requestedType&&s.push("raincloud"),t.trellis&&"function"==typeof t.trellis.isActive&&t.trellis.isActive()&&s.push("trellis"),t.storyboard&&t.storyboard._used&&s.push("storyboard");const r=i.link;return t.linkedViews&&r&&(!0===r.enabled||"function"==typeof r.dimension)&&s.push("link"),t.ink&&i.ink&&!0===i.ink.enabled&&s.push("ink"),t.measure&&i.measure&&!0===i.measure.enabled&&s.push("measure"),t.contextMenu&&i.contextMenu&&!0===i.contextMenu.enabled&&s.push("context-menu"),t.perspectives&&(t.perspectives._used||C.perspectivesTokenDecoded)&&s.push("perspectives"),t.history&&i.history&&!0===i.history.enabled&&s.push("history"),(null==(n=t._highlightFilter)?void 0:n.isActive())&&s.push("highlight-filter"),s}(e,t);if(0===i.length)return E.delete(t),void j(t,n);E.add(t);const s=function(e){const t=e&&e.config&&e.config.chart&&e.config.chart.license;if(t)return t;const n=T.getKey();if(n)return n;const i=h.getApex();return i&&i.license?i.license:null}(e);if(function(e){if(!e)return!1;const t=T.validateKey(e);if(!t.valid)return!1;const n=t.data&&t.data.plan;return"string"==typeof n&&I.has(n.toLowerCase())}(s))return void j(t,n);!function(e,t){if(L(e,t),"undefined"==typeof MutationObserver)return;if(e._wmWrapObserver&&e._wmObservedWrap===t)return;e._wmWrapObserver&&e._wmWrapObserver.disconnect();const n=new MutationObserver(()=>{D.node(t)||L(e,t)});n.observe(t,{childList:!0}),e._wmWrapObserver=n,e._wmObservedWrap=t}(t,n),function(e,t,n){if(e._premiumLicenseNotified)return;e._premiumLicenseNotified=!0;const i=n.length>1;if(!t)return void console.warn(`[ApexCharts] Premium feature${i?"s":""} in use (${n.join(", ")}) without a license. Running in trial mode with a watermark. Get a license: ${K}`);const s=T.validateKey(t);if(s.valid){const e=s.data&&s.data.plan||"current";return void console.warn(`[ApexCharts] Premium feature${i?"s":""} in use (${n.join(", ")}) require a Premium or Enterprise license; the ${e} plan does not include ${i?"them":"it"}. Running in trial mode with a watermark. Upgrade: ${K}`)}t!==T.getKey()&&console.error(`[Apex] ${s.message}`)}(t,s,i)}catch(e){}}function W(){if(!h.isBrowser())return;const e=new Set,t=h.getApex(),n=t&&t._chartInstances;Array.isArray(n)&&n.forEach(t=>{const n=t&&t.chart;n&&n.w&&!n.w.globals.isDestroyed&&(e.add(n),M(n.w,n))}),Array.from(E).forEach(t=>{const n=t&&t.w,i=n&&n.dom&&n.dom.elWrap;n&&!n.globals.isDestroyed&&i&&!1!==i.isConnected?e.has(t)||M(n,t):E.delete(t)})}T.onChange(W);const U="apex";function N(e){return function(e){if("undefined"!=typeof Buffer)return Buffer.from(e,"utf-8").toString("base64");const t=(new TextEncoder).encode(e);let n="";for(let e=0;e<t.length;e++)n+=String.fromCharCode(t[e]);return btoa(n)}(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function B(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");for(;t.length%4;)t+="=";return function(e){if("undefined"!=typeof Buffer)return Buffer.from(e,"base64").toString("utf-8");const t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return(new TextDecoder).decode(n)}(t)}class V{constructor(e,t){this.w=e,this.ctx=t,this._saved=[],this._counter=0,this._used=!1}capture(){const e={v:1,view:function(e,t){var n,i;const s=e.config.xaxis||{},r=(Array.isArray(e.config.yaxis)?e.config.yaxis:e.config.yaxis?[e.config.yaxis]:[]).map(e=>p(e&&e.min,e&&e.max)),a=r.some(e=>null!==e),o=e.config.theme,l=t&&t.drilldown;return{v:1,window:{xaxis:p(s.min,s.max),yaxis:a?r:null},zoomed:!!e.interact.zoomed,collapsed:(e.globals.collapsedSeriesIndices||[]).slice(),ancillaryCollapsed:(e.globals.ancillaryCollapsedSeriesIndices||[]).slice(),selectedDataPoints:f(e.interact.selectedDataPoints),theme:o?{mode:null!=(n=o.mode)?n:null,palette:null!=(i=o.palette)?i:null}:null,locale:e.config.chart&&e.config.chart.defaultLocale||null,annotations:y(e,t),drill:l&&l.depth>0?{path:l.path.slice()}:null,measure:g(t)}}(this.w,this.ctx)},t=this._serializableDelta();return t&&Object.keys(t).length&&(e.options=t),e}_serializableDelta(){const e=this.w.config,t=e.chart&&e.chart.perspectives&&e.chart.perspectives.serializeOptions||["theme","xaxis","yaxis","title","subtitle"],n={};return t.forEach(t=>{if(void 0!==e[t]){const i=function(e){try{return JSON.parse(JSON.stringify(e))}catch(e){return}}(e[t]);void 0!==i&&(n[t]=i)}}),n}encode(e){const t=e||this.capture();return N(JSON.stringify(t))}decode(e){return V.decode(e)}toURL(){if(!h.isBrowser())return"";const e=this.encode(this.capture()),t=new URL(window.location.href);return t.hash=`${U}=${e}`,t.toString()}apply(e,t={}){const n="string"==typeof e?V.decode(e):e;if(!n||!n.view)return;this._used=!0,M(this.w,this.ctx);const i=void 0===t.animate||t.animate,s=u.extend(n.options?u.clone(n.options):{},t.mergeOptions||{}),r=Object.keys(s).length?s:void 0;(this.w.config.chart.group?this.ctx.getSyncedCharts():[this.ctx]).forEach(e=>{v(e,n.view,{animate:i,mergeOptions:r})})}save(e){const t="perspective-"+ ++this._counter;return this._saved.push({id:t,name:e||t,token:this.capture()}),this._used=!0,M(this.w,this.ctx),t}list(){return this._saved.map(e=>({id:e.id,name:e.name,token:e.token}))}delete(e){const t=this._saved.findIndex(t=>t.id===e);t>-1&&this._saved.splice(t,1)}teardown(){this._saved=[],this._counter=0}static decode(e){if("string"!=typeof e||!e)return null;try{const t=JSON.parse(B(e));return t&&"object"==typeof t?1!==t.v?(console.warn(`apexcharts: unsupported perspective version ${t.v} (expected 1).`),null):t:null}catch(e){return console.warn("apexcharts: failed to decode perspective token.",e),null}}static fromURL(e){try{const t=e||(h.isBrowser()?window.location.href:"");if(!t)return null;const n=new URL(t).hash.replace(/^#/,"");if(!n)return null;const i=n.split("&").map(e=>e.split("=")).find(e=>e[0]===U);return i&&null!=i[1]?V.decode(decodeURIComponent(i[1])):null}catch(e){return null}}}d.default.registerFeatures({perspectives:V,perspectivesStatics:{decode:e=>($(),V.decode(e)),fromURL:e=>($(),V.fromURL(e))}}),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>d.default});
|
|
5
|
+
"use strict";var e=Object.defineProperty,t=Object.defineProperties,n=Object.getOwnPropertyDescriptors,i=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable,a=(t,n,i)=>n in t?e(t,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[n]=i,o=(e,t)=>{for(var n in t||(t={}))s.call(t,n)&&a(e,n,t[n]);if(i)for(var n of i(t))r.call(t,n)&&a(e,n,t[n]);return e},l=(e,i)=>t(e,n(i));Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function c(e){if(e&&e.__esModule)return e;const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const n in e)if("default"!==n){const i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,i.get?i:{enumerable:!0,get:()=>e[n]})}return t.default=e,Object.freeze(t)}const d=c(require("apexcharts/core")),u=d.__apex_Utils,h=d.__apex_Environment_Environment;function p(e,t){const n=null!=e,i=null!=t;return n||i?{min:n?e:null,max:i?t:null}:null}function f(e){return Array.isArray(e)?e.map(e=>Array.isArray(e)?e.slice():e):[]}function m(e,t){return"function"==typeof e&&t?e===t.addXaxisAnnotation?"xaxis":e===t.addYaxisAnnotation?"yaxis":e===t.addPointAnnotation?"point":null:null}function y(e,t){const n=e.config.annotations?u.clone(e.config.annotations):null,i=[],s=e.globals.memory&&e.globals.memory.methodsToExec||[];for(const e of s){if(!e||"addAnnotation"!==e.label)continue;const n=m(e.method,t);n&&i.push({kind:n,params:u.clone(e.params)})}return{static:n,dynamic:i}}function g(e){const t=e&&e.measure;if(!t||"function"!=typeof t.getPins)return null;const n=t.getPins();return Array.isArray(n)&&n.length?{pins:n}:null}function v(e,t,{animate:n=!0,mergeOptions:i}={}){var s,r;if(!e||!t)return;"number"==typeof t.v&&t.v>1&&console.warn(`[apexcharts] ViewState v${t.v} is newer than this build understands (v1); applying best-effort.`),e.clearAnnotations();const a=i?u.clone(i):{},o=t.window&&t.window.xaxis;a.xaxis=Object.assign({},a.xaxis,o?{min:null!=(s=o.min)?s:void 0,max:null!=(r=o.max)?r:void 0}:{min:void 0,max:void 0});const l=t.window&&t.window.yaxis;if(Array.isArray(l)&&(a.yaxis=l.map(e=>{var t,n;return e?{min:null!=(t=e.min)?t:void 0,max:null!=(n=e.max)?n:void 0}:{}})),t.theme){const e={};null!=t.theme.mode&&(e.mode=t.theme.mode),null!=t.theme.palette&&(e.palette=t.theme.palette),Object.keys(e).length&&(a.theme=Object.assign({},a.theme,e))}t.annotations&&t.annotations.static&&(a.annotations=u.clone(t.annotations.static)),e.updateOptions(a,!1,n,!1,!1),function(e,t){if(!e||!t)return;const n=e.w;n.interact.zoomed=!!t.zoomed,function(e,t,n){const i=e.w;if(null==t&&null==n)return;const s=i.globals.seriesNames||[],r=new Set([...t||[],...n||[]]),a=new Set([...i.globals.collapsedSeriesIndices||[],...i.globals.ancillaryCollapsedSeriesIndices||[]]);for(let t=0;t<s.length;t++){const n=s[t];if(null==n)continue;const i=r.has(t),o=a.has(t);i&&!o?e.hideSeries(n):!i&&o&&e.showSeries(n)}}(e,t.collapsed,t.ancillaryCollapsed),t.annotations&&Array.isArray(t.annotations.dynamic)&&t.annotations.dynamic.forEach(t=>{const n=function(e){switch(e){case"xaxis":return"addXaxisAnnotation";case"yaxis":return"addYaxisAnnotation";case"point":return"addPointAnnotation";default:return null}}(t.kind);n&&"function"==typeof e[n]&&e[n](t.params,!0)});(function(e,t){Array.isArray(t)&&(e.w.interact.selectedDataPoints=f(t))})(e,t.selectedDataPoints),t.locale&&t.locale!==n.config.chart.defaultLocale&&e.setLocale(t.locale);e.measure&&"function"==typeof e.measure.setPins&&e.measure.setPins(t.measure&&t.measure.pins||[])}(e,t)}const b=globalThis.console;function w(e,...t){b.error(e,...t)}function x(e){b.warn(e)}const _="APEX-",A=new Date("2027-07-31T00:00:00Z"),S="__apex_license_v1__";function O(){const e=globalThis;let t=e[S];return t||(t={key:null,listeners:new Set,result:null},e[S]=t),t}const k=class{static get licenseKey(){return O().key}static set licenseKey(e){O().key=e}static get listeners(){return O().listeners}static get validationResult(){return O().result}static set validationResult(e){O().result=e}static getKey(){return this.licenseKey}static getLicenseStatus(){return this.licenseKey?(this.validationResult=this.validateKey(this.licenseKey),this.validationResult):{expired:!1,signatureVerified:!1,valid:!1}}static isKeyValid(e){return!!e&&this.validateKey(e).valid}static isLicenseValid(){return this.getLicenseStatus().valid}static onChange(e){return this.listeners.add(e),()=>{this.listeners.delete(e)}}static setLicense(e){var t,n;if(!e)return this.licenseKey=null,void this.publish({expired:!1,signatureVerified:!1,valid:!1});const i=this.validateKey(e);i.valid||e===this.licenseKey||!(null==(n=this.validationResult)?void 0:n.valid)?(this.licenseKey=e,this.publish(i),i.valid||w(`[Apex] ${i.message}`)):x(`[Apex] Ignoring license key: ${null!=(t=i.message)?t:"it is not valid"} A valid license is already active on this page.`)}static validateKey(e){const t=this.parseKey(e),n=this.validateStructure(e,t);if(!n.valid||!(null==t?void 0:t.signature))return n;const i=this.verdicts.get(e);return!1===i?{data:t.data,expired:!1,message:"Invalid license key. The license signature does not verify.",signatureVerified:!0,valid:!1}:(void 0===i&&this.verifySignature(e,t,n),l(o({},n),{signatureVerified:!0===i}))}static _resetSignatureState(){this.verdicts.clear(),this.verifying.clear(),this.warnedUnverifiable=!1,this.epoch++}static base64ToBytes(e){const t=e.replace(/-/g,"+").replace(/_/g,"/"),n=t.padEnd(4*Math.ceil(t.length/4),"="),i=globalThis.atob;if("function"!=typeof i)throw new Error("no base64 decoder available");const s=i(n),r=new Uint8Array(s.length);for(let e=0;e<s.length;e++)r[e]=s.charCodeAt(e);return r}static canonicalPayload(e){const t=e.domains&&e.domains.length>0?e.domains.join(","):"";return`v1|${e.issueDate}|${e.expiryDate}|${e.plan}|${t}`}static notify(e){for(const t of this.listeners)try{t(e)}catch(e){}}static parseKey(e){if("string"!=typeof e||!e.startsWith(_))return null;const t=e.slice(5);if(!t)return null;try{const e=(new TextDecoder).decode(this.base64ToBytes(t)),n=JSON.parse(e);return n.issueDate&&n.expiryDate&&n.plan?{data:{domains:Array.isArray(n.domains)?n.domains:void 0,expiryDate:n.expiryDate,issueDate:n.issueDate,plan:n.plan,valid:!0},signature:"string"==typeof n.sig&&n.sig?n.sig:null}:null}catch(e){return null}}static publish(e){this.validationResult=e,this.notify(e)}static validateStructure(e,t){const n=e=>({expired:!1,message:e,signatureVerified:!1,valid:!1});if("string"!=typeof e||!e.startsWith(_))return n('Invalid license key format. License key must start with "APEX-".');if(!t)return n("Invalid license key. Unable to decode license data.");const{data:i,signature:s}=t;if(!s&&new Date>=A)return n("This license key is in the old unsigned format, which is no longer accepted. Please request a replacement key.");if(new Date(i.expiryDate)<new Date)return{data:i,expired:!0,message:`License expired on ${i.expiryDate}. Please renew your license.`,signatureVerified:!1,valid:!1};if(i.domains&&i.domains.length>0){const e="undefined"==typeof location?"":location.hostname;if(!i.domains.some(t=>e===t||e.endsWith(`.${t}`)))return{data:i,expired:!1,message:`License is not valid for this domain (${e}). Allowed domains: ${i.domains.join(", ")}.`,signatureVerified:!1,valid:!1}}return{data:i,expired:!1,signatureVerified:!1,valid:!0}}static verifySignature(e,t,n){return i=this,s=null,r=function*(){var i;if(this.verifying.has(e)||this.verdicts.has(e))return;this.verifying.add(e);const s=this.epoch,r=null==(i=globalThis.crypto)?void 0:i.subtle;if(!r||0===this.publicKeysSpki.length)return this.verifying.delete(e),void(this.warnedUnverifiable||(this.warnedUnverifiable=!0,x(r?"[Apex] No license signing key is configured in this build, so license signatures cannot be verified.":"[Apex] Web Crypto is unavailable (a secure context is required), so the license signature cannot be verified.")));const a=(new TextEncoder).encode(this.canonicalPayload(t.data));let c=!1;for(const e of this.publicKeysSpki){try{const n=yield r.importKey("spki",this.base64ToBytes(e),{name:"ECDSA",namedCurve:"P-256"},!1,["verify"]);c=yield r.verify({hash:"SHA-256",name:"ECDSA"},n,this.base64ToBytes(t.signature),a)}catch(e){c=!1}if(c)break}if(this.verifying.delete(e),this.epoch!==s)return;if(this.verdicts.set(e,c),c){const t=l(o({},n),{signatureVerified:!0});return void(this.licenseKey===e?this.publish(t):this.notify(t))}const d="Invalid license key. The license signature does not verify.",u={data:t.data,expired:!1,message:d,signatureVerified:!0,valid:!1};this.licenseKey===e?this.publish(u):this.notify(u),w(`[Apex] ${d}`)},new Promise((e,t)=>{var n=e=>{try{o(r.next(e))}catch(e){t(e)}},a=e=>{try{o(r.throw(e))}catch(e){t(e)}},o=t=>t.done?e(t.value):Promise.resolve(t.value).then(n,a);o((r=r.apply(i,s)).next())});var i,s,r}};k.publicKeysSpki=["MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEQIaK9UMD6n0oR/FIy8QdL0uSzKMQlf1BB+tOrji4/WuHsyRNxeDhVykoSsNURozMi1xhmqWvBH1L//xIfugTPA=="],k.verdicts=new Map,k.verifying=new Set,k.warnedUnverifiable=!1,k.epoch=0;let T=k;const R=class{static applyStyles(e){Object.assign(e.style,this.CRITICAL_STYLES,{backgroundImage:this.createWatermarkPattern(),backgroundRepeat:"repeat"})}static node(e){return e?e.querySelector(`[${this.WATERMARK_ATTR}]`):null}static add(e,t){return e&&"undefined"!=typeof document?(this.setManaged(e,t),this.paint(e)):null}static exists(e){return!!this.node(e)}static remove(e,t){e&&(this.setManaged(e,t),this.erase(e))}static untrack(e){this.managed.delete(e)}static createWatermarkPattern(){const e=this.WATERMARK_TEXT;return`url("data:image/svg+xml,${encodeURIComponent(`\n <svg xmlns="http://www.w3.org/2000/svg" width="300" height="200">\n <text\n x="50%"\n y="50%"\n dominant-baseline="middle"\n text-anchor="middle"\n font-family="-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Arial, sans-serif"\n font-size="18"\n font-weight="600"\n fill="rgba(134, 134, 134, 0.1)"\n transform="rotate(-35, 100, 60)"\n >${e}</text>\n </svg>\n `.trim())}")`}static erase(e){var t;null==(t=this.node(e))||t.remove()}static paint(e){let t=this.node(e);return t||(t=document.createElement("div"),t.setAttribute(this.WATERMARK_ATTR,""),e.appendChild(t)),this.applyStyles(t),"function"==typeof getComputedStyle&&"static"===getComputedStyle(e).position&&(e.style.position="relative"),t}static reconcile(){const e=T.isLicenseValid();for(const t of this.managed)t.isConnected?e?this.erase(t):this.paint(t):this.managed.delete(t)}static setManaged(e,t){!1!==(null==t?void 0:t.manage)?this.track(e):this.managed.delete(e)}static track(e){this.managed.add(e),this.subscribed||(this.subscribed=!0,T.onChange(()=>{this.reconcile()}))}};R.WATERMARK_ATTR="data-apexcharts-watermark",R.WATERMARK_TEXT="APEXCHARTS",R.ATTR="data-apexcharts-watermark",R.CRITICAL_STYLES={bottom:"0",display:"block",left:"0",msUserSelect:"none",opacity:"1",pointerEvents:"none",position:"absolute",right:"0",top:"0",userSelect:"none",visibility:"visible",webkitUserSelect:"none",zIndex:"10000"},R.managed=new Set,R.subscribed=!1;let P=R;const D="https://apexcharts.com/pricing",K="__apexcharts_license_enforcer_v1__";globalThis[K]||(globalThis[K]={perspectivesTokenDecoded:!1,enforced:new Set});const C=globalThis[K],E=C.enforced;function $(){C.perspectivesTokenDecoded=!0,W()}const I=new Set(["premium","enterprise"]);function L(e,t){const n=P.add(t,{manage:!1});if(e._wmPainted=!0,!n||"undefined"==typeof MutationObserver)return;if(e._wmNodeObserver&&e._wmObservedNode===n)return;e._wmNodeObserver&&e._wmNodeObserver.disconnect();const i=new MutationObserver(()=>{const e=P.node(t);e&&(i.disconnect(),P.applyStyles(e),i.takeRecords(),i.observe(e,{attributes:!0,attributeFilter:["style"]}))});i.observe(n,{attributes:!0,attributeFilter:["style"]}),e._wmNodeObserver=i,e._wmObservedNode=n}function j(e,t){if(!e._wmPainted)return;e._wmPainted=!1,e._wmWrapObserver&&(e._wmWrapObserver.disconnect(),e._wmWrapObserver=null),e._wmNodeObserver&&(e._wmNodeObserver.disconnect(),e._wmNodeObserver=null),e._wmObservedNode=null,e._wmObservedWrap=null;const n=t||e.w&&e.w.dom&&e.w.dom.elWrap;n&&P.remove(n,{manage:!1})}function M(e,t){try{if(!h.isBrowser())return;if(e&&e.globals&&e.globals.isDestroyed)return void E.delete(t);const n=e&&e.dom&&e.dom.elWrap;if(!n)return;const i=function(e,t){var n;const i=e&&e.config&&e.config.chart||{},s=[];"unit"===i.type&&s.push("unit"),"raincloud"===i.requestedType&&s.push("raincloud"),t.trellis&&"function"==typeof t.trellis.isActive&&t.trellis.isActive()&&s.push("trellis"),t.storyboard&&t.storyboard._used&&s.push("storyboard");const r=i.link;return t.linkedViews&&r&&(!0===r.enabled||"function"==typeof r.dimension)&&s.push("link"),t.ink&&i.ink&&!0===i.ink.enabled&&s.push("ink"),t.measure&&i.measure&&!0===i.measure.enabled&&s.push("measure"),t.contextMenu&&i.contextMenu&&!0===i.contextMenu.enabled&&s.push("context-menu"),t.perspectives&&(t.perspectives._used||C.perspectivesTokenDecoded)&&s.push("perspectives"),t.history&&i.history&&!0===i.history.enabled&&s.push("history"),(null==(n=t._highlightFilter)?void 0:n.isActive())&&s.push("highlight-filter"),s}(e,t);if(0===i.length)return E.delete(t),void j(t,n);E.add(t);const s=function(e){const t=e&&e.config&&e.config.chart&&e.config.chart.license;if(t)return t;const n=T.getKey();if(n)return n;const i=h.getApex();return i&&i.license?i.license:null}(e);if(function(e){if(!e)return!1;const t=T.validateKey(e);if(!t.valid)return!1;const n=t.data&&t.data.plan;return"string"==typeof n&&I.has(n.toLowerCase())}(s))return void j(t,n);!function(e,t){if(L(e,t),"undefined"==typeof MutationObserver)return;if(e._wmWrapObserver&&e._wmObservedWrap===t)return;e._wmWrapObserver&&e._wmWrapObserver.disconnect();const n=new MutationObserver(()=>{P.node(t)||L(e,t)});n.observe(t,{childList:!0}),e._wmWrapObserver=n,e._wmObservedWrap=t}(t,n),function(e,t,n){if(e._premiumLicenseNotified)return;e._premiumLicenseNotified=!0;const i=n.length>1;if(!t)return void console.warn(`[ApexCharts] Premium feature${i?"s":""} in use (${n.join(", ")}) without a license. Running in trial mode with a watermark. Get a license: ${D}`);const s=T.validateKey(t);if(s.valid){const e=s.data&&s.data.plan||"current";return void console.warn(`[ApexCharts] Premium feature${i?"s":""} in use (${n.join(", ")}) require a Premium or Enterprise license; the ${e} plan does not include ${i?"them":"it"}. Running in trial mode with a watermark. Upgrade: ${D}`)}t!==T.getKey()&&console.error(`[Apex] ${s.message}`)}(t,s,i)}catch(e){}}function W(){if(!h.isBrowser())return;const e=new Set,t=h.getApex(),n=t&&t._chartInstances;Array.isArray(n)&&n.forEach(t=>{const n=t&&t.chart;n&&n.w&&!n.w.globals.isDestroyed&&(e.add(n),M(n.w,n))}),Array.from(E).forEach(t=>{const n=t&&t.w,i=n&&n.dom&&n.dom.elWrap;n&&!n.globals.isDestroyed&&i&&!1!==i.isConnected?e.has(t)||M(n,t):E.delete(t)})}T.onChange(W);const U="apex";function N(e){return function(e){if("undefined"!=typeof Buffer)return Buffer.from(e,"utf-8").toString("base64");const t=(new TextEncoder).encode(e);let n="";for(let e=0;e<t.length;e++)n+=String.fromCharCode(t[e]);return btoa(n)}(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function B(e){let t=e.replace(/-/g,"+").replace(/_/g,"/");for(;t.length%4;)t+="=";return function(e){if("undefined"!=typeof Buffer)return Buffer.from(e,"base64").toString("utf-8");const t=atob(e),n=new Uint8Array(t.length);for(let e=0;e<t.length;e++)n[e]=t.charCodeAt(e);return(new TextDecoder).decode(n)}(t)}class V{constructor(e,t){this.w=e,this.ctx=t,this._saved=[],this._counter=0,this._used=!1}capture(){const e={v:1,view:function(e,t){var n,i;const s=e.config.xaxis||{},r=(Array.isArray(e.config.yaxis)?e.config.yaxis:e.config.yaxis?[e.config.yaxis]:[]).map(e=>p(e&&e.min,e&&e.max)),a=r.some(e=>null!==e),o=e.config.theme,l=t&&t.drilldown;return{v:1,window:{xaxis:p(s.min,s.max),yaxis:a?r:null},zoomed:!!e.interact.zoomed,collapsed:(e.globals.collapsedSeriesIndices||[]).slice(),ancillaryCollapsed:(e.globals.ancillaryCollapsedSeriesIndices||[]).slice(),selectedDataPoints:f(e.interact.selectedDataPoints),theme:o?{mode:null!=(n=o.mode)?n:null,palette:null!=(i=o.palette)?i:null}:null,locale:e.config.chart&&e.config.chart.defaultLocale||null,annotations:y(e,t),drill:l&&l.depth>0?{path:l.path.slice()}:null,measure:g(t)}}(this.w,this.ctx)},t=this._serializableDelta();return t&&Object.keys(t).length&&(e.options=t),e}_serializableDelta(){const e=this.w.config,t=e.chart&&e.chart.perspectives&&e.chart.perspectives.serializeOptions||["theme","xaxis","yaxis","title","subtitle"],n={};return t.forEach(t=>{if(void 0!==e[t]){const i=function(e){try{return JSON.parse(JSON.stringify(e))}catch(e){return}}(e[t]);void 0!==i&&(n[t]=i)}}),n}encode(e){const t=e||this.capture();return N(JSON.stringify(t))}decode(e){return V.decode(e)}toURL(){if(!h.isBrowser())return"";const e=this.encode(this.capture()),t=new URL(window.location.href);return t.hash=`${U}=${e}`,t.toString()}apply(e,t={}){const n="string"==typeof e?V.decode(e):e;if(!n||!n.view)return;this._used=!0,M(this.w,this.ctx);const i=void 0===t.animate||t.animate,s=u.extend(n.options?u.clone(n.options):{},t.mergeOptions||{}),r=Object.keys(s).length?s:void 0;(this.w.config.chart.group?this.ctx.getSyncedCharts():[this.ctx]).forEach(e=>{v(e,n.view,{animate:i,mergeOptions:r})})}save(e){const t="perspective-"+ ++this._counter;return this._saved.push({id:t,name:e||t,token:this.capture()}),this._used=!0,M(this.w,this.ctx),t}list(){return this._saved.map(e=>({id:e.id,name:e.name,token:e.token}))}delete(e){const t=this._saved.findIndex(t=>t.id===e);t>-1&&this._saved.splice(t,1)}teardown(){this._saved=[],this._counter=0}static decode(e){if("string"!=typeof e||!e)return null;try{const t=JSON.parse(B(e));return t&&"object"==typeof t?1!==t.v?(console.warn(`apexcharts: unsupported perspective version ${t.v} (expected 1).`),null):t:null}catch(e){return console.warn("apexcharts: failed to decode perspective token.",e),null}}static fromURL(e){try{const t=e||(h.isBrowser()?window.location.href:"");if(!t)return null;const n=new URL(t).hash.replace(/^#/,"");if(!n)return null;const i=n.split("&").map(e=>e.split("=")).find(e=>e[0]===U);return i&&null!=i[1]?V.decode(decodeURIComponent(i[1])):null}catch(e){return null}}}d.default.registerFeatures({perspectives:V,perspectivesStatics:{decode:e=>($(),V.decode(e)),fromURL:e=>($(),V.fromURL(e))}}),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>d.default});
|
|
@@ -38,7 +38,7 @@ var __async = (__this, __arguments, generator) => {
|
|
|
38
38
|
});
|
|
39
39
|
};
|
|
40
40
|
/*!
|
|
41
|
-
* ApexCharts v8.
|
|
41
|
+
* ApexCharts v8.3.1
|
|
42
42
|
* (c) 2018-2026 ApexCharts
|
|
43
43
|
*/
|
|
44
44
|
import * as _core from "apexcharts/core";
|
|
@@ -478,6 +478,7 @@ function licensedForPremium(key) {
|
|
|
478
478
|
}
|
|
479
479
|
function reinstateWatermark(ctx, elWrap) {
|
|
480
480
|
const node = C.add(elWrap, { manage: false });
|
|
481
|
+
ctx._wmPainted = true;
|
|
481
482
|
if (!node || typeof MutationObserver === "undefined") return;
|
|
482
483
|
if (ctx._wmNodeObserver && ctx._wmObservedNode === node) return;
|
|
483
484
|
if (ctx._wmNodeObserver) ctx._wmNodeObserver.disconnect();
|
|
@@ -506,6 +507,8 @@ function addWatermark(ctx, elWrap) {
|
|
|
506
507
|
ctx._wmObservedWrap = elWrap;
|
|
507
508
|
}
|
|
508
509
|
function teardownWatermark(ctx, elWrap) {
|
|
510
|
+
if (!ctx._wmPainted) return;
|
|
511
|
+
ctx._wmPainted = false;
|
|
509
512
|
if (ctx._wmWrapObserver) {
|
|
510
513
|
ctx._wmWrapObserver.disconnect();
|
|
511
514
|
ctx._wmWrapObserver = null;
|