apexcharts 7.2.0 → 7.4.0
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/LICENSE +30 -11
- package/dist/apexcharts.common.js +2 -2
- package/dist/apexcharts.core.js +545 -463
- package/dist/apexcharts.core.min.js +2 -2
- package/dist/apexcharts.esm.js +1149 -801
- package/dist/apexcharts.js +684 -254
- package/dist/apexcharts.min.js +2 -2
- package/dist/apexcharts.ssr.common.js +2 -2
- package/dist/apexcharts.ssr.esm.js +684 -254
- package/dist/area.common.js +1 -1
- package/dist/area.esm.js +1 -1
- package/dist/bar.common.js +2 -2
- package/dist/bar.esm.js +20 -10
- package/dist/bar.js +2 -2
- package/dist/boxPlot.common.js +2 -2
- package/dist/boxPlot.esm.js +20 -10
- package/dist/bubble.common.js +1 -1
- package/dist/bubble.esm.js +1 -1
- package/dist/candlestick.common.js +2 -2
- package/dist/candlestick.esm.js +20 -10
- package/dist/candlestick.js +2 -2
- package/dist/column.common.js +2 -2
- package/dist/column.esm.js +20 -10
- package/dist/core.common.js +2 -2
- package/dist/core.esm.js +545 -463
- package/dist/donut.common.js +1 -1
- package/dist/donut.esm.js +1 -1
- package/dist/dumbbell.common.js +2 -2
- package/dist/dumbbell.esm.js +20 -10
- package/dist/features/all.common.js +2 -2
- package/dist/features/all.esm.js +364 -26
- package/dist/features/annotations.common.js +1 -1
- package/dist/features/annotations.esm.js +1 -1
- package/dist/features/annotations.js +1 -1
- 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 +1 -1
- package/dist/features/drilldown.esm.js +1 -1
- package/dist/features/drilldown.js +1 -1
- 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 +12 -14
- 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/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 +14 -1
- package/dist/features/keyboard.js +2 -2
- package/dist/features/legend.common.js +1 -1
- package/dist/features/legend.esm.js +1 -1
- package/dist/features/legend.js +1 -1
- package/dist/features/link.common.js +1 -1
- package/dist/features/link.esm.js +38 -38
- 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 +1 -1
- package/dist/features/morph.esm.js +1 -1
- package/dist/features/morph.js +1 -1
- package/dist/features/perspectives.common.js +1 -1
- package/dist/features/perspectives.esm.js +11 -11
- package/dist/features/perspectives.js +1 -1
- package/dist/features/raincloud.common.js +1 -1
- package/dist/features/raincloud.esm.js +1 -1
- package/dist/features/raincloud.js +1 -1
- package/dist/features/renderer-canvas.common.js +1 -1
- package/dist/features/renderer-canvas.esm.js +1 -1
- package/dist/features/renderer-canvas.js +1 -1
- package/dist/features/stats.common.js +1 -1
- package/dist/features/stats.esm.js +1 -1
- package/dist/features/stats.js +1 -1
- package/dist/features/storyboard.common.js +1 -1
- package/dist/features/storyboard.esm.js +11 -11
- package/dist/features/storyboard.js +1 -1
- package/dist/features/streamgraph.common.js +1 -1
- package/dist/features/streamgraph.esm.js +1 -1
- package/dist/features/streamgraph.js +1 -1
- package/dist/features/toolbar.common.js +2 -2
- package/dist/features/toolbar.esm.js +172 -25
- package/dist/features/toolbar.js +2 -2
- package/dist/features/trellis.common.js +1 -1
- package/dist/features/trellis.esm.js +1 -1
- package/dist/features/trellis.js +1 -1
- 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 +180 -2
- package/dist/features/weave.js +2 -2
- package/dist/heatmap.common.js +1 -1
- package/dist/heatmap.esm.js +1 -1
- package/dist/heatmap.js +1 -1
- package/dist/histogram.common.js +2 -2
- package/dist/histogram.esm.js +20 -10
- package/dist/line.common.js +1 -1
- package/dist/line.esm.js +1 -1
- package/dist/line.js +1 -1
- 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 +1 -1
- package/dist/pie.esm.js +1 -1
- package/dist/pie.js +1 -1
- package/dist/polarArea.common.js +1 -1
- package/dist/polarArea.esm.js +1 -1
- package/dist/radar.common.js +1 -1
- package/dist/radar.esm.js +1 -1
- package/dist/radar.js +1 -1
- package/dist/radialBar.common.js +1 -1
- package/dist/radialBar.esm.js +1 -1
- package/dist/radialBar.js +1 -1
- package/dist/raincloud.common.js +2 -2
- package/dist/raincloud.esm.js +20 -10
- package/dist/rangeArea.common.js +1 -1
- package/dist/rangeArea.esm.js +1 -1
- package/dist/rangeBar.common.js +2 -2
- package/dist/rangeBar.esm.js +20 -10
- package/dist/scatter.common.js +1 -1
- package/dist/scatter.esm.js +1 -1
- package/dist/streamgraph.common.js +1 -1
- package/dist/streamgraph.esm.js +1 -1
- package/dist/sunburst.common.js +1 -1
- package/dist/sunburst.esm.js +1 -1
- package/dist/sunburst.js +1 -1
- package/dist/treemap.common.js +1 -1
- package/dist/treemap.esm.js +1 -1
- package/dist/treemap.js +1 -1
- 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 +1 -1
- package/dist/unit.esm.js +79 -79
- package/dist/unit.js +1 -1
- package/dist/violin.common.js +2 -2
- package/dist/violin.esm.js +20 -10
- package/dist/violin.js +2 -2
- package/dist/waterfall.common.js +2 -2
- package/dist/waterfall.esm.js +20 -10
- package/package.json +2 -2
- package/src/apexcharts.js +39 -15
- package/src/charts/common/bar/Helpers.js +31 -12
- package/src/modules/Data.js +8 -2
- package/src/modules/Exports.js +14 -12
- package/src/modules/Formatters.js +24 -1
- package/src/modules/Range.js +28 -1
- package/src/modules/Toolbar.js +112 -2
- package/src/modules/ZoomPanSelection.js +85 -7
- package/src/modules/accessibility/KeyboardNavigation.js +14 -0
- package/src/modules/axes/YAxis.js +12 -15
- package/src/modules/helpers/UpdateHelpers.js +25 -8
- package/src/modules/settings/Globals.js +5 -10
- package/src/modules/settings/Options.js +15 -0
- package/src/modules/weave/PluginAPI.js +57 -1
- package/src/modules/weave/WeaveHost.js +148 -0
- package/src/ssr/DOMShim.js +50 -0
- package/src/types/internal.d.ts +1 -1
- package/src/utils/Utils.js +6 -9
- package/types/apexcharts.d.ts +17 -0
package/dist/features/morph.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
!function(t,e){"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={})}(this,function(t){"use strict";var e=Object.defineProperty,r=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable,a=(t,r,i)=>r in t?e(t,r,{enumerable:!0,configurable:!0,writable:!0,value:i}):t[r]=i,s=(t,e)=>{for(var s in e||(e={}))i.call(e,s)&&a(t,s,e[s]);if(r)for(var s of r(e))n.call(e,s)&&a(t,s,e[s]);return t};const l=globalThis.ApexCharts,o=globalThis.ApexCharts.__internals.__apex_Environment_Environment,h=globalThis.ApexCharts.__internals.__apex_BrowserAPIs_BrowserAPIs,u=globalThis.ApexCharts.__internals;u.__apex_Animations,u.__apex_Animations_computeStagger,u.__apex_Animations_applyAnimationPolicy;const c=u.__apex_Animations_prefersReducedMotion;u.__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[s({},t)];const r=t.width>=t.height,i=r?t.width:t.height,n=r?t.height:t.width,a=n>0?i/n: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 u=[],c=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?n/e:0;for(let n=0;n<e;n++)u.push(r?{x:t.x+p,y:t.y+n*i,width:c,height:i}:{x:t.x+n*i,y:t.y+p,width:i,height:c});p+=c}return u}function g(t,e,r){if(!(e>0))return[];const i=t.width>=t.height,n=i?t.width:t.height,a=i?t.height:t.width,s=i?t.y:t.x,l=s+a,o=a>0?n/a:e;let h=Math.max(Math.ceil(Math.sqrt(o*e)),Math.ceil(n/16));h>=1||(h=1),h>e&&(h=e);const u=Math.floor(e/h);let c=e-u*h;const p=[],d=n/h;let f=i?t.x:t.y;for(let t=0;t<h;t++){const t=u+(c>0?1:0);c>0&&c--;const e=[],n=r(f,f+d,i);if(Array.isArray(n))for(let t=0;t<n.length;t++){const r=n[t];if(!r)continue;const i=Math.max(s,Math.min(r[0],r[1])),a=Math.min(l,Math.max(r[0],r[1]));a>i&&e.push([i,a])}e.length||e.push([s,l]);const a=e.reduce((t,e)=>t+(e[1]-e[0]),0),o=e.map(r=>a>0?(r[1]-r[0])/a*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 n=e[t][0],a=(e[t][1]-n)/r;for(let t=0;t<r;t++)p.push(i?{x:f,y:n+t*a,width:d,height:a}:{x:n+t*a,y:f,width:a,height:d})}f+=d}return p}function y(t,e,r,i,n,a){let s=n===r?0:Math.round((t-r)/(n-r)*32767),l=a===i?0:Math.round((e-i)/(a-i)*32767),o=0;for(let t=32768;t>=1;t/=2){const e=(s&t)>0?1:0,r=(l&t)>0?1:0;if(o+=t*t*(3*e^r),0===r){1===e&&(s=t-1-s,l=t-1-l);const r=s;s=l,l=r}}return o}function m(t,e){let r=1/0,i=1/0,n=-1/0,a=-1/0;const s=t.map(t=>{const[s,l]=e(t);return s<r&&(r=s),s>n&&(n=s),l<i&&(i=l),l>a&&(a=l),[s,l]});return t.map((t,e)=>({item:t,d:y(s[e][0],s[e][1],r,i,n,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 b(t,e){const r=x(t),i=x(e);return r&&i?t=>{const e=Math.round(r[0]+(i[0]-r[0])*t),n=Math.round(r[1]+(i[1]-r[1])*t),a=Math.round(r[2]+(i[2]-r[2])*t),s=r[3]+(i[3]-r[3])*t;return s>=1?`rgb(${e},${n},${a})`:`rgba(${e},${n},${a},${s})`}: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 _=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"]),S=1500;function P(t){return _.has(t)?"bar":w.has(t)?"radial":$.has(t)?"unit":v.has(t)?"partition":M.has(t)?"summary":null}l.registerFeatures({morphTypeChange:class{constructor(t,e){this.w=t,this.ctx=e,this._snapshot=null,this._ghost=null,this._pieceLayer=null,this._pieceCancel=null}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),n=P(e);return"unit"===n?!!r.every(t=>"number"==typeof t)||r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):"partition"===n||("radial"===n?!!r.every(t=>"number"==typeof t)||1===r.length&&r[0]&&"object"==typeof r[0]&&Array.isArray(r[0].data):"bar"===n||"summary"===n?r.every(t=>t&&"object"==typeof t&&Array.isArray(t.data)):null!==i&&null!==n)}captureBeforeDestroy({fromType:t,toType:e,newSeries:r}){if(this._snapshot=null,this._removeGhost(),this._cancelPieces(),!o.isBrowser())return!1;const i=this.w.config.chart.animations;if(!i||!1===i.enabled)return!1;if(i.chartTypeMorph&&!1===i.chartTypeMorph.enabled)return!1;if(i.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:s}=this._captureFromDOM(t);if(!n.length)return!1;const l=this._buildMapping(n,t,e,r,a);if(0===l.size)return!1;this._snapshot={fromType:t,toType:e,mapping:l,oldLayout:{translateX:this.w.layout.translateX||0,translateY:this.w.layout.translateY||0}};const h=P(t),u=P(e),p=this._canProbePaths();if("unit"===u&&("bar"===h||"summary"===h||"radial"===h&&p)){const t=this._countUnitSeries(r);this._snapshot.pieceOut=t>0&&t<=S}else if("unit"===h&&("bar"===u||"summary"===u||"radial"===u&&p)){let t=0;if(s.forEach(e=>{t+=e.length}),t>0&&t<=S){this._snapshot.pieceIn=!0,this._snapshot.sourceDots=s;const t=[];"radial"===u?(Array.isArray(r)?r:[]).forEach((e,r)=>{t.push(`${r}:0`)}):(Array.isArray(r)?r:[]).forEach((e,r)=>{const i=e&&Array.isArray(e.data)?e.data:[];for(let e=0;e<i.length;e++)t.push(`${r}:${e}`)}),this._snapshot.keyOrder=t}}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 n=i.cloneNode(!0),a=[".apexcharts-xaxis",".apexcharts-yaxis",".apexcharts-grid",".apexcharts-gridlines-horizontal",".apexcharts-gridlines-vertical",".apexcharts-legend",".apexcharts-title-text",".apexcharts-subtitle-text",".apexcharts-annotations",".apexcharts-zoom-rect",".apexcharts-selection-rect",".apexcharts-xcrosshairs",".apexcharts-ycrosshairs"];"function"==typeof n.querySelectorAll&&a.forEach(t=>{n.querySelectorAll(t).forEach(t=>{t.parentNode&&t.parentNode.removeChild(t)})}),"function"==typeof n.querySelectorAll&&n.querySelectorAll("[id]").forEach(t=>{t.removeAttribute("id")}),null==(e=n.removeAttribute)||e.call(n,"id"),this._ghost=n}_mountGhost(){var t,e,r;const i=this._ghost;if(!i||!o.isBrowser())return;const n=null==(t=this.w.dom)?void 0:t.elWrap;if(!n||"function"!=typeof n.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"),n.appendChild(i);const s=this.getSpeed(),l=Math.max(120,Math.round(.55*s));h.requestAnimationFrame(()=>{a&&(a.transition=`opacity ${l}ms ease-in`,a.opacity="0")}),setTimeout(()=>this._removeGhost(),l+60)}_removeGhost(){const t=this._ghost;this._ghost=null,t&&t.parentNode&&t.parentNode.removeChild(t)}_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 n=h.createElementNS("http://www.w3.org/2000/svg","g");if(!n)return null;n.setAttribute("class","apexcharts-morph-pieces"),n.setAttribute("pointer-events","none");const a=null==(e=this.w.globals)?void 0:e.cuid;return a&&n.setAttribute("clip-path",`url(#gridRectBarMask${a})`),i.appendChild(n),this._pieceLayer=n,n}_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(t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")})}_cancelPieces(){this._pieceCancel&&(this._pieceCancel(),this._pieceCancel=null);const t=this._pieceLayer;this._pieceLayer=null,t&&t.parentNode&&t.parentNode.removeChild(t),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 n=i.ownerSVGElement;if("function"!=typeof i.isPointInFill||!n||"function"!=typeof n.createSVGPoint)return r.removeChild(i),null;const a=n.createSVGPoint(),s=(t,e)=>{a.x=t,a.y=e;const r=i;return r.isPointInFill(a)||"function"==typeof r.isPointInStroke&&r.isPointInStroke(a)},l=48;return{intervalsAt:(t,r,i)=>{const n=i?e.y:e.x,a=n+(i?e.height:e.width);if(!(a>n))return null;const o=(t,e)=>i?s(e,t):s(t,e),h=[t+.1*(r-t),(t+r)/2,r-.1*(r-t)],u=(t,e,r)=>{let i=e,n=t;for(let t=0;t<6;t++){const t=(i+n)/2;o(t,r)?n=t:i=t}return(i+n)/2},c=(a-n)/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(n+e*c,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?n:u(n+g*c,n+(g-1)*c,r),s=e===l?a:u(n+e*c,n+(e+1)*c,p[e]);s>i&&f.push([i,s]),g=-1}}return f.length?f:null},dispose:()=>{i.parentNode&&i.parentNode.removeChild(i)}}}_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=new Map;let n=0;if(r.querySelectorAll(".apexcharts-unit-area").forEach(t=>{var e,r,a,s,l,o,h;const u=parseInt(null!=(e=t.getAttribute("i"))?e:"",10);if(isNaN(u))return;const c=t.getAttribute("cx");let p,d,f=3;if(null!=c)p=parseFloat(c),d=parseFloat(null!=(r=t.getAttribute("cy"))?r:""),f=parseFloat(null!=(a=t.getAttribute("r"))?a:"3")||3;else{const e=parseFloat(null!=(s=t.getAttribute("width"))?s:"0")||0,r=parseFloat(null!=(l=t.getAttribute("height"))?l:"0")||0;p=parseFloat(null!=(o=t.getAttribute("x"))?o:"")+e/2,d=parseFloat(null!=(h=t.getAttribute("y"))?h:"")+r/2,f=Math.max(e,r)/2||3}if(!isFinite(p)||!isFinite(d))return;let g=i.get(u);g||(g=[],i.set(u,g)),g.push({el:t,x:p,y:d,r:f,fill:t.getAttribute("fill")}),n++}),0===n||n>S)return this._revealPieceHidden();const a=this._makePieceLayer();if(!a)return this._revealPieceHidden();const s=[],l=a.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 n=i.get(t),o=this.getInitialBBoxFor(t),u=e.mapping.get(`${t}:0`);if(!o||!u)return void n.forEach(t=>{t.el.removeAttribute("opacity"),t.el.removeAttribute("data-piece-hidden")});const c=u.fill&&0!==u.fill.indexOf("url(")?u.fill:(null==(r=this.w.globals.colors)?void 0:r[t])||n[0].fill;let p=null;if(h){const e=this.getInitialPathFor(t,0);e&&(p=this._makeExtentProber(e,o,a))}const d=p?g(o,n.length,p.intervalsAt):f(o,n.length);p&&p.dispose();const y=m(d,t=>[t.x+t.width/2,t.y+t.height/2]),x=m(n,t=>[t.x,t.y]);for(let e=0;e<x.length;e++){const r=y[e],i=x[e],n=l.createElementNS("http://www.w3.org/2000/svg","rect");n.setAttribute("data-i",String(t)),n.setAttribute("x",String(r.x)),n.setAttribute("y",String(r.y)),n.setAttribute("width",String(r.width)),n.setAttribute("height",String(r.height)),n.setAttribute("rx","0"),n.setAttribute("fill",String(c)),a.appendChild(n),s.push({el:n,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:b(c,i.fill),fillEnd:i.fill,delay:0,meta:{dotEl:i.el}})}}),!s.length)return this._cancelPieces();this._runPieces(s,t=>{const e=t.meta.dotEl;e.removeAttribute("opacity"),e.removeAttribute("data-piece-hidden"),t.el.parentNode&&t.el.parentNode.removeChild(t.el)})}_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 n=this._collectTargetMarks(r.toType);if(!n.size)return this._revealPieceHidden();const a=r.oldLayout.translateX-(this.w.layout.translateX||0),s=r.oldLayout.translateY-(this.w.layout.translateY||0),l=Array.from(r.sourceDots.keys()).sort((t,e)=>t-e),o=this._makePieceLayer();if(!o)return this._revealPieceHidden();const h=o.ownerDocument,u=[],c=P(r.toType),p="summary"===c||"radial"===c;for(let t=0;t<l.length;t++){const i=r.sourceDots.get(l[t]),c=r.keyOrder[t],d=c?n.get(c):null;if(!d||!i||!i.length){d&&d.els.forEach(t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")});continue}const y=d.fill&&0!==d.fill.indexOf("url(")?d.fill:(null==(e=this.w.globals.colors)?void 0:e[d.realIndex])||i[0].fill;let x=null;if(p){const t=d.d||d.els.map(t=>t.getAttribute("pathTo")||t.getAttribute("d")).filter(Boolean).join(" ");t&&(x=this._makeExtentProber(t,d.bbox,o))}const A=x?g(d.bbox,i.length,x.intervalsAt):f(d.bbox,i.length);x&&x.dispose();const _=m(A,t=>[t.x+t.width/2,t.y+t.height/2]),w=m(i,t=>[t.x,t.y]),$={remaining:w.length,els:d.els,tiles:[]};for(let t=0;t<w.length;t++){const e=w[t],r=_[t],i=h.createElementNS("http://www.w3.org/2000/svg","rect"),n=e.x+a-e.r,l=e.y+s-e.r;i.setAttribute("data-key",c),i.setAttribute("x",String(n)),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||y)),o.appendChild(i),$.tiles.push(i),u.push({el:i,from:{x:n,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:b(e.fill,y),fillEnd:String(y),delay:0,meta:{markState:$}})}}if(!u.length)return this._cancelPieces();this._runPieces(u,t=>{const e=t.meta.markState;e.remaining--,0===e.remaining&&(e.els.forEach(t=>{t.removeAttribute("opacity"),t.removeAttribute("data-piece-hidden")}),e.tiles.forEach(t=>{t.parentNode&&t.parentNode.removeChild(t)}))})}_runPieces(t,e){const r=this.getSpeed(),i=Math.min(300,.35*r),n=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}){let n=!1;const a=Date.now(),s=Math.max(1,e),l=(t,e)=>{const r=t.from,i=t.to,n=t.el;n.setAttribute("x",String(r.x+(i.x-r.x)*e)),n.setAttribute("y",String(r.y+(i.y-r.y)*e)),n.setAttribute("width",String(Math.max(0,r.width+(i.width-r.width)*e))),n.setAttribute("height",String(Math.max(0,r.height+(i.height-r.height)*e))),n.setAttribute("rx",String(Math.max(0,r.rx+(i.rx-r.rx)*e))),t.fill?n.setAttribute("fill",t.fill(e)):e>=1&&t.fillEnd&&n.setAttribute("fill",t.fillEnd)},o=()=>{if(n)return;const e=Date.now()-a;let u=!1;for(let i=0;i<t.length;i++){const n=t[i];if(n._done)continue;const a=(e-n.delay)/s;if(a<1&&(u=!0),a<=0)continue;const o=Math.min(1,a);l(n,A(o)),o>=1&&(n._done=!0,r&&r(n))}u?h.requestAnimationFrame(o):i&&i()};return h.requestAnimationFrame(o),()=>{n=!0}}({pieces:t,duration:n,onPieceDone:e,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 n=P(t);if("radial"===n)return r.querySelectorAll(".apexcharts-pie-series .apexcharts-pie-area").forEach((t,e)=>{const r=t.getAttribute("data:pathFinal")||t.getAttribute("d");if(!r||!r.trim())return;const n=this._pathBBox(r);n&&i.set(`${e}:0`,{realIndex:e,j:0,d:r,bbox:{x:n.minX,y:n.minY,width:n.maxX-n.minX,height:n.maxY-n.minY},fill:t.getAttribute("fill"),els:[t]})}),i;const a="summary"===n?`.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 n=0;t.querySelectorAll("path[pathTo]").forEach(t=>{var e;const a=t.getAttribute("pathTo")||t.getAttribute("d");if(!a||!a.trim())return;const s=parseInt(null!=(e=t.getAttribute("j"))?e:"",10),l=isNaN(s)?n++:s,o=this._pathBBox(a);if(!o)return;const h=`${r}:${l}`,u=i.get(h);u?(u.els.push(t),u.bbox={x:Math.min(u.bbox.x,o.minX),y:Math.min(u.bbox.y,o.minY),width:Math.max(u.bbox.x+u.bbox.width,o.maxX)-Math.min(u.bbox.x,o.minX),height:Math.max(u.bbox.y+u.bbox.height,o.maxY)-Math.min(u.bbox.y,o.minY)}):i.set(h,{realIndex:r,j:l,bbox:{x:o.minX,y:o.minY,width:o.maxX-o.minX,height:o.maxY-o.minY},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=[],n=[],a=new Map,s=P(t);if("bar"===s){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]").forEach((t,e)=>{const n=t.getAttribute("pathTo")||t.getAttribute("d");n&&i.push({realIndex:r,j:e,d:n,fill:t.getAttribute("fill")})})})}else if("summary"===s){const e=new Map;r.querySelectorAll(`.apexcharts-${t}-area`).forEach(t=>{var r,i;const n=parseInt(null!=(r=t.getAttribute("j"))?r:"",10);if(isNaN(n))return;const a=t.getAttribute("pathTo")||t.getAttribute("d");if(!a||!a.trim())return;const s="function"==typeof t.closest?t.closest(".apexcharts-series"):null,l=parseInt(null!=(i=null==s?void 0:s.getAttribute("data:realIndex"))?i:"0",10)||0,o=`${l}:${n}`,h=e.get(o);h?h.d+=` ${a}`:e.set(o,{realIndex:l,j:n,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"===s)if("treemap"===t){const t=t=>{var e,r,i,n;const a=parseFloat(null!=(e=t.getAttribute("x"))?e:""),s=parseFloat(null!=(r=t.getAttribute("y"))?r:""),l=parseFloat(null!=(i=t.getAttribute("width"))?i:""),o=parseFloat(null!=(n=t.getAttribute("height"))?n:"");return[a,s,l,o].every(t=>isFinite(t))?`M ${a} ${s} L ${a+l} ${s} L ${a+l} ${s+o} L ${a} ${s+o} Z`:null};r.querySelectorAll(".apexcharts-treemap-rect").forEach(e=>{var r,n;const a=t(e);a&&i.push({realIndex:parseInt(null!=(r=e.getAttribute("i"))?r:"0",10)||0,j:parseInt(null!=(n=e.getAttribute("j"))?n:"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&&n.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&&n.push({key:r,d:e,fill:t.getAttribute("fill")})})}else if("unit"===s){const t=r.querySelectorAll(".apexcharts-unit-area"),e=new Map;t.forEach(t=>{var r,i,n,s,l,o,h;const u=parseInt(null!=(r=t.getAttribute("i"))?r:"",10);if(isNaN(u))return;const c=t.getAttribute("cx");let p,d,f=3;if(null!=c)p=parseFloat(c),d=parseFloat(null!=(i=t.getAttribute("cy"))?i:""),f=parseFloat(null!=(n=t.getAttribute("r"))?n:"3")||3;else{const e=parseFloat(null!=(s=t.getAttribute("width"))?s:"0")||0,r=parseFloat(null!=(l=t.getAttribute("height"))?l:"0")||0;p=parseFloat(null!=(o=t.getAttribute("x"))?o:"")+e/2,d=parseFloat(null!=(h=t.getAttribute("y"))?h:"")+r/2,f=Math.max(e,r)/2||3}if(!isFinite(p)||!isFinite(d))return;let g=a.get(u);g||(g=[],a.set(u,g)),g.push({x:p,y:d,r:f,fill:t.getAttribute("fill")});const y=e.get(u);y?(p<y.minX&&(y.minX=p),p>y.maxX&&(y.maxX=p),d<y.minY&&(y.minY=d),d>y.maxY&&(y.maxY=d)):e.set(u,{minX:p,minY:d,maxX:p,maxY:d,fill:t.getAttribute("fill")})}),Array.from(e.keys()).sort((t,e)=>t-e).forEach(t=>{const r=e.get(t),n=r.minX-2,a=r.minY-2,s=r.maxX+2,l=r.maxY+2;i.push({realIndex:t,j:0,d:`M ${n} ${a} L ${s} ${a} L ${s} ${l} L ${n} ${l} Z`,fill:r.fill})})}else if("radial"===s)if("radialBar"===t||"gauge"===t){const t=this.w.layout.gridWidth/2,e=Math.min(this.w.layout.gridWidth,this.w.layout.gridHeight)/2;r.querySelectorAll(".apexcharts-radial-series .apexcharts-radialbar-area").forEach(r=>{var n;const a=r.parentElement,s=parseInt(null!=(n=null==a?void 0:a.getAttribute("data:realIndex"))?n:"0",10),l=r.getAttribute("d");if(!l)return;const o=parseFloat(r.getAttribute("stroke-width")||"0"),h=o>1&&this._radialArcToFilledSegment(l,o,t,e)||l;i.push({realIndex:s,j:0,d:h,fill:r.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:n,unitDots:a}}_radialArcToFilledSegment(t,e,r,i){const n=t.match(/M\s*(-?[\d.]+)\s+(-?[\d.]+)\s+A\s*(-?[\d.]+)\s+(?:-?[\d.]+)\s+(?:-?[\d.]+)\s+(\d)\s+(\d)\s+(-?[\d.]+)\s+(-?[\d.]+)/);if(!n)return null;const a=parseFloat(n[1]),s=parseFloat(n[2]),l=parseFloat(n[3]),o=parseInt(n[4],10),h=parseInt(n[5],10),u=parseFloat(n[6]),c=parseFloat(n[7]);if(!isFinite(l)||l<=0)return null;const p=e/2,d=l+p,f=Math.max(0,l-p),g=(t,e,n)=>{const a=t-r,s=e-i,l=Math.sqrt(a*a+s*s);if(0===l)return{x:r,y:i};const o=n/l;return{x:r+a*o,y:i+s*o}},y=g(a,s,d),m=g(u,c,d),x=g(a,s,f),b=g(u,c,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,n,a){const s=i/2,l=r+s,o=Math.max(0,r-s),h=(n-90)*Math.PI/180,u=(a-90)*Math.PI/180,c=t+l*Math.cos(h),p=e+l*Math.sin(h),d=t+l*Math.cos(u),f=e+l*Math.sin(u),g=t+o*Math.cos(h),y=e+o*Math.sin(h),m=t+o*Math.cos(u),x=e+o*Math.sin(u),b=a>n?1:0,A=Math.abs(a-n)>180?1:0;return`M ${c} ${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,n){const a=new Map,s=P(r),l=t.slice().sort((t,e)=>t.realIndex-e.realIndex||t.j-e.j);if("partition"===s&&n&&n.length){const t=l.filter(t=>t.key);t.length===l.length&&(t.forEach(t=>{a.set(`key:${t.key}`,{d:t.d,fill:t.fill})}),n.forEach(t=>{a.set(`key:${t.key}`,{d:t.d,fill:t.fill})}))}if("radial"===s||"unit"===s||"partition"===s)return l.forEach((t,e)=>{a.set(`${e}:0`,{d:t.d,fill:t.fill})}),a;if("bar"===s||"summary"===s){const t=[];return(Array.isArray(i)?i:[]).forEach((e,r)=>{const i=e&&Array.isArray(e.data)?e.data:[];for(let e=0;e<i.length;e++)t.push({realIndex:r,j:e})}),l.forEach((e,r)=>{const i=t[r];i&&a.set(`${i.realIndex}:${i.j}`,{d:e.d,fill:e.fill})}),a}return a}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 i=this._snapshot.oldLayout.translateX-(this.w.layout.translateX||0),n=this._snapshot.oldLayout.translateY-(this.w.layout.translateY||0);return 0===i&&0===n?r.d:this._translatePathD(r.d,i,n)}_translatePathD(t,e,r){if(0===e&&0===r)return t;return d(t).map(t=>{const i=t[0];return"Z"===i?"Z":"M"===i||"L"===i||"T"===i?`${i} ${t[1]+e} ${t[2]+r}`:"H"===i?`${i} ${t[1]+e}`:"V"===i?`${i} ${t[1]+r}`:"C"===i?`${i} ${t[1]+e} ${t[2]+r} ${t[3]+e} ${t[4]+r} ${t[5]+e} ${t[6]+r}`:"S"===i||"Q"===i?`${i} ${t[1]+e} ${t[2]+r} ${t[3]+e} ${t[4]+r}`:"A"===i?`${i} ${t[1]} ${t[2]} ${t[3]} ${t[4]} ${t[5]} ${t[6]+e} ${t[7]+r}`: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 n=i.x+i.width/2,a=i.y+i.height/2;if(!(r>1&&e>=0))return{x:n,y:a};const s=(Math.min(e,r-1)+.5)/r;return i.height>=i.width?{x:n,y:i.y+i.height*(1-s)}:{x:i.x+i.width*s,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 i=this._snapshot.oldLayout.translateX-(this.w.layout.translateX||0),n=this._snapshot.oldLayout.translateY-(this.w.layout.translateY||0);return{x:r.minX+i,y:r.minY+n,width:r.maxX-r.minX,height:r.maxY-r.minY}}_pathBBox(t){const e=d(t);let r=1/0,i=1/0,n=-1/0,a=-1/0,s=!1;return e.forEach(t=>{const e=t[0];if("Z"===e)return;let l=[];if("H"===e)l=[[t[1],(i+a)/2||t[1]]];else if("V"===e)l=[[(r+n)/2||t[1],t[1]]];else if("A"===e)l=[[t[6],t[7]]];else for(let e=1;e+1<t.length;e+=2)l.push([t[e],t[e+1]]);l.forEach(([t,e])=>{isFinite(t)&&isFinite(e)&&(s=!0,t<r&&(r=t),t>n&&(n=t),e<i&&(i=e),e>a&&(a=e))})}),s?{minX:r,minY:i,maxX:n,maxY:a}:null}getInitialFillFor(t,e){if(!this._snapshot)return null;const r=this._snapshot.mapping.get(`${t}:${e}`);return r?r.fill:null}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;const e=null==(t=this.w.globals.dom)?void 0:t.baseEl;if(!e)return;this._snapshot.pieceOut?this._separatePieces():this._snapshot.pieceIn?this._combinePieces():this._mountGhost();const r=this.getSpeed();[".apexcharts-xaxis",".apexcharts-yaxis",".apexcharts-grid",".apexcharts-gridlines-horizontal",".apexcharts-gridlines-vertical",".apexcharts-legend",".apexcharts-title-text",".apexcharts-subtitle-text"].forEach(t=>{e.querySelectorAll(t).forEach(t=>{t.style&&(t.style.opacity="0",t.style.transition=`opacity ${r}ms ease-out`,h.requestAnimationFrame(()=>{t.style.opacity="1"}),setTimeout(()=>{t.style.transition="",t.style.opacity=""},r+80))})}),setTimeout(()=>this.cleanup(),r+100)}cleanup(){this._snapshot=null,this._removeGhost(),this._cancelPieces()}}}),t.default=l,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
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 f(e,t){const n=null!=e,i=null!=t;return n||i?{min:n?e:null,max:i?t:null}:null}function p(e){return Array.isArray(e)?e.map(e=>Array.isArray(e)?e.slice():e):[]}function y(e,t){return"function"==typeof e&&t?e===t.addXaxisAnnotation?"xaxis":e===t.addYaxisAnnotation?"yaxis":e===t.addPointAnnotation?"point":null:null}function m(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=y(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,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=p(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 K=R;let D=!1;const P=new Set;function E(){D=!0,j()}const C=new Set(["premium","enterprise"]);function I(e,t){const n=K.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=K.node(t);e&&(i.disconnect(),K.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 L(e,t){e._wmWrapObserver&&(e._wmWrapObserver.disconnect(),e._wmWrapObserver=null),e._wmNodeObserver&&(e._wmNodeObserver.disconnect(),e._wmNodeObserver=null),e._wmObservedNode=null;const n=t||e.w&&e.w.dom&&e.w.dom.elWrap;n&&K.remove(n,{manage:!1})}function M(e,t){try{if(!h.isBrowser())return;if(e&&e.globals&&e.globals.isDestroyed)return void P.delete(t);const n=e&&e.dom&&e.dom.elWrap;if(!n)return;const i=function(e,t){const n=e&&e.config&&e.config.chart||{},i=[];"unit"===n.type&&i.push("unit"),"raincloud"===n.requestedType&&i.push("raincloud"),t.trellis&&"function"==typeof t.trellis.isActive&&t.trellis.isActive()&&i.push("trellis"),t.storyboard&&t.storyboard._used&&i.push("storyboard");const s=n.link;return t.linkedViews&&s&&(!0===s.enabled||"function"==typeof s.dimension)&&i.push("link"),t.ink&&n.ink&&!0===n.ink.enabled&&i.push("ink"),t.measure&&n.measure&&!0===n.measure.enabled&&i.push("measure"),t.contextMenu&&n.contextMenu&&!0===n.contextMenu.enabled&&i.push("context-menu"),t.perspectives&&(t.perspectives._used||D)&&i.push("perspectives"),t.history&&n.history&&!0===n.history.enabled&&i.push("history"),i}(e,t);if(0===i.length)return P.delete(t),void L(t,n);P.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&&C.has(n.toLowerCase())}(s))return void L(t,n);!function(e,t){if(I(e,t),"undefined"==typeof MutationObserver||e._wmWrapObserver)return;const n=new MutationObserver(()=>{K.node(t)||I(e,t)});n.observe(t,{childList:!0}),e._wmWrapObserver=n}(t,n),function(e,t,n){if(e._premiumLicenseNotified)return;if(e._premiumLicenseNotified=!0,n.length,!t)return;const i=T.validateKey(t);if(i.valid)return void(i.data&&i.data.plan);T.getKey()}(t,s,i)}catch(e){}}function j(){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(P).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):P.delete(t)})}T.onChange(j);const N="apex";function U(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 W(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 ${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=>f(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:f(s.min,s.max),yaxis:a?r:null},zoomed:!!e.interact.zoomed,collapsed:(e.globals.collapsedSeriesIndices||[]).slice(),ancillaryCollapsed:(e.globals.ancillaryCollapsedSeriesIndices||[]).slice(),selectedDataPoints:p(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:m(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 U(JSON.stringify(t))}decode(e){return $.decode(e)}toURL(){if(!h.isBrowser())return"";const e=this.encode(this.capture()),t=new URL(window.location.href);return t.hash=`${N}=${e}`,t.toString()}apply(e,t={}){const n="string"==typeof e?$.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(W(e));return t&&"object"==typeof t?1!==t.v?null:t:null}catch(e){return 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]===N);return i&&null!=i[1]?$.decode(decodeURIComponent(i[1])):null}catch(e){return null}}}d.default.registerFeatures({perspectives:$}),d.default.perspectives={decode:e=>(E(),$.decode(e)),fromURL:e=>(E(),$.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 v7.
|
|
41
|
+
* ApexCharts v7.4.0
|
|
42
42
|
* (c) 2018-2026 ApexCharts
|
|
43
43
|
*/
|
|
44
44
|
import * as ApexCharts from "apexcharts/core";
|
|
@@ -344,14 +344,14 @@ const l = class {
|
|
|
344
344
|
const t2 = __spreadProps(__spreadValues({}, n2), { signatureVerified: true });
|
|
345
345
|
return void (this.licenseKey === e2 ? this.publish(t2) : this.notify(t2));
|
|
346
346
|
}
|
|
347
|
-
const
|
|
348
|
-
this.licenseKey === e2 ? this.publish(
|
|
347
|
+
const u = "Invalid license key. The license signature does not verify.", h = { data: i2.data, expired: false, message: u, signatureVerified: true, valid: false };
|
|
348
|
+
this.licenseKey === e2 ? this.publish(h) : this.notify(h), t(`[Apex] ${u}`);
|
|
349
349
|
});
|
|
350
350
|
}
|
|
351
351
|
};
|
|
352
352
|
l.publicKeysSpki = ["MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEQIaK9UMD6n0oR/FIy8QdL0uSzKMQlf1BB+tOrji4/WuHsyRNxeDhVykoSsNURozMi1xhmqWvBH1L//xIfugTPA=="], l.verdicts = /* @__PURE__ */ new Map(), l.verifying = /* @__PURE__ */ new Set(), l.warnedUnverifiable = false, l.epoch = 0;
|
|
353
353
|
let o = l;
|
|
354
|
-
const
|
|
354
|
+
const j = class {
|
|
355
355
|
static applyStyles(e2) {
|
|
356
356
|
Object.assign(e2.style, this.CRITICAL_STYLES, { backgroundImage: this.createWatermarkPattern(), backgroundRepeat: "repeat" });
|
|
357
357
|
}
|
|
@@ -409,8 +409,8 @@ const A = class {
|
|
|
409
409
|
})));
|
|
410
410
|
}
|
|
411
411
|
};
|
|
412
|
-
|
|
413
|
-
let
|
|
412
|
+
j.WATERMARK_ATTR = "data-apexcharts-watermark", j.WATERMARK_TEXT = "APEXCHARTS", j.ATTR = "data-apexcharts-watermark", j.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" }, j.managed = /* @__PURE__ */ new Set(), j.subscribed = false;
|
|
413
|
+
let C = j;
|
|
414
414
|
const PRICING_URL = "https://apexcharts.com/pricing";
|
|
415
415
|
let _perspectivesTokenDecoded = false;
|
|
416
416
|
const enforced = /* @__PURE__ */ new Set();
|
|
@@ -464,15 +464,15 @@ function licensedForPremium(key) {
|
|
|
464
464
|
return typeof plan === "string" && PREMIUM_PLANS.has(plan.toLowerCase());
|
|
465
465
|
}
|
|
466
466
|
function reinstateWatermark(ctx, elWrap) {
|
|
467
|
-
const node =
|
|
467
|
+
const node = C.add(elWrap, { manage: false });
|
|
468
468
|
if (!node || typeof MutationObserver === "undefined") return;
|
|
469
469
|
if (ctx._wmNodeObserver && ctx._wmObservedNode === node) return;
|
|
470
470
|
if (ctx._wmNodeObserver) ctx._wmNodeObserver.disconnect();
|
|
471
471
|
const nodeObs = new MutationObserver(() => {
|
|
472
|
-
const n2 =
|
|
472
|
+
const n2 = C.node(elWrap);
|
|
473
473
|
if (!n2) return;
|
|
474
474
|
nodeObs.disconnect();
|
|
475
|
-
|
|
475
|
+
C.applyStyles(n2);
|
|
476
476
|
nodeObs.takeRecords();
|
|
477
477
|
nodeObs.observe(n2, { attributes: true, attributeFilter: ["style"] });
|
|
478
478
|
});
|
|
@@ -484,7 +484,7 @@ function addWatermark(ctx, elWrap) {
|
|
|
484
484
|
reinstateWatermark(ctx, elWrap);
|
|
485
485
|
if (typeof MutationObserver === "undefined" || ctx._wmWrapObserver) return;
|
|
486
486
|
const wrapObs = new MutationObserver(() => {
|
|
487
|
-
if (!
|
|
487
|
+
if (!C.node(elWrap)) reinstateWatermark(ctx, elWrap);
|
|
488
488
|
});
|
|
489
489
|
wrapObs.observe(elWrap, { childList: true });
|
|
490
490
|
ctx._wmWrapObserver = wrapObs;
|
|
@@ -500,7 +500,7 @@ function teardownWatermark(ctx, elWrap) {
|
|
|
500
500
|
}
|
|
501
501
|
ctx._wmObservedNode = null;
|
|
502
502
|
const wrap = elWrap || ctx.w && ctx.w.dom && ctx.w.dom.elWrap;
|
|
503
|
-
if (wrap)
|
|
503
|
+
if (wrap) C.remove(wrap, { manage: false });
|
|
504
504
|
}
|
|
505
505
|
function notifyTrial(ctx, key, features) {
|
|
506
506
|
if (ctx._premiumLicenseNotified) return;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t((e="undefined"!=typeof globalThis?globalThis:e||self).ApexPerspectives={})}(this,function(e){"use strict";var t=Object.defineProperty,n=Object.defineProperties,i=Object.getOwnPropertyDescriptors,s=Object.getOwnPropertySymbols,r=Object.prototype.hasOwnProperty,a=Object.prototype.propertyIsEnumerable,o=(e,n,i)=>n in e?t(e,n,{enumerable:!0,configurable:!0,writable:!0,value:i}):e[n]=i,l=(e,t)=>{for(var n in t||(t={}))r.call(t,n)&&o(e,n,t[n]);if(s)for(var n of s(t))a.call(t,n)&&o(e,n,t[n]);return e},c=(e,t)=>n(e,i(t));const d=globalThis.ApexCharts,u=globalThis.ApexCharts.__internals.__apex_Utils,h=globalThis.ApexCharts.__internals.__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 k(){const e=globalThis;let t=e[S];return t||(t={key:null,listeners:new Set,result:null},e[S]=t),t}const T=class{static get licenseKey(){return k().key}static set licenseKey(e){k().key=e}static get listeners(){return k().listeners}static get validationResult(){return k().result}static set validationResult(e){k().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),c(l({},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 o=!1;for(const e of this.publicKeysSpki){try{const n=yield r.importKey("spki",this.base64ToBytes(e),{name:"ECDSA",namedCurve:"P-256"},!1,["verify"]);o=yield r.verify({hash:"SHA-256",name:"ECDSA"},n,this.base64ToBytes(t.signature),a)}catch(e){o=!1}if(o)break}if(this.verifying.delete(e),this.epoch!==s)return;if(this.verdicts.set(e,o),o){const t=c(l({},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}};T.publicKeysSpki=["MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEQIaK9UMD6n0oR/FIy8QdL0uSzKMQlf1BB+tOrji4/WuHsyRNxeDhVykoSsNURozMi1xhmqWvBH1L//xIfugTPA=="],T.verdicts=new Map,T.verifying=new Set,T.warnedUnverifiable=!1,T.epoch=0;let O=T;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=O.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,O.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 C=R;const K="https://apexcharts.com/pricing";let P=!1;const D=new Set;function E(){P=!0,j()}const $=new Set(["premium","enterprise"]);function I(e,t){const n=C.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=C.node(t);e&&(i.disconnect(),C.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 L(e,t){e._wmWrapObserver&&(e._wmWrapObserver.disconnect(),e._wmWrapObserver=null),e._wmNodeObserver&&(e._wmNodeObserver.disconnect(),e._wmNodeObserver=null),e._wmObservedNode=null;const n=t||e.w&&e.w.dom&&e.w.dom.elWrap;n&&C.remove(n,{manage:!1})}function M(e,t){try{if(!h.isBrowser())return;if(e&&e.globals&&e.globals.isDestroyed)return void D.delete(t);const n=e&&e.dom&&e.dom.elWrap;if(!n)return;const i=function(e,t){const n=e&&e.config&&e.config.chart||{},i=[];"unit"===n.type&&i.push("unit"),"raincloud"===n.requestedType&&i.push("raincloud"),t.trellis&&"function"==typeof t.trellis.isActive&&t.trellis.isActive()&&i.push("trellis"),t.storyboard&&t.storyboard._used&&i.push("storyboard");const s=n.link;return t.linkedViews&&s&&(!0===s.enabled||"function"==typeof s.dimension)&&i.push("link"),t.ink&&n.ink&&!0===n.ink.enabled&&i.push("ink"),t.measure&&n.measure&&!0===n.measure.enabled&&i.push("measure"),t.contextMenu&&n.contextMenu&&!0===n.contextMenu.enabled&&i.push("context-menu"),t.perspectives&&(t.perspectives._used||P)&&i.push("perspectives"),t.history&&n.history&&!0===n.history.enabled&&i.push("history"),i}(e,t);if(0===i.length)return D.delete(t),void L(t,n);D.add(t);const s=function(e){const t=e&&e.config&&e.config.chart&&e.config.chart.license;if(t)return t;const n=O.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=O.validateKey(e);if(!t.valid)return!1;const n=t.data&&t.data.plan;return"string"==typeof n&&$.has(n.toLowerCase())}(s))return void L(t,n);!function(e,t){if(I(e,t),"undefined"==typeof MutationObserver||e._wmWrapObserver)return;const n=new MutationObserver(()=>{C.node(t)||I(e,t)});n.observe(t,{childList:!0}),e._wmWrapObserver=n}(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=O.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!==O.getKey()&&console.error(`[Apex] ${s.message}`)}(t,s,i)}catch(e){}}function j(){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(D).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):D.delete(t)})}O.onChange(j);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 W(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 B{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 B.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?B.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(W(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]?B.decode(decodeURIComponent(i[1])):null}catch(e){return null}}}d.registerFeatures({perspectives:B}),d.perspectives={decode:e=>(E(),B.decode(e)),fromURL:e=>(E(),B.fromURL(e))},e.default=d,Object.defineProperties(e,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
"use strict";var t=Object.defineProperty,r=Object.defineProperties,e=Object.getOwnPropertyDescriptors,n=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable,s=(r,e,n)=>e in r?t(r,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[e]=n,l=(t,r)=>{for(var e in r||(r={}))o.call(r,e)&&s(t,e,r[e]);if(n)for(var e of n(r))i.call(r,e)&&s(t,e,r[e]);return t},a=(t,n)=>r(t,e(n));Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function u(t){if(t&&t.__esModule)return t;const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const e in t)if("default"!==e){const n=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,n.get?n:{enumerable:!0,get:()=>t[e]})}return r.default=t,Object.freeze(r)}const c=u(require("apexcharts/core")),y="__apexcharts_series_transforms__";globalThis[y]||(globalThis[y]={});const f=c.__apex_Utils;function d(t,r){const e=t.length;if(0===e)return NaN;if(1===e)return t[0];const n=(e-1)*r,o=Math.floor(n),i=Math.ceil(n);return o===i?t[o]:t[o]+(t[i]-t[o])*(n-o)}function h(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=d(e,.25),o=d(e,.5),i=d(e,.75),s=i-n;let l=e[0],a=e[e.length-1],u=[];if("tukey"===r.whiskers&&s>0){const t=n-1.5*s,r=i+1.5*s;let o=0;for(;o<e.length&&e[o]<t;)o++;let c=e.length-1;for(;c>=0&&e[c]>r;)c--;o<=c&&(l=e[o],a=e[c],u=e.slice(0,o).concat(e.slice(c+1)))}return{summary:[l,n,o,i,a],outliers:u,iqr:s}}function p(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=e.length;let o=r.bandwidth;if(!("number"==typeof o&&o>0)){const t=function(t){const r=t.length;if(r<2)return 0;let e=0;for(let n=0;n<r;n++)e+=t[n];const n=e/r;let o=0;for(let e=0;e<r;e++){const r=t[e]-n;o+=r*r}return Math.sqrt(o/r)}(e),r=d(e,.75)-d(e,.25);o=.9*(r>0?Math.min(t,r/1.349):t)*Math.pow(n,-.2)}if(!isFinite(o)||o<=0){const t=e[0],r=Math.abs(t)>0?.001*Math.abs(t):.001;return{density:[[t-r,0],[t,1],[t+r,0]],bandwidth:r}}const i=Math.max(8,Math.floor(r.resolution||64)),s=e[0]-2*o,l=(e[n-1]+2*o-s)/(i-1),a=1/(n*o*Math.sqrt(2*Math.PI)),u=[];for(let t=0;t<i;t++){const r=s+t*l;let i=0;for(let t=0;t<n;t++){const n=(r-e[t])/o;i+=Math.exp(-.5*n*n)}u.push([r,i*a])}return{density:u,bandwidth:o}}function b(t,r){var e;if(!t||"object"!=typeof t||Array.isArray(t))return null;let n=null;if(Array.isArray(t.points)?n=t.points:Array.isArray(null==(e=t.y)?void 0:e.points)?n=t.y.points:r&&Array.isArray(t.y)&&"number"==typeof t.y[0]&&(n=t.y),!n)return null;const o=[];for(let t=0;t<n.length;t++){const r=f.parseNumber(n[t]);null!==r&&isFinite(r)&&o.push(r)}return o.length?o:null}const m=new WeakSet,g=new WeakSet;function v(t,r){var e,n;if(!Array.isArray(t))return t;const o=(null==(e=r.config.plotOptions)?void 0:e.violin)||{},i=o.kde||{},s=(null==(n=o.box)?void 0:n.whiskers)||"minmax";return t.map(t=>{if(!Array.isArray(null==t?void 0:t.data))return t;let r=!1;const e=t.data.map(t=>{var e,n;const o=Array.isArray(null==(e=null==t?void 0:t.y)?void 0:e.density)&&t.y.density.length>0,u=Array.isArray(null==(n=null==t?void 0:t.y)?void 0:n.summary)&&5===t.y.summary.length;if(o&&!m.has(t)){if(u&&!g.has(t))return t;const e=b(t,!1);if(!e)return t;const n=h(e,{whiskers:s});if(!n)return t;r=!0;const o=a(l({},t),{y:a(l({},t.y),{summary:n.summary})});return g.add(o),o}const c=b(t,!0);if(!c)return t;const y=p(c,{bandwidth:i.bandwidth,resolution:i.resolution});if(!y)return t;const f=h(c,{whiskers:s});r=!0;const d=a(l({},t),{y:l({density:y.density,points:c},f?{summary:f.summary}:{})});return m.add(d),d});return r?a(l({},t),{data:e}):t})}var A,w;A="raincloud","function"==typeof(w=v)&&(globalThis[y][A]=w),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>c.default}),exports.raincloudTransform=v;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
!function(t,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r((t="undefined"!=typeof globalThis?globalThis:t||self).ApexRaincloud={})}(this,function(t){"use strict";var r=Object.defineProperty,e=Object.defineProperties,n=Object.getOwnPropertyDescriptors,o=Object.getOwnPropertySymbols,s=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable,a=(t,e,n)=>e in t?r(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,l=(t,r)=>{for(var e in r||(r={}))s.call(r,e)&&a(t,e,r[e]);if(o)for(var e of o(r))i.call(r,e)&&a(t,e,r[e]);return t},u=(t,r)=>e(t,n(r));const c=globalThis.ApexCharts,f="__apexcharts_series_transforms__";globalThis[f]||(globalThis[f]={});const y=globalThis.ApexCharts.__internals.__apex_Utils;function d(t,r){const e=t.length;if(0===e)return NaN;if(1===e)return t[0];const n=(e-1)*r,o=Math.floor(n),s=Math.ceil(n);return o===s?t[o]:t[o]+(t[s]-t[o])*(n-o)}function h(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=d(e,.25),o=d(e,.5),s=d(e,.75),i=s-n;let a=e[0],l=e[e.length-1],u=[];if("tukey"===r.whiskers&&i>0){const t=n-1.5*i,r=s+1.5*i;let o=0;for(;o<e.length&&e[o]<t;)o++;let c=e.length-1;for(;c>=0&&e[c]>r;)c--;o<=c&&(a=e[o],l=e[c],u=e.slice(0,o).concat(e.slice(c+1)))}return{summary:[a,n,o,s,l],outliers:u,iqr:i}}function p(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=e.length;let o=r.bandwidth;if(!("number"==typeof o&&o>0)){const t=function(t){const r=t.length;if(r<2)return 0;let e=0;for(let n=0;n<r;n++)e+=t[n];const n=e/r;let o=0;for(let e=0;e<r;e++){const r=t[e]-n;o+=r*r}return Math.sqrt(o/r)}(e),r=d(e,.75)-d(e,.25);o=.9*(r>0?Math.min(t,r/1.349):t)*Math.pow(n,-.2)}if(!isFinite(o)||o<=0){const t=e[0],r=Math.abs(t)>0?.001*Math.abs(t):.001;return{density:[[t-r,0],[t,1],[t+r,0]],bandwidth:r}}const s=Math.max(8,Math.floor(r.resolution||64)),i=e[0]-2*o,a=(e[n-1]+2*o-i)/(s-1),l=1/(n*o*Math.sqrt(2*Math.PI)),u=[];for(let t=0;t<s;t++){const r=i+t*a;let s=0;for(let t=0;t<n;t++){const n=(r-e[t])/o;s+=Math.exp(-.5*n*n)}u.push([r,s*l])}return{density:u,bandwidth:o}}function b(t,r){var e;if(!t||"object"!=typeof t||Array.isArray(t))return null;let n=null;if(Array.isArray(t.points)?n=t.points:Array.isArray(null==(e=t.y)?void 0:e.points)?n=t.y.points:r&&Array.isArray(t.y)&&"number"==typeof t.y[0]&&(n=t.y),!n)return null;const o=[];for(let t=0;t<n.length;t++){const r=y.parseNumber(n[t]);null!==r&&isFinite(r)&&o.push(r)}return o.length?o:null}const m=new WeakSet,g=new WeakSet;function A(t,r){var e,n;if(!Array.isArray(t))return t;const o=(null==(e=r.config.plotOptions)?void 0:e.violin)||{},s=o.kde||{},i=(null==(n=o.box)?void 0:n.whiskers)||"minmax";return t.map(t=>{if(!Array.isArray(null==t?void 0:t.data))return t;let r=!1;const e=t.data.map(t=>{var e,n;const o=Array.isArray(null==(e=null==t?void 0:t.y)?void 0:e.density)&&t.y.density.length>0,a=Array.isArray(null==(n=null==t?void 0:t.y)?void 0:n.summary)&&5===t.y.summary.length;if(o&&!m.has(t)){if(a&&!g.has(t))return t;const e=b(t,!1);if(!e)return t;const n=h(e,{whiskers:i});if(!n)return t;r=!0;const o=u(l({},t),{y:u(l({},t.y),{summary:n.summary})});return g.add(o),o}const c=b(t,!0);if(!c)return t;const f=p(c,{bandwidth:s.bandwidth,resolution:s.resolution});if(!f)return t;const y=h(c,{whiskers:i});r=!0;const d=u(l({},t),{y:l({density:f.density,points:c},y?{summary:y.summary}:{})});return m.add(d),d});return r?u(l({},t),{data:e}):t})}var v,w;v="raincloud","function"==typeof(w=A)?globalThis[f][v]=w:console.warn(`ApexCharts: registerSeriesTransform("${v}") expects a function (series, w) => series.`),t.default=c,t.raincloudTransform=A,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function t(t){if(t&&t.__esModule)return t;const s=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const e in t)if("default"!==e){const i=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(s,e,i.get?i:{enumerable:!0,get:()=>t[e]})}return s.default=t,Object.freeze(s)}const s=t(require("apexcharts/core")),e=s.__apex_Graphics,i={fill:"fill",stroke:"stroke","stroke-width":"strokeWidth","stroke-dasharray":"strokeDash","stroke-linecap":"lineCap","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","fill-rule":"fillRule"},r=Symbol("never"),l={circle:0,square:1,rect:1,triangle:2,diamond:3,star:4,sparkle:5,cross:6,plus:7,line:8},a=["circle","square","triangle","diamond","star","sparkle","cross","plus","line"],n={attr:()=>n,plot:()=>n,during:()=>n,after:t=>("function"==typeof t&&t(),n),animate:()=>n,delay:()=>n,loop:()=>n,finish:()=>n,stop:()=>n},h={nodeName:"path",style:{},classList:{add(){},remove(){},toggle(){},contains:()=>!1},setAttribute(){},getAttribute:()=>null,removeAttribute(){},hasAttribute:()=>!1,addEventListener(){},removeEventListener(){},appendChild(){},getBBox:()=>({x:0,y:0,width:0,height:0})},o={__isCanvasMark:!0,node:{nodeName:"g",instance:null,style:{},classList:{add(){},remove(){},toggle(){},contains:()=>!1},setAttribute(){},getAttribute:()=>null,removeAttribute(){},addEventListener(){},removeEventListener(){},appendChild(){},getBBox:()=>({x:0,y:0,width:0,height:0})},attr:()=>o,add:()=>o,addTo:()=>o,remove:()=>o,clear:()=>o,css:()=>o,hide:()=>o,show:()=>o,removeClass:()=>o,animate:()=>n};class c{constructor(t,s){this.__isCanvasMark=!0,this._g=t,this._i=s}get node(){return h}attr(t,s){return"string"==typeof t?("fill"===t&&void 0!==s&&this._g._setMarkerFill(this._i,s),void 0===s?null:this):(t&&void 0!==t.fill&&this._g._setMarkerFill(this._i,t.fill),this)}add(t){return this}addTo(t){return this}remove(){return this}css(t){return this}fill(t){return void 0!==t&&this._g._setMarkerFill(this._i,t),this}stroke(t){return this}hide(){return this}show(){return this}removeClass(t){return this}animate(){return n}}const _={__isCanvasMark:!0,node:h,attr:()=>_,add:()=>_,addTo:()=>_,remove:()=>_,css:()=>_,animate:()=>n};class d{constructor(t){this.__isCanvasMark=!0,this._cmd=t;const s=this;this.node={nodeName:t?t.tag:"g",instance:this,style:{},classList:{add(){},remove(){},toggle(){},contains:()=>!1},setAttribute(t,e){s._applyAttr(t,e)},getAttribute:()=>null,removeAttribute(){},hasAttribute:()=>!1,addEventListener(){},removeEventListener(){},appendChild(){},getBBox:()=>({x:0,y:0,width:0,height:0})}}_applyAttr(t,s){const e=this._cmd;if(!e)return;const r=i[t];void 0!==r&&(e[r]=s)}attr(t,s){if("string"==typeof t)return void 0===s?null:(this._applyAttr(t,s),this);for(const s in t)void 0!==t[s]&&this._applyAttr(s,t[s]);return this}add(t){return this}addTo(t){return this}remove(){return this}clear(){return this}css(t){return this}fill(t){return"object"==typeof t?this.attr(t):this.attr("fill",t)}stroke(t){return"object"==typeof t?(void 0!==t.color&&this.attr("stroke",t.color),void 0!==t.width&&this.attr("stroke-width",t.width),this):this.attr("stroke",t)}plot(t){return"string"==typeof t&&this._cmd&&"path"===this._cmd.tag&&(this._cmd.d=t),this}hide(){return this}show(){return this}removeClass(t){return this}bbox(){return{x:0,y:0,width:0,height:0}}animate(){return n}}class u{constructor(t){this.w=t,this._g=new e(t),this._list=[],this._mx=new Float64Array(16),this._my=new Float64Array(16),this._msize=new Float64Array(16),this._mshape=new Int16Array(16),this._mstyle=new Int32Array(16),this._msi=new Int32Array(16),this._mn=0,this._mcap=16,this._crx=new Float64Array(16),this._cry=new Float64Array(16),this._crw=new Float64Array(16),this._crh=new Float64Array(16),this._crstyle=new Int32Array(16),this._crsi=new Int32Array(16),this._crdi=new Int32Array(16),this._crn=0,this._crcap=16,this._cellRadius=0,this._styles=[],this._styleMap=new Map,this._lf=r,this._ls=r,this._lsw=r,this._ld=r,this._lfo=r,this._lso=r,this._lid=-1,this._lofFill=r,this._lofBase=-1,this._lofId=-1,this._rlf=r,this._rls=r,this._rlsw=r,this._rlfo=r,this._rlso=r,this._rlid=-1}_resetStyleCache(){this._lf=r,this._ls=r,this._lsw=r,this._ld=r,this._lfo=r,this._lso=r,this._lid=-1,this._lofFill=r,this._lofBase=-1,this._lofId=-1,this._rlf=r,this._rls=r,this._rlsw=r,this._rlfo=r,this._rlso=r,this._rlid=-1}reset(){this._list=[],this._mn=0,this._styles=[],this._styleMap=new Map,this._resetStyleCache();const t=this.w.config.series||[];let s=16;for(let e=0;e<t.length;e++){const i=t[e]&&t[e].data;Array.isArray(i)&&(s+=i.length)}s=Math.ceil(1.15*s)+16,s>this._mcap&&this._allocMarkers(s),this._crn=0,this._cellRadius=0,s>this._crcap&&this._allocRects(s)}_allocRects(t){this._crcap=t,this._crx=new Float64Array(t),this._cry=new Float64Array(t),this._crw=new Float64Array(t),this._crh=new Float64Array(t),this._crstyle=new Int32Array(t),this._crsi=new Int32Array(t),this._crdi=new Int32Array(t)}_growRects(){const t=2*this._crcap,s=new Float64Array(t);s.set(this._crx),this._crx=s;const e=new Float64Array(t);e.set(this._cry),this._cry=e;const i=new Float64Array(t);i.set(this._crw),this._crw=i;const r=new Float64Array(t);r.set(this._crh),this._crh=r;const l=new Int32Array(t);l.set(this._crstyle),this._crstyle=l;const a=new Int32Array(t);a.set(this._crsi),this._crsi=a;const n=new Int32Array(t);n.set(this._crdi),this._crdi=n,this._crcap=t}_allocMarkers(t){this._mcap=t,this._mx=new Float64Array(t),this._my=new Float64Array(t),this._msize=new Float64Array(t),this._mshape=new Int16Array(t),this._mstyle=new Int32Array(t),this._msi=new Int32Array(t)}_growMarkers(){const t=2*this._mcap,s=new Float64Array(t);s.set(this._mx),this._mx=s;const e=new Float64Array(t);e.set(this._my),this._my=e;const i=new Float64Array(t);i.set(this._msize),this._msize=i;const r=new Int16Array(t);r.set(this._mshape),this._mshape=r;const l=new Int32Array(t);l.set(this._mstyle),this._mstyle=l;const a=new Int32Array(t);a.set(this._msi),this._msi=a,this._mcap=t}displayList(){return this._list}markerCount(){return this._mn}_internStyle(t,s,e,i,r,l){const a=`${t}|${s}|${e}|${i}|${r}|${l}`,n=this._styleMap.get(a);if(void 0!==n)return n;const h=this._styles.length;return this._styles.push({fill:t,stroke:s,strokeWidth:e,strokeDash:i,fillOpacity:r,strokeOpacity:l}),this._styleMap.set(a,h),h}_setMarkerFill(t,s){const e=this._mstyle[t];if(s===this._lofFill&&e===this._lofBase)return void(this._mstyle[t]=this._lofId);const i=this._styles[e];if(!i||i.fill===s)return this._lofFill=s,this._lofBase=e,void(this._lofId=e);const r=this._internStyle(s,i.stroke,i.strokeWidth,i.strokeDash,i.fillOpacity,i.strokeOpacity);this._mstyle[t]=r,this._lofFill=s,this._lofBase=e,this._lofId=r}markerStyle(t){return this._styles[this._mstyle[t]]}markerSeries(t){return this._msi[t]}shapeName(t){return a[t]||"circle"}drawRectCell(t,s,e,i,r={}){const l=this._rectStyleId(r);this._crn>=this._crcap&&this._growRects();const a=this._crn++;return this._crx[a]=t||0,this._cry[a]=s||0,this._crw[a]=e>0?e:0,this._crh[a]=i>0?i:0,this._crstyle[a]=l,this._crsi[a]=null==r.seriesIndex?-1:r.seriesIndex,this._crdi[a]=null==r.dataPointIndex?-1:r.dataPointIndex,r.radius&&(this._cellRadius=r.radius),_}_rectStyleId(t){const s=t.fill,e=t.stroke,i=t.strokeWidth,r=t.fillOpacity,l=t.strokeOpacity;if(s===this._rlf&&e===this._rls&&i===this._rlsw&&r===this._rlfo&&l===this._rlso)return this._rlid;const a=this._internStyle(s,e,i,0,r,l);return this._rlf=s,this._rls=e,this._rlsw=i,this._rlfo=r,this._rlso=l,this._rlid=a,a}rectCount(){return this._crn}rectStyle(t){return this._styles[this._crstyle[t]]}rectSeries(t){return this._crsi[t]}_cmd(t,s){const e={tag:t,z:s||0,fill:void 0,stroke:void 0,strokeWidth:void 0,strokeDash:void 0,lineCap:void 0,fillOpacity:void 0,strokeOpacity:void 0,fillRule:void 0};return this._list.push(e),e}group(t){return o}drawMarker(t,s,e={}){var i;const r=this._markerStyleId(e);this._mn>=this._mcap&&this._growMarkers();const a=this._mn++;return this._mx[a]=t||0,this._my[a]="number"==typeof s?s:NaN,this._msize[a]=e.pSize||0,this._mshape[a]=null!=(i=l[e.shape||"circle"])?i:0,this._mstyle[a]=r,this._msi[a]=null==e.seriesIndex?-1:e.seriesIndex,new c(this,a)}_markerStyleId(t){const s=t.shape||"circle",e="line"===s||"plus"===s||"cross"===s,i=e?"none":t.pointFillColor,r=e?t.pointFillColor:t.pointStrokeColor,l=t.pointStrokeWidth,a=t.pointStrokeDashArray,n=t.pointFillOpacity,h=e?t.pointFillOpacity:t.pointStrokeOpacity;if(i===this._lf&&r===this._ls&&l===this._lsw&&a===this._ld&&n===this._lfo&&h===this._lso)return this._lid;const o=this._internStyle(i,r,l,a,n,h);return this._lf=i,this._ls=r,this._lsw=l,this._ld=a,this._lfo=n,this._lso=h,this._lid=o,o}renderPaths(t){const s=this._cmd("path",t.realIndex);return s.d=t.pathTo,t.pathToNumeric&&(s.nxs=t.pathToNumeric.xs,s.nys=t.pathToNumeric.ys,s.ncloseY=t.pathToNumeric.closeY),s.stroke=t.stroke,s.strokeWidth=t.strokeWidth,s.fill=t.fill,s.lineCap=t.strokeLinecap,s.si=t.realIndex,this.w.globals.animationEnded=!0,new d(s)}drawPath(t){const s=this._cmd("path",0);return s.d=t.d,s.stroke=t.stroke,s.strokeWidth=t.strokeWidth,s.fill=t.fill,s.fillOpacity=t.fillOpacity,s.strokeOpacity=t.strokeOpacity,s.lineCap=t.strokeLinecap,s.strokeDash=t.strokeDashArray,new d(s)}drawLine(t,s,e,i,r="#a8a8a8",l=0,a=1){const n=this._cmd("line",0);return n.lx1=t,n.ly1=s,n.lx2=e,n.ly2=i,n.stroke=r,n.strokeDash=l,n.strokeWidth=a,new d(n)}drawRect(t=0,s=0,e=0,i=0,r=0,l="#fefefe",a=1,n=null,h=null,o=0){const c=this._cmd("rect",0);return c.x1=t,c.y1=s,c.rw=e>0?e:0,c.rh=i>0?i:0,c.radius=r,c.fill=l,c.fillOpacity=a,null!=h&&(c.stroke=h,c.strokeWidth=null==n?1:n,c.strokeDash=o),new d(c)}drawCircle(t,s=null){const e=this._cmd("circle",0);return e.r=t<0?0:t,s&&(e.cx=s.cx,e.cy=s.cy,void 0!==s.fill&&(e.fill=s.fill),void 0!==s.stroke&&(e.stroke=s.stroke)),new d(e)}drawText(t){const s=this._cmd("text",0);return s.text=Array.isArray(t.text)?t.text.join(" "):t.text,s.tx=t.x,s.ty=t.y,s.textAnchor=t.textAnchor||"start",s.fontSize=t.fontSize,s.fontFamily=t.fontFamily,s.fill=t.foreColor,new d(s)}markerPath(t,s,e,i){return this._g.getMarkerPath(t,s,a[e]||"circle",i)}}const p=s.__apex_SVGElement,y=s.__apex_math_SVGNS,f=s.__apex_BrowserAPIs_BrowserAPIs,m=2*Math.PI;class g{constructor(t){this.w=t,this._host=null,this._canvas=null,this._c2d=null,this._margin=0,this._dpr=1,this._dim=null,this._alpha=1,this._unitPaths=new Map,this._markerBatches=0}markerBatchCount(){return this._markerBatches}_seriesAlpha(t){const s=this._dim;return!s||null==s.active||s.active<0||null==t||t<0||t===s.active?1:null==s.opacity?.2:s.opacity}_plotDims(){var t;const s=Math.max(0,Math.ceil(this.w.layout.gridWidth||0)),e=Math.max(0,Math.ceil(this.w.layout.gridHeight||0)),i=(null==(t=this.w.globals.markers)?void 0:t.largestSize)||0;return{gw:s,gh:e,margin:Math.ceil(i+8)}}createHost(){const t=f.getWindow();this._dpr=Math.min(2,t&&t.devicePixelRatio||1);const{gw:s,gh:e,margin:i}=this._plotDims();this._margin=i;const r=s+2*i,l=e+2*i,a=f.createElementNS(y,"foreignObject");a.setAttribute("x",String(-i)),a.setAttribute("y",String(-i)),a.setAttribute("width",String(r)),a.setAttribute("height",String(l)),a.setAttribute("class","apexcharts-canvas-series"),a.style.overflow="visible";const n=f.createElement("canvas");return n.setAttribute("class","apexcharts-series-canvas"),n.width=Math.max(1,Math.round(r*this._dpr)),n.height=Math.max(1,Math.round(l*this._dpr)),n.style.width=r+"px",n.style.height=l+"px",n.style.pointerEvents="none",a.appendChild(n),this._canvas=n,this._c2d=n.getContext("2d"),this._host=new p(a),this._host}getHost(){return this._host}clear(){this._c2d&&this._canvas&&(this._c2d.setTransform(1,0,0,1,0,0),this._c2d.clearRect(0,0,this._canvas.width,this._canvas.height))}_syncDpr(){if(!this._canvas)return;const t=f.getWindow(),s=Math.min(2,t&&t.devicePixelRatio||1);if(s===this._dpr)return;this._dpr=s;const e=parseFloat(this._canvas.style.width)||0,i=parseFloat(this._canvas.style.height)||0;this._canvas.width=Math.max(1,Math.round(e*s)),this._canvas.height=Math.max(1,Math.round(i*s))}paint(t,s,e=null){const i=this._c2d;if(!i)return;this._dim=e||null,this._syncDpr(),this.clear();const r=this._dpr,l=this._margin;if(i.setTransform(r,0,0,r,l*r,l*r),t.length){const s=t.length>1?t.map((t,s)=>[t,s]).sort((t,s)=>t[0].z===s[0].z?t[1]-s[1]:t[0].z-s[0].z).map(t=>t[0]):t;for(let t=0;t<s.length;t++){const e=s[t];this._alpha=this._dim?this._seriesAlpha(e.si):1,this._paintOne(i,e)}}this._paintRects(i,s),this._paintMarkers(i,s),this._alpha=1}_paintRects(t,s){const e=s.rectCount?s.rectCount():0;if(!e)return;const i=s._crx,r=s._cry,l=s._crw,a=s._crh,n=s._crstyle,h=s._cellRadius||0,o=t,c=h>0&&"function"==typeof o.roundRect,_=!!this._dim,d=Math.max(0,this.w.layout.gridWidth||0),u=Math.max(0,this.w.layout.gridHeight||0);t.save(),t.beginPath(),t.rect(0,0,d,u),t.clip();let p=0;for(;p<e;){const d=n[p],u=s.rectStyle(p);if(!u){p++;continue}const y=u.fill,f=y&&"none"!==y&&!("string"==typeof y&&0===y.indexOf("url(")),m=u.stroke,g=null==u.strokeWidth?0:Number(u.strokeWidth),w=m&&"none"!==m&&g>0&&!("string"==typeof m&&0===m.indexOf("url("));f&&(t.fillStyle=y),w&&(t.strokeStyle=m,t.lineWidth=g,t.setLineDash([]));const k=null==u.fillOpacity?1:Number(u.fillOpacity),A=null==u.strokeOpacity?1:Number(u.strokeOpacity);let x=p;for(;x<e&&n[x]===d;){const e=l[x],n=a[x];if(e>0&&n>0){const l=_?this._seriesAlpha(s.rectSeries(x)):1;c?(t.beginPath(),o.roundRect(i[x],r[x],e,n,h),f&&(t.globalAlpha=k*l,t.fill()),w&&(t.globalAlpha=A*l,t.stroke())):(f&&(t.globalAlpha=k*l,t.fillRect(i[x],r[x],e,n)),w&&(t.globalAlpha=A*l,t.strokeRect(i[x],r[x],e,n)))}x++}p=x}t.globalAlpha=1,t.restore()}_unitPath(t,s,e){const i=s+"|"+e;let r=this._unitPaths.get(i);if(void 0===r){try{r=new Path2D(t.markerPath(0,0,s,e))}catch(t){r=null}this._unitPaths.set(i,r)}return r}_paintMarkers(t,s){this._markerBatches=0;const e=s.markerCount();if(!e)return;const i=s._mx,r=s._my,l=s._msize,a=s._mshape,n=s._mstyle,h=!!this._dim;h||(this._alpha=1);let o=0;for(;o<e;){const c=n[o],_=a[o],d=s.markerStyle(o);if(!d){o++;continue}const u=this._applyFill(t,d),p=this._applyStroke(t,d);this._markerBatches++;const y=null==d.fillOpacity?1:Number(d.fillOpacity),f=null==d.strokeOpacity?1:Number(d.strokeOpacity);if(0===_){let _=o;for(;_<e&&0===a[_]&&n[_]===c;){const e=l[_]||0,a=r[_];if(e>0&&a==a)if(t.beginPath(),t.arc(i[_],a,e,0,m),h){const e=this._seriesAlpha(s.markerSeries(_));u&&(t.globalAlpha=y*e,t.fill()),p&&(t.globalAlpha=f*e,t.stroke())}else u&&t.fill(),p&&t.stroke();_++}t.globalAlpha=1,o=_}else{const d=this._dpr,m=this._margin;let g=o;for(;g<e&&a[g]===_&&n[g]===c;){const e=r[g],a=l[g];if(e==e&&a>0){const r=this._unitPath(s,_,a);if(r){t.setTransform(d,0,0,d,(m+i[g])*d,(m+e)*d);const l=h?this._seriesAlpha(s.markerSeries(g)):1;u&&(t.globalAlpha=y*l,t.fill(r)),p&&(t.globalAlpha=f*l,t.stroke(r))}}g++}t.setTransform(d,0,0,d,m*d,m*d),t.globalAlpha=1,o=g}}}_paintNumericPath(t,s){const e=s.nxs,i=s.nys,r=e.length;if(r){t.beginPath(),t.moveTo(e[0],i[0]);for(let s=1;s<r;s++)t.lineTo(e[s],i[s]);null!=s.ncloseY&&(t.lineTo(e[r-1],s.ncloseY),t.lineTo(e[0],s.ncloseY),t.closePath()),this._applyFill(t,s)&&t.fill("evenodd"===s.fillRule?"evenodd":"nonzero"),this._applyStroke(t,s)&&t.stroke(),t.globalAlpha=1}}_paintOne(t,s){switch(s.tag){case"path":if(s.nxs){this._paintNumericPath(t,s);break}if(!s.d)return;if(!s.path2d)try{s.path2d=new Path2D(s.d)}catch(t){return}this._fillStrokePath(t,s,s.path2d);break;case"rect":{const e=new Path2D;s.radius&&"function"==typeof e.roundRect?e.roundRect(s.x1,s.y1,s.rw,s.rh,s.radius):e.rect(s.x1,s.y1,s.rw,s.rh),this._fillStrokePath(t,s,e);break}case"circle":if(!(s.r>0))return;t.beginPath(),t.arc(s.cx,s.cy,s.r,0,m),this._fillStroke(t,s);break;case"line":t.beginPath(),t.moveTo(s.lx1,s.ly1),t.lineTo(s.lx2,s.ly2),this._strokeOnly(t,s);break;case"text":{if(null==s.text)return;t.save(),t.globalAlpha=this._alpha,t.fillStyle=s.fill||"#000";const e=s.fontSize||"11px";t.font=`${"number"==typeof e?e+"px":e} ${s.fontFamily||"Helvetica, Arial, sans-serif"}`,t.textAlign="middle"===s.textAnchor?"center":"end"===s.textAnchor?"right":"left",t.fillText(String(s.text),s.tx,s.ty),t.restore();break}}}_fillStrokePath(t,s,e){this._applyFill(t,s)&&t.fill(e,"evenodd"===s.fillRule?"evenodd":"nonzero"),this._applyStroke(t,s)&&t.stroke(e),t.globalAlpha=1}_fillStroke(t,s){this._applyFill(t,s)&&t.fill(),this._applyStroke(t,s)&&t.stroke(),t.globalAlpha=1}_strokeOnly(t,s){this._applyStroke(t,s)&&t.stroke(),t.globalAlpha=1}_applyFill(t,s){const e=s.fill;return!(!e||"none"===e)&&(("string"!=typeof e||0!==e.indexOf("url("))&&(t.globalAlpha=(null==s.fillOpacity?1:Number(s.fillOpacity))*this._alpha,t.fillStyle=e,!0))}_applyStroke(t,s){const e=s.stroke,i=null==s.strokeWidth?1:Number(s.strokeWidth);if(!(e&&"none"!==e&&i>0))return!1;if("string"==typeof e&&0===e.indexOf("url("))return!1;t.globalAlpha=(null==s.strokeOpacity?1:Number(s.strokeOpacity))*this._alpha,t.strokeStyle=e,t.lineWidth=i,t.lineCap=s.lineCap||"butt";const r=s.strokeDash;return r&&0!==r?t.setLineDash(Array.isArray(r)?r:[Number(r)]):t.setLineDash([]),!0}toDataURL(){return this._canvas?this._canvas.toDataURL():null}destroy(){this._host=null,this._canvas=null,this._c2d=null,this._unitPaths.clear()}}class w{constructor(t,s){this.w=t,this.ctx=s,this.kind="canvas",this._g=new u(t),this._compositor=new g(t)}beginSeries(){this._g.reset()}present(){const t=this._compositor.createHost();return this._compositor.paint(this._g.displayList(),this._g),t}clear(){this._compositor.clear()}canRepaintInPlace(){const t=this._compositor.getHost();return!!(t&&t.node&&t.node.isConnected)}repaintInPlace(){this._compositor.paint(this._g.displayList(),this._g)}group(t){return this._g.group(t)}drawPath(t){return this._g.drawPath(t)}drawLine(...t){return this._g.drawLine(...t)}drawRect(...t){return this._g.drawRect(...t)}drawRectCell(t,s,e,i,r){return this._g.drawRectCell(t,s,e,i,r)}drawCircle(t,s){return this._g.drawCircle(t,s)}drawMarker(t,s,e){return this._g.drawMarker(t,s,e)}renderPaths(t){return this._g.renderPaths(t)}drawText(t){return this._g.drawText(t)}supports(t){return"solidFill"===t||"dashArray"===t}hitTest(t,s){const e=this._g,i=e.rectCount?e.rectCount():0;if(!i)return null;const r=e._crx,l=e._cry,a=e._crw,n=e._crh;for(let h=i-1;h>=0;h--){const i=a[h],o=n[h];if(!(i<=0||o<=0)&&(t>=r[h]&&t<r[h]+i&&s>=l[h]&&s<l[h]+o))return{seriesIndex:e._crsi[h],dataPointIndex:e._crdi[h],x:r[h],y:l[h],width:i,height:o}}return null}restyle(t){this._compositor.paint(this._g.displayList(),this._g,t||null)}toBitmap(){const t=this._compositor.toDataURL();if(!t)return null;const s=this.w.globals,e=this.w.config.chart,i=this._compositor._margin;return{dataURL:t,x:(s.translateX||0)+(e.offsetX||0)-i,y:(s.translateY||0)+(e.offsetY||0)-i,w:(this.w.layout.gridWidth||0)+2*i,h:(this.w.layout.gridHeight||0)+2*i}}destroy(){this._compositor.destroy()}}s.default.registerRenderer("canvas",(t,s)=>new w(t,s)),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>s.default});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
!function(t,s){"object"==typeof exports&&"undefined"!=typeof module?s(exports):"function"==typeof define&&define.amd?define(["exports"],s):s((t="undefined"!=typeof globalThis?globalThis:t||self).ApexRendererCanvas={})}(this,function(t){"use strict";const s=globalThis.ApexCharts,e=globalThis.ApexCharts.__internals.__apex_Graphics,i={fill:"fill",stroke:"stroke","stroke-width":"strokeWidth","stroke-dasharray":"strokeDash","stroke-linecap":"lineCap","fill-opacity":"fillOpacity","stroke-opacity":"strokeOpacity","fill-rule":"fillRule"},r=Symbol("never"),l={circle:0,square:1,rect:1,triangle:2,diamond:3,star:4,sparkle:5,cross:6,plus:7,line:8},a=["circle","square","triangle","diamond","star","sparkle","cross","plus","line"],n={attr:()=>n,plot:()=>n,during:()=>n,after:t=>("function"==typeof t&&t(),n),animate:()=>n,delay:()=>n,loop:()=>n,finish:()=>n,stop:()=>n},h={nodeName:"path",style:{},classList:{add(){},remove(){},toggle(){},contains:()=>!1},setAttribute(){},getAttribute:()=>null,removeAttribute(){},hasAttribute:()=>!1,addEventListener(){},removeEventListener(){},appendChild(){},getBBox:()=>({x:0,y:0,width:0,height:0})},o={__isCanvasMark:!0,node:{nodeName:"g",instance:null,style:{},classList:{add(){},remove(){},toggle(){},contains:()=>!1},setAttribute(){},getAttribute:()=>null,removeAttribute(){},addEventListener(){},removeEventListener(){},appendChild(){},getBBox:()=>({x:0,y:0,width:0,height:0})},attr:()=>o,add:()=>o,addTo:()=>o,remove:()=>o,clear:()=>o,css:()=>o,hide:()=>o,show:()=>o,removeClass:()=>o,animate:()=>n};class c{constructor(t,s){this.__isCanvasMark=!0,this._g=t,this._i=s}get node(){return h}attr(t,s){return"string"==typeof t?("fill"===t&&void 0!==s&&this._g._setMarkerFill(this._i,s),void 0===s?null:this):(t&&void 0!==t.fill&&this._g._setMarkerFill(this._i,t.fill),this)}add(t){return this}addTo(t){return this}remove(){return this}css(t){return this}fill(t){return void 0!==t&&this._g._setMarkerFill(this._i,t),this}stroke(t){return this}hide(){return this}show(){return this}removeClass(t){return this}animate(){return n}}const _={__isCanvasMark:!0,node:h,attr:()=>_,add:()=>_,addTo:()=>_,remove:()=>_,css:()=>_,animate:()=>n};class d{constructor(t){this.__isCanvasMark=!0,this._cmd=t;const s=this;this.node={nodeName:t?t.tag:"g",instance:this,style:{},classList:{add(){},remove(){},toggle(){},contains:()=>!1},setAttribute(t,e){s._applyAttr(t,e)},getAttribute:()=>null,removeAttribute(){},hasAttribute:()=>!1,addEventListener(){},removeEventListener(){},appendChild(){},getBBox:()=>({x:0,y:0,width:0,height:0})}}_applyAttr(t,s){const e=this._cmd;if(!e)return;const r=i[t];void 0!==r&&(e[r]=s)}attr(t,s){if("string"==typeof t)return void 0===s?null:(this._applyAttr(t,s),this);for(const s in t)void 0!==t[s]&&this._applyAttr(s,t[s]);return this}add(t){return this}addTo(t){return this}remove(){return this}clear(){return this}css(t){return this}fill(t){return"object"==typeof t?this.attr(t):this.attr("fill",t)}stroke(t){return"object"==typeof t?(void 0!==t.color&&this.attr("stroke",t.color),void 0!==t.width&&this.attr("stroke-width",t.width),this):this.attr("stroke",t)}plot(t){return"string"==typeof t&&this._cmd&&"path"===this._cmd.tag&&(this._cmd.d=t),this}hide(){return this}show(){return this}removeClass(t){return this}bbox(){return{x:0,y:0,width:0,height:0}}animate(){return n}}class p{constructor(t){this.w=t,this._g=new e(t),this._list=[],this._mx=new Float64Array(16),this._my=new Float64Array(16),this._msize=new Float64Array(16),this._mshape=new Int16Array(16),this._mstyle=new Int32Array(16),this._msi=new Int32Array(16),this._mn=0,this._mcap=16,this._crx=new Float64Array(16),this._cry=new Float64Array(16),this._crw=new Float64Array(16),this._crh=new Float64Array(16),this._crstyle=new Int32Array(16),this._crsi=new Int32Array(16),this._crdi=new Int32Array(16),this._crn=0,this._crcap=16,this._cellRadius=0,this._styles=[],this._styleMap=new Map,this._lf=r,this._ls=r,this._lsw=r,this._ld=r,this._lfo=r,this._lso=r,this._lid=-1,this._lofFill=r,this._lofBase=-1,this._lofId=-1,this._rlf=r,this._rls=r,this._rlsw=r,this._rlfo=r,this._rlso=r,this._rlid=-1}_resetStyleCache(){this._lf=r,this._ls=r,this._lsw=r,this._ld=r,this._lfo=r,this._lso=r,this._lid=-1,this._lofFill=r,this._lofBase=-1,this._lofId=-1,this._rlf=r,this._rls=r,this._rlsw=r,this._rlfo=r,this._rlso=r,this._rlid=-1}reset(){this._list=[],this._mn=0,this._styles=[],this._styleMap=new Map,this._resetStyleCache();const t=this.w.config.series||[];let s=16;for(let e=0;e<t.length;e++){const i=t[e]&&t[e].data;Array.isArray(i)&&(s+=i.length)}s=Math.ceil(1.15*s)+16,s>this._mcap&&this._allocMarkers(s),this._crn=0,this._cellRadius=0,s>this._crcap&&this._allocRects(s)}_allocRects(t){this._crcap=t,this._crx=new Float64Array(t),this._cry=new Float64Array(t),this._crw=new Float64Array(t),this._crh=new Float64Array(t),this._crstyle=new Int32Array(t),this._crsi=new Int32Array(t),this._crdi=new Int32Array(t)}_growRects(){const t=2*this._crcap,s=new Float64Array(t);s.set(this._crx),this._crx=s;const e=new Float64Array(t);e.set(this._cry),this._cry=e;const i=new Float64Array(t);i.set(this._crw),this._crw=i;const r=new Float64Array(t);r.set(this._crh),this._crh=r;const l=new Int32Array(t);l.set(this._crstyle),this._crstyle=l;const a=new Int32Array(t);a.set(this._crsi),this._crsi=a;const n=new Int32Array(t);n.set(this._crdi),this._crdi=n,this._crcap=t}_allocMarkers(t){this._mcap=t,this._mx=new Float64Array(t),this._my=new Float64Array(t),this._msize=new Float64Array(t),this._mshape=new Int16Array(t),this._mstyle=new Int32Array(t),this._msi=new Int32Array(t)}_growMarkers(){const t=2*this._mcap,s=new Float64Array(t);s.set(this._mx),this._mx=s;const e=new Float64Array(t);e.set(this._my),this._my=e;const i=new Float64Array(t);i.set(this._msize),this._msize=i;const r=new Int16Array(t);r.set(this._mshape),this._mshape=r;const l=new Int32Array(t);l.set(this._mstyle),this._mstyle=l;const a=new Int32Array(t);a.set(this._msi),this._msi=a,this._mcap=t}displayList(){return this._list}markerCount(){return this._mn}_internStyle(t,s,e,i,r,l){const a=`${t}|${s}|${e}|${i}|${r}|${l}`,n=this._styleMap.get(a);if(void 0!==n)return n;const h=this._styles.length;return this._styles.push({fill:t,stroke:s,strokeWidth:e,strokeDash:i,fillOpacity:r,strokeOpacity:l}),this._styleMap.set(a,h),h}_setMarkerFill(t,s){const e=this._mstyle[t];if(s===this._lofFill&&e===this._lofBase)return void(this._mstyle[t]=this._lofId);const i=this._styles[e];if(!i||i.fill===s)return this._lofFill=s,this._lofBase=e,void(this._lofId=e);const r=this._internStyle(s,i.stroke,i.strokeWidth,i.strokeDash,i.fillOpacity,i.strokeOpacity);this._mstyle[t]=r,this._lofFill=s,this._lofBase=e,this._lofId=r}markerStyle(t){return this._styles[this._mstyle[t]]}markerSeries(t){return this._msi[t]}shapeName(t){return a[t]||"circle"}drawRectCell(t,s,e,i,r={}){const l=this._rectStyleId(r);this._crn>=this._crcap&&this._growRects();const a=this._crn++;return this._crx[a]=t||0,this._cry[a]=s||0,this._crw[a]=e>0?e:0,this._crh[a]=i>0?i:0,this._crstyle[a]=l,this._crsi[a]=null==r.seriesIndex?-1:r.seriesIndex,this._crdi[a]=null==r.dataPointIndex?-1:r.dataPointIndex,r.radius&&(this._cellRadius=r.radius),_}_rectStyleId(t){const s=t.fill,e=t.stroke,i=t.strokeWidth,r=t.fillOpacity,l=t.strokeOpacity;if(s===this._rlf&&e===this._rls&&i===this._rlsw&&r===this._rlfo&&l===this._rlso)return this._rlid;const a=this._internStyle(s,e,i,0,r,l);return this._rlf=s,this._rls=e,this._rlsw=i,this._rlfo=r,this._rlso=l,this._rlid=a,a}rectCount(){return this._crn}rectStyle(t){return this._styles[this._crstyle[t]]}rectSeries(t){return this._crsi[t]}_cmd(t,s){const e={tag:t,z:s||0,fill:void 0,stroke:void 0,strokeWidth:void 0,strokeDash:void 0,lineCap:void 0,fillOpacity:void 0,strokeOpacity:void 0,fillRule:void 0};return this._list.push(e),e}group(t){return o}drawMarker(t,s,e={}){var i;const r=this._markerStyleId(e);this._mn>=this._mcap&&this._growMarkers();const a=this._mn++;return this._mx[a]=t||0,this._my[a]="number"==typeof s?s:NaN,this._msize[a]=e.pSize||0,this._mshape[a]=null!=(i=l[e.shape||"circle"])?i:0,this._mstyle[a]=r,this._msi[a]=null==e.seriesIndex?-1:e.seriesIndex,new c(this,a)}_markerStyleId(t){const s=t.shape||"circle",e="line"===s||"plus"===s||"cross"===s,i=e?"none":t.pointFillColor,r=e?t.pointFillColor:t.pointStrokeColor,l=t.pointStrokeWidth,a=t.pointStrokeDashArray,n=t.pointFillOpacity,h=e?t.pointFillOpacity:t.pointStrokeOpacity;if(i===this._lf&&r===this._ls&&l===this._lsw&&a===this._ld&&n===this._lfo&&h===this._lso)return this._lid;const o=this._internStyle(i,r,l,a,n,h);return this._lf=i,this._ls=r,this._lsw=l,this._ld=a,this._lfo=n,this._lso=h,this._lid=o,o}renderPaths(t){const s=this._cmd("path",t.realIndex);return s.d=t.pathTo,t.pathToNumeric&&(s.nxs=t.pathToNumeric.xs,s.nys=t.pathToNumeric.ys,s.ncloseY=t.pathToNumeric.closeY),s.stroke=t.stroke,s.strokeWidth=t.strokeWidth,s.fill=t.fill,s.lineCap=t.strokeLinecap,s.si=t.realIndex,this.w.globals.animationEnded=!0,new d(s)}drawPath(t){const s=this._cmd("path",0);return s.d=t.d,s.stroke=t.stroke,s.strokeWidth=t.strokeWidth,s.fill=t.fill,s.fillOpacity=t.fillOpacity,s.strokeOpacity=t.strokeOpacity,s.lineCap=t.strokeLinecap,s.strokeDash=t.strokeDashArray,new d(s)}drawLine(t,s,e,i,r="#a8a8a8",l=0,a=1){const n=this._cmd("line",0);return n.lx1=t,n.ly1=s,n.lx2=e,n.ly2=i,n.stroke=r,n.strokeDash=l,n.strokeWidth=a,new d(n)}drawRect(t=0,s=0,e=0,i=0,r=0,l="#fefefe",a=1,n=null,h=null,o=0){const c=this._cmd("rect",0);return c.x1=t,c.y1=s,c.rw=e>0?e:0,c.rh=i>0?i:0,c.radius=r,c.fill=l,c.fillOpacity=a,null!=h&&(c.stroke=h,c.strokeWidth=null==n?1:n,c.strokeDash=o),new d(c)}drawCircle(t,s=null){const e=this._cmd("circle",0);return e.r=t<0?0:t,s&&(e.cx=s.cx,e.cy=s.cy,void 0!==s.fill&&(e.fill=s.fill),void 0!==s.stroke&&(e.stroke=s.stroke)),new d(e)}drawText(t){const s=this._cmd("text",0);return s.text=Array.isArray(t.text)?t.text.join(" "):t.text,s.tx=t.x,s.ty=t.y,s.textAnchor=t.textAnchor||"start",s.fontSize=t.fontSize,s.fontFamily=t.fontFamily,s.fill=t.foreColor,new d(s)}markerPath(t,s,e,i){return this._g.getMarkerPath(t,s,a[e]||"circle",i)}}const u=globalThis.ApexCharts.__internals.__apex_SVGElement,y=globalThis.ApexCharts.__internals,f=y.__apex_math_SVGNS;y.__apex_math_Point,y.__apex_math_Matrix,y.__apex_math_Box;const m=globalThis.ApexCharts.__internals.__apex_BrowserAPIs_BrowserAPIs,g=2*Math.PI;class w{constructor(t){this.w=t,this._host=null,this._canvas=null,this._c2d=null,this._margin=0,this._dpr=1,this._dim=null,this._alpha=1,this._unitPaths=new Map,this._markerBatches=0}markerBatchCount(){return this._markerBatches}_seriesAlpha(t){const s=this._dim;return!s||null==s.active||s.active<0||null==t||t<0||t===s.active?1:null==s.opacity?.2:s.opacity}_plotDims(){var t;const s=Math.max(0,Math.ceil(this.w.layout.gridWidth||0)),e=Math.max(0,Math.ceil(this.w.layout.gridHeight||0)),i=(null==(t=this.w.globals.markers)?void 0:t.largestSize)||0;return{gw:s,gh:e,margin:Math.ceil(i+8)}}createHost(){const t=m.getWindow();this._dpr=Math.min(2,t&&t.devicePixelRatio||1);const{gw:s,gh:e,margin:i}=this._plotDims();this._margin=i;const r=s+2*i,l=e+2*i,a=m.createElementNS(f,"foreignObject");a.setAttribute("x",String(-i)),a.setAttribute("y",String(-i)),a.setAttribute("width",String(r)),a.setAttribute("height",String(l)),a.setAttribute("class","apexcharts-canvas-series"),a.style.overflow="visible";const n=m.createElement("canvas");return n.setAttribute("class","apexcharts-series-canvas"),n.width=Math.max(1,Math.round(r*this._dpr)),n.height=Math.max(1,Math.round(l*this._dpr)),n.style.width=r+"px",n.style.height=l+"px",n.style.pointerEvents="none",a.appendChild(n),this._canvas=n,this._c2d=n.getContext("2d"),this._host=new u(a),this._host}getHost(){return this._host}clear(){this._c2d&&this._canvas&&(this._c2d.setTransform(1,0,0,1,0,0),this._c2d.clearRect(0,0,this._canvas.width,this._canvas.height))}_syncDpr(){if(!this._canvas)return;const t=m.getWindow(),s=Math.min(2,t&&t.devicePixelRatio||1);if(s===this._dpr)return;this._dpr=s;const e=parseFloat(this._canvas.style.width)||0,i=parseFloat(this._canvas.style.height)||0;this._canvas.width=Math.max(1,Math.round(e*s)),this._canvas.height=Math.max(1,Math.round(i*s))}paint(t,s,e=null){const i=this._c2d;if(!i)return;this._dim=e||null,this._syncDpr(),this.clear();const r=this._dpr,l=this._margin;if(i.setTransform(r,0,0,r,l*r,l*r),t.length){const s=t.length>1?t.map((t,s)=>[t,s]).sort((t,s)=>t[0].z===s[0].z?t[1]-s[1]:t[0].z-s[0].z).map(t=>t[0]):t;for(let t=0;t<s.length;t++){const e=s[t];this._alpha=this._dim?this._seriesAlpha(e.si):1,this._paintOne(i,e)}}this._paintRects(i,s),this._paintMarkers(i,s),this._alpha=1}_paintRects(t,s){const e=s.rectCount?s.rectCount():0;if(!e)return;const i=s._crx,r=s._cry,l=s._crw,a=s._crh,n=s._crstyle,h=s._cellRadius||0,o=t,c=h>0&&"function"==typeof o.roundRect,_=!!this._dim,d=Math.max(0,this.w.layout.gridWidth||0),p=Math.max(0,this.w.layout.gridHeight||0);t.save(),t.beginPath(),t.rect(0,0,d,p),t.clip();let u=0;for(;u<e;){const d=n[u],p=s.rectStyle(u);if(!p){u++;continue}const y=p.fill,f=y&&"none"!==y&&!("string"==typeof y&&0===y.indexOf("url(")),m=p.stroke,g=null==p.strokeWidth?0:Number(p.strokeWidth),w=m&&"none"!==m&&g>0&&!("string"==typeof m&&0===m.indexOf("url("));f&&(t.fillStyle=y),w&&(t.strokeStyle=m,t.lineWidth=g,t.setLineDash([]));const k=null==p.fillOpacity?1:Number(p.fillOpacity),x=null==p.strokeOpacity?1:Number(p.strokeOpacity);let A=u;for(;A<e&&n[A]===d;){const e=l[A],n=a[A];if(e>0&&n>0){const l=_?this._seriesAlpha(s.rectSeries(A)):1;c?(t.beginPath(),o.roundRect(i[A],r[A],e,n,h),f&&(t.globalAlpha=k*l,t.fill()),w&&(t.globalAlpha=x*l,t.stroke())):(f&&(t.globalAlpha=k*l,t.fillRect(i[A],r[A],e,n)),w&&(t.globalAlpha=x*l,t.strokeRect(i[A],r[A],e,n)))}A++}u=A}t.globalAlpha=1,t.restore()}_unitPath(t,s,e){const i=s+"|"+e;let r=this._unitPaths.get(i);if(void 0===r){try{r=new Path2D(t.markerPath(0,0,s,e))}catch(t){r=null}this._unitPaths.set(i,r)}return r}_paintMarkers(t,s){this._markerBatches=0;const e=s.markerCount();if(!e)return;const i=s._mx,r=s._my,l=s._msize,a=s._mshape,n=s._mstyle,h=!!this._dim;h||(this._alpha=1);let o=0;for(;o<e;){const c=n[o],_=a[o],d=s.markerStyle(o);if(!d){o++;continue}const p=this._applyFill(t,d),u=this._applyStroke(t,d);this._markerBatches++;const y=null==d.fillOpacity?1:Number(d.fillOpacity),f=null==d.strokeOpacity?1:Number(d.strokeOpacity);if(0===_){let _=o;for(;_<e&&0===a[_]&&n[_]===c;){const e=l[_]||0,a=r[_];if(e>0&&a==a)if(t.beginPath(),t.arc(i[_],a,e,0,g),h){const e=this._seriesAlpha(s.markerSeries(_));p&&(t.globalAlpha=y*e,t.fill()),u&&(t.globalAlpha=f*e,t.stroke())}else p&&t.fill(),u&&t.stroke();_++}t.globalAlpha=1,o=_}else{const d=this._dpr,m=this._margin;let g=o;for(;g<e&&a[g]===_&&n[g]===c;){const e=r[g],a=l[g];if(e==e&&a>0){const r=this._unitPath(s,_,a);if(r){t.setTransform(d,0,0,d,(m+i[g])*d,(m+e)*d);const l=h?this._seriesAlpha(s.markerSeries(g)):1;p&&(t.globalAlpha=y*l,t.fill(r)),u&&(t.globalAlpha=f*l,t.stroke(r))}}g++}t.setTransform(d,0,0,d,m*d,m*d),t.globalAlpha=1,o=g}}}_paintNumericPath(t,s){const e=s.nxs,i=s.nys,r=e.length;if(r){t.beginPath(),t.moveTo(e[0],i[0]);for(let s=1;s<r;s++)t.lineTo(e[s],i[s]);null!=s.ncloseY&&(t.lineTo(e[r-1],s.ncloseY),t.lineTo(e[0],s.ncloseY),t.closePath()),this._applyFill(t,s)&&t.fill("evenodd"===s.fillRule?"evenodd":"nonzero"),this._applyStroke(t,s)&&t.stroke(),t.globalAlpha=1}}_paintOne(t,s){switch(s.tag){case"path":if(s.nxs){this._paintNumericPath(t,s);break}if(!s.d)return;if(!s.path2d)try{s.path2d=new Path2D(s.d)}catch(t){return}this._fillStrokePath(t,s,s.path2d);break;case"rect":{const e=new Path2D;s.radius&&"function"==typeof e.roundRect?e.roundRect(s.x1,s.y1,s.rw,s.rh,s.radius):e.rect(s.x1,s.y1,s.rw,s.rh),this._fillStrokePath(t,s,e);break}case"circle":if(!(s.r>0))return;t.beginPath(),t.arc(s.cx,s.cy,s.r,0,g),this._fillStroke(t,s);break;case"line":t.beginPath(),t.moveTo(s.lx1,s.ly1),t.lineTo(s.lx2,s.ly2),this._strokeOnly(t,s);break;case"text":{if(null==s.text)return;t.save(),t.globalAlpha=this._alpha,t.fillStyle=s.fill||"#000";const e=s.fontSize||"11px";t.font=`${"number"==typeof e?e+"px":e} ${s.fontFamily||"Helvetica, Arial, sans-serif"}`,t.textAlign="middle"===s.textAnchor?"center":"end"===s.textAnchor?"right":"left",t.fillText(String(s.text),s.tx,s.ty),t.restore();break}}}_fillStrokePath(t,s,e){this._applyFill(t,s)&&t.fill(e,"evenodd"===s.fillRule?"evenodd":"nonzero"),this._applyStroke(t,s)&&t.stroke(e),t.globalAlpha=1}_fillStroke(t,s){this._applyFill(t,s)&&t.fill(),this._applyStroke(t,s)&&t.stroke(),t.globalAlpha=1}_strokeOnly(t,s){this._applyStroke(t,s)&&t.stroke(),t.globalAlpha=1}_applyFill(t,s){const e=s.fill;return!(!e||"none"===e)&&(("string"!=typeof e||0!==e.indexOf("url("))&&(t.globalAlpha=(null==s.fillOpacity?1:Number(s.fillOpacity))*this._alpha,t.fillStyle=e,!0))}_applyStroke(t,s){const e=s.stroke,i=null==s.strokeWidth?1:Number(s.strokeWidth);if(!(e&&"none"!==e&&i>0))return!1;if("string"==typeof e&&0===e.indexOf("url("))return!1;t.globalAlpha=(null==s.strokeOpacity?1:Number(s.strokeOpacity))*this._alpha,t.strokeStyle=e,t.lineWidth=i,t.lineCap=s.lineCap||"butt";const r=s.strokeDash;return r&&0!==r?t.setLineDash(Array.isArray(r)?r:[Number(r)]):t.setLineDash([]),!0}toDataURL(){return this._canvas?this._canvas.toDataURL():null}destroy(){this._host=null,this._canvas=null,this._c2d=null,this._unitPaths.clear()}}class k{constructor(t,s){this.w=t,this.ctx=s,this.kind="canvas",this._g=new p(t),this._compositor=new w(t)}beginSeries(){this._g.reset()}present(){const t=this._compositor.createHost();return this._compositor.paint(this._g.displayList(),this._g),t}clear(){this._compositor.clear()}canRepaintInPlace(){const t=this._compositor.getHost();return!!(t&&t.node&&t.node.isConnected)}repaintInPlace(){this._compositor.paint(this._g.displayList(),this._g)}group(t){return this._g.group(t)}drawPath(t){return this._g.drawPath(t)}drawLine(...t){return this._g.drawLine(...t)}drawRect(...t){return this._g.drawRect(...t)}drawRectCell(t,s,e,i,r){return this._g.drawRectCell(t,s,e,i,r)}drawCircle(t,s){return this._g.drawCircle(t,s)}drawMarker(t,s,e){return this._g.drawMarker(t,s,e)}renderPaths(t){return this._g.renderPaths(t)}drawText(t){return this._g.drawText(t)}supports(t){return"solidFill"===t||"dashArray"===t}hitTest(t,s){const e=this._g,i=e.rectCount?e.rectCount():0;if(!i)return null;const r=e._crx,l=e._cry,a=e._crw,n=e._crh;for(let h=i-1;h>=0;h--){const i=a[h],o=n[h];if(!(i<=0||o<=0)&&(t>=r[h]&&t<r[h]+i&&s>=l[h]&&s<l[h]+o))return{seriesIndex:e._crsi[h],dataPointIndex:e._crdi[h],x:r[h],y:l[h],width:i,height:o}}return null}restyle(t){this._compositor.paint(this._g.displayList(),this._g,t||null)}toBitmap(){const t=this._compositor.toDataURL();if(!t)return null;const s=this.w.globals,e=this.w.config.chart,i=this._compositor._margin;return{dataURL:t,x:(s.translateX||0)+(e.offsetX||0)-i,y:(s.translateY||0)+(e.offsetY||0)-i,w:(this.w.layout.gridWidth||0)+2*i,h:(this.w.layout.gridHeight||0)+2*i}}destroy(){this._compositor.destroy()}}s.registerRenderer("canvas",(t,s)=>new k(t,s)),t.default=s,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
"use strict";var t=Object.defineProperty,r=Object.defineProperties,e=Object.getOwnPropertyDescriptors,n=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable,s=(r,e,n)=>e in r?t(r,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):r[e]=n,a=(t,r)=>{for(var e in r||(r={}))i.call(r,e)&&s(t,e,r[e]);if(n)for(var e of n(r))o.call(r,e)&&s(t,e,r[e]);return t},l=(t,n)=>r(t,e(n));Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});function u(t){if(t&&t.__esModule)return t;const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t)for(const e in t)if("default"!==e){const n=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,n.get?n:{enumerable:!0,get:()=>t[e]})}return r.default=t,Object.freeze(r)}const c=u(require("apexcharts/core")),f=c.__apex_Utils,h="__apexcharts_series_transforms__";function d(t,r){t&&"string"==typeof t&&"function"==typeof r&&(globalThis[h][t]=r)}globalThis[h]||(globalThis[h]={});const g="__apexcharts_row_sources__";function y(t,r){t&&"string"==typeof t&&"function"==typeof r&&(globalThis[g][t]=r)}globalThis[g]||(globalThis[g]={});function p(t,r){const e=t.length;if(0===e)return NaN;if(1===e)return t[0];const n=(e-1)*r,i=Math.floor(n),o=Math.ceil(n);return i===o?t[i]:t[i]+(t[o]-t[i])*(n-i)}function b(t){const r=t.length;if(r<2)return 0;let e=0;for(let n=0;n<r;n++)e+=t[n];const n=e/r;let i=0;for(let e=0;e<r;e++){const r=t[e]-n;i+=r*r}return Math.sqrt(i/r)}function m(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r);let n=e[0],i=e[e.length-1];const o=r.range;if(Array.isArray(o)&&2===o.length){const t=Number(o[0]),r=Number(o[1]);isFinite(t)&&isFinite(r)&&r>t&&(n=t,i=r)}if(!(i>n)){const t=Math.abs(n)>0?.05*Math.abs(n):.5;return{edges:[n-t,n+t],binWidth:2*t,rule:"single",capped:!1}}const s=i-n;let a,l;if("number"==typeof r.binWidth&&r.binWidth>0)a=r.binWidth,l="binWidth";else if("number"==typeof r.bins&&r.bins>=1)a=s/Math.floor(r.bins),l="count";else{const t=function(t,r,e){const n=t.length,i=t=>r/Math.max(1,Math.ceil(t));switch(e){case"sqrt":return{width:i(Math.sqrt(n)),rule:"sqrt"};case"rice":return{width:i(2*Math.cbrt(n)),rule:"rice"};case"scott":{const r=b(t);return r>0?{width:3.49*r*Math.pow(n,-1/3),rule:"scott"}:{width:i(Math.log2(n)+1),rule:"sturges"}}case"fd":{const r=p(t,.75)-p(t,.25);return r>0?{width:2*r*Math.pow(n,-1/3),rule:"fd"}:{width:i(Math.log2(n)+1),rule:"sturges"}}case"auto":{const r=i(Math.log2(n)+1),e=p(t,.75)-p(t,.25);if(e<=0)return{width:r,rule:"sturges"};const o=2*e*Math.pow(n,-1/3);return o<r?{width:o,rule:"fd"}:{width:r,rule:"sturges"}}default:return{width:i(Math.log2(n)+1),rule:"sturges"}}}(e,s,"string"==typeof r.bins?r.bins:"auto");a=t.width,l=t.rule}(!isFinite(a)||a<=0)&&(a=s);let u=Math.ceil(s/a);(!isFinite(u)||u<1)&&(u=1);let c=!1;u>1e3&&(u=1e3,a=s/u,c=!0),a=s/u;const f=new Array(u+1);for(let t=0;t<=u;t++)f[t]=n+t*a;return f[u]=Math.max(f[u],i),{edges:f,binWidth:a,rule:l,capped:c}}function A(t,r){const e=r.length-1;if(!(t>=r[0])||t>r[e])return-1;if(t===r[e])return e-1;const n=(r[e]-r[0])/e;if(n>0){let i=Math.floor((t-r[0])/n);return i<0&&(i=0),i>e-1&&(i=e-1),t<r[i]?i--:t>=r[i+1]&&i++,i<0||i>e-1?-1:i}let i=0,o=e-1;for(;i<=o;){const e=i+o>>1;if(t<r[e])o=e-1;else{if(!(t>=r[e+1]))return e;i=e+1}}return-1}function v(t,r){var e;if(!t||"object"!=typeof t||Array.isArray(t))return null;let n=null;if(Array.isArray(t.points)?n=t.points:Array.isArray(null==(e=t.y)?void 0:e.points)?n=t.y.points:r&&Array.isArray(t.y)&&"number"==typeof t.y[0]&&(n=t.y),!n)return null;const i=[];for(let t=0;t<n.length;t++){const r=f.parseNumber(n[t]);null!==r&&isFinite(r)&&i.push(r)}return i.length?i:null}function w(t){const r=[];if(!Array.isArray(t))return r;for(let e=0;e<t.length;e++){const n=t[e];let i=n;Array.isArray(n)?i=1===n.length?n[0]:n[1]:n&&"object"==typeof n&&(i=void 0!==n.y?n.y:n.x);const o=f.parseNumber(i);null!==o&&isFinite(o)&&r.push(o)}return r}function M(t,r){var e;const n=r.config,i=r.globals;if(!Array.isArray(t))return t;i.histogramRawSeries||(i.histogramRawSeries=t.map(t=>l(a({},t),{data:Array.isArray(null==t?void 0:t.data)?t.data.slice():null==t?void 0:t.data})));const o=i.histogramRawSeries,s=(null==(e=n.plotOptions)?void 0:e.histogram)||{},u=o.map(t=>w(null==t?void 0:t.data));let c=[];if(1===u.length)c=u[0];else for(const t of u)c=c.concat(t);const f=m(c,{bins:s.bins,binWidth:s.binWidth,range:s.range});if(!f)return r.histogramData={edges:[],binWidth:0,counts:[],rule:"",capped:!1},o;const{edges:h,binWidth:d}=f,g=u.map(t=>function(t,r){const e=new Array(Math.max(0,r.length-1)).fill(0);for(let n=0;n<t.length;n++){const i=A(t[n],r);i>=0&&e[i]++}return e}(t,h));r.histogramData={edges:h,binWidth:d,counts:g,rule:f.rule,capped:f.capped};const y=i.collapsedSeriesIndices||[];return o.map((t,r)=>{if(-1!==y.indexOf(r))return l(a({},t),{data:[]});const e=function(t,r={}){let e=t.slice();if(r.cumulative){let t=0;e=e.map(r=>t+=r)}const n=t.reduce((t,r)=>t+r,0);if(n<=0)return e;if("relative"===r.normalize)return e.map(t=>t/n*100);if("density"===r.normalize){const t=r.binWidth;if("number"==typeof t&&t>0)return e.map(r=>r/(n*t))}return e}(g[r],{normalize:s.normalize,cumulative:s.cumulative,binWidth:d}),n=[];for(let t=0;t<e.length;t++)n.push({x:(h[t]+h[t+1])/2,y:e[t]});return l(a({},t),{data:n})})}const x=new WeakSet;function O(t,r){var e,n;if(!Array.isArray(t))return t;const i=(null==(n=null==(e=r.config.plotOptions)?void 0:e.boxPlot)?void 0:n.whiskers)||"minmax";return t.map(t=>{if(!Array.isArray(null==t?void 0:t.data))return t;let r=!1;const e=t.data.map(t=>{if(Array.isArray(null==t?void 0:t.y)&&5===t.y.length&&!x.has(t))return t;const e=v(t,!1);if(!e)return t;const n=function(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=p(e,.25),i=p(e,.5),o=p(e,.75),s=o-n;let a=e[0],l=e[e.length-1],u=[];if("tukey"===r.whiskers&&s>0){const t=n-1.5*s,r=o+1.5*s;let i=0;for(;i<e.length&&e[i]<t;)i++;let c=e.length-1;for(;c>=0&&e[c]>r;)c--;i<=c&&(a=e[i],l=e[c],u=e.slice(0,i).concat(e.slice(c+1)))}return{summary:[a,n,i,o,l],outliers:u,iqr:s}}(e,{whiskers:i});if(!n)return t;r=!0;const o=l(a({},t),{y:n.summary,points:e});return x.add(o),o});return r?l(a({},t),{data:e}):t})}function _(t,r){var e,n;if(!Array.isArray(t))return t;const i=(null==(n=null==(e=r.config.plotOptions)?void 0:e.violin)?void 0:n.kde)||{};return t.map(t=>{if(!Array.isArray(null==t?void 0:t.data))return t;let r=!1;const e=t.data.map(t=>{var e;if(Array.isArray(null==(e=null==t?void 0:t.y)?void 0:e.density)&&t.y.density.length&&!x.has(t))return t;const n=v(t,!0);if(!n)return t;const o=function(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=e.length;let i=r.bandwidth;if(!("number"==typeof i&&i>0)){const t=b(e),r=p(e,.75)-p(e,.25);i=.9*(r>0?Math.min(t,r/1.349):t)*Math.pow(n,-.2)}if(!isFinite(i)||i<=0){const t=e[0],r=Math.abs(t)>0?.001*Math.abs(t):.001;return{density:[[t-r,0],[t,1],[t+r,0]],bandwidth:r}}const o=Math.max(8,Math.floor(r.resolution||64)),s=e[0]-2*i,a=(e[n-1]+2*i-s)/(o-1),l=1/(n*i*Math.sqrt(2*Math.PI)),u=[];for(let t=0;t<o;t++){const r=s+t*a;let o=0;for(let t=0;t<n;t++){const n=(r-e[t])/i;o+=Math.exp(-.5*n*n)}u.push([r,o*l])}return{density:u,bandwidth:i}}(n,{bandwidth:i.bandwidth,resolution:i.resolution});if(!o)return t;r=!0;const s=l(a({},t),{y:{density:o.density,points:n}});return x.add(s),s});return r?l(a({},t),{data:e}):t})}function P(t,r,e){const n=e&&null!=e.maxRows?e.maxRows:3e3,i=function(t,r){let e=0,n=0;for(const r of t)e+=r.length,r.length>n&&(n=r.length);if(e<=r)return{clusters:t,stride:1,total:e,kept:e};const i=r=>{let e=0;for(const n of t)e+=Math.ceil(n.length/r);return e};let o=Math.max(2,Math.ceil(e/r));for(;o<n&&i(o)>r;)o++;let s=0;return{clusters:t.map(t=>{const r=[];for(let e=0;e<t.length;e+=o)r.push(t[e]);return s+=r.length,r}),stride:o,total:e,kept:s}}(r.map(t=>t.rows),n);i.stride;const o=t.globals&&t.globals.colors||[];return r.map((t,r)=>{const e=o[t.realIndex]||o[0];return{name:t.name,data:i.clusters[r].map((n,i)=>a({id:`${t.realIndex}:${r}:${i}`,x:t.name,y:n},e?{fillColor:e}:{}))}})}function S(t,r){const e=t.globals,n=t.histogramData,i=e&&e.histogramRawSeries;if(!n||!Array.isArray(n.edges)||n.edges.length<2)return null;if(!Array.isArray(i)||!i.length)return null;const o=e&&e.collapsedSeriesIndices||[],s=n.edges,a=[];return i.forEach((r,e)=>{var n;if(-1!==o.indexOf(e))return;const l=function(t,r){const e=Math.max(0,r.length-1),n=new Array(e);for(let t=0;t<e;t++)n[t]=[];for(let e=0;e<t.length;e++){const i=A(t[e],r);i>=0&&n[i].push(t[e])}return n}(w(r&&r.data),s),u=t.seriesData&&(null==(n=t.seriesData.seriesNames)?void 0:n[e])||(null==r?void 0:r.name);l.forEach((t,r)=>{const n=`${j(s[r])}-${j(s[r+1])}`;a.push({name:i.length>1&&u?`${u} ${n}`:n,realIndex:e,rows:t})})}),a.length?P(t,a,r):null}function j(t){if(!isFinite(t))return String(t);const r=Math.round(t);return Math.abs(t-r)<1e-6?String(r):String(Number(t.toFixed(2)))}function W(t){return(r,e)=>{var n;const i=t(r);if(!Array.isArray(i)||!i.length)return null;const o=r.globals&&r.globals.collapsedSeriesIndices||[],s=r.globals&&((null==(n=r.globals.categoryLabels)?void 0:n.length)?r.globals.categoryLabels:r.globals.labels)||[],a=[];return i.forEach((t,e)=>{var n;if(-1!==o.indexOf(e))return;if(!Array.isArray(t))return;const l=r.seriesData&&(null==(n=r.seriesData.seriesNames)?void 0:n[e]);t.forEach((t,r)=>{const n=null!=s[r]?String(s[r]):`#${r+1}`;a.push({name:i.length>1&&l?`${l} ${n}`:n,realIndex:e,rows:Array.isArray(t)?t.slice():[]})})}),a.length?P(r,a,e):null}}const D=W(t=>{var r;return null==(r=t.candleData)?void 0:r.seriesBoxPoints}),T=W(t=>{var r;return null==(r=t.violinData)?void 0:r.seriesViolinPoints});d("histogram",M),d("boxPlot",O),d("violin",_),y("histogram",S),y("boxPlot",D),y("violin",T),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>c.default}),exports.boxPlotRows=D,exports.boxPlotTransform=O,exports.histogramRows=S,exports.histogramTransform=M,exports.violinRows=T,exports.violinTransform=_;
|
package/dist/features/stats.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
5
|
!function(t,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports):"function"==typeof define&&define.amd?define(["exports"],r):r((t="undefined"!=typeof globalThis?globalThis:t||self).ApexStats={})}(this,function(t){"use strict";var r=Object.defineProperty,e=Object.defineProperties,n=Object.getOwnPropertyDescriptors,s=Object.getOwnPropertySymbols,i=Object.prototype.hasOwnProperty,o=Object.prototype.propertyIsEnumerable,a=(t,e,n)=>e in t?r(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n,l=(t,r)=>{for(var e in r||(r={}))i.call(r,e)&&a(t,e,r[e]);if(s)for(var e of s(r))o.call(r,e)&&a(t,e,r[e]);return t},u=(t,r)=>e(t,n(r));const c=globalThis.ApexCharts,f=globalThis.ApexCharts.__internals.__apex_Utils,h="__apexcharts_series_transforms__";function d(t,r){t&&"string"==typeof t?"function"==typeof r?globalThis[h][t]=r:console.warn(`ApexCharts: registerSeriesTransform("${t}") expects a function (series, w) => series.`):console.warn("ApexCharts: registerSeriesTransform requires a non-empty name.")}globalThis[h]||(globalThis[h]={});const g="__apexcharts_row_sources__";function p(t,r){t&&"string"==typeof t?"function"==typeof r?globalThis[g][t]=r:console.warn(`ApexCharts: registerRowSource("${t}") expects a function (w, opts) => series.`):console.warn("ApexCharts: registerRowSource requires a non-empty name.")}globalThis[g]||(globalThis[g]={});function y(t,r){const e=t.length;if(0===e)return NaN;if(1===e)return t[0];const n=(e-1)*r,s=Math.floor(n),i=Math.ceil(n);return s===i?t[s]:t[s]+(t[i]-t[s])*(n-s)}function m(t){const r=t.length;if(r<2)return 0;let e=0;for(let n=0;n<r;n++)e+=t[n];const n=e/r;let s=0;for(let e=0;e<r;e++){const r=t[e]-n;s+=r*r}return Math.sqrt(s/r)}function b(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r);let n=e[0],s=e[e.length-1];const i=r.range;if(Array.isArray(i)&&2===i.length){const t=Number(i[0]),r=Number(i[1]);isFinite(t)&&isFinite(r)&&r>t&&(n=t,s=r)}if(!(s>n)){const t=Math.abs(n)>0?.05*Math.abs(n):.5;return{edges:[n-t,n+t],binWidth:2*t,rule:"single",capped:!1}}const o=s-n;let a,l;if("number"==typeof r.binWidth&&r.binWidth>0)a=r.binWidth,l="binWidth";else if("number"==typeof r.bins&&r.bins>=1)a=o/Math.floor(r.bins),l="count";else{const t=function(t,r,e){const n=t.length,s=t=>r/Math.max(1,Math.ceil(t));switch(e){case"sqrt":return{width:s(Math.sqrt(n)),rule:"sqrt"};case"rice":return{width:s(2*Math.cbrt(n)),rule:"rice"};case"scott":{const r=m(t);return r>0?{width:3.49*r*Math.pow(n,-1/3),rule:"scott"}:{width:s(Math.log2(n)+1),rule:"sturges"}}case"fd":{const r=y(t,.75)-y(t,.25);return r>0?{width:2*r*Math.pow(n,-1/3),rule:"fd"}:{width:s(Math.log2(n)+1),rule:"sturges"}}case"auto":{const r=s(Math.log2(n)+1),e=y(t,.75)-y(t,.25);if(e<=0)return{width:r,rule:"sturges"};const i=2*e*Math.pow(n,-1/3);return i<r?{width:i,rule:"fd"}:{width:r,rule:"sturges"}}default:return{width:s(Math.log2(n)+1),rule:"sturges"}}}(e,o,"string"==typeof r.bins?r.bins:"auto");a=t.width,l=t.rule}(!isFinite(a)||a<=0)&&(a=o);let u=Math.ceil(o/a);(!isFinite(u)||u<1)&&(u=1);let c=!1;u>1e3&&(u=1e3,a=o/u,c=!0),a=o/u;const f=new Array(u+1);for(let t=0;t<=u;t++)f[t]=n+t*a;return f[u]=Math.max(f[u],s),{edges:f,binWidth:a,rule:l,capped:c}}function w(t,r){const e=r.length-1;if(!(t>=r[0])||t>r[e])return-1;if(t===r[e])return e-1;const n=(r[e]-r[0])/e;if(n>0){let s=Math.floor((t-r[0])/n);return s<0&&(s=0),s>e-1&&(s=e-1),t<r[s]?s--:t>=r[s+1]&&s++,s<0||s>e-1?-1:s}let s=0,i=e-1;for(;s<=i;){const e=s+i>>1;if(t<r[e])i=e-1;else{if(!(t>=r[e+1]))return e;s=e+1}}return-1}function A(t,r){var e;if(!t||"object"!=typeof t||Array.isArray(t))return null;let n=null;if(Array.isArray(t.points)?n=t.points:Array.isArray(null==(e=t.y)?void 0:e.points)?n=t.y.points:r&&Array.isArray(t.y)&&"number"==typeof t.y[0]&&(n=t.y),!n)return null;const s=[];for(let t=0;t<n.length;t++){const r=f.parseNumber(n[t]);null!==r&&isFinite(r)&&s.push(r)}return s.length?s:null}function v(t){const r=[];if(!Array.isArray(t))return r;for(let e=0;e<t.length;e++){const n=t[e];let s=n;Array.isArray(n)?s=1===n.length?n[0]:n[1]:n&&"object"==typeof n&&(s=void 0!==n.y?n.y:n.x);const i=f.parseNumber(s);null!==i&&isFinite(i)&&r.push(i)}return r}function x(t,r){var e;const n=r.config,s=r.globals;if(!Array.isArray(t))return t;s.histogramRawSeries||(s.histogramRawSeries=t.map(t=>u(l({},t),{data:Array.isArray(null==t?void 0:t.data)?t.data.slice():null==t?void 0:t.data})));const i=s.histogramRawSeries,o=(null==(e=n.plotOptions)?void 0:e.histogram)||{},a=i.map(t=>v(null==t?void 0:t.data));let c=[];if(1===a.length)c=a[0];else for(const t of a)c=c.concat(t);const f=b(c,{bins:o.bins,binWidth:o.binWidth,range:o.range});if(!f)return r.histogramData={edges:[],binWidth:0,counts:[],rule:"",capped:!1},i;const{edges:h,binWidth:d}=f,g=a.map(t=>function(t,r){const e=new Array(Math.max(0,r.length-1)).fill(0);for(let n=0;n<t.length;n++){const s=w(t[n],r);s>=0&&e[s]++}return e}(t,h));r.histogramData={edges:h,binWidth:d,counts:g,rule:f.rule,capped:f.capped};const p=s.collapsedSeriesIndices||[];return i.map((t,r)=>{if(-1!==p.indexOf(r))return u(l({},t),{data:[]});const e=function(t,r={}){let e=t.slice();if(r.cumulative){let t=0;e=e.map(r=>t+=r)}const n=t.reduce((t,r)=>t+r,0);if(n<=0)return e;if("relative"===r.normalize)return e.map(t=>t/n*100);if("density"===r.normalize){const t=r.binWidth;if("number"==typeof t&&t>0)return e.map(r=>r/(n*t))}return e}(g[r],{normalize:o.normalize,cumulative:o.cumulative,binWidth:d}),n=[];for(let t=0;t<e.length;t++)n.push({x:(h[t]+h[t+1])/2,y:e[t]});return u(l({},t),{data:n})})}const M=new WeakSet;function S(t,r){var e,n;if(!Array.isArray(t))return t;const s=(null==(n=null==(e=r.config.plotOptions)?void 0:e.boxPlot)?void 0:n.whiskers)||"minmax";return t.map(t=>{if(!Array.isArray(null==t?void 0:t.data))return t;let r=!1;const e=t.data.map(t=>{if(Array.isArray(null==t?void 0:t.y)&&5===t.y.length&&!M.has(t))return t;const e=A(t,!1);if(!e)return t;const n=function(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=y(e,.25),s=y(e,.5),i=y(e,.75),o=i-n;let a=e[0],l=e[e.length-1],u=[];if("tukey"===r.whiskers&&o>0){const t=n-1.5*o,r=i+1.5*o;let s=0;for(;s<e.length&&e[s]<t;)s++;let c=e.length-1;for(;c>=0&&e[c]>r;)c--;s<=c&&(a=e[s],l=e[c],u=e.slice(0,s).concat(e.slice(c+1)))}return{summary:[a,n,s,i,l],outliers:u,iqr:o}}(e,{whiskers:s});if(!n)return t;r=!0;const i=u(l({},t),{y:n.summary,points:e});return M.add(i),i});return r?u(l({},t),{data:e}):t})}function _(t,r){var e,n;if(!Array.isArray(t))return t;const s=(null==(n=null==(e=r.config.plotOptions)?void 0:e.violin)?void 0:n.kde)||{};return t.map(t=>{if(!Array.isArray(null==t?void 0:t.data))return t;let r=!1;const e=t.data.map(t=>{var e;if(Array.isArray(null==(e=null==t?void 0:t.y)?void 0:e.density)&&t.y.density.length&&!M.has(t))return t;const n=A(t,!0);if(!n)return t;const i=function(t,r={}){if(!Array.isArray(t)||0===t.length)return null;const e=t.slice().sort((t,r)=>t-r),n=e.length;let s=r.bandwidth;if(!("number"==typeof s&&s>0)){const t=m(e),r=y(e,.75)-y(e,.25);s=.9*(r>0?Math.min(t,r/1.349):t)*Math.pow(n,-.2)}if(!isFinite(s)||s<=0){const t=e[0],r=Math.abs(t)>0?.001*Math.abs(t):.001;return{density:[[t-r,0],[t,1],[t+r,0]],bandwidth:r}}const i=Math.max(8,Math.floor(r.resolution||64)),o=e[0]-2*s,a=(e[n-1]+2*s-o)/(i-1),l=1/(n*s*Math.sqrt(2*Math.PI)),u=[];for(let t=0;t<i;t++){const r=o+t*a;let i=0;for(let t=0;t<n;t++){const n=(r-e[t])/s;i+=Math.exp(-.5*n*n)}u.push([r,i*l])}return{density:u,bandwidth:s}}(n,{bandwidth:s.bandwidth,resolution:s.resolution});if(!i)return t;r=!0;const o=u(l({},t),{y:{density:i.density,points:n}});return M.add(o),o});return r?u(l({},t),{data:e}):t})}function $(t,r,e){const n=e&&null!=e.maxRows?e.maxRows:3e3,s=function(t,r){let e=0,n=0;for(const r of t)e+=r.length,r.length>n&&(n=r.length);if(e<=r)return{clusters:t,stride:1,total:e,kept:e};const s=r=>{let e=0;for(const n of t)e+=Math.ceil(n.length/r);return e};let i=Math.max(2,Math.ceil(e/r));for(;i<n&&s(i)>r;)i++;let o=0;return{clusters:t.map(t=>{const r=[];for(let e=0;e<t.length;e+=i)r.push(t[e]);return o+=r.length,r}),stride:i,total:e,kept:o}}(r.map(t=>t.rows),n);s.stride>1&&console.warn(`ApexCharts: rowSeries() thinned ${s.total} rows to ${s.kept} (every ${s.stride}${2===s.stride?"nd":3===s.stride?"rd":"th"} row) to stay under maxRows=${n}. Raise maxRows to draw more.`);const i=t.globals&&t.globals.colors||[];return r.map((t,r)=>{const e=i[t.realIndex]||i[0];return{name:t.name,data:s.clusters[r].map((n,s)=>l({id:`${t.realIndex}:${r}:${s}`,x:t.name,y:n},e?{fillColor:e}:{}))}})}function O(t,r){const e=t.globals,n=t.histogramData,s=e&&e.histogramRawSeries;if(!n||!Array.isArray(n.edges)||n.edges.length<2)return null;if(!Array.isArray(s)||!s.length)return null;const i=e&&e.collapsedSeriesIndices||[],o=n.edges,a=[];return s.forEach((r,e)=>{var n;if(-1!==i.indexOf(e))return;const l=function(t,r){const e=Math.max(0,r.length-1),n=new Array(e);for(let t=0;t<e;t++)n[t]=[];for(let e=0;e<t.length;e++){const s=w(t[e],r);s>=0&&n[s].push(t[e])}return n}(v(r&&r.data),o),u=t.seriesData&&(null==(n=t.seriesData.seriesNames)?void 0:n[e])||(null==r?void 0:r.name);l.forEach((t,r)=>{const n=`${T(o[r])}-${T(o[r+1])}`;a.push({name:s.length>1&&u?`${u} ${n}`:n,realIndex:e,rows:t})})}),a.length?$(t,a,r):null}function T(t){if(!isFinite(t))return String(t);const r=Math.round(t);return Math.abs(t-r)<1e-6?String(r):String(Number(t.toFixed(2)))}function P(t){return(r,e)=>{var n;const s=t(r);if(!Array.isArray(s)||!s.length)return null;const i=r.globals&&r.globals.collapsedSeriesIndices||[],o=r.globals&&((null==(n=r.globals.categoryLabels)?void 0:n.length)?r.globals.categoryLabels:r.globals.labels)||[],a=[];return s.forEach((t,e)=>{var n;if(-1!==i.indexOf(e))return;if(!Array.isArray(t))return;const l=r.seriesData&&(null==(n=r.seriesData.seriesNames)?void 0:n[e]);t.forEach((t,r)=>{const n=null!=o[r]?String(o[r]):`#${r+1}`;a.push({name:s.length>1&&l?`${l} ${n}`:n,realIndex:e,rows:Array.isArray(t)?t.slice():[]})})}),a.length?$(r,a,e):null}}const R=P(t=>{var r;return null==(r=t.candleData)?void 0:r.seriesBoxPoints}),W=P(t=>{var r;return null==(r=t.violinData)?void 0:r.seriesViolinPoints});d("histogram",x),d("boxPlot",S),d("violin",_),p("histogram",O),p("boxPlot",R),p("violin",W),t.boxPlotRows=R,t.boxPlotTransform=S,t.default=c,t.histogramRows=O,t.histogramTransform=x,t.violinRows=W,t.violinTransform=_,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* ApexCharts v7.
|
|
2
|
+
* ApexCharts v7.4.0
|
|
3
3
|
* (c) 2018-2026 ApexCharts
|
|
4
4
|
*/
|
|
5
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_Environment_Environment,h=d.__apex_Animations_prefersReducedMotion,f=globalThis.console;function p(e,...t){f.error(e,...t)}function y(e){f.warn(e)}const v="APEX-",m=new Date("2027-07-31T00:00:00Z"),g="__apex_license_v1__";function b(){const e=globalThis;let t=e[g];return t||(t={key:null,listeners:new Set,result:null},e[g]=t),t}const x=class{static get licenseKey(){return b().key}static set licenseKey(e){b().key=e}static get listeners(){return b().listeners}static get validationResult(){return b().result}static set validationResult(e){b().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||p(`[Apex] ${i.message}`)):y(`[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(v))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(v))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>=m)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,y(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),p(`[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}};x.publicKeysSpki=["MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEQIaK9UMD6n0oR/FIy8QdL0uSzKMQlf1BB+tOrji4/WuHsyRNxeDhVykoSsNURozMi1xhmqWvBH1L//xIfugTPA=="],x.verdicts=new Map,x.verifying=new Set,x.warnedUnverifiable=!1,x.epoch=0;let w=x;const _=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=w.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,w.onChange(()=>{this.reconcile()}))}};_.WATERMARK_ATTR="data-apexcharts-watermark",_.WATERMARK_TEXT="APEXCHARTS",_.ATTR="data-apexcharts-watermark",_.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"},_.managed=new Set,_.subscribed=!1;let A=_;let S=!1;const k=new Set;function O(){S=!0,C()}const T=new Set(["premium","enterprise"]);function E(e,t){const n=A.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=A.node(t);e&&(i.disconnect(),A.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 I(e,t){e._wmWrapObserver&&(e._wmWrapObserver.disconnect(),e._wmWrapObserver=null),e._wmNodeObserver&&(e._wmNodeObserver.disconnect(),e._wmNodeObserver=null),e._wmObservedNode=null;const n=t||e.w&&e.w.dom&&e.w.dom.elWrap;n&&A.remove(n,{manage:!1})}function R(e,t){try{if(!u.isBrowser())return;if(e&&e.globals&&e.globals.isDestroyed)return void k.delete(t);const n=e&&e.dom&&e.dom.elWrap;if(!n)return;const i=function(e,t){const n=e&&e.config&&e.config.chart||{},i=[];"unit"===n.type&&i.push("unit"),"raincloud"===n.requestedType&&i.push("raincloud"),t.trellis&&"function"==typeof t.trellis.isActive&&t.trellis.isActive()&&i.push("trellis"),t.storyboard&&t.storyboard._used&&i.push("storyboard");const s=n.link;return t.linkedViews&&s&&(!0===s.enabled||"function"==typeof s.dimension)&&i.push("link"),t.ink&&n.ink&&!0===n.ink.enabled&&i.push("ink"),t.measure&&n.measure&&!0===n.measure.enabled&&i.push("measure"),t.contextMenu&&n.contextMenu&&!0===n.contextMenu.enabled&&i.push("context-menu"),t.perspectives&&(t.perspectives._used||S)&&i.push("perspectives"),t.history&&n.history&&!0===n.history.enabled&&i.push("history"),i}(e,t);if(0===i.length)return k.delete(t),void I(t,n);k.add(t);const s=function(e){const t=e&&e.config&&e.config.chart&&e.config.chart.license;if(t)return t;const n=w.getKey();if(n)return n;const i=u.getApex();return i&&i.license?i.license:null}(e);if(function(e){if(!e)return!1;const t=w.validateKey(e);if(!t.valid)return!1;const n=t.data&&t.data.plan;return"string"==typeof n&&T.has(n.toLowerCase())}(s))return void I(t,n);!function(e,t){if(E(e,t),"undefined"==typeof MutationObserver||e._wmWrapObserver)return;const n=new MutationObserver(()=>{A.node(t)||E(e,t)});n.observe(t,{childList:!0}),e._wmWrapObserver=n}(t,n),function(e,t,n){if(e._premiumLicenseNotified)return;if(e._premiumLicenseNotified=!0,n.length,!t)return;const i=w.validateKey(t);if(i.valid)return void(i.data&&i.data.plan);w.getKey()}(t,s,i)}catch(e){}}function C(){if(!u.isBrowser())return;const e=new Set,t=u.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),R(n.w,n))}),Array.from(k).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)||R(n,t):k.delete(t)})}w.onChange(C);const K=d.__apex_Utils;function P(e,t){const n=null!=e,i=null!=t;return n||i?{min:n?e:null,max:i?t:null}:null}function D(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 L(e,t){const n=e.config.annotations?K.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:K.clone(e.params)})}return{static:n,dynamic:i}}function j(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 N(e,t,{animate:n=!0,mergeOptions:i}={}){var s,r;if(!e||!t)return;"number"==typeof t.v&&t.v,e.clearAnnotations();const a=i?K.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=K.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=D(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="apex";function U(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 W(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 ${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:D(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:L(e,t),drill:l&&l.depth>0?{path:l.path.slice()}:null,measure:j(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 U(JSON.stringify(t))}decode(e){return $.decode(e)}toURL(){if(!u.isBrowser())return"";const e=this.encode(this.capture()),t=new URL(window.location.href);return t.hash=`${B}=${e}`,t.toString()}apply(e,t={}){const n="string"==typeof e?$.decode(e):e;if(!n||!n.view)return;this._used=!0,R(this.w,this.ctx);const i=void 0===t.animate||t.animate,s=K.extend(n.options?K.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=>{N(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,R(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(W(e));return t&&"object"==typeof t?1!==t.v?null:t:null}catch(e){return null}}static fromURL(e){try{const t=e||(u.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]===B);return i&&null!=i[1]?$.decode(decodeURIComponent(i[1])):null}catch(e){return null}}}d.default.registerFeatures({perspectives:$}),d.default.perspectives={decode:e=>(O(),$.decode(e)),fromURL:e=>(O(),$.fromURL(e))},d.default.registerFeatures({storyboard:class{constructor(e,t){this.w=e,this.ctx=t,this._beats=[],this._observer=null,this._activeIndex=-1,this._animate=!0,this._warnedNoPerspectives=!1,this._used=!1}bind(e={}){var t;if(this.unbind(),!u.isBrowser())return 0;const n=this.ctx.el&&this.ctx.el.ownerDocument;if(!n||"undefined"==typeof IntersectionObserver)return 0;let i=null;if(e.scroller&&(i="string"==typeof e.scroller?n.querySelector(e.scroller):e.scroller),this._beats=this._resolveBeats(n,i,e.beats),!this._beats.length)return 0;this._animate=!1!==e.animate;const s=Math.min(Math.max(null!=(t=e.offset)?t:.5,0),1),r=+(100*s).toFixed(3),a=+(100-100*s).toFixed(3);return this._observer=new IntersectionObserver(e=>this._onIntersect(e),{root:i,rootMargin:`-${r}% 0px -${a}%`,threshold:0}),this._beats.forEach(e=>{var t;return null==(t=this._observer)?void 0:t.observe(e.el)}),this._used=!0,R(this.w,this.ctx),this._beats.length}_resolveBeats(e,t,n){const i=[];if(Array.isArray(n))return n.forEach((t,n)=>{var s,r;if(!t)return;const a=t.el&&"object"==typeof t.el?t.el:t.selector?e.querySelector(t.selector):null;a&&i.push({el:a,key:null!=(r=null!=(s=t.key)?s:a.getAttribute("data-apex-beat"))?r:String(n),view:t.view,options:t.options,announce:t.announce,onEnter:"function"==typeof t.onEnter?t.onEnter:void 0})}),i;return(t||e).querySelectorAll("[data-apex-beat]").forEach((e,t)=>{i.push({el:e,key:e.getAttribute("data-apex-beat")||String(t),view:e.getAttribute("data-apex-view")||void 0,options:void 0,announce:e.getAttribute("data-apex-announce")||void 0,onEnter:void 0})}),i}_onIntersect(e){e.forEach(e=>{const t=this._beats.findIndex(t=>t.el===e.target);t<0||(e.isIntersecting?this._activate(t):t===this._activeIndex&&e.rootBounds&&e.boundingClientRect.top>=e.rootBounds.bottom&&t>0&&this._activate(t-1))})}_activate(e,t={}){var n,i;if(e===this._activeIndex)return;const s=this._beats[e];if(!s)return;const r=e>this._activeIndex?"down":"up";this._activeIndex=e;const a=(void 0!==t.animate?t.animate:this._animate)&&!h();if(null!=s.view||s.options)if(this.ctx.perspectives){const e=null!=(n=s.view)?n:{},t="string"==typeof e||e.view?e:{view:this._normalizeView(e)};this.ctx.perspectives.apply(t,{animate:a,mergeOptions:s.options})}else this._warnedNoPerspectives||(this._warnedNoPerspectives=!0);const o={index:e,key:s.key,el:s.el,direction:r};s.onEnter&&s.onEnter(this.ctx,o),s.announce&&this._announce(s.announce),"function"==typeof this.w.config.chart.events.beatChange&&this.w.config.chart.events.beatChange(this.ctx,o),null==(i=this.ctx.events)||i.fireEvent("beatChange",[this.ctx,o])}_normalizeView(e){const t=e.annotations&&e.annotations.static||{};return l(o({},e),{annotations:{static:o({points:[],xaxis:[],yaxis:[],texts:[],images:[]},t),dynamic:e.annotations&&e.annotations.dynamic||[]}})}goTo(e,t={}){const n="number"==typeof e?e:this._beats.findIndex(t=>t.key===e);n>=0&&n<this._beats.length&&this._activate(n,t)}current(){if(this._activeIndex<0)return null;const e=this._beats[this._activeIndex];return{index:this._activeIndex,key:e?e.key:null}}unbind(){this._observer&&(this._observer.disconnect(),this._observer=null),this._beats=[],this._activeIndex=-1,this._used=!1,R(this.w,this.ctx)}teardown(){this.unbind()}_announce(e){const t=this.w;if(!t.config.chart.accessibility.announcements.enabled)return;const n=t.dom.baseEl;if(!n)return;const i=n.querySelector(".apexcharts-sr-status");i&&(i.textContent="",setTimeout(()=>{i.textContent=e},0))}}}),Object.defineProperty(exports,"default",{enumerable:!0,get:()=>d.default});
|