UNPKG

ag-charts-community

Version:

Advanced Charting / Charts supporting Javascript / Typescript / React / Angular / Vue

3 lines 148 kB
"use strict";var __defProp=Object.defineProperty,__getOwnPropDesc=Object.getOwnPropertyDescriptor,__getOwnPropNames=Object.getOwnPropertyNames,__hasOwnProp=Object.prototype.hasOwnProperty,__export=(i,t)=>{for(var e in t)__defProp(i,e,{get:t[e],enumerable:!0})},__copyProps=(i,t,e,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of __getOwnPropNames(t))!__hasOwnProp.call(i,n)&&n!==e&&__defProp(i,n,{get:()=>t[n],enumerable:!(s=__getOwnPropDesc(t,n))||s.enumerable});return i},__toCommonJS=i=>__copyProps(__defProp({},"__esModule",{value:!0}),i),__decorateClass=(i,t,e,s)=>{for(var n=s>1?void 0:s?__getOwnPropDesc(t,e):t,a=i.length-1,r;a>=0;a--)(r=i[a])&&(n=(s?r(t,e,n):r(n))||n);return s&&n&&__defProp(t,e,n),n},integrated_charts_scene_exports={};__export(integrated_charts_scene_exports,{Arc:()=>Arc,BBox:()=>BBox,Caption:()=>Caption,CategoryScale:()=>CategoryScale,Group:()=>Group,Line:()=>Line,LinearScale:()=>LinearScale,Marker:()=>Marker,Path:()=>Path,RadialColumnShape:()=>RadialColumnShape,Rect:()=>Rect,Scene:()=>Scene,Sector:()=>Sector,Shape:()=>Shape,TranslatableGroup:()=>TranslatableGroup,getRadialColumnWidth:()=>getRadialColumnWidth,toRadians:()=>import_ag_charts_core42.toRadians}),module.exports=__toCommonJS(integrated_charts_scene_exports);var import_ag_charts_core27=require("ag-charts-core"),import_ag_charts_core2=require("ag-charts-core"),import_ag_charts_core=require("ag-charts-core"),interpolate=Symbol("interpolate"),_BBox=class X{constructor(t,e,s,n){this.x=t,this.y=e,this.width=s,this.height=n}static fromObject({x:t,y:e,width:s,height:n}){return new X(t,e,s,n)}static merge(t){let e=1/0,s=1/0,n=-1/0,a=-1/0;for(const r of t)r.x<e&&(e=r.x),r.y<s&&(s=r.y),end(r.x,r.width)>n&&(n=end(r.x,r.width)),end(r.y,r.height)>a&&(a=end(r.y,r.height));return new X(e,s,n-e,a-s)}static nearestBox(t,e,s){return(0,import_ag_charts_core.nearestSquared)(t,e,s)}toDOMRect(){return{x:this.x,y:this.y,width:this.width,height:this.height,top:this.y,left:this.x,right:end(this.x,this.width),bottom:end(this.y,this.height),toJSON(){return{}}}}clone(){const{x:t,y:e,width:s,height:n}=this;return new X(t,e,s,n)}equals(t){return(0,import_ag_charts_core.boxesEqual)(this,t)}containsPoint(t,e){return(0,import_ag_charts_core.boxContains)(this,t,e)}intersectsWith(t){return!(this.x+this.width<=t.x||t.x+t.width<=this.x||this.y+this.height<=t.y||t.y+t.height<=this.y)}intersection(t){const e=Math.max(this.x,t.x),s=Math.max(this.y,t.y),n=Math.min(end(this.x,this.width),end(t.x,t.width)),a=Math.min(end(this.y,this.height),end(t.y,t.height));if(!(e>n||s>a))return new X(e,s,n-e,a-s)}collidesBBox(t){return this.x<end(t.x,t.width)&&end(this.x,this.width)>t.x&&this.y<end(t.y,t.height)&&end(this.y,this.height)>t.y}computeCenter(){return{x:this.x+this.width/2,y:this.y+this.height/2}}isFinite(){return Number.isFinite(this.x)&&Number.isFinite(this.y)&&Number.isFinite(this.width)&&Number.isFinite(this.height)}distanceSquared(t,e){if(this.containsPoint(t,e))return 0;const s=t-(0,import_ag_charts_core.clamp)(this.x,t,end(this.x,this.width)),n=e-(0,import_ag_charts_core.clamp)(this.y,e,end(this.y,this.height));return s*s+n*n}shrink(t,e){if(typeof t=="number")this.applyMargin(t,e);else for(const s of Object.keys(t)){const n=t[s];typeof n=="number"&&this.applyMargin(n,s)}return this.width<0&&(this.width=0),this.height<0&&(this.height=0),this}grow(t,e){if(typeof t=="number")this.applyMargin(-t,e);else for(const s of Object.keys(t)){const n=t[s];typeof n=="number"&&this.applyMargin(-n,s)}return this}applyMargin(t,e){switch(e){case"top":this.y+=t;case"bottom":this.height-=t;break;case"left":this.x+=t;case"right":this.width-=t;break;case"vertical":this.y+=t,this.height-=t*2;break;case"horizontal":this.x+=t,this.width-=t*2;break;case void 0:this.x+=t,this.y+=t,this.width-=t*2,this.height-=t*2;break}}translate(t,e){return this.x+=t,this.y+=e,this}[interpolate](t,e){return new X(this.x*(1-e)+t.x*e,this.y*(1-e)+t.y*e,this.width*(1-e)+t.width*e,this.height*(1-e)+t.height*e)}};_BBox.zero=Object.freeze(new _BBox(0,0,0,0)),_BBox.NaN=Object.freeze(new _BBox(Number.NaN,Number.NaN,Number.NaN,Number.NaN));var BBox=_BBox;function end(i,t){return i===-1/0&&t===1/0?1/0:i+t}var cmp=(i,t)=>Math.sign(i-t);function compareZIndex(i,t){if(typeof i=="number"&&typeof t=="number")return cmp(i,t);const e=typeof i=="number"?[i]:i,s=typeof t=="number"?[t]:t,n=Math.min(e.length,s.length);for(let a=0;a<n;a+=1){const r=cmp(e[a],s[a]);if(r!==0)return r}return cmp(e.length,s.length)}var import_ag_charts_core3=require("ag-charts-core"),MAX_ERROR_COUNT=5,_Node=class H{constructor(t){this.serialNumber=H._nextSerialNumber++,this.childNodeCounts={groups:0,nonGroups:0,thisComplexity:0,complexity:0},this.id=(0,import_ag_charts_core2.createId)(this),this.name=void 0,this.transitionOut=void 0,this.pointerEvents=0,this._datum=void 0,this._previousDatum=void 0,this.scene=void 0,this._debugDirtyProperties=void 0,this.parentNode=void 0,this.cachedBBox=void 0,this.isContainerNode=!1,this.visible=!0,this.zIndex=0,this.batchLevel=0,this.batchDirty=!1,this.name=t?.name,this.tag=t?.tag??Number.NaN,this.zIndex=t?.zIndex??0,this.scene=t?.scene,(t?.debugDirty??H._debugEnabled)&&(this._debugDirtyProperties=new Map([["__first__",[]]]))}static toSVG(t,e,s){const n=t?.toSVG();if(n==null||!n.elements.length&&!n.defs?.length)return;const a=(0,import_ag_charts_core2.createSvgElement)("svg");if(a.setAttribute("width",String(e)),a.setAttribute("height",String(s)),a.setAttribute("viewBox",`0 0 ${e} ${s}`),a.setAttribute("overflow","visible"),n.defs?.length){const r=(0,import_ag_charts_core2.createSvgElement)("defs");r.append(...n.defs),a.append(r)}return a.append(...n.elements),a.outerHTML}static*extractBBoxes(t,e){for(const s of t)if(!e||s.visible&&!s.transitionOut){const n=s.getBBox();n&&(yield n)}}get datum(){return this._datum}set datum(t){this._datum!==t&&(this._previousDatum=this._datum,this._datum=t)}get previousDatum(){return this._previousDatum}get unsafeNonNullDatum(){return this.datum}get unsafeDatum(){return this.datum}set unsafeDatum(t){this.datum=t}get unsafePreviousDatum(){return this.previousDatum}get layerManager(){return this.scene?.layersManager}get imageLoader(){return this.scene?.imageLoader}closestDatum(){for(const{datum:t}of this.traverseUp(!0))if(t!=null)return t}unsafeClosestDatum(){return this.closestDatum()}preRender(t,e=1){if(this.childNodeCounts.groups=0,this.childNodeCounts.nonGroups=1,this.childNodeCounts.complexity=e,this.childNodeCounts.thisComplexity=e,this.batchLevel>0||this.batchDirty)throw new Error("AG Charts - illegal rendering state; batched update in progress");return this.childNodeCounts}isolatedRender(t){const e=t.currentFont;t.ctx.save();try{this.render(t)}catch(s){const n=s.errorCount??1;if(n>=MAX_ERROR_COUNT)throw s.errorCount=n,s;import_ag_charts_core2.Logger.warnOnce("Error during rendering",s,s.stack)}finally{t.ctx.restore(),t.currentFont=e}}render(t){const{stats:e}=t;if(this.debugDirtyProperties(),t.debugNodeSearch){const s=this.name??this.id;t.debugNodeSearch.some(n=>typeof n=="string"?n===s:n.test(s))&&(t.debugNodes[this.name??this.id]=this)}e&&(e.nodesRendered++,e.opsPerformed+=this.childNodeCounts.thisComplexity)}setScene(t){this.scene=t}*traverseUp(t){t&&(yield this);let e=this.parentNode;for(;e;)yield e,e=e.parentNode}isRoot(){return!this.parentNode}removeChild(t){throw new Error(`AG Charts - internal error, unknown child node ${t.name??t.id} in $${this.name??this.id}`)}remove(){this.parentNode?.removeChild(this)}destroy(){this.parentNode&&this.remove()}batchedUpdate(t){this.batchLevel++;try{t()}finally{this.batchLevel--,this.batchLevel===0&&this.batchDirty&&(this.markDirty(),this.batchDirty=!1)}}setProperties(t){this.batchLevel++;try{const e=this,s=t,n=Object.keys(s);for(let a=0,r=n.length;a<r;a++){const o=n[a];e[o]=s[o]}}finally{this.batchLevel--,this.batchLevel===0&&this.batchDirty&&(this.markDirty(),this.batchDirty=!1)}return this}setPropertiesWithKeys(t,e){this.batchLevel++;try{const s=this,n=t;for(let a=0,r=e.length;a<r;a++){const o=e[a];s[o]=n[o]}}finally{this.batchLevel--,this.batchLevel===0&&this.batchDirty&&(this.markDirty(),this.batchDirty=!1)}return this}containsPoint(t,e){return!1}distanceSquared(t,e){return 1/0}pickNode(t,e){if(!(!this.visible||this.pointerEvents===1)&&this.containsPoint(t,e))return this}pickNodes(t,e,s=[]){return!this.visible||this.pointerEvents===1||this.containsPoint(t,e)&&s.push(this),s}getBBox(){return this.cachedBBox??(this.cachedBBox=Object.freeze(this.computeBBox())),this.cachedBBox}computeBBox(){}onChangeDetection(t){this.markDirty(t)}markDirtyChildrenOrder(){this.cachedBBox=void 0}markDirty(t){if(this.batchLevel>0){this.batchDirty=!0;return}t!=null&&this._debugDirtyProperties&&this.markDebugProperties(t),this.cachedBBox=void 0,this.parentNode?.markDirty()}markDebugProperties(t){const e=this._debugDirtyProperties?.get(t)??[],s=new Error("Stack trace for property change tracking").stack?.split(`
`).filter(n=>n!=="Error"&&!n.includes(".markDebugProperties")&&!n.includes(".markDirty")&&!n.includes("Object.assign ")&&!n.includes(`${this.constructor.name}.`))??"unknown";e.push(s[0].replace(" at ","").trim()),this._debugDirtyProperties?.set(t,e)}debugDirtyProperties(){if(this._debugDirtyProperties!=null){if(!this._debugDirtyProperties.has("__first__"))for(const[t,e]of this._debugDirtyProperties.entries())e.length>1&&import_ag_charts_core2.Logger.logGroup(`Property changed multiple times before render: ${this.constructor.name}.${t} (${e.length}x)`,()=>{for(const s of e)import_ag_charts_core2.Logger.log(s)});this._debugDirtyProperties.clear()}}static handleNodeZIndexChange(t){t.onZIndexChange()}onZIndexChange(){this.parentNode?.markDirtyChildrenOrder()}resolveFont(){}toSVG(){}};_Node.className="AbstractNode",_Node._nextSerialNumber=0,_Node._debugEnabled=!1,__decorateClass([(0,import_ag_charts_core2.DeclaredSceneChangeDetection)()],_Node.prototype,"visible",2),__decorateClass([(0,import_ag_charts_core2.DeclaredSceneChangeDetection)({equals:import_ag_charts_core2.objectsEqual,changeCb:_Node.handleNodeZIndexChange})],_Node.prototype,"zIndex",2);var Node=_Node,import_ag_charts_core26=require("ag-charts-core"),import_ag_charts_core21=require("ag-charts-core"),import_ag_charts_core5=require("ag-charts-core"),HALF_PIXEL_EPSILON=1e-8;function deviceDimension(i,t){const e=t*i,s=e-Math.floor(e),n=Math.abs(s-.5)<HALF_PIXEL_EPSILON?e+HALF_PIXEL_EPSILON:e;return Math.round(n)}function roundToDevicePixel(i,t){return deviceDimension(i,t)/i}function align(i,t,e){const s=roundToDevicePixel(i,t);return e==null?s:e===0?0:e<1?alignAfter(i,e):roundToDevicePixel(i,e+t)-s}function alignBefore(i,t){return Math.floor(t*i)/i}function alignAfter(i,t){return Math.ceil(t*i)/i}var import_ag_charts_core4=require("ag-charts-core");function clearContext({context:i,pixelRatio:t,width:e,height:s}){i.save();try{i.resetTransform(),i.clearRect(0,0,Math.ceil(e*t),Math.ceil(s*t))}finally{i.restore()}}function debugContext(i){if(import_ag_charts_core4.Debug.check("canvas")){const t=i.save.bind(i),e=i.restore.bind(i);let s=0;Object.assign(i,{save(){t(),s++},restore(){if(s===0)throw new Error("AG Charts - Unable to restore() past depth 0");e(),s--},verifyDepthZero(){if(s!==0)throw new Error(`AG Charts - Save/restore depth is non-zero: ${s}`)}})}}function canvasDimensions(i,t,e){return[deviceDimension(e,i),deviceDimension(e,t)]}var fallbackCanvas;function getFallbackCanvas(){const i=(0,import_ag_charts_core5.getOffscreenCanvas)();return fallbackCanvas??(fallbackCanvas=new i(1,1)),fallbackCanvas}var HdpiOffscreenCanvas=class{constructor(i){const{width:t,height:e,pixelRatio:s,willReadFrequently:n=!1}=i;this.width=t,this.height=e,this.pixelRatio=s;const[a,r]=canvasDimensions(t,e,s),o=(0,import_ag_charts_core5.getOffscreenCanvas)();this.canvas=new o(a,r),this.context=this.canvas.getContext("2d",{willReadFrequently:n}),this.context.setTransform(s,0,0,s,0,0),debugContext(this.context)}drawImage(i,t=0,e=0){return i.drawImage(this.canvas,t,e)}transferToImageBitmap(){return this.canvas.width<1||this.canvas.height<1?getFallbackCanvas().transferToImageBitmap():this.canvas.transferToImageBitmap()}resize(i,t,e){if(!(i>0&&t>0))return;const{canvas:s,context:n}=this;if(i!==this.width||t!==this.height||e!==this.pixelRatio){const[a,r]=canvasDimensions(i,t,e);s.width=a,s.height=r}n.setTransform(e,0,0,e,0,0),this.width=i,this.height=t,this.pixelRatio=e}clear(){clearContext(this)}destroy(){this.canvas.width=0,this.canvas.height=0,this.context.clearRect(0,0,0,0),this.canvas=null,this.context=null,Object.freeze(this)}},import_ag_charts_core18=require("ag-charts-core"),import_ag_charts_core9=require("ag-charts-core"),import_ag_charts_core8=require("ag-charts-core"),import_ag_charts_core7=require("ag-charts-core"),AbstractScale=class{invertWithPercentage(i){return this.invert(i,!0)}snapshotDomain(){return this.domain}restoreDomain(i){this.domain=i}get domainMin(){return this.getDomainMinMax()[0]}get domainMax(){return this.getDomainMinMax()[1]}ticks(i,t,e){}niceDomain(i,t=this.domain){return t}get bandwidth(){}get step(){}get inset(){}},Invalidating=(i,t)=>{const e=Symbol(String(t));i[e]=void 0,Object.defineProperty(i,t,{get(){return this[e]},set(s){this[e]!==s&&(this[e]=s,this.invalid=!0)},enumerable:!0,configurable:!1})},import_ag_charts_core6=require("ag-charts-core");function visibleTickRange(i,t,e){if(e==null||e[0]===0&&e[1]===1)return;const s=(0,import_ag_charts_core6.clamp)(0,Math.floor(e[0]*i.length),i.length),n=(0,import_ag_charts_core6.clamp)(0,Math.ceil(e[1]*i.length),i.length),a=t?i.length-n:s,r=t?i.length-s:n;return[a,r]}function filterVisibleTicks(i,t,e){const s=visibleTickRange(i,t,e);if(s==null)return{ticks:i,count:i.length,firstTickIndex:0};const[n,a]=s;return{ticks:i.slice(n,a),count:i.length,firstTickIndex:n}}function unpackDomainMinMax(i){const t=(0,import_ag_charts_core6.readIntegratedWrappedValue)(i.at(0)),e=(0,import_ag_charts_core6.readIntegratedWrappedValue)(i.at(-1));return t!=null&&e!=null?[t,e]:[void 0,void 0]}var convertColorStringToOklcha=i=>{const t=import_ag_charts_core7.Color.fromString(i),[e,s,n]=import_ag_charts_core7.Color.RGBtoOKLCH(t.r,t.g,t.b);return{l:e,c:s,h:n,a:t.a}},delta=1e-6,isAchromatic=i=>i.c<delta||i.l<delta||i.l>1-delta,interpolateOklch=(i,t,e)=>{e=(0,import_ag_charts_core7.clamp)(0,e,1);let s;if(isAchromatic(i))s=t.h;else if(isAchromatic(t))s=i.h;else{const o=i.h;let h=t.h;const c=t.h-i.h;c>180?h-=360:c<-180&&(h+=360),s=o*(1-e)+h*e}const n=i.c*(1-e)+t.c*e,a=i.l*(1-e)+t.l*e,r=i.a*(1-e)+t.a*e;return import_ag_charts_core7.Color.fromOKLCH(a,n,s,r)},ColorScale=class extends AbstractScale{constructor(){super(...arguments),this.type="color",this.defaultTickCount=0,this.invalid=!0,this.domain=[0,1],this.range=["red","blue"],this.mode="continuous",this.parsedRange=this.range.map(convertColorStringToOklcha)}update(){const{domain:i,range:t}=this;i.length<2&&(import_ag_charts_core7.Logger.warnOnce("`colorDomain` should have at least 2 values."),i.length===0?i.push(0,1):i.length===1&&i.push(i[0]+1));for(let s=1;s<i.length;s++){const n=i[s-1],a=i[s];if(n>a){import_ag_charts_core7.Logger.warnOnce("`colorDomain` values should be supplied in ascending order."),i.sort((r,o)=>r-o);break}}const e=this.mode==="discrete"?i.length-1:i.length;if(t.length<e)for(let s=t.length;s<e;s++)t.push(t.length>0?t[0]:"black");this.parsedRange=this.range.map(convertColorStringToOklcha)}normalizeDomains(...i){return{domain:i.map(t=>t.domain).flat(),animatable:!0}}toDomain(){}convert(i){this.refresh();const t=(0,import_ag_charts_core7.toNumber)(i),{domain:e,range:s,parsedRange:n}=this,a=e[0],r=e.at(-1),o=s[0],h=s.at(-1);if(t<=a)return o;if(t>=r)return h;let c,l;if(e.length===2){const f=(t-a)/(r-a),g=1/(s.length-1);c=s.length<=2?0:Math.min(Math.floor(f*(s.length-1)),s.length-2),l=(f-c*g)/g}else{for(c=0;c<e.length-2&&!(t<e[c+1]);c++);const f=e[c],g=e[c+1];l=(t-f)/(g-f)}if(this.mode==="discrete")return s[c];const u=n[c],d=n[c+1];return interpolateOklch(u,d,l).toRgbaString()}invert(){}getDomainMinMax(){return unpackDomainMinMax(this.domain)}refresh(){this.invalid&&(this.invalid=!1,this.update(),this.invalid&&import_ag_charts_core7.Logger.warnOnce("Expected update to not invalidate scale"))}};__decorateClass([Invalidating],ColorScale.prototype,"domain",2),__decorateClass([Invalidating],ColorScale.prototype,"range",2),__decorateClass([Invalidating],ColorScale.prototype,"mode",2);var Gradient=class{constructor(i,t=[],e){this.colorSpace=i,this.stops=t,this.bbox=e,this._cache=void 0}createGradient(i,t,e){const s=this.bbox??t;if(!s.isFinite())return;if(this._cache?.ctx===i&&this._cache.bbox.equals(s))return this._cache.gradient;const{stops:n,colorSpace:a}=this;if(n.length===0)return;if(n.length===1)return n[0].color;let r=this.createCanvasGradient(i,s,e);if(r==null)return;const o=a==="oklch",h=.05;let c=n[0];r.addColorStop(c.stop,c.color);for(let l=1;l<n.length;l+=1){const u=n[l];if(o){const d=new ColorScale;d.domain=[c.stop,u.stop],d.range=[c.color,u.color];for(let f=c.stop+h;f<u.stop;f+=h)r.addColorStop(f,d.convert(f)??"transparent")}r.addColorStop(u.stop,u.color),c=u}return"createPattern"in r&&(r=r.createPattern()),this._cache={ctx:i,bbox:s,gradient:r},r}toSvg(i){const t=this.bbox??i,e=this.createSvgGradient(t);for(const{stop:s,color:n}of this.stops){const a=(0,import_ag_charts_core8.createSvgElement)("stop");a.setAttribute("offset",`${s}`),a.setAttribute("stop-color",`${n}`),e.appendChild(a)}return e}},ConicGradient=class extends Gradient{constructor(i,t,e=0,s){super(i,t,s),this.angle=e}createCanvasGradient(i,t,e){const{angle:n}=this,a=(0,import_ag_charts_core9.normalizeAngle360FromDegrees)(n+-90),r=e?.centerX??t.x+t.width*.5,o=e?.centerY??t.y+t.height*.5;return i.createConicGradient(a,r,o)}createSvgGradient(i){return(0,import_ag_charts_core9.createSvgElement)("linearGradient")}},import_ag_charts_core10=require("ag-charts-core"),LinearGradient=class extends Gradient{constructor(i,t,e=0,s){super(i,t,s),this.angle=e}getGradientPoints(i){const{angle:e}=this,s=(0,import_ag_charts_core10.normalizeAngle360FromDegrees)(e+90),n=Math.cos(s),a=Math.sin(s),r=i.width,o=i.height,h=i.x+r*.5,c=i.y+o*.5,l=Math.hypot(o,r)/2,u=Math.atan2(o,r);let d;s<Math.PI/2?d=s:s<Math.PI?d=Math.PI-s:s<1.5*Math.PI?d=s-Math.PI:d=2*Math.PI-s;const f=l*Math.abs(Math.cos(d-u));return{x0:h+n*f,y0:c+a*f,x1:h-n*f,y1:c-a*f}}createCanvasGradient(i,t){const{x0:e,y0:s,x1:n,y1:a}=this.getGradientPoints(t);if(!(Number.isNaN(e)||Number.isNaN(s)||Number.isNaN(n)||Number.isNaN(a)))return i.createLinearGradient(e,s,n,a)}createSvgGradient(i){const{x0:t,y0:e,x1:s,y1:n}=this.getGradientPoints(i),a=(0,import_ag_charts_core10.createSvgElement)("linearGradient");return a.setAttribute("x1",String(t)),a.setAttribute("y1",String(e)),a.setAttribute("x2",String(s)),a.setAttribute("y2",String(n)),a.setAttribute("gradientUnits","userSpaceOnUse"),a}},import_ag_charts_core11=require("ag-charts-core"),RadialGradient=class extends Gradient{constructor(i,t,e){super(i,t,e)}createCanvasGradient(i,t,e){const s=e?.centerX??t.x+t.width*.5,n=e?.centerY??t.y+t.height*.5,a=e?.innerRadius??0,r=e?.outerRadius??Math.hypot(t.width*.5,t.height*.5)/Math.SQRT2;return i.createRadialGradient(s,n,a,s,n,r)}createSvgGradient(i){const t=i.x+i.width*.5,e=i.y+i.height*.5,s=(0,import_ag_charts_core11.createSvgElement)("radialGradient");return s.setAttribute("cx",String(t)),s.setAttribute("cy",String(e)),s.setAttribute("r",String(Math.hypot(i.width*.5,i.height*.5)/Math.SQRT2)),s.setAttribute("gradientUnits","userSpaceOnUse"),s}},import_ag_charts_core12=require("ag-charts-core"),StopProperties=class extends import_ag_charts_core12.BaseProperties{constructor(){super(...arguments),this.color="black"}};__decorateClass([import_ag_charts_core12.Property],StopProperties.prototype,"stop",2),__decorateClass([import_ag_charts_core12.Property],StopProperties.prototype,"color",2),__decorateClass([import_ag_charts_core12.Property],StopProperties.prototype,"name",2);var ColorScaleProperties=class extends import_ag_charts_core12.BaseProperties{constructor(){super(...arguments),this.fills=new import_ag_charts_core12.PropertiesArray(StopProperties),this.mode="continuous"}};__decorateClass([import_ag_charts_core12.Property],ColorScaleProperties.prototype,"fills",2),__decorateClass([import_ag_charts_core12.Property],ColorScaleProperties.prototype,"domain",2),__decorateClass([import_ag_charts_core12.Property],ColorScaleProperties.prototype,"mode",2),__decorateClass([import_ag_charts_core12.Property],ColorScaleProperties.prototype,"missingDataFill",2);function getDefaultColorStops(i,t){const e=t==="discrete"?1:0,s=i.map((n,a,{length:r})=>({stop:(a+e)/(r-1+e),color:n}));return t==="discrete"?(0,import_ag_charts_core12.discreteColorStops)(s):s}function getColorStops(i,t,e,s="continuous"){const n=i.map(d=>typeof d=="string"?{color:d}:d);if(n.length===0)return getDefaultColorStops(t,s);const a=Math.min(...e),r=Math.max(...e),o=s==="discrete",h=(0,import_ag_charts_core12.resolveStopPositions)(n,a,r,o);let c=n.find(d=>d.color!=null)?.color,l;const u=n.map((d,f)=>{let g=d?.color;const p=Math.max(0,Math.min(1,(h[f]-a)/(r-a)));return g!=null?c=g:c==null?(l==null&&(l=new ColorScale,l.domain=[0,1],l.range=t),g=l.convert(p)):g=c,{stop:p,color:g}});return s==="discrete"?(0,import_ag_charts_core12.discreteColorStops)(u):u}var import_ag_charts_core13=require("ag-charts-core"),Image=class{constructor(i,t){this.imageLoader=i,this._cache=void 0,this.url=t.url,this.backgroundFill=t.backgroundFill??"black",this.backgroundFillOpacity=t.backgroundFillOpacity??1,this.repeat=t.repeat??"no-repeat",this.width=t.width,this.height=t.height,this.fit=t.fit??"stretch",this.rotation=t.rotation??0}createCanvasImage(i,t,e,s){if(!t)return null;const[n,a]=this.getSize(t.width,t.height,e,s);return n<1||a<1?(import_ag_charts_core13.Logger.warnOnce("Image fill is too small to render, ignoring."),null):i.createPattern(t,this.repeat)}getSize(i,t,e,s){const{fit:n}=this;let a=i,r=t,o=1;const h=e/s,c=i/t;return n==="stretch"||i===0||t===0?(a=e,r=s):n==="contain"?o=c>h?e/i:s/t:n==="cover"&&(o=c>h?s/t:e/i),[Math.max(1,a*o),Math.max(1,r*o)]}setImageTransform(i,t){if(typeof i=="string")return;const{url:e,rotation:s,width:n,height:a}=this,r=this.imageLoader?.loadImage(e);if(!r)return;const o=(0,import_ag_charts_core13.normalizeAngle360FromDegrees)(s),h=Math.cos(o),c=Math.sin(o),[l,u]=this.getSize(r.width,r.height,n??t.width,a??t.height),d=l/r.width,f=u/r.height,g=t.x+t.width/2,p=t.y+t.height/2,y=h*l-c*u,m=c*l+h*u,b=y/2,v=m/2,S=(0,import_ag_charts_core13.getDOMMatrix)();i?.setTransform(new S([h*d,c*f,-c*d,h*f,g-b,p-v]))}createPattern(i,t,e,s){const n=this.width??t,a=this.height??e,r=this._cache;if(r?.ctx===i&&r.width===n&&r.height===a)return r.pattern;const o=this.imageLoader?.loadImage(this.url,s),h=this.createCanvasImage(i,o,n,a);if(h!=null)return this._cache={ctx:i,pattern:h,width:n,height:a},h}toSvg(i,t){const{url:e,rotation:s,backgroundFill:n,backgroundFillOpacity:a}=this,{x:r,y:o,width:h,height:c}=i,l=(0,import_ag_charts_core13.createSvgElement)("pattern");l.setAttribute("viewBox",`0 0 ${h} ${c}`),l.setAttribute("x",String(r)),l.setAttribute("y",String(o)),l.setAttribute("width",String(h)),l.setAttribute("height",String(c)),l.setAttribute("patternUnits","userSpaceOnUse");const u=(0,import_ag_charts_core13.createSvgElement)("rect");u.setAttribute("x","0"),u.setAttribute("y","0"),u.setAttribute("width",String(h)),u.setAttribute("height",String(c)),u.setAttribute("fill",n),u.setAttribute("fill-opacity",String(a)),l.appendChild(u);const d=(0,import_ag_charts_core13.createSvgElement)("image");return d.setAttribute("href",e),d.setAttribute("x","0"),d.setAttribute("y","0"),d.setAttribute("width",String(h)),d.setAttribute("height",String(c)),d.setAttribute("preserveAspectRatio","none"),d.setAttribute("transform",`scale(${1/t}) rotate(${s}, ${h/2}, ${c/2})`),l.appendChild(d),l}},import_ag_charts_core17=require("ag-charts-core"),import_ag_charts_core15=require("ag-charts-core"),import_ag_charts_core14=require("ag-charts-core"),commandEx=/^[\t\n\f\r ]*([achlmqstvz])[\t\n\f\r ]*/i,coordinateEx=/^[+-]?((\d*\.\d+)|(\d+\.)|(\d+))(e[+-]?\d+)?/i,commaEx=/[\t\n\f\r ]*,?[\t\n\f\r ]*/,flagEx=/^[01]/,pathParams={z:[],h:[coordinateEx],v:[coordinateEx],m:[coordinateEx,coordinateEx],l:[coordinateEx,coordinateEx],t:[coordinateEx,coordinateEx],s:[coordinateEx,coordinateEx,coordinateEx,coordinateEx],q:[coordinateEx,coordinateEx,coordinateEx,coordinateEx],c:[coordinateEx,coordinateEx,coordinateEx,coordinateEx,coordinateEx,coordinateEx],a:[coordinateEx,coordinateEx,coordinateEx,flagEx,flagEx,coordinateEx,coordinateEx]};function parseSvg(i){if(!i)return;const t=[];let e=0,s;for(;e<i.length;){const n=commandEx.exec(i.slice(e));let a;if(n==null){if(!s){import_ag_charts_core14.Logger.warnOnce(`Invalid SVG path, error at index ${e}: Missing command.`);return}a=s}else a=n[1],e+=n[0].length;const r=parseSegment(a,i,e);if(!r)return;e=r[0],s=a,t.push(r[1])}return t}function parseSegment(i,t,e){const s=pathParams[i.toLocaleLowerCase()],n={command:i,params:[]};for(const a of s){const r=t.slice(e),o=a.exec(r);if(o!=null){n.params.push(Number.parseFloat(o[0])),e+=o[0].length;const h=commaEx.exec(r.slice(o[0].length));h!=null&&(e+=h[0].length)}else{if(n.params.length===1)return[e,n];import_ag_charts_core14.Logger.warnOnce(`Invalid SVG path, error at index ${e}: No path segment parameters for command [${i}]`);return}}return[e,n]}function linearRoot(i,t){const e=-t/i;return i!==0&&e>=0&&e<=1?[e]:[]}function quadraticRoots(i,t,e,s=1e-6){if(Math.abs(i)<s)return linearRoot(t,e);const n=t*t-4*i*e,a=[];if(Math.abs(n)<s){const r=-t/(2*i);r>=0&&r<=1&&a.push(r)}else if(n>0){const r=Math.sqrt(n),o=(-t-r)/(2*i),h=(-t+r)/(2*i);o>=0&&o<=1&&a.push(o),h>=0&&h<=1&&a.push(h)}return a}function cubicRoots(i,t,e,s,n=1e-6){if(Math.abs(i)<n)return quadraticRoots(t,e,s,n);const a=t/i,r=e/i,o=s/i,h=(3*r-a*a)/9,c=(9*a*r-27*o-2*a*a*a)/54,l=h*h*h+c*c,u=1/3,d=[];if(l>=0){const f=Math.sqrt(l),g=Math.sign(c+f)*Math.pow(Math.abs(c+f),u),p=Math.sign(c-f)*Math.pow(Math.abs(c-f),u),y=Math.abs(Math.sqrt(3)*(g-p)/2),m=-u*a+(g+p);if(m>=0&&m<=1&&d.push(m),Math.abs(y)<n){const b=-u*a-(g+p)/2;b>=0&&b<=1&&d.push(b)}}else{const f=Math.acos(c/Math.sqrt(-h*h*h)),g=u*a,p=2*Math.sqrt(-h),y=p*Math.cos(u*f)-g,m=p*Math.cos(u*(f+2*Math.PI))-g,b=p*Math.cos(u*(f+4*Math.PI))-g;y>=0&&y<=1&&d.push(y),m>=0&&m<=1&&d.push(m),b>=0&&b<=1&&d.push(b)}return d}function segmentIntersection(i,t,e,s,n,a,r,o){const h=(e-i)*(o-a)-(s-t)*(r-n);if(h===0)return 0;const c=((r-n)*(t-a)-(i-n)*(o-a))/h,l=((e-i)*(t-a)-(s-t)*(i-n))/h;return c>=0&&c<=1&&l>=0&&l<=1?1:0}function cubicSegmentIntersections(i,t,e,s,n,a,r,o,h,c,l,u){let d=0;const f=c-u,g=l-h,p=h*(u-c)-c*(l-h),y=bezierCoefficients(i,e,n,r),m=bezierCoefficients(t,s,a,o),b=f*y[0]+g*m[0],v=f*y[1]+g*m[1],S=f*y[2]+g*m[2],M=f*y[3]+g*m[3]+p,C=cubicRoots(b,v,S,M);for(const x of C){const _=x*x,P=x*_,w=y[0]*P+y[1]*_+y[2]*x+y[3],k=m[0]*P+m[1]*_+m[2]*x+m[3];let N;h===l?N=(k-c)/(u-c):N=(w-h)/(l-h),N>=0&&N<=1&&d++}return d}function bezierCoefficients(i,t,e,s){return[-i+3*t-3*e+s,3*i-6*t+3*e,-3*i+3*t,i]}var ExtendedPath2D=class{constructor(){this.previousCommands=[],this.previousParams=[],this.previousClosedPath=!1,this.commands=[],this.params=[],this.commandsLength=0,this.paramsLength=0,this.cx=Number.NaN,this.cy=Number.NaN,this.sx=Number.NaN,this.sy=Number.NaN,this.openedPath=!1,this.closedPath=!1;const i=(0,import_ag_charts_core15.getPath2D)();this.path2d=new i}isEmpty(){return this.commandsLength===0}isDirty(){return this.closedPath!==this.previousClosedPath||this.previousCommands.length!==this.commandsLength||this.previousParams.length!==this.paramsLength||this.previousCommands.toString()!==this.commands.slice(0,this.commandsLength).toString()||this.previousParams.toString()!==this.params.slice(0,this.paramsLength).toString()}getPath2D(){return this.path2d}moveTo(i,t){this.openedPath=!0,this.sx=i,this.sy=t,this.cx=i,this.cy=t,this.path2d.moveTo(i,t),this.commands[this.commandsLength++]=0,this.params[this.paramsLength++]=i,this.params[this.paramsLength++]=t}lineTo(i,t){this.openedPath?(this.cx=i,this.cy=t,this.path2d.lineTo(i,t),this.commands[this.commandsLength++]=1,this.params[this.paramsLength++]=i,this.params[this.paramsLength++]=t):this.moveTo(i,t)}cubicCurveTo(i,t,e,s,n,a){this.openedPath||this.moveTo(i,t),this.path2d.bezierCurveTo(i,t,e,s,n,a),this.commands[this.commandsLength++]=2,this.params[this.paramsLength++]=i,this.params[this.paramsLength++]=t,this.params[this.paramsLength++]=e,this.params[this.paramsLength++]=s,this.params[this.paramsLength++]=n,this.params[this.paramsLength++]=a}closePath(){this.openedPath&&(this.cx=this.sx,this.cy=this.sy,this.sx=Number.NaN,this.sy=Number.NaN,this.path2d.closePath(),this.commands[this.commandsLength++]=3,this.openedPath=!1,this.closedPath=!0)}rect(i,t,e,s){this.moveTo(i,t),this.lineTo(i+e,t),this.lineTo(i+e,t+s),this.lineTo(i,t+s),this.closePath()}roundRect(i,t,e,s,n){n=Math.min(n,e/2,s/2),this.moveTo(i,t+n),this.arc(i+n,t+n,n,Math.PI,1.5*Math.PI),this.lineTo(i+n,t),this.lineTo(i+e-n,t),this.arc(i+e-n,t+n,n,1.5*Math.PI,2*Math.PI),this.lineTo(i+e,t+n),this.lineTo(i+e,t+s-n),this.arc(i+e-n,t+s-n,n,0,Math.PI/2),this.lineTo(i+e-n,t+s),this.lineTo(i+n,t+s),this.arc(i+ +n,t+s-n,n,Math.PI/2,Math.PI),this.lineTo(i,t+s-n),this.closePath()}ellipse(i,t,e,s,n,a,r,o=!1){const h=e,c=s/e,l=Math.cos(n),u=Math.sin(n),d=-c*u,f=c*l,g=h*Math.cos(a),p=h*Math.sin(a),y=i+l*g+d*p,m=t+u*g+f*p,b=(y-this.cx)**2+(m-this.cy)**2;this.openedPath?b>1e-6&&this.lineTo(y,m):this.moveTo(y,m);let v=o?-(0,import_ag_charts_core15.normalizeAngle360)(a-r):(0,import_ag_charts_core15.normalizeAngle360)(r-a);Math.abs(Math.abs(r-a)-2*Math.PI)<1e-6&&v<2*Math.PI&&(v+=2*Math.PI*(o?-1:1));const S=Math.max(Math.ceil(Math.abs(v)/(Math.PI/2)),1),M=v/S,C=4/3*Math.tan(M/4);for(let x=0;x<S;x+=1){const _=a+M*(x+0),P=a+M*(x+1),w=h*Math.sin(_),k=h*Math.cos(_),N=h*Math.sin(P),L=h*Math.cos(P),E=k-C*w,z=w+C*k,B=L+C*N,F=N-C*L,D=L,I=N;this.cubicCurveTo(i+l*E+d*z,t+u*E+f*z,i+l*B+d*F,t+u*B+f*F,i+l*D+d*I,t+u*D+f*I)}}arc(i,t,e,s,n,a){this.ellipse(i,t,e,e,0,s,n,a)}appendSvg(i){const t=parseSvg(i);if(t==null)return!1;let e=0,s=0,n,a,r=0,o=0;for(const{command:h,params:c}of t){n??(n=c[0]),a??(a=c[1]);const l=h===h.toLowerCase(),u=l?n:0,d=l?a:0;switch(h.toLowerCase()){case"m":this.moveTo(u+c[0],d+c[1]),n=u+c[0],a=d+c[1],e=n,s=a;break;case"c":this.cubicCurveTo(u+c[0],d+c[1],u+c[2],d+c[3],u+c[4],d+c[5]),r=u+c[2],o=d+c[3],n=u+c[4],a=d+c[5];break;case"s":this.cubicCurveTo(n+n-r,a+a-o,u+c[0],d+c[1],u+c[2],d+c[3]),r=u+c[0],o=d+c[1],n=u+c[2],a=d+c[3];break;case"q":this.cubicCurveTo((u+2*c[0])/3,(d+2*c[1])/3,(2*c[0]+c[2])/3,(2*c[1]+c[3])/3,c[2],c[3]),r=c[0],o=c[1],n=c[2],a=c[3];break;case"t":this.cubicCurveTo((n+2*(n+n-r))/3,(a+2*(a+a-o))/3,(2*(n+n-r)+c[0])/3,(2*(a+a-o)+c[1])/3,c[0],c[1]),r=n+n-r,o=a+a-o,n=c[0],a=c[1];break;case"a":this.svgEllipse(n,a,c[0],c[1],c[2]*Math.PI/180,c[3],c[4],u+c[5],d+c[6]),n=u+c[5],a=d+c[6];break;case"h":this.lineTo(u+c[0],a),n=u+c[0];break;case"l":this.lineTo(u+c[0],d+c[1]),n=u+c[0],a=d+c[1];break;case"v":this.lineTo(n,d+c[0]),a=d+c[0];break;case"z":this.closePath(),n=e,a=s;break;default:throw new Error(`Could not translate command '${h}' with '${c.join(" ")}'`)}}return!0}svgEllipse(i,t,e,s,n,a,r,o,h){e=Math.abs(e),s=Math.abs(s);const c=(i-o)/2,l=(t-h)/2,u=Math.sin(n),d=Math.cos(n),f=d*c+u*l,g=-u*c+d*l,p=f/e,y=g/s;let m=p*p+y*y,b=(i+o)/2,v=(t+h)/2,S=0,M=0;m>=1?(m=Math.sqrt(m),e*=m,s*=m):(m=Math.sqrt(1/m-1),a===r&&(m=-m),S=m*e*y,M=-m*s*p,b+=d*S-u*M,v+=u*S+d*M);const C=Math.atan2((g-M)/s,(f-S)/e),x=Math.atan2((-g-M)/s,(-f-S)/e)-C,_=C+x,P=!!(1-r);this.ellipse(b,v,e,s,n,C,_,P)}clear(i){i?(this.previousCommands=this.commands.slice(0,this.commandsLength),this.previousParams=this.params.slice(0,this.paramsLength),this.previousClosedPath=this.closedPath,this.commands=[],this.params=[],this.commandsLength=0,this.paramsLength=0):(this.commandsLength=0,this.paramsLength=0);const t=(0,import_ag_charts_core15.getPath2D)();this.path2d=new t,this.openedPath=!1,this.closedPath=!1}isPointInPath(i,t){const e=this.commands,s=this.params,n=this.commandsLength,a=-1e4,r=-1e4;let o=Number.NaN,h=Number.NaN,c=0,l=0,u=0;for(let d=0,f=0;d<n;d++)switch(e[d]){case 0:u+=segmentIntersection(o,h,c,l,a,r,i,t),c=s[f++],o=c,l=s[f++],h=l;break;case 1:u+=segmentIntersection(c,l,s[f++],s[f++],a,r,i,t),c=s[f-2],l=s[f-1];break;case 2:u+=cubicSegmentIntersections(c,l,s[f++],s[f++],s[f++],s[f++],s[f++],s[f++],a,r,i,t),c=s[f-2],l=s[f-1];break;case 3:u+=segmentIntersection(o,h,c,l,a,r,i,t);break}return u%2===1}distanceSquared(i,t){let e=1/0;const s=this.commands,n=this.params,a=this.commandsLength;let r=Number.NaN,o=Number.NaN,h=0,c=0;for(let l=0,u=0;l<a;l++)switch(s[l]){case 0:h=r=n[u++],c=o=n[u++];break;case 1:{const d=h,f=c;h=n[u++],c=n[u++],e=(0,import_ag_charts_core15.lineDistanceSquared)(i,t,d,f,h,c,e);break}case 2:{const d=h,f=c,g=n[u++],p=n[u++],y=n[u++],m=n[u++];h=n[u++],c=n[u++],e=(0,import_ag_charts_core15.bezier2DDistance)(d,f,g,p,y,m,h,c,i,t)**2;break}case 3:e=(0,import_ag_charts_core15.lineDistanceSquared)(i,t,h,c,r,o,e);break}return e}toSVG(i=(t,e)=>({x:t,y:e})){const t=[],{commands:e,params:s}=this,n=(r,o)=>{t.push(r);for(let h=0;h<o;h+=2){const{x:c,y:l}=i(s[a++],s[a++]);t.push(c,l)}};let a=0;for(let r=0;r<this.commandsLength;r++)switch(e[r]){case 0:n("M",2);break;case 1:n("L",2);break;case 2:n("C",6);break;case 3:n("Z",0);break}return t.join(" ")}computeBBox(){const{commands:i,params:t}=this;let[e,s,n,a]=[1/0,1/0,-1/0,-1/0],[r,o]=[Number.NaN,Number.NaN],[h,c]=[Number.NaN,Number.NaN];const l=(d,f)=>{e=Math.min(f,e),s=Math.min(d,s),n=Math.max(d,n),a=Math.max(f,a),r=d,o=f};let u=0;for(let d=0;d<this.commandsLength;d++)switch(i[d]){case 0:l(t[u++],t[u++]),h=r,c=o;break;case 1:l(t[u++],t[u++]);break;case 2:{const g=r,p=o,y=t[u++],m=t[u++],b=t[u++],v=t[u++],S=t[u++],M=t[u++],C=(0,import_ag_charts_core15.bezier2DExtrema)(g,p,y,m,b,v,S,M);for(const x of C){const _=(0,import_ag_charts_core15.evaluateBezier)(g,y,b,S,x),P=(0,import_ag_charts_core15.evaluateBezier)(p,m,v,M,x);l(_,P)}l(S,M);break}case 3:l(h,c),h=Number.NaN,c=Number.NaN;break}return new BBox(s,e,n-s,a-e)}},import_ag_charts_core16=require("ag-charts-core");function drawPatternUnitPolygon(i,t,e){const{width:s,height:n,padding:a,strokeWidth:r}=t,o=s/2,h=n/2,c=Math.max(1,s-a-r/2),l=Math.max(1,n-a-r/2);let u=!1;for(const[d,f]of e){const g=o+(d-.5)*c,p=h+(f-.5)*l;u?i.lineTo(g,p):i.moveTo(g,p),u=!0}i.closePath()}var PATTERNS={circles(i,{width:t,strokeWidth:e,padding:s}){const n=t/2,a=Math.max(1,n-s-e/2);i.arc(n,n,a,0,Math.PI*2)},squares(i,{width:t,height:e,pixelRatio:s,padding:n,strokeWidth:a}){const r=n+a/2;i.moveTo(align(s,r),align(s,r)),i.lineTo(align(s,t-r),align(s,r)),i.lineTo(align(s,t-r),align(s,e-r)),i.lineTo(align(s,r),align(s,e-r)),i.closePath()},triangles(i,t){drawPatternUnitPolygon(i,t,[[.5,0],[1,1],[0,1]])},diamonds(i,t){drawPatternUnitPolygon(i,t,[[.5,0],[1,.5],[.5,1],[0,.5]])},stars(i,{width:t,height:e,padding:s}){const a=Math.max(1,(t-s)/2),r=a/2,o=Math.PI/2;for(let h=0;h<5*2;h++){const c=h%2===0?a:r,l=h*Math.PI/5-o,u=t/2+Math.cos(l)*c,d=e/2+Math.sin(l)*c;i.lineTo(u,d)}i.closePath()},hearts(i,{width:t,height:e,padding:s}){const n=Math.max(1,t/4-s/2),a=t/2,r=e/2+n/2;i.arc(a-n,r-n,n,(0,import_ag_charts_core16.toRadians)(130),(0,import_ag_charts_core16.toRadians)(330)),i.arc(a+n,r-n,n,(0,import_ag_charts_core16.toRadians)(220),(0,import_ag_charts_core16.toRadians)(50)),i.lineTo(a,r+n),i.closePath()},crosses(i,t){drawPatternUnitPolygon(i,t,[[.25,0],[.5,.25],[.75,0],[1,.25],[.75,.5],[1,.75],[.75,1],[.5,.75],[.25,1],[0,.75],[.25,.5],[0,.25]])},"vertical-lines"(i,{width:t,height:e,pixelRatio:s,strokeWidth:n}){const a=align(s,t/2)-n%2/2;i.moveTo(a,0),i.lineTo(a,e)},"horizontal-lines"(i,{width:t,height:e,pixelRatio:s,strokeWidth:n}){const a=align(s,e/2)-n%2/2;i.moveTo(0,a),i.lineTo(t,a)},"forward-slanted-lines"(i,{width:t,height:e,strokeWidth:s}){const n=Math.atan2(e,t),a=s*Math.cos(n),r=s*Math.sin(n);i.moveTo(-a,r),i.lineTo(a,-r),i.moveTo(-a,e+r),i.lineTo(t+a,-r),i.moveTo(t-a,e+r),i.lineTo(t+a,e-r)},"backward-slanted-lines"(i,{width:t,height:e,strokeWidth:s}){const n=Math.atan2(e,t),a=s*Math.cos(n),r=s*Math.sin(n);i.moveTo(t-a,-r),i.lineTo(t+a,r),i.moveTo(-a,-r),i.lineTo(t+a,e+r),i.moveTo(-a,e-r),i.lineTo(a,e+r)}},Pattern=class{constructor(i){this._cache=void 0,this.width=Math.max(i?.width??10,1),this.height=Math.max(i?.height??10,1),this.fill=i.fill??"none",this.fillOpacity=i.fillOpacity??1,this.backgroundFill=i.backgroundFill??"none",this.backgroundFillOpacity=i.backgroundFillOpacity??1,this.stroke=i.stroke??"black",this.strokeOpacity=i.strokeOpacity??1,this.strokeWidth=i.strokeWidth??1,this.padding=i.padding??1,this.pattern=i.pattern??"forward-slanted-lines",this.rotation=i.rotation??0,this.scale=i.scale??1,this.path=i.path}getPath(i){const{pattern:t,width:e,height:s,padding:n,strokeWidth:a,path:r}=this,o=new ExtendedPath2D;let h=PATTERNS[t]!=null;return r&&h&&(h=!o.appendSvg(r)),h&&PATTERNS[t](o,{width:e,height:s,pixelRatio:i,strokeWidth:a,padding:n}),o}renderStroke(i,t){const{stroke:e,strokeWidth:s,strokeOpacity:n}=this;s&&(t.strokeStyle=e,t.lineWidth=s,t.globalAlpha=n,t.stroke(i))}renderFill(i,t){const{fill:e,fillOpacity:s}=this;e!=="none"&&(t.fillStyle=e,t.globalAlpha=s,t.fill(i))}createCanvasPattern(i,t){const{width:e,height:s,scale:n,backgroundFill:a,backgroundFillOpacity:r}=this;if(e*n<1||s*n<1)return import_ag_charts_core17.Logger.warnOnce("Pattern fill is too small to render, ignoring."),null;const o=new HdpiOffscreenCanvas({width:e,height:s,pixelRatio:t*n}),h=o.context;a!=="none"&&(h.fillStyle=a,h.globalAlpha=r,h.fillRect(0,0,e,s));const c=this.getPath(t).getPath2D();this.renderFill(c,h),this.renderStroke(c,h);const l=i.createPattern(o.canvas,"repeat");return this.setPatternTransform(l,t),o.destroy(),l}setPatternTransform(i,t,e=0,s=0){if(i==null)return;const n=(0,import_ag_charts_core17.normalizeAngle360FromDegrees)(this.rotation),a=1/t,r=Math.cos(n)*a,o=Math.sin(n)*a,h=(0,import_ag_charts_core17.getDOMMatrix)();i.setTransform(new h([r,o,-o,r,e,s]))}createPattern(i,t){if(this._cache?.ctx===i&&this._cache.pixelRatio===t)return this._cache.pattern;const e=this.createCanvasPattern(i,t);if(e!=null)return this._cache={ctx:i,pattern:e,pixelRatio:t},e}toSvg(){const{width:i,height:t,fill:e,fillOpacity:s,backgroundFill:n,backgroundFillOpacity:a,stroke:r,strokeWidth:o,strokeOpacity:h,rotation:c,scale:l}=this,u=(0,import_ag_charts_core17.createSvgElement)("pattern");u.setAttribute("viewBox",`0 0 ${i} ${t}`),u.setAttribute("width",String(i)),u.setAttribute("height",String(t)),u.setAttribute("patternUnits","userSpaceOnUse");const d=(0,import_ag_charts_core17.createSvgElement)("rect");d.setAttribute("x","0"),d.setAttribute("y","0"),d.setAttribute("width",String(i)),d.setAttribute("height",String(t)),d.setAttribute("fill",n),d.setAttribute("fill-opacity",String(a)),u.appendChild(d);const f=(0,import_ag_charts_core17.createSvgElement)("path");return f.setAttribute("fill",e),f.setAttribute("fill-opacity",String(s)),f.setAttribute("stroke-opacity",String(h)),f.setAttribute("stroke",r),f.setAttribute("stroke-width",String(o)),f.setAttribute("transform",`rotate(${c}) scale(${l})`),f.setAttribute("d",this.getPath(1).toSVG()),u.appendChild(f),u}};function setSvgFontAttributes(i,t){const{fontStyle:e,fontWeight:s,fontSize:n,fontFamily:a}=t;e&&i.setAttribute("font-style",e),s&&i.setAttribute("font-weight",String(s)),n!=null&&i.setAttribute("font-size",String(n)),a&&i.setAttribute("font-family",a)}function setSvgStrokeAttributes(i,t){const{stroke:e,strokeWidth:s,strokeOpacity:n}=t;e&&i.setAttribute("stroke",e),s!=null&&i.setAttribute("stroke-width",String(s)),n!=null&&i.setAttribute("stroke-opacity",String(n))}function setSvgLineDashAttributes(i,t){const{lineDash:e,lineDashOffset:s}=t;if(e?.some(n=>n!==0)){const n=e.length%2===1?[...e,...e]:e;i.setAttribute("stroke-dasharray",n.join(" ")),s!=null&&i.setAttribute("stroke-dashoffset",String(s))}}var _Shape=class extends Node{constructor(){super(...arguments),this.drawingMode="overlay",this.fillOpacity=1,this.strokeOpacity=1,this.fill="black",this.strokeWidth=0,this.lineDashOffset=0,this.opacity=1}getGradient(t){if((0,import_ag_charts_core18.isGradientFill)(t))return this.createGradient(t)}createGradient(t){const{colorSpace:e="rgb",gradient:s="linear",colorStops:n,rotation:a=0,reverse:r=!1}=t;if(n==null)return;let o=getColorStops(n,["black"],[0,1]);switch(r&&(o=o.map(h=>({color:h.color,stop:1-h.stop})).reverse()),s){case"linear":return new LinearGradient(e,o,a);case"radial":return new RadialGradient(e,o);case"conic":return new ConicGradient(e,o,a)}}getPattern(t){if((0,import_ag_charts_core18.isPatternFill)(t))return this.createPattern(t)}createPattern(t){return new Pattern(t)}getImage(t){if((0,import_ag_charts_core18.isImageFill)(t))return this.createImage(t)}createImage(t){return new Image(this.imageLoader,t)}onFillChange(){typeof this.fill=="object"&&(0,import_ag_charts_core18.objectsEqual)(this._cachedFill??{},this.fill)||(this.fillGradient=this.getGradient(this.fill),this.fillPattern=this.getPattern(this.fill),this.fillImage=this.getImage(this.fill),this._cachedFill=this.fill)}onStrokeChange(){this.strokeGradient=this.getGradient(this.stroke)}align(t,e){return align(this.layerManager?.canvas?.pixelRatio??1,t,e)}markDirty(t){super.markDirty(t),this.cachedDefaultGradientFillBBox=void 0}fillStroke(t,e,s,n){this.__drawingMode==="cutout"&&(t.globalCompositeOperation="destination-out",this.executeFill(t,e),t.globalCompositeOperation="source-over"),this.renderFill(t,e,s,n),this.renderStroke(t,e,s)}renderFill(t,e,s,n){const{__fill:a,__fillOpacity:r=1,fillImage:o}=this;if(a!=null&&a!=="none"&&r>0){const h=t.globalAlpha;o&&(t.globalAlpha=o.backgroundFillOpacity,t.fillStyle=o.backgroundFill,this.executeFill(t,e),t.globalAlpha=h),this.applyFillAndAlpha(t,s,n),this.applyShadow(t),this.executeFill(t,e),t.globalAlpha=h,this.fillShadow?.enabled&&(t.shadowColor="rgba(0, 0, 0, 0)")}}executeFill(t,e){e?t.fill(e):t.fill()}applyFillAndAlpha(t,e,s){const{__fill:n,fillGradient:a,fillPattern:r,fillImage:o,__fillOpacity:h=1,__opacity:c=1}=this,l=c*h;if(l!==1&&(t.globalAlpha*=l),a){const u=s??this.fillBBox??this.getDefaultGradientFillBBox()??e??this.getBBox(),{fillParams:d}=this;t.fillStyle=a.createGradient(t,u,d)??"black"}else if(r){const{x:u,y:d}=e??this.getBBox(),f=this.layerManager?.canvas?.pixelRatio??1,g=r.createPattern(t,f);r.setPatternTransform(g,f,u,d),g?t.fillStyle=g:(t.fillStyle=r.fill,t.globalAlpha*=r.fillOpacity)}else if(o){const u=e??this.getBBox(),d=o.createPattern(t,u.width,u.height,this);o.setImageTransform(d,u),t.fillStyle=d??"transparent"}else t.fillStyle=typeof n=="string"?n:"black"}applyStrokeAndAlpha(t,e){const{__stroke:s,__strokeOpacity:n=1,strokeGradient:a,__opacity:r=1}=this;t.strokeStyle=a?.createGradient(t,e??this.getBBox())??(typeof s=="string"?s:void 0)??"black";const o=r*n;o!==1&&(t.globalAlpha*=o)}applyShadow(t){const e=this.layerManager?.canvas.pixelRatio??1,{__fillShadow:s}=this;s?.enabled&&(t.shadowColor=s.color,t.shadowOffsetX=s.xOffset*e,t.shadowOffsetY=s.yOffset*e,t.shadowBlur=s.blur*e)}renderStroke(t,e,s){const{__stroke:n,__strokeWidth:a=0,__strokeOpacity:r=1,__lineDash:o,__lineDashOffset:h,__lineCap:c,__lineJoin:l,__miterLimit:u}=this;if(n!=null&&n!=="none"&&a>0&&r>0){const{globalAlpha:d}=t;this.applyStrokeAndAlpha(t,s),t.lineWidth=a,o&&t.setLineDash(o),h&&(t.lineDashOffset=h),c&&(t.lineCap=c),l&&(t.lineJoin=l),u!=null&&(t.miterLimit=u),this.executeStroke(t,e),t.globalAlpha=d}}executeStroke(t,e){e?t.stroke(e):t.stroke()}getDefaultGradientFillBBox(){return this.cachedDefaultGradientFillBBox??(this.cachedDefaultGradientFillBBox=Object.freeze(this.computeDefaultGradientFillBBox())),this.cachedDefaultGradientFillBBox}computeDefaultGradientFillBBox(){}containsPoint(t,e){return this.isPointInPath(t,e)}applySvgFillAttributes(t,e){const{fill:s,fillOpacity:n}=this;if(typeof s=="string")t.setAttribute("fill",s);else if((0,import_ag_charts_core18.isGradientFill)(s)&&this.fillGradient){e??(e=[]);const a=this.fillGradient.toSvg(this.fillBBox??this.getBBox()),r=(0,import_ag_charts_core18.generateUUID)();a.setAttribute("id",r),e.push(a),t.setAttribute("fill",`url(#${r})`)}else if((0,import_ag_charts_core18.isPatternFill)(s)&&this.fillPattern){e??(e=[]);const a=this.fillPattern.toSvg(),r=(0,import_ag_charts_core18.generateUUID)();a.setAttribute("id",r),e.push(a),t.setAttribute("fill",`url(#${r})`)}else if((0,import_ag_charts_core18.isImageFill)(s)&&this.fillImage){e??(e=[]);const a=this.layerManager?.canvas?.pixelRatio??1,r=this.fillImage.toSvg(this.getBBox(),a),o=(0,import_ag_charts_core18.generateUUID)();r.setAttribute("id",o),e.push(r),t.setAttribute("fill",`url(#${o})`)}else t.setAttribute("fill","none");return t.setAttribute("fill-opacity",String(n)),e}applySvgStrokeAttributes(t){const{stroke:e,strokeOpacity:s,strokeWidth:n,lineDash:a,lineDashOffset:r}=this;setSvgStrokeAttributes(t,{stroke:(0,import_ag_charts_core18.isString)(e)?e:void 0,strokeOpacity:s,strokeWidth:n}),setSvgLineDashAttributes(t,{lineDash:a,lineDashOffset:r})}static handleFillChange(t){t.onFillChange()}static handleStrokeChange(t){t.onStrokeChange()}setStyleProperties(t,e,s){const n=t?.opacity??1,a=t?.fill,r=(t?.fillOpacity??1)*n,o=(t?.strokeOpacity??1)*n,h=t?.strokeWidth??0,c=t?.lineDashOffset??0;let l=!1;this.__fillOpacity!==r&&(this.__fillOpacity=r,l=!0),this.__strokeOpacity!==o&&(this.__strokeOpacity=o,l=!0),this.__strokeWidth!==h&&(this.__strokeWidth=h,l=!0),this.__lineDashOffset!==c&&(this.__lineDashOffset=c,l=!0),this.__lineDash!==t?.lineDash&&(this.__lineDash=t?.lineDash,l=!0),this.setFillProperties(a,e,s),a!==this.fill&&(this.fill=a),t?.stroke!==this.stroke&&(this.stroke=t?.stroke),l&&this.markDirty()}setFillProperties(t,e,s){const n=e==null||!(0,import_ag_charts_core18.isGradientFill)(t)||t.bounds==null||t.bounds==="item"?void 0:e[t.bounds];let a=!1;this.__fillBBox!==n&&(this.__fillBBox=n,a=!0),this.__fillParams!==s&&(this.__fillParams=s,a=!0),a&&(this.onFillChange(),this.markDirty())}};__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"drawingMode",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"fillOpacity",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"strokeOpacity",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneObjectChangeDetection)({equals:import_ag_charts_core18.objectsEqual,changeCb:_Shape.handleFillChange})],_Shape.prototype,"fill",2),__decorateClass([(0,import_ag_charts_core18.SceneObjectChangeDetection)({equals:import_ag_charts_core18.objectsEqual,changeCb:_Shape.handleStrokeChange})],_Shape.prototype,"stroke",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"strokeWidth",2),__decorateClass([(0,import_ag_charts_core18.SceneArrayChangeDetection)()],_Shape.prototype,"lineDash",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"lineDashOffset",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"lineCap",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"lineJoin",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)()],_Shape.prototype,"miterLimit",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneChangeDetection)({convertor:i=>(0,import_ag_charts_core18.clamp)(0,i??1,1)})],_Shape.prototype,"opacity",2),__decorateClass([(0,import_ag_charts_core18.SceneObjectChangeDetection)({equals:import_ag_charts_core18.TRIPLE_EQ,checkDirtyOnAssignment:!0})],_Shape.prototype,"fillShadow",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneObjectChangeDetection)({equals:import_ag_charts_core18.boxesEqual,changeCb:i=>i.onFillChange()})],_Shape.prototype,"fillBBox",2),__decorateClass([(0,import_ag_charts_core18.DeclaredSceneObjectChangeDetection)({equals:import_ag_charts_core18.objectsEqual,changeCb:i=>i.onFillChange()})],_Shape.prototype,"fillParams",2);var Shape=_Shape,import_ag_charts_core20=require("ag-charts-core"),import_ag_charts_core19=require("ag-charts-core"),IDENTITY_MATRIX_ELEMENTS=[1,0,0,1,0,0],Matrix=class Y{get e(){return[...this.elements]}constructor(t=IDENTITY_MATRIX_ELEMENTS){this.elements=[...t]}setElements(t){const e=this.elements;return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],this}get identity(){const t=this.elements;return(0,import_ag_charts_core19.isNumberEqual)(t[0],1)&&(0,import_ag_charts_core19.isNumberEqual)(t[1],0)&&(0,import_ag_charts_core19.isNumberEqual)(t[2],0)&&(0,import_ag_charts_core19.isNumberEqual)(t[3],1)&&(0,import_ag_charts_core19.isNumberEqual)(t[4],0)&&(0,import_ag_charts_core19.isNumberEqual)(t[5],0)}AxB(t,e,s){const n=t[0]*e[0]+t[2]*e[1],a=t[1]*e[0]+t[3]*e[1],r=t[0]*e[2]+t[2]*e[3],o=t[1]*e[2]+t[3]*e[3],h=t[0]*e[4]+t[2]*e[5]+t[4],c=t[1]*e[4]+t[3]*e[5]+t[5];s=s??t,s[0]=n,s[1]=a,s[2]=r,s[3]=o,s[4]=h,s[5]=c}multiplySelf(t){return this.AxB(this.elements,t.elements),this}multiply(t){const e=[Number.NaN,Number.NaN,Number.NaN,Number.NaN,Number.NaN,Number.NaN];return t instanceof Y?this.AxB(this.elements,t.elements,e):this.AxB(this.elements,[t.a,t.b,t.c,t.d,t.e,t.f],e),new Y(e)}preMultiplySelf(t){return this.AxB(t.elements,this.elements,this.elements),this}inverse(){const t=this.elements;let e=t[0],s=t[1],n=t[2],a=t[3];const r=t[4],o=t[5],h=1/(e*a-s*n);return e*=h,s*=h,n*=h,a*=h,new Y([a,-s,-n,e,n*o-a*r,s*r-e*o])}invertSelf(){const t=this.elements;let e=t[0],s=t[1],n=t[2],a=t[3];const r=t[4],o=t[5],h=1/(e*a-s*n);return e*=h,s*=h,n*=h,a*=h,t[0]=a,t[1]=-s,t[2]=-n,t[3]=e,t[4]=n*o-a*r,t[5]=s*r-e*o,this}transformPoint(t,e){const s=this.elements;return{x:t*s[0]+e*s[2]+s[4],y:t*s[1]+e*s[3]+s[5]}}transformBBox(t,e){const s=this.elements,n=s[0],a=s[1],r=s[2],o=s[3],h=t.width*.5,c=t.height*.5,l=t.x+h,u=t.y+c,d=Math.abs(h*n)+Math.abs(c*r),f=Math.abs(h*a)+Math.abs(c*o);return e??(e=new BBox(0,0,0,0)),e.x=l*n+u*r+s[4]-d,e.y=l*a+u*o+s[5]-f,e.width=d+d,e.height=f+f,e}toContext(t){if(this.identity)return;const e=this.elements;t.transform(e[0],e[1],e[2],e[3],e[4],e[5])}static updateTransformMatrix(t,e,s,n,a,r,o){const h=e,c=s;let l,u;h===1&&c===1?(l=0,u=0):(l=o?.scalingCenterX??0,u=o?.scalingCenterY??0);const d=n,f=Math.cos(d),g=Math.sin(d);let p,y;d===0?(p=0,y=0):(p=o?.rotationCenterX??0,y=o?.rotationCenterY??0);const m=a,b=r,v=l*(1-h)-p,S=u*(1-c)-y;return t.setElements([f*h,g*h,-g*c,f*c,f*v-g*S+p+m,g*v+f*S+y+b]),t}};function isMatrixTransform(i){return isMatrixTransformType(i.constructor)}var MATRIX_TRANSFORM_TYPE=Symbol("isMatrixTransform");function isMatrixTransformType(i){return i[MATRIX_TRANSFORM_TYPE]===!0}function MatrixTransform(i){var t,e;const s=i;if(isMatrixTransformType(i))return i;const n=Symbol("matrix_combined_transform");class a extends s{constructor(){super(...arguments),this[e]=new Matrix,this._dirtyTransform=!0}onChangeDetection(o){super.onChangeDetection(o),this._dirtyTransform=!0,!(this.batchLevel>0)&&this.markDirty("transform")}updateMatrix(o){}computeTransformMatrix(){this._dirtyTransform&&(this[n].setElements(IDENTITY_MATRIX_ELEMENTS),this.updateMatrix(this[n]),this._dirtyTransform=!1)}toParent(o){return this.computeTransformMatrix(),this[n].identity?o.clone():this[n].transformBBox(o)}toParentPoint(o,h){return this.computeTransformMatrix(),this[n].identity?{x:o,y:h}:this[n].transformPoint(o,h)}fromParent(o){return this.computeTransformMatrix(),this[n].identity?o.clone():this[n].inverse().transformBBox(o)}fromParentPoint(o,h){return this.computeTransformMatrix(),this[n].identity?{x:o,y:h}:this[n].inverse().transformPoint(o,h)}computeBBox(){const o=super.computeBBox();return o&&this.toParent(o)}computeBBoxWithoutTransforms(){return super.computeBBox()}pickNode(o,h){return{x:o,y:h}=this.fromParentPoint(o,h),super.pickNode(o,h)}pickNodes(o,h,c){return{x:o,y:h}=this.fromParentPoint(o,h),super.pickNodes(o,h,c)}distanceSquared(o,h){return{x:o,y:h}=this.fromParentPoint(o,h),super.distanceSquared(o,h)}render(o){this.computeTransformMatrix();const{ctx:h}=o,c=this[n];let l=!1;try{c.identity||(h.save(),l=!0,c.toContext(h)),super.render(o)}finally{l&&h.restore()}}toSVG(){this.computeTransformMatrix();const o=super.toSVG(),h=this[n];if(h.identity||o==null)return o;const c=(0,import_ag_charts_core20.createSvgElement)("g");c.append(...o.elements);const[l,u,d,f,g,p]=h.e;return c.setAttribute("transform",`matrix(${l} ${u} ${d} ${f} ${g} ${p})`),{elements:[c],defs:o.defs}}}return t=MATRIX_TRANSFORM_TYPE,e=n,a[t]=!0,a}function Rotatable(i){var t;const e=i,s=Symbol("matrix_rotation");class n extends MatrixTransform(e){constructor(){super(...arguments),this[t]=new Matrix,this.rotationCenterX=0,this.rotationCenterY=0,this.rotation=0}updateMatrix(r){super.updateMatrix(r);const{rotation:o,rotationCenterX:h,rotationCenterY:c}=this;o!==0&&(Matrix.updateTransformMatrix(this[s],1,1,o,0,0,{rotationCenterX:h,rotationCenterY:c}),r.multiplySelf(this[s]))}}return t=s,__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"rotationCenterX",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"rotationCenterY",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"rotation",2),n}function Scalable(i){var t;const e=i,s=Symbol("matrix_scale");class n extends MatrixTransform(e){constructor(){super(...arguments),this[t]=new Matrix,this.scalingX=1,this.scalingY=1,this.scalingCenterX=0,this.scalingCenterY=0}updateMatrix(r){super.updateMatrix(r);const{scalingX:o,scalingY:h,scalingCenterX:c,scalingCenterY:l}=this;o===1&&h===1||(Matrix.updateTransformMatrix(this[s],o,h,0,0,0,{scalingCenterX:c,scalingCenterY:l}),r.multiplySelf(this[s]))}resetScalingProperties(r,o,h,c){this.__scalingX=r,this.__scalingY=o,this.__scalingCenterX=h,this.__scalingCenterY=c,this.onChangeDetection("scaling")}}return t=s,__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"scalingX",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"scalingY",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"scalingCenterX",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"scalingCenterY",2),n}function Translatable(i){var t;const e=i,s=Symbol("matrix_translation");class n extends MatrixTransform(e){constructor(){super(...arguments),this[t]=new Matrix,this.translationX=0,this.translationY=0}updateMatrix(r){super.updateMatrix(r);const{translationX:o,translationY:h}=this;o===0&&h===0||(Matrix.updateTransformMatrix(this[s],1,1,0,o,h),r.multiplySelf(this[s]))}}return t=s,__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"translationX",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],n.prototype,"translationY",2),n}var Transformable=class{static fromCanvas(i,t){const e=[];for(const s of i.traverseUp())isMatrixTransform(s)&&e.unshift(s);for(const s of e)t=s.fromParent(t);return isMatrixTransform(i)&&(t=i.fromParent(t)),t}static toCanvas(i,t){t==null?t=i.getBBox():isMatrixTransform(i)&&(t=i.toParent(t));for(const e of i.traverseUp())isMatrixTransform(e)&&(t=e.toParent(t));return t}static fromCanvasPoint(i,t,e){const s=[];for(const n of i.traverseUp())isMatrixTransform(n)&&s.unshift(n);for(const n of s)({x:t,y:e}=n.fromParentPoint(t,e));return isMatrixTransform(i)&&({x:t,y:e}=i.fromParentPoint(t,e)),{x:t,y:e}}static toCanvasPoint(i,t,e){isMatrixTransform(i)&&({x:t,y:e}=i.toParentPoint(t,e));for(const s of i.traverseUp())isMatrixTransform(s)&&({x:t,y:e}=s.toParentPoint(t,e));return{x:t,y:e}}},sharedOffscreenCanvas,_Group=class U extends Node{constructor(t){super(t),this.childNodes=new Set,this.dirty=!1,this.dirtyZIndex=!1,this.clipRect=void 0,this.opacity=1,this._childFontDirty=!0,this.layer=void 0,this.image=void 0,this._lastWidth=Number.NaN,this._lastHeight=Number.NaN,this._lastDevicePixelRatio=Number.NaN,this.isContainerNode=!0,this.renderToOffscreenCanvas=t?.renderToOffscreenCanvas===!0,this.optimizeForInfrequentRedraws=t?.optimizeForInfrequentRedraws===!0}static is(t){return t instanceof U}static computeChildrenBBox(t,e=!0){return BBox.merge(Node.extractBBoxes(t,e))}static compareChildren(t,e){return compareZIndex(t.__zIndex,e.__zIndex)||t.serialNumber-e.serialNumber}containsPoint(t,e){return!0}computeBBox(){return U.computeChildrenBBox(this.children())}computeSafeClippingBBox(t){const e=this.computeBBox();if(e?.isFinite()!==!0)return;let s=0;const n=4;for(const d of this.descendants())d instanceof Shape&&(s=Math.max(s,d.strokeWidth));const a=Math.max(1,s/2*n),{x:r,y:o}=Transformable.toCanvasPoint(this,0,0),h=alignBefore(t,r+e.x-a)-r,c=alignBefore(t,o+e.y-a)-o,l=Math.ceil(e.x+e.width-h+a),u=Math.ceil(e.y+e.height-c+a);return new BBox(h,c,l,u)}prepareSharedCanvas(t,e,s){return sharedOffscreenCanvas?.pixelRatio===s?sharedOffscreenCanvas.resize(t,e,s):sharedOffscreenCanvas=new HdpiOffscreenCanvas({width:t,height:e,pixelRatio:s}),sharedOffscreenCanvas}setScene(t){const e=this.scene;super.setScene(t),this.layer&&e&&e!==t&&(e.layersManager.removeLayer(this.layer),this.layer=void 0);for(const s of this.children())s.setScene(t)}resolveFont(){if(!this.renderToOffscreenCanvas)return this.resolveChildFont()}resolveChildFont(){if(this._childFontDirty){this._cachedChildFont=void 0;for(const t of this.children()){const e=t.resolveFont();if(e!=null){this._cachedChildFont=e;break}}this._childFontDirty=!1}return this._cachedChildFont}markDirty(t){this.dirty=!0,this._childFontDirty=!0,super.markDirty(t)}markDirtyChildrenOrder(){super.markDirtyChildrenOrder(),this.dirtyZIndex=!0,this.markDirty()}append(t){for(const e of(0,import_ag_charts_core21.toIterable)(t))e.remove(),this.childNodes.add(e),e.parentNode=this,e.setScene(this.scene);this.markDirtyChildrenOrder(),this.markDirty()}appendChild(t){return this.append(t),t}removeChild(t){if(!this.childNodes?.delete(t))throw new Error(`AG Charts - internal error, unknown child node ${t.name??t.id} in $${this.name??this.id}`);t.parentNode=void 0,t.setScene(),this.markDirtyChildrenOrder(),this.markDirty()}clear(){for(const t of this.children())delete t.parentNode,t.setScene();this.childNodes?.clear(),this.markDirty()}pickNode(t,e){if(!(!this.visible||this.pointerEvents===1||!this.containsPoint(t,e))){if(this.childNodes!=null&&this.childNodes.size!==0){const s=[...this.children()];for(let n=s.length-1;n>=0;n--){const r=s[n].pickNode(t,e);if(r!=null)return r}}else if(!this.isContainerNode)return this}}pickNodes(t,e,s=[]){if(!this.visible||this.pointerEvents===1||!this.containsPoint(t,e))return s;this.isContainerNode||s.push(this);for(const n of this.children())n.pickNodes(t,e,s);return s}isDirty(t){const{width:e,height:s,devicePixelRatio:n}=t,{dirty:a,layer:r}=this,o=r!=null&&(this._lastWidth!==e||this._lastHeight!==s),h=this._lastDevicePixelRatio!==n;return this._lastWidth=e,this._lastHeight=s,this._lastDevicePixelRatio=n,a||o||h}preRender(t){let e;if(this.dirty){e=super.preRender(t,0);for(const s of this.children()){const n=s.preRender(t);e.groups+=n.groups,e.nonGroups+=n.nonGroups,e.complexity+=n.complexity}e.groups+=1,e.nonGroups-=1}else e=this.childNodeCounts;return this.renderToOffscreenCanvas&&!this.optimizeForInfrequentRedraws&&e.nonGroups>0&&this.getVisibility()?this.layer??(this.layer=this.layerManager?.addLayer({name:this.name})):this.layer!=null&&(this.layerManager?.removeLayer(this.layer),this.layer=void 0),e}render(t){const{layer:e,renderToOffscreenCanvas:s}=this,n={...t},a=this.isDirty(t);if(this.dirty=!1,!s){this.renderInContext(n),super.render(n);return}const{ctx:r,stats:o,devicePixelRatio:h}=t;let{image:c}=this;if(a){c?.bitmap.close(),c=void 0;const u=e?void 0:this.computeSafeClippingBBox(h),d=(f,...g)=>{const p=f.context;p.direction=n.direction,n.ctx=p,n.currentFont=void 0,f.clear(),p.save();try{p.setTransform(...g),p.globalAlpha=1,this.renderInContext(n)}finally{p.restore(),p.verifyDepthZero?.()}};if(e)d(e,r.getTransform());else if(u){const{x:f,y:g,width:p,height:y}=u,m=Math.floor(p*h),b=Math.floor(y*h);if(m>0&&b>0){const v=this.prepareSharedCanvas(p,y,h);d(v,h,0,0,h,-f*h,-g*h),c={bitmap:v.transferToImageBitmap(),x:f,y:g,width:p,height:y}}}this.image=c,o&&o.layersRendered++}else o&&o.layersSkipped++;const{globalAlpha:l}=r;if(r.globalAlpha=l*this.opacity,e){r.save();try{r.resetTransform(),e.drawImage(r)}finally{r.restore()}}else if(c){const{bitmap:u,x:d,y:f,width:g,height:p}=c;r.drawImage(u,0,0,g*h,p*h,d,f,g,p)}r.globalAlpha=l,super.render(n)}applyClip(t,e){const{x:s,y:n,width:a,height:r}=e;t.beginPath(),t.rect(s,n,a,r),t.clip()}renderInContext(t){const{ctx:e,stats:s}=t;this.dirtyZIndex&&(this.sortChildren(U.compareChildren),this.dirtyZIndex=!1),e.save();try{e.globalAlpha*=this.opacity;const n=this.resolveChildFont();n!=null&&t.currentFont!==n&&(e.font=n,t.currentFont=n),this.clipRect!=null&&(this.applyClip(e,this.clipRect),t.clipBBox=Transformable.toCanvas(this,this.clipRect));for(const a of this.children()){if(!a.visible){s&&(s.nodesSkipped+=a.childNodeCounts.nonGroups+a.childNodeCounts.groups,s.opsSkipped+=a.childNodeCounts.complexity);continue}a.isolatedRender(t)}}finally{e.restore()}}sortChildren(t){if(!this.childNodes)return;const e=[...this.childNodes].sort(t);this.childNodes.clear();for(const s of e)this.childNodes.add(s)}*children(){yield*this.childNodes}*excludeChildren(t){for(const e of this.children())(t.instance&&!(e instanceof t.instance)||t.name&&e.name!==t.name)&&(yield e)}*descendants(){for(const t of this.children())yield t,t instanceof U&&(yield*t.descendants())}setClipRect(t){this.clipRect=t?Transformable.fromCanvas(this,t):void 0}setClipRectCanvasSpace(t){this.clipRect=t}getVisibility(){for(const t of this.traverseUp(!0))if(!t.visible)return!1;return!0}toSVG(){if(!this.visible)return;const t=[],e=[];for(const s of this.children()){const n=s.toSVG();n!=null&&(e.push(...n.elements),n.defs!=null&&t.push(...n.defs))}return{elements:e,defs:t}}};_Group.className="Group",__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)({convertor:i=>(0,import_ag_charts_core21.clamp)(0,i,1)})],_Group.prototype,"opacity",2);var Group=_Group,ScalableGroup=Scalable(Group),RotatableGroup=Rotatable(Group),TranslatableGroup=Translatable(Group),TransformableGroup=Rotatable(Translatable(Group)),import_ag_charts_core22=require("ag-charts-core"),StatsAccumulator=class{constructor(){this.stats=new Map,this.lastLogTime=Date.now(),this.LOG_INTERVAL_MS=1e4,this.startPeriodicLogging()}startPeriodicLogging(){import_ag_charts_core22.Debug.check("scene:stats","scene:stats:verbose")&&(this.stopPeriodicLogging(),this.intervalId=setInterval(()=>{this.logAccumulatedStats()},this.LOG_INTERVAL_MS))}stopPeriodicLogging(){this.intervalId&&(clearInterval(this.intervalId),this.intervalId=void 0)}recordTiming(i,t){const e=this.stats.get(i);e?(e.min=Math.min(e.min,t),e.max=Math.max(e.max,t),e.sum+=t,e.count+=1):this.stats.set(i,{min:t,max:t,sum:t,count:1})}recordTimings(i){for(const[t,e]of Object.entries(i))t!=="start"&&typeof e=="number"&&this.recordTiming(t,e)}logAccumulatedStats(){if(this.stats.size===0)return;const i=(Date.now()-this.lastLogTime)/1e3,t=Array.from(this.stats.keys()).sort((a,r)=>a==="\u23F1\uFE0F"?-1:r==="\u23F1\uFE0F"?1:a.localeCompare(r)),e=[];for(const a of t){const r=this.stats.get(a),o=r.sum/r.count;e.push(`${a}[${r.min.toFixed(1)}/${o.toFixed(1)}/${r.max.toFixed(1)}]ms`)}const n=this.stats.get("\u23F1\uFE0F")?.count??0;import_ag_charts_core22.Logger.log(`\u{1F4CA} Stats (${i.toFixed(0)}s, ${n} renders): ${e.join(" ")}`),this.stats.clear(),this.lastLogTime=Date.now()}destroy(){this.stopPeriodicLogging(),this.stats.clear()}},globalStatsAccumulator,statsAccumulatorConsumers=0;function getStatsAccumulator(){return globalStatsAccumulator??(globalStatsAccumulator=new StatsAccumulator),globalStatsAccumulator}function registerDebugStatsConsumer(){statsAccumulatorConsumers++;let i=!1;return()=>{i||statsAccumulatorConsumers===0||(i=!0,statsAccumulatorConsumers--,statsAccumulatorConsumers===0&&cleanupDebugStats())}}function formatBytes(i){for(const t of["B","KB","MB","GB"]){if(i<1536)return`${i.toFixed(1)}${t}`;i/=1024}return`${i.toFixed(1)}TB}`}function memoryUsage(){if(!("memory"in performance))return;const{totalJSHeapSize:i,usedJSHeapSize:t,jsHeapSizeLimit:e}=performance.memory,s=[];for(const n of[t,i,e])typeof n=="number"&&s.push(formatBytes(n));return`Heap ${s.join(" / ")}`}function debugStats(i,t,e,s,n={},a=BBox.zero,r){if(!import_ag_charts_core22.Debug.check("scene:stats","scene:stats:verbose"))return;const{layersRendered:o=0,layersSkipped:h=0,nodesRendered:c=0,nodesSkipped:l=0,opsPerformed:u=0,opsSkipped:d=0}=s??{},f=performance.now(),{start:g,...p}=t,y=f-g,m=getStatsAccumulator();m.recordTimings(p),m.recordTiming("\u23F1\uFE0F",y);const b=Object.entries(p).map(([D,I])=>time(D,I)).filter(D=>D!=null).join(" + "),v=Object.entries(n).map(([D,I])=>`${D}: ${JSON.stringify(I)}`).join(" ; "),S=import_ag_charts_core22.Debug.check("scene:stats:verbose"),M=S?memoryUsage():null,C=S?import_ag_charts_core22.DebugMetrics.flush():{},x=Object.entries(C),_=[],P=[];for(const[D,I]of x)D.endsWith(":aggregation")&&Array.isArray(I)?_.push(`${D.replace(":aggregation","")}(${I.join(",")})`):D.endsWith(":nodeData")&&typeof I=="number"&&P.push(`${D.replace(":nodeData","")}(${I})`);const w=_.length>0?`Aggregation: ${_.join(", ")}`:null,k=P.length>0?`NodeData: ${P.join(", ")}`:null,N=[`${time("\u23F1\uFE0F",g,f)} (${b})`,`${v}`,w,k,`Layers: ${S?pct(o,h):i.size}`,S?`Nodes: ${pct(c,l)}`:null,S?`Ops: ${pct(u,d)}`:null,M].filter(import_ag_charts_core22.isString),L=new import_ag_charts_core22.TextMeasurer(e),E=new Map(N.map(D=>[D,L.measureText(D)])),z=Math.max(...Array.from(E.values(),D=>D.width)),B=accumulate(E.values(),D=>D.height),F=2+a.x;e.save();try{e.fillStyle=r?.background??"white",e.fillRect(F,0,z,B),e.fillStyle=r?.foreground??"black";let D=0;for(const[I,j]of E.entries())D+=j.height,e.fillText(I,F,D)}catch(D){import_ag_charts_core22.Logger.warnOnce("Error during debug stats rendering",D)}finally{e.restore()}}function prepareSceneNodeHighlight(i){const t=(0,import_ag_charts_core22.toArray)((0,import_ag_charts_core22.getWindow)("agChartsSceneDebug")),e=[];for(const s of t)s==="layout"?e.push("seriesRoot","legend","root",/Axis-\d+-axis/):e.push(s);i.debugNodeSearch=e}function debugSceneNodeHighlight(i,t){i.save();try{for(const[e,s]of Object.entries(t)){const n=Transformable.toCanvas(s);if(!n){import_ag_charts_core22.Logger.log(`Scene.render() - no bbox for debugged node [${e}].`);continue}i.globalAlpha=.8,i.strokeStyle="red",i.lineWidth=1,i.strokeRect(n.x,n.y,n.width,n.height),i.fillStyle="red",i.strokeStyle="white",i.font="16px sans-serif",i.textBaseline="top",i.textAlign="left",i.lineWidth=2,i.strokeText(e,n.x,n.y,n.width),i.fillText(e,n.x,n.y,n.width)}}catch(e){import_ag_charts_core22.Logger.warnOnce("Error during debug rendering",e)}finally{i.restore()}}var skippedProperties=new Set,allowedProperties=new Set(["gradient","zIndex","clipRect","cachedBBox","childNodeCounts","path","__zIndex","name","__scalingCenterX","__scalingCenterY","__rotationCenterX","__rotationCenterY","_previousDatum","__fill","__lineDash","borderPath","borderClipPath","_clipPath"]);function nodeProps(i){const{...t}=i;for(const e of Object.keys(t))allowedProperties.has(e)||typeof t[e]!="number"&&typeof t[e]!="string"&&typeof t[e]!="boolean"&&(skippedProperties.add(e),delete t[e]);return t}function buildTree(i,t){if(!import_ag_charts_core22.Debug.check(!0,"scene"))return{};let e=0;return{node:t==="json"?nodeProps(i):i,name:i.name??i.id,dirty:i instanceof Group?i.dirty:void 0,...Array.from(i instanceof Group?i.children():[],s=>buildTree(s,t)).reduce((s,n)=>{let{name:a}=n;const{node:{visible:r,opacity:o,zIndex:h,translationX:c,translationY:l,rotation:u,scalingX:d,scalingY:f},node:g}=n;(!r||o<=0)&&(a=`(${a})`),Group.is(g)&&g.renderToOffscreenCanvas&&(a=`*${a}*`);const p=Array.isArray(h)?`(${h.join(", ")})`:h,y=[`${(e++).toString().padStart(3,"0")}|`,`${a??"<unknown>"}`,`z: ${p}`,c&&`x: ${c}`,l&&`y: ${l}`,u&&`r: ${u}`,d!=null&&d!==1&&`sx: ${d}`,f!=null&&f!==1&&`sy: ${f}`].filter(v=>!!v).join(" ");let m=y,b=1;for(;s[m]!=null&&b<100;)m=`${y} (${b++})`;return s[m]=n,s},{})}}function buildDirtyTree(i){const t=i instanceof Group?i.dirty:void 0;if(!t)return{dirtyTree:{},paths:[]};const e=Array.from(i instanceof Group?i.children():[],a=>buildDirtyTree(a)).filter(a=>a.paths.length>0),s=Group.is(i)?i.name??i.id:i.id,n=e.length?e.flatMap(a=>a.paths).map(a=>`${s}.${a}`):[s];return{dirtyTree:{name:s,node:i,dirty:t,...e.map(a=>a.dirtyTree).filter(a=>a.dirty!=null).reduce((a,r)=>(a[r.name??"<unknown>"]=r,a),{})},paths:n}}function pct(i,t){const e=i+t;return`${i} / ${e} (${Math.round(100*i/e)}%)`}function time(i,t,e){const s=e==null?t:e-t;return`${i}: ${Math.round(s*100)/100}ms`}function accumulate(i,t){let e=0;for(const s of i)e+=t(s);return e}function cleanupDebugStats(i=!1){if(!globalStatsAccumulator){i&&(statsAccumulatorConsumers=0);return}!i&&statsAccumulatorConsumers>0||(globalStatsAccumulator.destroy(),globalStatsAccumulator=void 0,i&&(statsAccumulatorConsumers=0))}var import_ag_charts_core23=require("ag-charts-core"),ImageSegmentNode=class extends Node{constructor(){super(...arguments),this.x=0,this.y=0,this.boxWidth=0,this.boxHeight=0,this.imageWidth=0,this.imageHeight=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0,this.paddingLeft=0,this.cornerRadius=0,this.opacity=1,this.url=""}setScene(i){i==null&&this.registeredLoader&&(this.registeredLoader.unregisterNode(this),this.registeredLoader=void 0),super.setScene(i)}destroy(){this.registeredLoader&&(this.registeredLoader.unregisterNode(this),this.registeredLoader=void 0),super.destroy()}render(i){const{ctx:t}=i,{x:e,y:s,boxWidth:n,boxHeight:a,cornerRadius:r,opacity:o}=this;if(n<=0||a<=0){super.render(i);return}const h=t.globalAlpha;if(t.globalAlpha=h*o,this.backgroundFill&&(this.tracePath(t,e,s,n,a,r),t.fillStyle=this.backgroundFill,t.fill()),this.url){const c=this.imageLoader;c!==this.registeredLoader&&(this.registeredLoader?.unregisterNode(this),this.registeredLoader=c);const l=c?.loadImage(this.url,this,{width:this.imageWidth,height:this.imageHeight});if(l){const u=e+this.paddingLeft,d=s+this.paddingTop,f=r>0;f&&(t.save(),this.tracePath(t,e,s,n,a,r),t.clip()),t.drawImage(l,u,d,this.imageWidth,this.imageHeight),f&&t.restore()}}else import_ag_charts_core23.Logger.warnOnce(`Image segment has an empty url; rendering background only (${n}x${a} box).`);t.globalAlpha=h,super.render(i)}tracePath(i,t,e,s,n,a){i.beginPath();const r=Math.max(0,Math.min(a,s/2,n/2));if(r===0){i.rect(t,e,s,n);return}i.moveTo(t+r,e),i.arcTo(t+s,e,t+s,e+n,r),i.arcTo(t+s,e+n,t,e+n,r),i.arcTo(t,e+n,t,e,r),i.arcTo(t,e,t+s,e,r),i.closePath()}computeBBox(){return new BBox(this.x,this.y,this.boxWidth,this.boxHeight)}};__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"x",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"y",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"boxWidth",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"boxHeight",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"imageWidth",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"imageHeight",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"paddingTop",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"paddingRight",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"paddingBottom",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"paddingLeft",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"cornerRadius",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],ImageSegmentNode.prototype,"opacity",2);var import_ag_charts_core25=require("ag-charts-core"),drawCorner=(i,{x0:t,y0:e,x1:s,y1:n,cx:a,cy:r},o,h)=>{if(h&&i.moveTo(t,e),t!==s||e!==n){const c=Math.atan2(e-r,t-a),l=Math.atan2(n-r,s-a);i.arc(a,r,o,c,l)}else i.lineTo(t,e)},import_ag_charts_core24=require("ag-charts-core"),Path=class extends Shape{constructor(){super(...arguments),this._clipX=Number.NaN,this._clipY=Number.NaN,this.clip=!1,this._dirtyPath=!0,this.lastPixelRatio=Number.NaN}get path(){return this._path??(this._path=new ExtendedPath2D),this._path}set path(i){this._path=i}set clipX(i){this._clipX=i,this.dirtyPath=!0}set clipY(i){this._clipY=i,this.dirtyPath=!0}set dirtyPath(i){this._dirtyPath!==i&&(this._dirtyPath=i,i&&this.markDirty("path"))}get dirtyPath(){return this._dirtyPath}checkPathDirty(){this._dirtyPath||(this.dirtyPath=this.path.isDirty()||(this.fillShadow?.isDirty()??!1)||(this._clipPath?.isDirty()??!1))}resetPathDirty(){this.path.clear(!0),this._dirtyPath=!1}isPathDirty(){return this.path.isDirty()}onChangeDetection(i){this._dirtyPath=!0,super.onChangeDetection(i)}computeBBox(){return this.updatePathIfDirty(),this.path.computeBBox()}isPointInPath(i,t){return this.updatePathIfDirty(),this.path.closedPath&&this.path.isPointInPath(i,t)}distanceSquared(i,t){return this.distanceSquaredTransformedPoint(i,t)}svgPathData(i){return this.updatePathIfDirty(),this.path.toSVG(i)}distanceSquaredTransformedPoint(i,t){return this.updatePathIfDirty(),this.path.closedPath&&this.path.isPointInPath(i,t)?0:this.path.distanceSquared(i,t)}isDirtyPath(){return!1}updatePath(){}updatePathIfDirty(){(this.dirtyPath||this.isDirtyPath())&&(this.updatePath(),this.dirtyPath=!1)}preRender(i){return i.devicePixelRatio!==this.lastPixelRatio&&(this.dirtyPath=!0),this.lastPixelRatio=i.devicePixelRatio,this.updatePathIfDirty(),super.preRender(i,this.pathComplexity())}pathComplexity(){return this.path.commands.length}render(i){const{ctx:t}=i;if(this.clip&&!Number.isNaN(this._clipX)&&!Number.isNaN(this._clipY)){t.save();try{const e=this.strokeWidth/2;this._clipPath??(this._clipPath=new ExtendedPath2D),this._clipPath.clear(),this._clipPath.rect(-e,-e,this._clipX+e,this._clipY+e+e),t.clip(this._clipPath?.getPath2D()),this._clipX>0&&this._clipY>0&&this.drawPath(t)}finally{t.restore()}}else this._clipPath=void 0,this.drawPath(t);this.fillShadow?.markClean(),super.render(i)}drawPath(i){this.fillStroke(i,this.path.getPath2D())}toSVG(){if(!this.visible)return;const i=(0,import_ag_charts_core24.createSvgElement)("path");i.setAttribute("d",this.svgPathData());const t=this.applySvgFillAttributes(i,[]);return this.applySvgStrokeAttributes(i),{elements:[i],defs:t}}};Path.className="Path",__decorateClass([(0,import_ag_charts_core24.SceneChangeDetection)()],Path.prototype,"clip",2),__decorateClass([(0,import_ag_charts_core24.SceneChangeDetection)()],Path.prototype,"clipX",1),__decorateClass([(0,import_ag_charts_core24.SceneChangeDetection)()],Path.prototype,"clipY",1);function cornerEdges(i,t,e,s,n){let a=!1,r=!1,o=s-Math.sqrt(Math.max(n**2-e**2,0)),h=0,c=0,l=e-Math.sqrt(Math.max(n**2-s**2,0));return o>i?(a=!0,o=i,h=e-Math.sqrt(Math.max(n**2-(s-i)**2))):(0,import_ag_charts_core25.isNumberEqual)(o,0)&&(o=0),l>t?(r=!0,c=s-Math.sqrt(Math.max(n**2-(e-t)**2)),l=t):(0,import_ag_charts_core25.isNumberEqual)(l,0)&&(l=0),{leading0:o,leading1:h,trailing0:c,trailing1:l,leadingClipped:a,trailingClipped:r}}function clippedRoundRect(i,t,e,s,n,a,r){let{topLeft:o,topRight:h,bottomRight:c,bottomLeft:l}=a;const u=Math.max(o+l,h+c),d=Math.max(o+h,l+c);if(u<=0&&d<=0){if(r==null)i.rect(t,e,s,n);else{const x=Math.max(t,r.x),_=Math.min(t+s,r.x+r.width),P=Math.max(e,r.y),w=Math.min(e+n,r.y+r.height);i.rect(x,P,_-x,w-P)}return}else if(r==null&&o===h&&o===c&&o===l){i.roundRect(t,e,s,n,o);return}if(s<0&&(t+=s,s=Math.abs(s)),n<0&&(e+=n,n=Math.abs(n)),s<=0||n<=0)return;if(r==null)r=new BBox(t,e,s,n);else{const x=Math.max(t,r.x),_=Math.min(t+s,r.x+r.width),P=Math.max(e,r.y),w=Math.min(e+n,r.y+r.height);r=new BBox(x,P,_-x,w-P)}const f=Math.max(u/n,d/s,1);f>1&&(o/=f,h/=f,c/=f,l/=f);let g=!0,p=!0,y=!0,m=!0,b,v,S,M;if(g){const x=cornerEdges(r.height,r.width,Math.max(t+o-r.x,0),Math.max(e+o-r.y,0),o);x.leadingClipped&&(m=!1),x.trailingClipped&&(p=!1);const _=Math.max(r.x+x.leading1,r.x),P=Math.max(r.y+x.leading0,r.y),w=Math.max(r.x+x.trailing1,r.x),k=Math.max(r.y+x.trailing0,r.y),N=t+o,L=e+o;b={x0:_,y0:P,x1:w,y1:k,cx:N,cy:L}}if(p){const x=cornerEdges(r.width,r.height,Math.max(e+h-r.y,0),Math.max(r.x+r.width-(t+s-h),0),h);x.leadingClipped&&(g=!1),x.trailingClipped&&(y=!1);const _=Math.min(r.x+r.width-x.leading0,r.x+r.width),P=Math.max(r.y+x.leading1,r.y),w=Math.min(r.x+r.width-x.trailing0,r.x+r.width),k=Math.max(r.y+x.trailing1,r.y),N=t+s-h,L=e+h;v={x0:_,y0:P,x1:w,y1:k,cx:N,cy:L}}if(y){const x=cornerEdges(r.height,r.width,Math.max(r.x+r.width-(t+s-c),0),Math.max(r.y+r.height-(e+n-c),0),c);x.leadingClipped&&(p=!1),x.trailingClipped&&(m=!1);const _=Math.min(r.x+r.width-x.leading1,r.x+r.width),P=Math.min(r.y+r.height-x.leading0,r.y+r.height),w=Math.min(r.x+r.width-x.trailing1,r.x+r.width),k=Math.min(r.y+r.height-x.trailing0,r.y+r.height),N=t+s-c,L=e+n-c;S={x0:_,y0:P,x1:w,y1:k,cx:N,cy:L}}if(m){const x=cornerEdges(r.width,r.height,Math.max(r.y+r.height-(e+n-l),0),Math.max(t+l-r.x,0),l);x.leadingClipped&&(y=!1),x.trailingClipped&&(g=!1);const _=Math.max(r.x+x.leading0,r.x),P=Math.min(r.y+r.height-x.leading1,r.y+r.height),w=Math.max(r.x+x.trailing0,r.x),k=Math.min(r.y+r.height-x.trailing1,r.y+r.height),N=t+l,L=e+n-l;M={x0:_,y0:P,x1:w,y1:k,cx:N,cy:L}}let C=!1;g&&b!=null&&(drawCorner(i,b,o,!C),C||(C=!0)),p&&v!=null&&(drawCorner(i,v,h,!C),C||(C=!0)),y&&S!=null&&(drawCorner(i,S,c,!C),C||(C=!0)),m&&M!=null&&drawCorner(i,M,l,!C),i.closePath()}var Rect=class extends Path{constructor(){super(...arguments),this.borderPath=new ExtendedPath2D,this.x=0,this.y=0,this.width=10,this.height=10,this.topLeftCornerRadius=0,this.topRightCornerRadius=0,this.bottomRightCornerRadius=0,this.bottomLeftCornerRadius=0,this.clipBBox=void 0,this.crisp=!1,this.lastUpdatePathStrokeWidth=this.__strokeWidth,this.effectiveStrokeWidth=this.__strokeWidth,this.hittester=super.isPointInPath.bind(this),this.distanceCalculator=super.distanceSquaredTransformedPoint.bind(this),this.microPixelEffectOpacity=1}set cornerRadius(i){this.topLeftCornerRadius=i,this.topRightCornerRadius=i,this.bottomRightCornerRadius=i,this.bottomLeftCornerRadius=i}isDirtyPath(){return this.lastUpdatePathStrokeWidth!==this.__strokeWidth||!!(this.path.isDirty()||this.borderPath.isDirty())}updatePath(){const{path:i,borderPath:t,__crisp:e,__topLeftCornerRadius:s,__topRightCornerRadius:n,__bottomRightCornerRadius:a,__bottomLeftCornerRadius:r}=this;let{__x:o,__y:h,__width:c,__height:l,__strokeWidth:u,__clipBBox:d}=this;const g=1/(this.layerManager?.canvas.pixelRatio??1);let p=1;if(i.clear(),t.clear(),c===0||l===0){this.effectiveStrokeWidth=0,this.lastUpdatePathStrokeWidth=0,this.microPixelEffectOpacity=0;return}if(e&&(c<=g&&(p*=c/g),l<=g&&(p*=l/g),c=this.align(o,c),l=this.align(h,l),o=this.align(o),h=this.align(h),d=d==null?void 0:new BBox(this.align(d.x),this.align(d.y),this.align(d.x,d.width),this.align(d.y,d.height))),u)if(c<g){const m=o+g/2;t.moveTo(m,h),t.lineTo(m,h+l),u=g,this.borderClipPath=void 0}else if(l<g){const m=h+g/2;t.moveTo(o,m),t.lineTo(o+c,m),u=g,this.borderClipPath=void 0}else if(u<c&&u<l){const m=u/2;o+=m,h+=m,c-=u,l-=u;const b=d?.clone().shrink(m),v={topLeft:s>0?s-u:0,topRight:n>0?n-u:0,bottomRight:a>0?a-u:0,bottomLeft:r>0?r-u:0};this.borderClipPath=void 0,c>0&&l>0&&(b==null||b?.width>0&&b?.height>0)&&(clippedRoundRect(i,o,h,c,l,v,b),clippedRoundRect(t,o,h,c,l,v,b))}else this.borderClipPath=this.borderClipPath??new ExtendedPath2D,this.borderClipPath.clear(),this.borderClipPath.rect(o,h,c,l),t.rect(o,h,c,l);else{const m={topLeft:s,topRight:n,bottomRight:a,bottomLeft:r};this.borderClipPath=void 0,clippedRoundRect(i,o,h,c,l,m,d)}if([s,n,a,r].every(areCornersZero)){let m=function(S,M){return v.getBBox().distanceSquared(S,M)};var y=m;const b=this.getBBox();this.hittester=b.containsPoint.bind(b);const v=this;this.distanceSquared=m}else this.hittester=super.isPointInPath,this.distanceCalculator=super.distanceSquaredTransformedPoint;this.effectiveStrokeWidth=u,this.lastUpdatePathStrokeWidth=u,this.microPixelEffectOpacity=p}computeBBox(){const{__x:i,__y:t,__width:e,__height:s,__clipBBox:n}=this;return n?.clone()??new BBox(i,t,e,s)}isPointInPath(i,t){return this.hittester(i,t)}get midPoint(){return{x:this.__x+this.__width/2,y:this.__y+this.__height/2}}setStaticProperties(i,t,e,s,n,a,r,o){this.__drawingMode=i,this.__topLeftCornerRadius=t,this.__topRightCornerRadius=e,this.__bottomRightCornerRadius=s,this.__bottomLeftCornerRadius=n,this.__visible=a,this.__crisp=r,this.__fillShadow=o,this.dirtyPath=!0,this.markDirty()}resetAnimationProperties(i,t,e,s,n,a){this.__x=i,this.__y=t,this.__width=e,this.__height=s,this.__opacity=n,this.__clipBBox=a,this.dirtyPath=!0,this.markDirty()}distanceSquared(i,t){return this.distanceCalculator(i,t)}applyFillAndAlpha(i){super.applyFillAndAlpha(i),i.globalAlpha*=this.microPixelEffectOpacity}applyStrokeAndAlpha(i){super.applyStrokeAndAlpha(i),i.globalAlpha*=this.microPixelEffectOpacity}renderStroke(i){const{stroke:t,effectiveStrokeWidth:e}=this;if(t&&e){const{globalAlpha:s}=i,{lineDash:n,lineDashOffset:a,lineCap:r,lineJoin:o,borderPath:h,borderClipPath:c}=this;c&&i.clip(c.getPath2D()),this.applyStrokeAndAlpha(i),i.lineWidth=e,n&&i.setLineDash(n),a&&(i.lineDashOffset=a),r&&(i.lineCap=r),o&&(i.lineJoin=o),i.stroke(h.getPath2D()),i.globalAlpha=s}}};Rect.className="Rect",__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"x",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"y",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"width",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"height",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"topLeftCornerRadius",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"topRightCornerRadius",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"bottomRightCornerRadius",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"bottomLeftCornerRadius",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)({equals:import_ag_charts_core25.boxesEqual})],Rect.prototype,"clipBBox",2),__decorateClass([(0,import_ag_charts_core25.DeclaredSceneChangeDetection)()],Rect.prototype,"crisp",2);function areCornersZero(i){return i===0}var _Text=class R extends Shape{constructor(t){super(t),this.generatingTextMap=!1,this.suppressedDirtyDuringGenerate=!1,this.x=0,this.y=0,this.lines=[],this.text=void 0,this.fontCache=void 0,this.fontSize=R.defaultFontSize,this.fontFamily="sans-serif",this.textAlign="start",this.textBaseline="alphabetic",this.boxPadding=0,this.trimText=t?.trimText??!0}onTextChange(){if(this.richText?.clear(),this.textMap?.clear(),this.segmentMetrics=void 0,(0,import_ag_charts_core26.isArray)(this.text)){this.lines=[],this.richText??(this.richText=new Group),this.richText.parentNode=this,this.richText.setScene(this.scene);const t=[];for(const e of this.text)if(e.type==="image")t.push(new ImageSegmentNode);else for(const s of(0,import_ag_charts_core26.toTextString)(e.text).split(import_ag_charts_core26.LineSplitter))s&&t.push(new R({trimText:!1}));this.richText.append(t)}else{this.richText&&(this.richText.parentNode=void 0,this.richText.setScene(),this.richText=void 0);const t=(0,import_ag_charts_core26.toTextString)(this.text).split(import_ag_charts_core26.LineSplitter);this.lines=this.trimText?t.map(e=>e.trim()):t}}get font(){return this.fontCache??(this.fontCache=(0,import_ag_charts_core26.toFontString)(this)),this.fontCache}resolveFont(){if(this.hasRenderableText())return this.font}static measureBBox(t,e,s,n){if((0,import_ag_charts_core26.isArray)(t)){const{font:a,lineHeight:r,textAlign:o,textBaseline:h}=n,{width:c,height:l,lineMetrics:u}=(0,import_ag_charts_core26.measureTextSegments)(t,a),d=r?r*u.length:l,f=R.calcTopOffset(d,u[0],h),g=R.calcLeftOffset(c,o);return new BBox(e-g,s-f,c,d)}else return R.computeBBox((0,import_ag_charts_core26.toTextString)(t).split(import_ag_charts_core26.LineSplitter),e,s,n)}static computeBBox(t,e,s,n){const{font:a,lineHeight:r,textAlign:o,textBaseline:h,isRtl:c}=n,{width:l,height:u,lineMetrics:d}=(0,import_ag_charts_core26.cachedTextMeasurer)(a).measureLines(t),f=r?r*d.length:u,g=R.calcTopOffset(f,d[0],h),p=R.calcLeftOffset(l,o,c);return new BBox(e-p,s-g,l,f)}static calcTopOffset(t,e,s){switch(s){case"alphabetic":return e?.ascent??0;case"middle":return t/2;case"bottom":return t;default:return 0}}static calcSegmentedTopOffset(t,e,s){switch(s){case"alphabetic":return e[0]?.ascent??0;case"middle":{const n=e[0];return e.length===1&&n.segments.length>0&&!n.blockImages?.length&&n.segments.every(r=>r.type!=="image")?n.ascent+n.segments.reduce((r,o)=>o.type==="image"?r:Math.min(r,(0,import_ag_charts_core26.cachedTextMeasurer)(o).baselineDistance("middle")),0):t/2}case"bottom":return t;default:return 0}}static calcLeftOffset(t,e,s){let n=0;switch(e){case"center":n=.5;break;case"right":case(s?"start":"end"):n=1}return t*n}getBBox(){const t=super.getBBox();if(!this.textMap?.size||!(0,import_ag_charts_core26.isArray)(this.text))return t;const{height:e,lineMetrics:s}=this.getSegmentMetrics(this.text),n=R.calcSegmentedTopOffset(e,s,this.textBaseline),a=this.y-n;return t.y===a?t:new BBox(t.x,a,t.width,t.height)}computeBBox(){if(!this.hasRenderableText())return new BBox(this.x,this.y,0,0);if(this.generateTextMap(),this.textMap?.size){const h=BBox.merge(this.textMap.values());return h.x=this.x-R.calcLeftOffset(h.width,this.textAlign),h.y=this.y,h}const t=this.scene?.isRtl,{x:e,y:s,lines:n,textBaseline:a,textAlign:r}=this,o=R.computeBBox(n,e,s,{font:this,textBaseline:a,textAlign:r,isRtl:t});return this.boxing!=null&&o.grow(this.boxPadding),o}getTextMeasureBBox(){return this.computeBBox()}getPlainText(){return(0,import_ag_charts_core26.toPlainText)(this.text)}isPointInPath(t,e){return this.getBBox()?.containsPoint(t,e)??!1}setScene(t){this.richText?.setScene(t),super.setScene(t)}generateTextMap(){if(!(!(0,import_ag_charts_core26.isArray)(this.text)||this.textMap?.size)){this.textMap??(this.textMap=new Map),this.generatingTextMap=!0,this.suppressedDirtyDuringGenerate=!1;try{this.buildTextMap(this.text)}finally{this.generatingTextMap=!1,this.suppressedDirtyDuringGenerate&&(this.suppressedDirtyDuringGenerate=!1,super.markDirty())}}}getSegmentMetrics(t){return this.segmentMetrics??(this.segmentMetrics=(0,import_ag_charts_core26.measureTextSegments)(t,this)),this.segmentMetrics}buildTextMap(t){const e=this.richText.children(),{width:s,lineMetrics:n}=this.getSegmentMetrics(t),a=this.x-s/2;let r=0;for(let o=0;o<n.length;){const h=n[o];if(h.blockImages?.length){const c=h.blockRowSpan??1,l=this.layoutBlockRow(n,o,c,r,a,e);if(l==null)return;r=l,o+=c;continue}r=this.renderLine(h,this.x-h.width/2,r,e),o+=1}}layoutBlockRow(t,e,s,n,a,r){const o=t[e].blockImages,h=(0,import_ag_charts_core26.blockStripWidth)(o),c=(0,import_ag_charts_core26.blockStripHeight)(o);let l=0;for(let y=0;y<s;y++)l+=t[e+y].height;const u=Math.max(c,l);let d=a;for(let y=0;y<o.length;y++){const m=o[y],b=m.textMetrics,v=(0,import_ag_charts_core26.toCanvasTextBaseline)(m.verticalAlign)??"middle",S=R.calcAnchoredOffset(v,u,b.height),M=r.next().value;if(!M)return this.abandonTextMap(),null;R.applyImageSegment(M,m,d,n+S),this.textMap.set(M,M.getBBox()),d+=b.width+(y<o.length-1?import_ag_charts_core26.BLOCK_IMAGE_SPACING:0)}const f=R.findFirstTextSegment(t,e,s),g=a+h+import_ag_charts_core26.BLOCK_IMAGE_SPACING;let p=n+R.calcAnchoredOffset((0,import_ag_charts_core26.toCanvasTextBaseline)(f?.verticalAlign)??"alphabetic",u,l);for(let y=0;y<s;y++)p=this.renderLine(t[e+y],g,p,r);return n+u}static findFirstTextSegment(t,e,s){for(let n=0;n<s;n++){const a=t[e+n].segments.find(r=>r.type!=="image");if(a)return a}}renderLine(t,e,s,n){const{height:a,ascent:r,textAscent:o,textDescent:h,segments:c}=t,l=s+r;let u=0;for(const d of c){const f=n.next().value;if(!f)return this.abandonTextMap(),s+a;if(d.type==="image"){const M=d.textMetrics.width,C=d.textMetrics.height,{above:x}=(0,import_ag_charts_core26.imageBoxAroundBaseline)((0,import_ag_charts_core26.toCanvasTextBaseline)(d.verticalAlign),C,o,h),_=f;R.applyImageSegment(_,d,e+u,l-x),this.textMap.set(_,_.getBBox()),u+=M;continue}const{color:g,textMetrics:p,verticalAlign:y,...m}=d,b=f,v=(0,import_ag_charts_core26.toCanvasTextBaseline)(y)??"alphabetic";b.x=e+u,b.y=R.calcSegmentY(v,s,r,a),b.setProperties({...m,textBaseline:v,fill:g??this.fill});const S=b.getBBox();this.textMap.set(b,S),u+=p.width}return s+a}abandonTextMap(){this.textMap?.clear(),this.segmentMetrics=void 0}static calcAnchoredOffset(t,e,s){const n=Math.max(0,e-s);switch(t){case"middle":return n/2;case"bottom":case"ideographic":case"alphabetic":return n;case"top":case"hanging":default:return 0}}static applyImageSegment(t,e,s,n){const{top:a,right:r,bottom:o,left:h}=(0,import_ag_charts_core26.resolvePadding)(e.padding);t.x=s,t.y=n,t.boxWidth=e.textMetrics.width,t.boxHeight=e.textMetrics.height,t.imageWidth=e.width,t.imageHeight=e.height,t.paddingTop=a,t.paddingRight=r,t.paddingBottom=o,t.paddingLeft=h,t.cornerRadius=e.cornerRadius??0,t.backgroundFill=e.backgroundFill,t.url=e.url}static calcSegmentY(t,e,s,n){switch(t){case"top":case"hanging":return e;case"middle":return e+n/2;case"bottom":case"ideographic":return e+n;case"alphabetic":default:return e+s}}render(t){const{ctx:e,stats:s}=t;if(!this.layerManager||!this.hasRenderableText()){s&&(s.nodesSkipped+=1);return}if((0,import_ag_charts_core26.isArray)(this.text)&&this.richText){this.generateTextMap();const n=this.richText.getBBox(),{width:a,height:r,lineMetrics:o}=this.getSegmentMetrics(this.text);let h=0;switch(this.textAlign){case"left":case"start":h=a/2;break;case"right":case"end":h=a/-2}const c=this.y-R.calcSegmentedTopOffset(r,o,this.textBaseline);this.renderBoxing(t,n.clone().translate(h,c)),e.save(),e.translate(h,c),this.richText.opacity=this.opacity,this.richText.render(t),e.restore()}else this.renderText(t);if(R.debug.check()){const n=this.getBBox();e.lineWidth=this.textMap?.size?2:1,e.strokeStyle=this.textMap?.size?"blue":"red",e.strokeRect(n.x,n.y,n.width,n.height)}super.render(t)}markDirty(t){if(this.generatingTextMap){this.suppressedDirtyDuringGenerate=!0;return}return this.textMap?.clear(),this.segmentMetrics=void 0,super.markDirty(t)}renderText(t){const{fill:e,stroke:s,strokeWidth:n,font:a,textAlign:r}=this;if(!e&&!(s&&n)||!this.layerManager)return super.render(t);const{ctx:o}=t;t.currentFont!==a&&(o.font=a,t.currentFont=a),o.textAlign=r,this.renderBoxing(t),this.fillStroke(o)}renderBoxing(t,e){if(!this.boxing)return;const s=e??R.computeBBox(this.lines,this.x,this.y,this);if(s.width===0||s.height===0)return;const{x:n,y:a,width:r,height:o}=s.grow(this.boxPadding);this.boxing.opacity=this.opacity,this.boxing.x=n,this.boxing.y=a,this.boxing.width=r,this.boxing.height=o,this.boxing.preRender(t),this.boxing.render(t)}executeFill(t){this.renderLines((e,s,n)=>t.fillText(e,s,n))}executeStroke(t){this.renderLines((e,s,n)=>t.strokeText(e,s,n))}renderLines(t){const{x:e,y:s,lines:n}=this;if(!Number.isFinite(e)||!Number.isFinite(s))return;const a=(0,import_ag_charts_core26.cachedTextMeasurer)(this),{lineMetrics:r}=a.measureLines(n),{textBaseline:o,lineHeight:h=a.lineHeight()}=this;let c=0;o==="top"?c=r[0].ascent:(o==="middle"||o==="bottom")&&(c=h*(1-n.length),o==="middle"?(c/=2,c-=a.baselineDistance(o)):c-=r[0].descent);for(const l of r)t(l.text,e,s+c),c+=h}setFont(t){this.fontFamily=t.fontFamily,this.fontSize=t.fontSize,this.fontStyle=t.fontStyle,this.fontWeight=t.fontWeight}setAlign(t){this.textAlign=t.textAlign,this.textBaseline=t.textBaseline}setBoxing(t){const e=t.border?.enabled?t.border?.stroke:void 0;t.fill!=null||e!=null?(this.boxing??(this.boxing=new Rect({scene:this.scene})),this.boxing.fill=t.fill,this.boxing.fillOpacity=t.fillOpacity??1,this.boxing.cornerRadius=t.cornerRadius??0,this.boxing.stroke=e,this.boxing.strokeWidth=t.border?.strokeWidth??0,this.boxing.strokeOpacity=t.border?.strokeOpacity??1,this.boxPadding=t.padding??0):this.boxing&&(this.boxing.destroy(),this.boxing=void 0)}hasBoxing(){return this.boxing!=null}getBoxingProperties(){const{fill:t,fillOpacity:e,cornerRadius:s,stroke:n,strokeWidth:a,strokeOpacity:r}=this.boxing??{};return{border:{enabled:n!=null,stroke:n,strokeWidth:a,strokeOpacity:r},cornerRadius:s,fill:t,fillOpacity:e,padding:this.boxPadding}}toSVG(){if(!this.visible||!this.hasRenderableText())return;const t=this.text;if(t==null)return;const e=(0,import_ag_charts_core26.createSvgElement)("text");if((0,import_ag_charts_core26.isArray)(t))for(const s of t){if(s.type==="image"){import_ag_charts_core26.Logger.warnOnce("SVG export drops inline image segments; text content is preserved.");continue}const n=(0,import_ag_charts_core26.createSvgElement)("tspan");setSvgFontAttributes(n,{fontSize:s.fontSize??this.fontSize,fontFamily:s.fontFamily??this.fontFamily,fontWeight:s.fontWeight??this.fontWeight,fontStyle:s.fontStyle??this.fontStyle}),this.applySvgFillAttributes(n),n.textContent=(0,import_ag_charts_core26.toTextString)(s.text),e.append(n)}else this.applySvgFillAttributes(e),setSvgFontAttributes(e,this),e.setAttribute("text-anchor",{center:"middle",left:"start",right:"end",start:"start",end:"end"}[this.textAlign??"start"]),e.setAttribute("alignment-baseline",this.textBaseline),e.setAttribute("x",String(this.x)),e.setAttribute("y",String(this.y)),e.textContent=(0,import_ag_charts_core26.toTextString)(t);return{elements:[e]}}hasRenderableText(){const{text:t}=this;return t==null?!1:(0,import_ag_charts_core26.isArray)(t)?t.length>0:(0,import_ag_charts_core26.toTextString)(t)!==""}};_Text.className="Text",_Text.debug=import_ag_charts_core26.Debug.create(!0,"scene:text"),_Text.defaultFontSize=10,__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],_Text.prototype,"x",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],_Text.prototype,"y",2),__decorateClass([(0,import_ag_charts_core26.SceneRefChangeDetection)({changeCb:i=>i.onTextChange()})],_Text.prototype,"text",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)({changeCb:i=>{i.fontCache=void 0}})],_Text.prototype,"fontStyle",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)({changeCb:i=>{i.fontCache=void 0}})],_Text.prototype,"fontWeight",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)({changeCb:i=>{i.fontCache=void 0}})],_Text.prototype,"fontSize",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)({changeCb:i=>{i.fontCache=void 0}})],_Text.prototype,"fontFamily",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],_Text.prototype,"textAlign",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],_Text.prototype,"textBaseline",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],_Text.prototype,"lineHeight",2);var Text=_Text,RotatableText=Rotatable(Text),TransformableText=Rotatable(Translatable(Text)),CaptionTooltipProperties=class extends import_ag_charts_core27.BaseProperties{};__decorateClass([import_ag_charts_core27.Property],CaptionTooltipProperties.prototype,"visible",2),__decorateClass([import_ag_charts_core27.Property],CaptionTooltipProperties.prototype,"text",2),__decorateClass([import_ag_charts_core27.Property],CaptionTooltipProperties.prototype,"renderer",2);var Caption=class extends import_ag_charts_core27.BaseProperties{constructor(){super(...arguments),this.id=(0,import_ag_charts_core27.createId)(this),this.node=new RotatableText({zIndex:1}).setProperties({textAlign:"center",pointerEvents:1}),this.enabled=!1,this.textAlign="center",this.fontSize=import_ag_charts_core27.FONT_SIZE.SMALLER,this.fontFamily="sans-serif",this.wrapping="always",this.truncate=!0,this.padding=0,this.layoutStyle="block",this.tooltip=new CaptionTooltipProperties,this.truncated=!1}registerInteraction(i,t){return i.eventsHub.on("layout:complete",()=>this.updateA11yText(i,t))}computeTextWrap(i,t){const{text:e,padding:s,wrapping:n,truncate:a}=this,r=a?i:1/0,o=a?t:1/0,h=Math.min(this.maxWidth??1/0,r)-s*2,c=this.maxHeight??o-s*2,l={maxWidth:h,maxHeight:c,font:this,textWrap:n};if(!Number.isFinite(h)&&!Number.isFinite(c)){this.node.text=e;return}let u;(0,import_ag_charts_core27.isArray)(e)?(u=(0,import_ag_charts_core27.wrapTextSegments)(e,l),this.truncated=u.some(import_ag_charts_core27.isSegmentTruncated)):(u=(0,import_ag_charts_core27.wrapText)((0,import_ag_charts_core27.toTextString)(e),l),this.truncated=(0,import_ag_charts_core27.isTextTruncated)(u)),this.node.text=u}updateA11yText(i,t){const{proxyInteractionService:e}=i;if(!this.enabled||!this.text){this.destroyProxyText();return}const s=Transformable.toCanvas(this.node);if(!s)return;const{id:n}=this;this.proxyText==null&&(this.proxyText=e.createProxyElement({type:"text",domManagerId:n,where:t}),this.proxyTextListeners=[this.proxyText.addListener("mousemove",o=>this.handleMouseMove(i,o)),this.proxyText.addListener("mouseleave",()=>this.handleTooltipHide(i)),this.proxyText.addListener("focus",()=>this.handleFocus(i)),this.proxyText.addListener("blur",()=>this.handleTooltipHide(i))]);const a=(0,import_ag_charts_core27.toPlainText)(this.text);a!==this.lastProxyTextContent&&(this.proxyText.textContent=a,this.lastProxyTextContent=a);const{lastProxyBBox:r}=this;(s.x!==r?.x||s.y!==r?.y||s.width!==r?.width||s.height!==r?.height)&&(this.proxyText.setBounds(s),this.lastProxyBBox={x:s.x,y:s.y,width:s.width,height:s.height})}getEffectiveTooltipVisible(){const{visible:i,text:t,renderer:e}=this.tooltip;return i??(t!=null||e!=null?"always":"auto")}getTooltipContent(i){const t=(0,import_ag_charts_core27.toPlainText)(this.text),{renderer:e,text:s}=this.tooltip;if(e!=null){const a={text:t},r=(0,import_ag_charts_core27.callWithContext)(i.chartService,e,a);if(r==="")return;if(r!=null)return{type:"raw",rawHtmlString:(0,import_ag_charts_core27.toTextString)(r)}}return{type:"structured",title:s??t}}showTooltip(i,t,e){if(!this.enabled)return;const s=this.getEffectiveTooltipVisible();if(s==="never"||s==="auto"&&!this.truncated)return;const n=this.getTooltipContent(i);n!=null&&i.tooltipManager.updateTooltip(this.id,{canvasX:t,canvasY:e,showArrow:!1},[n])}handleMouseMove(i,t){if(t==null)return;const{x:e,y:s}=Transformable.toCanvas(this.node),n=t.sourceEvent.offsetX+e,a=t.sourceEvent.offsetY+s;this.showTooltip(i,n,a)}handleFocus(i){const t=Transformable.toCanvas(this.node);if(!t)return;const e=t.x+t.width/2,s=t.y+t.height/2;this.showTooltip(i,e,s)}handleTooltipHide(i){i.tooltipManager.removeTooltip(this.id,void 0,!0)}destroy(){this.destroyProxyText()}destroyProxyText(){if(this.proxyText!=null){for(const i of this.proxyTextListeners??[])i();this.proxyTextListeners=void 0,this.proxyText.destroy(),this.proxyText=void 0,this.lastProxyTextContent=void 0,this.lastProxyBBox=void 0}}};Caption.className="Caption",__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node","visible")],Caption.prototype,"enabled",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node")],Caption.prototype,"text",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node")],Caption.prototype,"textAlign",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node")],Caption.prototype,"fontStyle",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node")],Caption.prototype,"fontWeight",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node")],Caption.prototype,"fontSize",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node")],Caption.prototype,"fontFamily",2),__decorateClass([import_ag_charts_core27.Property,(0,import_ag_charts_core27.ProxyPropertyOnWrite)("node","fill")],Caption.prototype,"color",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"spacing",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"maxWidth",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"maxHeight",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"wrapping",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"truncate",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"padding",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"layoutStyle",2),__decorateClass([import_ag_charts_core27.Property],Caption.prototype,"tooltip",2);var import_ag_charts_core29=require("ag-charts-core"),import_ag_charts_core28=require("ag-charts-core");function drawMarkerUnitPolygon(i,t){const{path:e,size:s}=i,{x:n,y:a}=i;e.clear();let r=!1;for(const[o,h]of t){const c=n+(o-.5)*s,l=a+(h-.5)*s;r?e.lineTo(c,l):e.moveTo(c,l),r=!0}e.closePath()}var MARKER_SHAPES={circle({path:i,x:t,y:e,size:s}){const n=s/2;i.arc(t,e,n,0,Math.PI*2),i.closePath()},cross(i){drawMarkerUnitPolygon(i,[[.25,0],[.5,.25],[.75,0],[1,.25],[.75,.5],[1,.75],[.75,1],[.5,.75],[.25,1],[0,.75],[.25,.5],[0,.25]])},diamond(i){drawMarkerUnitPolygon(i,[[.5,0],[1,.5],[.5,1],[0,.5]])},heart({path:i,x:t,y:e,size:s}){const n=s/4;e=e+n/2,i.arc(t-n,e-n,n,(0,import_ag_charts_core28.toRadians)(130),(0,import_ag_charts_core28.toRadians)(330)),i.arc(t+n,e-n,n,(0,import_ag_charts_core28.toRadians)(220),(0,import_ag_charts_core28.toRadians)(50)),i.lineTo(t,e+n),i.closePath()},pin({path:i,x:t,y:e,size:s}){i.moveTo(t+(.891-.5)*s,e+(.391-.5)*s),i.cubicCurveTo(t+(.891-.5)*s,e+(.606-.5)*s,t+(.5-.5)*s,e+(1-.5)*s,t+(.5-.5)*s,e+(1-.5)*s),i.cubicCurveTo(t+(.5-.5)*s,e+(1-.5)*s,t+(.109-.5)*s,e+(.606-.5)*s,t+(.109-.5)*s,e+(.391-.5)*s),i.cubicCurveTo(t+(.109-.5)*s,e+(.175-.5)*s,t+(.284-.5)*s,e+(0-.5)*s,t+(.5-.5)*s,e+(0-.5)*s),i.cubicCurveTo(t+(.716-.5)*s,e+(0-.5)*s,t+(.891-.5)*s,e+(.175-.5)*s,t+(.891-.5)*s,e+(.391-.5)*s),i.closePath()},plus(i){drawMarkerUnitPolygon(i,[[1/3,0],[2/3,0],[2/3,1/3],[1,1/3],[1,2/3],[2/3,2/3],[2/3,1],[1/3,1],[1/3,2/3],[0,2/3],[0,1/3],[1/3,1/3]])},square({path:i,x:t,y:e,size:s}){const n=s/2;i.moveTo(t-n,e-n),i.lineTo(t+n,e-n),i.lineTo(t+n,e+n),i.lineTo(t-n,e+n),i.closePath()},star({path:i,x:t,y:e,size:s}){const a=s/2,r=a/2,o=Math.PI/2;for(let h=0;h<5*2;h++){const c=h%2===0?a:r,l=h*Math.PI/5-o,u=t+Math.cos(l)*c,d=e+Math.sin(l)*c;i.lineTo(u,d)}i.closePath()},triangle(i){drawMarkerUnitPolygon(i,[[.5,0],[1,.87],[0,.87]])}},MAX_CACHE_ENTRIES=1024,stringShapeCache=new Map,functionShapeCache=new WeakMap;function buildPath(i,t,e){const s=new ExtendedPath2D,n={path:s,x:0,y:0,size:t,pixelRatio:e};return typeof i=="string"?MARKER_SHAPES[i](n):i(n),s}function getSharedMarkerPath(i,t,e=1){if(typeof i=="string"){const s=`${i}:${t}`;let n=stringShapeCache.get(s);return n===void 0&&(stringShapeCache.size>=MAX_CACHE_ENTRIES&&stringShapeCache.clear(),n=buildPath(i,t,1),stringShapeCache.set(s,n)),n}if(typeof i=="function"){let s=functionShapeCache.get(i);s===void 0&&(s=new Map,functionShapeCache.set(i,s));const n=`${t}:${e}`;let a=s.get(n);return a===void 0&&(s.size>=MAX_CACHE_ENTRIES&&s.clear(),a=buildPath(i,t,e),s.set(n,a)),a}return buildPath("square",t,e)}var PIN_ANCHOR=Object.freeze({x:.5,y:1}),CENTRE_ANCHOR=Object.freeze({x:.5,y:.5}),DRAW_BBOX_SCRATCH=new BBox(0,0,0,0),FILL_BBOX_SCRATCH=new BBox(0,0,0,0),InternalMarker=class extends Path{constructor(){super(...arguments),this.shape="square",this.x=0,this.y=0,this.size=12}onChangeDetection(i){if(i==="__x"||i==="__y"){this.markDirty(i);return}super.onChangeDetection(i)}isPointInPath(i,t){return this.distanceSquaredLocal(i,t)<=0}isPointInSharedPath(i,t){if(!this._sharedPath?.closedPath)return!1;const e=Marker.anchor(this.shape),s=i-this.x+(e.x-.5)*this.size,n=t-this.y+(e.y-.5)*this.size;return this._sharedPath.isPointInPath(s,n)}get midPoint(){return{x:this.x,y:this.y}}distanceSquared(i,t){return this.distanceSquaredLocal(i,t)}distanceSquaredLocal(i,t){const e=Marker.anchor(this.shape),s=i-this.x+(e.x-.5)*this.size,n=t-this.y+(e.y-.5)*this.size,a=this.size/2;return Math.max(s*s+n*n-a*a,0)}pathComplexity(){return this._sharedPath?.commands.length??0}updatePath(){const{shape:i,size:t}=this;if(i==null||!(t>0)){this._sharedPath=void 0;return}const e=this.layerManager?.canvas?.pixelRatio??1,s=i==="square"?align(e,t):t;this._sharedPath=getSharedMarkerPath(i,s,e)}computeBBox(){const{x:i,y:t,size:e}=this,s=Marker.anchor(this.shape);return new BBox(i-e*s.x,t-e*s.y,e,e)}drawPath(i){if(this._sharedPath===void 0)return;const{shape:t,x:e,y:s,size:n}=this,a=Marker.anchor(t),r=e-(a.x-.5)*n,o=s-(a.y-.5)*n,h=this.layerManager?.canvas?.pixelRatio??1,c=(t==="square"?align(h,n):n)/2,l=t==="square"?align(h,r-c)+c:r,u=t==="square"?align(h,o-c)+c:o,d=super.getBBox();DRAW_BBOX_SCRATCH.x=d.x-l,DRAW_BBOX_SCRATCH.y=d.y-u,DRAW_BBOX_SCRATCH.width=d.width,DRAW_BBOX_SCRATCH.height=d.height;let f;const g=this.__fillBBox;g&&(FILL_BBOX_SCRATCH.x=g.x-l,FILL_BBOX_SCRATCH.y=g.y-u,FILL_BBOX_SCRATCH.width=g.width,FILL_BBOX_SCRATCH.height=g.height,f=FILL_BBOX_SCRATCH),i.save(),i.translate(l,u);try{this.fillStroke(i,this._sharedPath.getPath2D(),DRAW_BBOX_SCRATCH,f)}finally{i.restore()}}svgPathData(i){if(this.updatePathIfDirty(),this._sharedPath===void 0)return"";const{shape:t,x:e,y:s,size:n}=this,a=Marker.anchor(t),r=e-(a.x-.5)*n,o=s-(a.y-.5)*n;return i?this._sharedPath.toSVG((h,c)=>i(h+r,c+o)):this._sharedPath.toSVG((h,c)=>({x:h+r,y:c+o}))}executeFill(i,t){if(t)return super.executeFill(i,t)}executeStroke(i,t){if(t)return super.executeStroke(i,t)}};__decorateClass([(0,import_ag_charts_core29.DeclaredSceneObjectChangeDetection)({equals:import_ag_charts_core29.TRIPLE_EQ})],InternalMarker.prototype,"shape",2),__decorateClass([(0,import_ag_charts_core29.DeclaredSceneChangeDetection)()],InternalMarker.prototype,"x",2),__decorateClass([(0,import_ag_charts_core29.DeclaredSceneChangeDetection)()],InternalMarker.prototype,"y",2),__decorateClass([(0,import_ag_charts_core29.DeclaredSceneChangeDetection)({convertor:Math.abs})],InternalMarker.prototype,"size",2);var Marker=class extends Rotatable(Scalable(Translatable(InternalMarker))){static anchor(i){return i==="pin"?PIN_ANCHOR:typeof i=="function"&&"anchor"in i?i.anchor:CENTRE_ANCHOR}constructor(i){super(i),i?.shape!=null&&(this.shape=i.shape)}resetAnimationProperties(i,t,e,s,n,a){const r=this.__size!==e;this.__x=i,this.__y=t,this.__size=e,this.__opacity=s,this.resetScalingProperties(n,a,i,t),r&&(this.dirtyPath=!0),this.markDirty()}setVisibilityAndPosition(i,t,e,s){let n=!1,a=!1;this.__visible!==i&&(this.__visible=i,n=!0),this.__shape!==t&&(this.__shape=t,n=!0,a=!0);const r=Math.abs(e);if(this.__size!==r&&(this.__size=r,n=!0,a=!0),s){const{x:o,y:h}=s;this.__x!==o&&(this.__x=o,n=!0),this.__y!==h&&(this.__y=h,n=!0),this.__scalingCenterX!==o&&(this.__scalingCenterX=o,n=!0),this.__scalingCenterY!==h&&(this.__scalingCenterY=h,n=!0)}n&&(a&&(this.dirtyPath=!0),this.markDirty())}},import_ag_charts_core31=require("ag-charts-core"),import_ag_charts_core30=require("ag-charts-core"),_BandScale=class ot extends AbstractScale{constructor(){super(...arguments),this.invalid=!0,this.range=[0,1],this.round=!1,this._bandwidth=1,this._step=1,this._inset=1,this._rawBandwidth=1,this._paddingInner=0,this._paddingOuter=0}static is(t){return t instanceof ot}get bandwidth(){return this.refresh(),this._bandwidth}get step(){return this.refresh(),this._step}get inset(){return this.refresh(),this._inset}get rawBandwidth(){return this.refresh(),this._rawBandwidth}set padding(t){t=(0,import_ag_charts_core30.clamp)(0,t,1),this._paddingInner=t,this._paddingOuter=t}get padding(){return this._paddingInner}set paddingInner(t){this.invalid=!0,this._paddingInner=(0,import_ag_charts_core30.clamp)(0,t,1)}get paddingInner(){return this._paddingInner}set paddingOuter(t){this.invalid=!0,this._paddingOuter=(0,import_ag_charts_core30.clamp)(0,t,1)}get paddingOuter(){return this._paddingOuter}getBandCountForUpdate(){return this.bands.length}refresh(){this.invalid&&(this.invalid=!1,this.update(),this.invalid&&import_ag_charts_core30.Logger.warnOnce("Expected update to not invalidate scale"))}convert(t,e){this.refresh();const s=this.findIndex(t,e?.alignment,e?.alignmentExclusive);return s==null||s<0||s>=this.getBandCountForUpdate()?Number.NaN:this.ordinalRange(s)}getDomainMinMax(){return unpackDomainMinMax(this.domain)}invertNearestIndex(t,e="center"){this.refresh();const s=this.getBandCountForUpdate();if(s===0)return-1;let n=0,a=s-1,r=1/0,o=0;for(;n<=a;){const h=Math.trunc((a+n)/2),c=this.ordinalRange(h),l=c-t;if(l===0)return h;(e==="center"||l<0)&&Math.abs(l)<r&&(r=Math.abs(l),o=h),c<t?n=h+1:a=h-1}return o}update(){const[t,e]=this.range;let{_paddingInner:s}=this;const{_paddingOuter:n}=this,a=this.getBandCountForUpdate();if(a===0)return;const r=e-t;let o;a===1?(s=0,o=r*(1-n*2)):o=r/Math.max(1,a-s+n*2);const h=this.round&&Math.floor(o)>0,c=h?Math.floor(o):o;let l=t+(r-c*(a-s))/2,u=c*(1-s);h&&(l=Math.round(l),u=Math.round(u)),this._step=c,this._inset=l,this._bandwidth=u,this._rawBandwidth=o*(1-s)}ordinalRange(t){const{_inset:e,_step:s,range:n}=this,a=Math.min(n[0],n[1]),r=Math.max(n[0],n[1]);return(0,import_ag_charts_core30.clamp)(a,e+s*t,r)}};__decorateClass([Invalidating],_BandScale.prototype,"range",2),__decorateClass([Invalidating],_BandScale.prototype,"round",2);var BandScale=_BandScale,CategoryScale=class ht extends BandScale{constructor(){super(...arguments),this.type="category",this.defaultTickCount=0,this.index=new Map,this.indexInitialized=!1,this._domain=[]}static is(t){return t instanceof ht}set domain(t){this._domain!==t&&(this.invalid=!0,this._domain=t,this.index.clear(),this.indexInitialized=!1)}get domain(){return this._domain}get bands(){return this._domain}normalizeDomains(...t){let e;const s=new Set;let n=!0;for(const a of t){const r=a.domain;s.has(r)||(s.add(r),e==null?e=deduplicateCategories(r):(n&&(n=domainOrderedToNormalizedDomain(r,e)),e=deduplicateCategories([...e,...r])))}return e??(e=[]),{domain:e,animatable:n}}toDomain(t){}invert(t,e=!1){this.refresh();const s=e?this.bandwidth/2:0,n=this.invertNearestIndex(Math.max(0,t-s));return e||t===this.ordinalRange(n)?this.domain[n]:void 0}invertWithPercentage(t){this.refresh();const e=this.invertNearestIndex(t,"left"),s=this.domain[e];if(s==null)return;const n=this.bandwidth===0?this.step:this.bandwidth,a=this.convert(s),r=n===0?0:(t-a)/n;return{value:s,groupPercentage:r}}ticks(t,e=this.domain,s){const{bands:n}=this;let{tickCount:a}=t;if(a===0){const p=n.length>1?1:0;return{ticks:n[p]?[n[p]]:[],count:void 0,firstTickIndex:p}}let r=a!=null&&a!==0?Math.trunc(n.length/a):1;if(r=(0,import_ag_charts_core31.previousPowerOf2)(r),r<=1)return filterVisibleTicks(e,!1,s);a=Math.trunc(n.length/r);const o=r*a,h=(0,import_ag_charts_core31.previousPowerOf2)(Math.trunc((n.length-o)/2)),c=(0,import_ag_charts_core31.clamp)(0,Math.floor((s?.[0]??0)*n.length),n.length),l=(0,import_ag_charts_core31.clamp)(0,Math.ceil((s?.[1]??1)*n.length),n.length),u=Math.floor((c-h)/r)*r+h,d=Math.ceil((l-h)/r)*r+h,f=[];for(let p=u;p<d;p+=r)p>=0&&p<n.length&&f.push(n[p]);let g=f.length>0?this.findIndex(f[0]):void 0;return g!=null&&(g=Math.floor((g-h)/r)),{ticks:f,count:void 0,firstTickIndex:g}}findIndex(t){const{index:e,indexInitialized:s}=this;if(!s){const{domain:n}=this;for(let a=0;a<n.length;a++)e.set((0,import_ag_charts_core31.dateToNumber)(n[a]),a);this.indexInitialized=!0}return e.get((0,import_ag_charts_core31.dateToNumber)(t))}};function deduplicateCategories(i){let t;const e=new Set;for(const s of i){const n=(0,import_ag_charts_core31.dateToNumber)(s),a=e.size;e.add(n),e.size!==a?t?.push(s):t??(t=i.slice(0,e.size))}return t??i}function domainOrderedToNormalizedDomain(i,t){let e=-1;for(const s of i){const n=t.indexOf(s);if(n===-1)e=1/0;else{if(n<=e)return!1;e=n}}return!0}var import_ag_charts_core33=require("ag-charts-core"),import_ag_charts_core32=require("ag-charts-core"),_ContinuousScale=class Z extends AbstractScale{constructor(t=[],e=[]){super(),this.range=e,this.defaultTickCount=Z.defaultTickCount,this.defaultClamp=!1,this._domain=[],this.domainNeedsValueOf=!0,this.d0Cache=Number.NaN,this.d1Cache=Number.NaN,this.d0Big=void 0,this.d1Big=void 0,this.domain=t}static is(t){return t instanceof Z}get domain(){return this._domain}set domain(t){if(!t||t.length<2){this._domain=narrowStoredDomain(t),this.d0Big=this.d1Big=void 0,this.d0Cache=Number.NaN,this.d1Cache=Number.NaN;return}const e=t[0],s=t[1];if(typeof e=="bigint"||typeof s=="bigint"){this.d0Big=typeof e=="bigint"?e:void 0,this.d1Big=typeof s=="bigint"?s:void 0,this.domainNeedsValueOf=!1,this.d0Cache=Number(e),this.d1Cache=Number(s),this._domain=narrowStoredDomain(t);return}this.d0Big=this.d1Big=void 0,this._domain=narrowStoredDomain(t),this.domainNeedsValueOf=e!=null&&typeof e=="object",this.domainNeedsValueOf?(this.d0Cache=e.valueOf(),this.d1Cache=s.valueOf()):(this.d0Cache=Number(e),this.d1Cache=Number(s))}normalizeDomains(...t){return normalizeContinuousDomains(...t)}calcBandwidth(t=1,e=1){const{domain:s}=this,n=this.getPixelRange();if(s.length===0)return n;let r=Math.abs(this.d1Cache-this.d0Cache)/Number(t)+1;if(e!==0){const o=Math.floor(n);r=Math.min(r,o)}return n/Math.max(1,r)}convert(t,e){const{domain:s}=this;if(!s||s.length<2||t==null)return Number.NaN;const{range:n}=this,a=e?.clamp??this.defaultClamp;if(this.d0Big!=null&&this.d1Big!=null&&this.transform==null&&(typeof t=="bigint"||typeof t=="number"&&Number.isFinite(t)))return convertBigInt(t,this.d0Big,this.d1Big,n,a);let r=this.d0Cache,o=this.d1Cache,h;if(typeof t=="number"?h=t:typeof t=="bigint"?h=Number(t):h=t.valueOf(),this.transform&&(r=this.transform(r),o=this.transform(o),h=this.transform(h)),a){const[l,u]=(0,import_ag_charts_core32.findMinMax)([r,o]);if(h<l)return n[0];if(h>u)return n[1]}if(r===o)return(n[0]+n[1])/2;if(h===r)return n[0];if(h===o)return n[1];const c=n[0];return c+(h-r)/(o-r)*(n[1]-c)}convertClamped(t){const{d0Big:e,d1Big:s}=this;if(typeof t=="bigint"&&e!=null&&s!=null){const h=(0,import_ag_charts_core32.minValue)(e,s),c=(0,import_ag_charts_core32.maxValue)(e,s);return this.convert((0,import_ag_charts_core32.minValue)(c,(0,import_ag_charts_core32.maxValue)(h,t)))}const{d0Cache:n,d1Cache:a}=this,r=Math.min(n,a),o=Math.max(n,a);return this.convert(Math.min(o,Math.max(r,(0,import_ag_charts_core32.toNumber)(t))))}invert(t,e){const{domain:s}=this;if(s.length<2)return;let n=this.d0Cache,a=this.d1Cache;this.transform&&(n=this.transform(n),a=this.transform(a));const{range:r}=this,[o,h]=r;let c;return o===h?c=this.toDomain((n+a)/2):c=this.toDomain(n+(t-o)/(h-o)*(a-n)),this.transformInvert?this.transformInvert(c):c}getDomainMinMax(){return unpackDomainMinMax(this.domain)}snapshotDomain(){const t=this._domain.slice();return this.d0Big!=null&&(t[0]=this.d0Big),this.d1Big!=null&&(t[1]=this.d1Big),t}exactEndpoint(t){return(t===0?this.d0Big:this.d1Big)??this._domain[t]}startIsMin(){return this.exactEndpoint(0)<=this.exactEndpoint(1)}get domainMin(){return this._domain.length<2?this._domain.at(0):this.exactEndpoint(this.startIsMin()?0:1)}get domainMax(){return this._domain.length<2?this._domain.at(0):this.exactEndpoint(this.startIsMin()?1:0)}getPixelRange(){const[t,e]=this.range;return Math.abs(e-t)}};_ContinuousScale.defaultTickCount=5;var ContinuousScale=_ContinuousScale;function narrowStoredDomain(i){return i.map(t=>typeof t=="bigint"?Number(t):t)}var BIGINT_RATIO_SCALE=10n**12n;function convertBigInt(i,t,e,s,n){const a=s[0],r=s[1];if(n){const d=t<e?t:e,f=t<e?e:t;if(i<d)return a;if(i>f)return r}if(t===e)return(a+r)/2;let o,h=0;if(typeof i=="number"){const d=Math.trunc(i);o=BigInt(d),h=i-d}else o=i;if(h===0){if(o===t)return a;if(o===e)return r}const c=e-t,l=(o-t)*BIGINT_RATIO_SCALE/c,u=Number(l)/Number(BIGINT_RATIO_SCALE)+h/Number(c);return a+u*(r-a)}function normalizeContinuousDomains(...i){let t,e;for(const s of i)for(const n of s.domain)(t===void 0||n<t)&&(t=n),(e===void 0||n>e)&&(e=n);return t!=null&&e!=null?{domain:[t,e],animatable:!0}:{domain:[],animatable:!1}}var LinearScale=class J extends ContinuousScale{constructor(){super([0,1],[0,1]),this.type="number"}static is(t){return t instanceof J}static getTickStep(t,e,s){const{interval:n,tickCount:a=ContinuousScale.defaultTickCount,minTickCount:r,maxTickCount:o}=s;return n==null?(0,import_ag_charts_core33.tickStep)(t,e,a,r,o):Number(n)}toDomain(t){return(0,import_ag_charts_core33.isBigInt)(this.domainMin)&&(0,import_ag_charts_core33.isBigInt)(this.domainMax)&&((0,import_ag_charts_core33.isBigInt)(t)||Number.isInteger(t))?BigInt(t):t}ticks({interval:t,tickCount:e=ContinuousScale.defaultTickCount,minTickCount:s,maxTickCount:n},a=this.domain,r){if(!a||a.length<2||e<1)return{ticks:[],count:0,firstTickIndex:0};const[o,h]=a,c=typeof o=="bigint"&&typeof h=="bigint",l=r==null||r[0]===0&&r[1]===1;if(c&&!t&&l){const g=(0,import_ag_charts_core33.createBigIntTicks)(o,h,e);return{ticks:g,count:g.length,firstTickIndex:0}}const u=a.map(Number);if(!u.every(Number.isFinite))return{ticks:[],count:0,firstTickIndex:0};const[d,f]=u;if(t){const g=Math.abs(Number(t));if(!(0,import_ag_charts_core33.isDenseInterval)((f-d)/g,this.getPixelRange()))return(0,import_ag_charts_core33.range)(d,f,g,r)}return(0,import_ag_charts_core33.createTicks)(d,f,e,s,n,r)}niceDomain(t,e=this.domain){if(e.length<2)return[];const{tickCount:s=ContinuousScale.defaultTickCount}=t,[n,a]=e;if(typeof n=="bigint"&&typeof a=="bigint"&&t.interval==null){const[l,u]=(0,import_ag_charts_core33.niceBigIntDomain)(n,a,s);return[t.nice[0]?l:n,t.nice[1]?u:a]}const o=e.map(Number);let[h,c]=o;if(s===1)[h,c]=(0,import_ag_charts_core33.niceTicksDomain)(h,c);else if(s>1){const l=h>c?Math.ceil:Math.floor,u=h>c?Math.floor:Math.ceil,d=4;for(let f=0;f<d;f++){const g=h,p=c,y=J.getTickStep(h,c,t),[m,b]=o;if(h=l(m/y)*y,c=u(b/y)*y,h===g&&c===p)break}}return[t.nice[0]?h:o[0],t.nice[1]?c:o[1]]}},import_ag_charts_core36=require("ag-charts-core"),HdpiCanvas=class{constructor(i){this.width=600,this.height=300,this.direction="ltr";const{width:t,height:e,willReadFrequently:s=!1}=i;this.element=i.canvasElement,this.pixelRatio=i.pixelRatio,this.element.style.display="block",this.element.style.width=(t??this.width)+"px",this.element.style.height=(e??this.height)+"px",this.element.width=deviceDimension(this.pixelRatio,t??this.width),this.element.height=deviceDimension(this.pixelRatio,e??this.height),this.context=this.element.getContext("2d",{willReadFrequently:s}),this.context.direction=this.direction,this.resize(t??this.width,e??this.height,this.pixelRatio),debugContext(this.context)}drawImage(i,t=0,e=0){return i.drawImage(this.context.canvas,t,e)}toDataURL(i){return this.element.toDataURL(i)}resize(i,t,e){if(!(i>0&&t>0))return;const{element:s,context:n}=this;s.width=deviceDimension(e,i),s.height=deviceDimension(e,t),n.setTransform(e,0,0,e,0,0),s.style.width=i+"px",s.style.height=t+"px",this.width=i,this.height=t,this.pixelRatio=e}setDirection(i){this.direction=i?"rtl":"ltr",this.element.dir=this.direction,this.context.direction=this.direction}clear(){clearContext(this)}destroy(){this.element.remove(),this.element.width=0,this.element.height=0,this.context.clearRect(0,0,0,0),Object.freeze(this)}reset(){this.context.reset(),this.context.verifyDepthZero?.(),this.context.direction=this.direction}},import_ag_charts_core34=require("ag-charts-core"),ImageLoader=class extends import_ag_charts_core34.EventEmitter{constructor(){super(...arguments),this.cache=new Map,this.imageLoadingCount=0,this.destroyed=!1}loadImage(i,t,e){const s=computeCacheKey(i,e),n=this.cache.get(s);if(n?.image)return n.image;if(n!=null&&t){n.nodes.add(t);return}if(!t)return;const a={image:void 0,nodes:new Set([t]),blobUrl:void 0};this.cache.set(s,a),this.imageLoadingCount++;const r=()=>{a.blobUrl!=null&&(URL.revokeObjectURL(a.blobUrl),a.blobUrl=void 0)},o=c=>{if(this.destroyed){r();return}a.image=c;for(const l of a.nodes)l.markDirty();a.nodes.clear(),this.imageLoadingCount--,r(),this.emit("image-loaded",{uri:i})},h=()=>{if(this.destroyed){r();return}this.imageLoadingCount--,a.nodes.clear(),r(),this.cache.delete(s),this.emit("image-error",{uri:i})};this.resolveSource(i,e).then(c=>{if(this.destroyed){c.blobUrl!=null&&URL.revokeObjectURL(c.blobUrl);return}c.blobUrl!=null&&(a.blobUrl=c.blobUrl);const l=(0,import_ag_charts_core34.getImage)(),u=new l;u.onload=()=>o(u),u.onerror=h,u.src=c.src}).catch(h)}unregisterNode(i){for(const t of this.cache.values())t.nodes.delete(i)}async resolveSource(i,t){if(!t||typeof fetch!="function"||typeof Blob>"u")return{src:i};const e=uriPathnameEndsWith(i,".svg"),s=i.startsWith("data:image/svg");if(!e&&!s)return{src:i};try{const n=await fetch(i,{mode:"cors"}),a=n.headers.get("content-type")??"",r=a.startsWith("image/")||a.startsWith("application/"),o=a.includes("svg");if(r&&!o)return{src:i};const h=await n.text();if(!o&&!looksLikeSvgMarkup(h))return{src:i};const c=injectSvgSize(h,t.width,t.height);if(!c)return{src:i};const l=new Blob([c],{type:"image/svg+xml"}),u=URL.createObjectURL(l);return{src:u,blobUrl:u}}catch{return{src:i}}}waitingToLoad(){return this.imageLoadingCount>0}destroy(){this.destroyed=!0;for(const i of this.cache.values())i.nodes.clear(),i.blobUrl!=null&&(URL.revokeObjectURL(i.blobUrl),i.blobUrl=void 0);this.cache.clear()}};function computeCacheKey(i,t){return t?`${i}@${t.width}x${t.height}`:i}function uriPathnameEndsWith(i,t){const e=i.search(/[?#]/);return(e>=0?i.slice(0,e):i).toLowerCase().endsWith(t)}var SVG_MARKUP_PREFIX=/^\uFEFF?\s{0,32}(?:<\?xml[^>]{0,256}\?>\s{0,32})?(?:<!DOCTYPE[^>]{0,256}>\s{0,32})?<svg[\s>]/i;function looksLikeSvgMarkup(i){return SVG_MARKUP_PREFIX.test(i)}var ABSOLUTE_SIZE=/^\s{0,8}\+?(\d{1,6}(?:\.\d{1,6})?(?:e[+-]?\d{1,3})?)\s{0,8}(?:px|pt|cm|mm|in|pc|q)?\s{0,8}$/i;function hasAbsoluteSize(i,t){const e=i.getAttribute(t);if(e==null)return!1;const s=ABSOLUTE_SIZE.exec(e);return s?Number.parseFloat(s[1])>0:!1}function injectSvgSize(i,t,e){if(!(typeof DOMParser>"u"||typeof XMLSerializer>"u"))try{const n=new DOMParser().parseFromString(i,"image/svg+xml").documentElement;if(n?.tagName.toLowerCase()!=="svg")return;const a=hasAbsoluteSize(n,"width"),r=hasAbsoluteSize(n,"height");return a&&r?void 0:(a||n.setAttribute("width",String(t)),r||n.setAttribute("height",String(e)),new XMLSerializer().serializeToString(n))}catch{return}}var import_ag_charts_core35=require("ag-charts-core"),LayersManager=class{constructor(i){this.canvas=i,this.debug=import_ag_charts_core35.Debug.create(!0,"scene"),this.layersMap=new Map,this.nextLayerId=0}get size(){return this.layersMap.size}resize(i,t,e){this.canvas.resize(i,t,e);for(const{canvas:s}of this.layersMap.values())s.resize(i,t,e)}addLayer(i){const{width:t,height:e,pixelRatio:s}=this.canvas,{name:n}=i,a=new HdpiOffscreenCanvas({width:t,height:e,pixelRatio:s});return this.layersMap.set(a,{id:this.nextLayerId++,name:n,canvas:a}),this.debug("Scene.addLayer() - layers",this.layersMap),a}removeLayer(i){this.layersMap.has(i)&&(this.layersMap.delete(i),i.destroy(),this.debug("Scene.removeLayer() -  layers",this.layersMap))}clear(){for(const i of this.layersMap.values())i.canvas.destroy();this.layersMap.clear()}},Scene=class extends import_ag_charts_core36.EventEmitter{constructor(i){super(),this.debug=import_ag_charts_core36.Debug.create(!0,"scene"),this.id=(0,import_ag_charts_core36.createId)(this),this.imageLoader=new ImageLoader,this.root=null,this.pendingSize=null,this.isDirty=!1,this.direction="ltr",this.cleanup=new import_ag_charts_core36.CleanupRegistry,this.updateDebugFlags(),this.canvas=new HdpiCanvas(i),this.layersManager=new LayersManager(this.canvas),this.cleanup.register(this.imageLoader.on("image-loaded",()=>{this.emit("scene-changed",{})}),this.imageLoader.on("image-error",({uri:t})=>{import_ag_charts_core36.Logger.warnOnce(`Unable to load image ${t}`)}))}waitingForUpdate(){return this.imageLoader?.waitingToLoad()??!1}get width(){return this.pendingSize?.[0]??this.canvas.width}get height(){return this.pendingSize?.[1]??this.canvas.height}get pixelRatio(){return this.pendingSize?.[2]??this.canvas.pixelRatio}get isRtl(){return this.direction==="rtl"}setContainer(i){const{element:t}=this.canvas;return t.remove(),i.appendChild(t),this}setRoot(i){return this.root===i?this:(this.isDirty=!0,this.root?.setScene(),this.root=i,i&&(i.visible=!0,i.setScene(this)),this)}updateDebugFlags(){import_ag_charts_core36.Debug.inDevelopmentMode(()=>Node._debugEnabled=!0)}clearCanvas(){this.canvas.clear()}attachNode(i){return this.appendChild(i),()=>i.remove()}appendChild(i){return this.root?.appendChild(i),this}removeChild(i){return i.remove(),this}download(i,t){(0,import_ag_charts_core36.downloadUrl)(this.canvas.toDataURL(t),i?.trim()??"image")}getDataURL(i){return this.canvas.toDataURL(i)}resize(i,t,e){return i=Math.round(i),t=Math.round(t),e??(e=this.pixelRatio),i>0&&t>0&&(i!==this.width||t!==this.height||e!==this.pixelRatio)?(this.pendingSize=[i,t,e],this.isDirty=!0,!0):!1}setDirection(i){this.direction=i?"rtl":"ltr",this.canvas.setDirection(i)}updateBaseFont(){const i=this.root?.resolveFont();i==null||i===this._contextFont||(this._baseFont=i,!this.pendingSize&&(this.canvas.context.font=i,this._contextFont=i))}applyPendingResize(){return this.pendingSize?(this.layersManager.resize(...this.pendingSize),this.pendingSize=null,this._contextFont=void 0,this._baseFont!=null&&(this.canvas.context.font=this._baseFont,this._contextFont=this._baseFont),!0):!1}render(i){const{debugSplitTimes:t={start:performance.now()},extraDebugStats:e,seriesRect:s,debugColors:n}=i??{},{canvas:a,canvas:{context:r}={},root:o,width:h,height:c,pixelRatio:l}=this;if(!r)return;const u=import_ag_charts_core36.Debug.check("scene:stats","scene:stats:verbose");u&&this.ensureDebugStatsRegistration();const d=performance.now(),f=this.applyPendingResize();if(o&&!o.visible){this.isDirty=!1;return}let g;if(o instanceof Group&&(g=o.dirty),o!=null&&g===!1&&!this.isDirty){this.debug.check()&&this.debug("Scene.render() - no-op",{tree:buildTree(o,"console")}),u&&debugStats(this.layersManager,t,r,void 0,e,s,n);return}const p={ctx:r,direction:this.direction,width:h,height:c,devicePixelRatio:l,debugNodes:{},currentFont:this._contextFont};import_ag_charts_core36.Debug.check("scene:stats:verbose")&&(p.stats={layersRendered:0,layersSkipped:0,nodesRendered:0,nodesSkipped:0,opsPerformed:0,opsSkipped:0}),prepareSceneNodeHighlight(p);let y=!1;if((g!==!1||f)&&(y=!0,a.clear()),o&&import_ag_charts_core36.Debug.check("scene:dirtyTree")){const{dirtyTree:m,paths:b}=buildDirtyTree(o);import_ag_charts_core36.Debug.create("scene:dirtyTree")("Scene.render() - dirtyTree",{dirtyTree:m,paths:b})}if(o&&y){if(o.visible&&o.preRender(p),this.debug.check()){const m=buildTree(o,"console");this.debug("Scene.render() - before",{canvasCleared:y,tree:m})}if(o.visible)try{r.save(),o.render(p),r.restore()}catch(m){throw this.canvas.reset(),m}}t["\u270D\uFE0F"]=performance.now()-d,r.verifyDepthZero?.(),this.isDirty=!1,u&&debugStats(this.layersManager,t,r,p.stats,e,s,n),debugSceneNodeHighlight(r,p.debugNodes),o&&this.debug.check()&&this.debug("Scene.render() - after",{tree:buildTree(o,"console"),canvasCleared:y})}ensureDebugStatsRegistration(){if(this.releaseDebugStats)return;const i=registerDebugStatsConsumer(),t=()=>{i(),this.releaseDebugStats=void 0};this.releaseDebugStats=t,this.cleanup.register(t)}toSVG(){const{root:i,width:t,height:e}=this;if(i!=null)return Node.toSVG(i,t,e)}strip(){const{context:i,pixelRatio:t}=this.canvas;i.setTransform(t,0,0,t,0,0),this.layersManager.clear(),this.setRoot(null),this.isDirty=!1,this.clear()}destroy(){this.canvas!=null&&(this.strip(),this.canvas.destroy(),this.imageLoader.destroy(),this.cleanup.flush(),cleanupDebugStats(),Object.assign(this,{canvas:void 0}))}};Scene.className="Scene";var import_ag_charts_core37=require("ag-charts-core"),Arc=class extends Path{constructor(){super(...arguments),this.centerX=0,this.centerY=0,this.radius=10,this.startAngle=0,this.endAngle=Math.PI*2,this.counterClockwise=!1,this.type=0}get fullPie(){return(0,import_ag_charts_core37.isNumberEqual)((0,import_ag_charts_core37.normalizeAngle360)(this.startAngle),(0,import_ag_charts_core37.normalizeAngle360)(this.endAngle))}updatePath(){const i=this.path;i.clear(),i.arc(this.centerX,this.centerY,this.radius,this.startAngle,this.endAngle,this.counterClockwise),this.type===1?i.closePath():this.type===2&&!this.fullPie&&(i.lineTo(this.centerX,this.centerY),i.closePath())}computeBBox(){return new BBox(this.centerX-this.radius,this.centerY-this.radius,this.radius*2,this.radius*2)}isPointInPath(i,t){const e=this.getBBox();return this.type!==0&&e.containsPoint(i,t)&&this.path.isPointInPath(i,t)}};Arc.className="Arc",__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"centerX",2),__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"centerY",2),__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"radius",2),__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"startAngle",2),__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"endAngle",2),__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"counterClockwise",2),__decorateClass([(0,import_ag_charts_core37.SceneChangeDetection)()],Arc.prototype,"type",2);var import_ag_charts_core38=require("ag-charts-core"),Line=class extends Shape{constructor(i={}){super(i),this.x1=0,this.y1=0,this.x2=0,this.y2=0,this.fill=void 0,this.strokeWidth=1}set x(i){this.x1=i,this.x2=i}set y(i){this.y1=i,this.y2=i}get midPoint(){return{x:(this.x1+this.x2)/2,y:(this.y1+this.y2)/2}}computeBBox(){return new BBox(Math.min(this.x1,this.x2),Math.min(this.y1,this.y2),Math.abs(this.x2-this.x1),Math.abs(this.y2-this.y1))}isPointInPath(i,t){return this.x1===this.x2||this.y1===this.y2?this.getBBox().clone().grow(this.strokeWidth/2).containsPoint(i,t):!1}distanceSquared(i,t){const{x1:e,y1:s,x2:n,y2:a}=this;return(0,import_ag_charts_core38.lineDistanceSquared)(i,t,e,s,n,a,1/0)}render(i){const{ctx:t,devicePixelRatio:e}=i;let{x1:s,y1:n,x2:a,y2:r}=this;if(s===a){const{strokeWidth:o}=this,h=Math.round(s*e)/e+Math.trunc(o*e)%2/(e*2);s=h,a=h}else if(n===r){const{strokeWidth:o}=this,h=Math.round(n*e)/e+Math.trunc(o*e)%2/(e*2);n=h,r=h}t.beginPath(),t.moveTo(s,n),t.lineTo(a,r),this.fillStroke(t),this.fillShadow?.markClean(),super.render(i)}toSVG(){if(!this.visible)return;const i=(0,import_ag_charts_core38.createSvgElement)("line");return i.setAttribute("x1",String(this.x1)),i.setAttribute("y1",String(this.y1)),i.setAttribute("x2",String(this.x2)),i.setAttribute("y2",String(this.y2)),this.applySvgStrokeAttributes(i),{elements:[i]}}};Line.className="Line",__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],Line.prototype,"x1",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],Line.prototype,"y1",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],Line.prototype,"x2",2),__decorateClass([(0,import_ag_charts_core3.SceneChangeDetection)()],Line.prototype,"y2",2);var import_ag_charts_core39=require("ag-charts-core");function rotatePoint(i,t,e){const s=Math.hypot(i,t),a=Math.atan2(t,i)+e;return{x:Math.cos(a)*s,y:Math.sin(a)*s}}var RadialColumnShape=class extends Path{constructor(){super(...arguments),this.isBeveled=!0,this.columnWidth=0,this.startAngle=0,this.endAngle=0,this.outerRadius=0,this.innerRadius=0,this.axisInnerRadius=0,this.axisOuterRadius=0}set cornerRadius(i){}computeBBox(){const{columnWidth:i}=this,[t,e]=this.normalizeRadii(this.innerRadius,this.outerRadius),s=this.getRotation(),n=-i/2,a=i/2,r=-e,o=-t;let h=1/0,c=1/0,l=-1/0,u=-1/0;for(let d=0;d<4;d+=1){const{x:f,y:g}=rotatePoint(d%2===0?n:a,d<2?r:o,s);h=Math.min(f,h),c=Math.min(g,c),l=Math.max(f,l),u=Math.max(g,u)}return new BBox(h,c,l-h,u-c)}getRotation(){const{startAngle:i,endAngle:t}=this,e=(0,import_ag_charts_core39.angleBetween)(i,t);return(0,import_ag_charts_core39.normalizeAngle360)(i+e/2+Math.PI/2)}normalizeRadii(i,t){return i>t?[t,i]:[i,t]}updatePath(){const{isBeveled:i}=this;i?this.updateBeveledPath():this.updateRectangularPath(),this.checkPathDirty()}updateRectangularPath(){const{columnWidth:i,path:t}=this,[e,s]=this.normalizeRadii(this.innerRadius,this.outerRadius),n=-i/2,a=i/2,r=-s,o=-e,h=this.getRotation(),c=[[n,o],[n,r],[a,r],[a,o]].map(([l,u])=>rotatePoint(l,u,h));t.clear(!0),t.moveTo(c[0].x,c[0].y),t.lineTo(c[1].x,c[1].y),t.lineTo(c[2].x,c[2].y),t.lineTo(c[3].x,c[3].y),t.closePath()}calculateCircleIntersection(i,t){const e=i*i;if(t<e)return null;const s=-Math.sqrt(t-e),n=Math.atan2(s,i);return{y:s,angle:n}}calculateBothIntersections(i,t,e){const s=e*e,n=this.calculateCircleIntersection(i,s),a=this.calculateCircleIntersection(t,s);return!n||!a?null:{left:n,right:a}}calculateAxisOuterIntersections(i,t,e){const s=e*e,n=this.calculateCircleIntersection(i,s),a=this.calculateCircleIntersection(t,s);return!n||!a?null:{left:n,right:a,radiusSquared:s}}moveToRotated(i,t,e){const s=rotatePoint(i,t,e);this.path.moveTo(s.x,s.y)}lineToRotated(i,t,e){const s=rotatePoint(i,t,e);this.path.lineTo(s.x,s.y)}renderTopWithCornerClipping(i,t,e){const{path:s}=this,{right:n,top:a,rotation:r}=e,o=a*a,h=t.radiusSquared-o;if(h<=0)this.lineToRotated(n,t.right.y,r),s.arc(0,0,i,r+t.right.angle,r+t.left.angle,!0);else{const c=Math.sqrt(h),l=Math.atan2(a,c),u=Math.atan2(a,-c);this.lineToRotated(n,t.right.y,r),s.arc(0,0,i,r+t.right.angle,r+l,!0),this.lineToRotated(-c,a,r),s.arc(0,0,i,r+u,r+t.left.angle,!0)}}updateBeveledPath(){const{columnWidth:i,path:t,axisInnerRadius:e,axisOuterRadius:s}=this,[n,a]=this.normalizeRadii(this.innerRadius,this.outerRadius),r=-i/2,o=i/2,h=-a,c=-n,l=this.getRotation(),u=(0,import_ag_charts_core39.isNumberEqual)(n,e),d=(0,import_ag_charts_core39.isNumberEqual)(a,s),f=Math.hypot(r,h)>s||Math.hypot(o,h)>s;if(!u&&!d&&!f){this.updateRectangularPath();return}const g=u?this.calculateBothIntersections(r,o,n):null,p=d?this.calculateBothIntersections(r,o,a):null,y=f?this.calculateAxisOuterIntersections(r,o,s):null;if(u&&!g||d&&!p||f&&!y){this.updateRectangularPath();return}t.clear(!0);const m={left:r,right:o,top:h,bottom:c,rotation:l};g?this.moveToRotated(r,g.left.y,l):this.moveToRotated(r,c,l),g?t.arc(0,0,n,l+g.left.angle,l+g.right.angle,!1):this.lineToRotated(o,c,l),p?(this.lineToRotated(o,p.right.y,l),t.arc(0,0,a,l+p.right.angle,l+p.left.angle,!0)):y?this.renderTopWithCornerClipping(s,y,m):(this.lineToRotated(o,h,l),this.lineToRotated(r,h,l)),t.closePath()}};RadialColumnShape.className="RadialColumnShape",__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"isBeveled",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"columnWidth",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"startAngle",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"endAngle",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"outerRadius",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"innerRadius",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"axisInnerRadius",2),__decorateClass([(0,import_ag_charts_core39.SceneChangeDetection)()],RadialColumnShape.prototype,"axisOuterRadius",2);function getRadialColumnWidth(i,t,e,s,n){const a=(0,import_ag_charts_core39.angleBetween)(i,t),r=a*(1-s)/2;if(i+=r,t-=r,a<.001)return 2*e*n;if(a>=2*Math.PI){const f=i+a/2;i=f-Math.PI,t=f+Math.PI}const o=e*Math.cos(i),h=e*Math.sin(i),c=e*Math.cos(t),l=e*Math.sin(t),u=Math.floor(Math.hypot(o-c,h-l)),d=2*e*n;return Math.max(1,Math.min(d,u))}var import_ag_charts_core41=require("ag-charts-core"),SectorBox=class K{constructor(t,e,s,n){this.startAngle=t,this.endAngle=e,this.innerRadius=s,this.outerRadius=n}clone(){const{startAngle:t,endAngle:e,innerRadius:s,outerRadius:n}=this;return new K(t,e,s,n)}equals(t){return this.startAngle===t.startAngle&&this.endAngle===t.endAngle&&this.innerRadius===t.innerRadius&&this.outerRadius===t.outerRadius}[interpolate](t,e){return new K(this.startAngle*(1-e)+t.startAngle*e,this.endAngle*(1-e)+t.endAngle*e,this.innerRadius*(1-e)+t.innerRadius*e,this.outerRadius*(1-e)+t.outerRadius*e)}},import_ag_charts_core40=require("ag-charts-core");function sectorBox({startAngle:i,endAngle:t,innerRadius:e,outerRadius:s}){let n=1/0,a=1/0,r=-1/0,o=-1/0;const h=(c,l)=>{n=Math.min(c,n),a=Math.min(l,a),r=Math.max(c,r),o=Math.max(l,o)};return h(e*Math.cos(i),e*Math.sin(i)),h(e*Math.cos(t),e*Math.sin(t)),h(s*Math.cos(i),s*Math.sin(i)),h(s*Math.cos(t),s*Math.sin(t)),(0,import_ag_charts_core40.isBetweenAngles)(0,i,t)&&h(s,0),(0,import_ag_charts_core40.isBetweenAngles)(Math.PI*.5,i,t)&&h(0,s),(0,import_ag_charts_core40.isBetweenAngles)(Math.PI,i,t)&&h(-s,0),(0,import_ag_charts_core40.isBetweenAngles)(Math.PI*1.5,i,t)&&h(0,-s),new BBox(n,a,r-n,o-a)}function isPointInSector(i,t,e){const s=Math.sqrt(Math.pow(i,2)+Math.pow(t,2)),{innerRadius:n,outerRadius:a}=e;if(e.startAngle===e.endAngle||s<Math.min(n,a)||s>Math.max(n,a))return!1;const r=(0,import_ag_charts_core40.normalizeAngle180)(e.startAngle),o=(0,import_ag_charts_core40.normalizeAngle180)(e.endAngle),h=Math.atan2(t,i);return r<o?h<=o&&h>=r:h<=o&&h>=-Math.PI||h>=r&&h<=Math.PI}function radiiScalingFactor(i,t,e,s){if(e===0&&s===0)return 0;if(Math.asin(Math.abs(1*e)/(i+1*e))+Math.asin(Math.abs(1*s)/(i+1*s))-t<0)return 1;let a=0,r=1;for(let o=0;o<8;o+=1){const h=(a+r)/2;Math.asin(Math.abs(h*e)/(i+h*e))+Math.asin(Math.abs(h*s)/(i+h*s))-t<0?a=h:r=h}return a}var delta2=1e-6;function clockwiseAngle(i,t){return(0,import_ag_charts_core40.angleBetween)(i,t)<delta2?t:(0,import_ag_charts_core40.normalizeAngle360)(i-t)+t}function clockwiseAngles(i,t,e=0){const n=Math.abs(t-i)>=2*Math.PI-delta2?2*Math.PI:(0,import_ag_charts_core40.normalizeAngle360)(t-i);return i=clockwiseAngle(i,e),t=i+n,{startAngle:i,endAngle:t}}function arcRadialLineIntersectionAngle(i,t,e,s,n,a){const r=Math.sin(a),o=Math.cos(a),h=i**2+t**2-e**2;let c,l,u,d;if(o>.5){const v=r/o,S=1+v**2,M=-2*(i+t*v),C=M**2-4*S*h;if(C<0)return;const x=(-M+Math.sqrt(C))/(2*S),_=(-M-Math.sqrt(C))/(2*S);c=x,l=x*v,u=_,d=_*v}else{const v=o/r,S=1+v**2,M=-2*(t+i*v),C=M**2-4*S*h;if(C<0)return;const x=(-M+Math.sqrt(C))/(2*S),_=(-M-Math.sqrt(C))/(2*S);c=x*v,l=x,u=_*v,d=_}const f=o,g=r,p=c*f+l*g,y=u*f+d*g,m=p>0?clockwiseAngle(Math.atan2(l-t,c-i),s):Number.NaN,b=y>0?clockwiseAngle(Math.atan2(d-t,u-i),s):Number.NaN;if(m>=s&&m<=n)return m;if(b>=s&&b<=n)return b}function arcCircleIntersectionAngle(i,t,e,s,n,a){const r=Math.hypot(i,t),o=(r**2-e**2+a**2)/(2*r),h=r-o,c=Math.atan2(t,i),l=Math.acos(-h/e),u=clockwiseAngle(c+l,s),d=clockwiseAngle(c-l,s);if(u>=s&&u<=n)return u;if(d>=s&&d<=n)return d}var Arc2=class{constructor(i,t,e,s,n){this.cx=i,this.cy=t,this.r=e,this.a0=s,this.a1=n,this.a0>=this.a1&&(this.a0=Number.NaN,this.a1=Number.NaN)}isValid(){return Number.isFinite(this.a0)&&Number.isFinite(this.a1)}pointAt(i){return{x:this.cx+this.r*Math.cos(i),y:this.cy+this.r*Math.sin(i)}}clipStart(i){i==null||!this.isValid()||i<this.a0||(this.a0=i,(Number.isNaN(i)||this.a0>=this.a1)&&(this.a0=Number.NaN,this.a1=Number.NaN))}clipEnd(i){i==null||!this.isValid()||i>this.a1||(this.a1=i,(Number.isNaN(i)||this.a0>=this.a1)&&(this.a0=Number.NaN,this.a1=Number.NaN))}},Sector=class extends Path{constructor(){super(...arguments),this.centerX=0,this.centerY=0,this.innerRadius=10,this.outerRadius=20,this.startAngle=0,this.endAngle=Math.PI*2,this.clipSector=void 0,this.concentricEdgeInset=0,this.radialEdgeInset=0,this.startOuterCornerRadius=0,this.endOuterCornerRadius=0,this.startInnerCornerRadius=0,this.endInnerCornerRadius=0}set inset(i){this.concentricEdgeInset=i,this.radialEdgeInset=i}set cornerRadius(i){this.startOuterCornerRadius=i,this.endOuterCornerRadius=i,this.startInnerCornerRadius=i,this.endInnerCornerRadius=i}computeBBox(){return sectorBox(this).translate(this.centerX,this.centerY)}normalizedRadii(){const{concentricEdgeInset:i}=this;let{innerRadius:t,outerRadius:e}=this;return t=t>0?t+i:0,e=Math.max(e-i,0),{innerRadius:t,outerRadius:e}}normalizedClipSector(){const{clipSector:i}=this;if(i==null)return;const{startAngle:t,endAngle:e}=clockwiseAngles(this.startAngle,this.endAngle),{innerRadius:s,outerRadius:n}=this.normalizedRadii(),a=clockwiseAngles(i.startAngle,i.endAngle,t);return new SectorBox(Math.max(t,a.startAngle),Math.min(e,a.endAngle),Math.max(s,i.innerRadius),Math.min(n,i.outerRadius))}getAngleOffset(i){return i>0?this.radialEdgeInset/i:0}arc(i,t,e,s,n,a,r,o){if(i<=0)return;const{startAngle:h,endAngle:c}=clockwiseAngles(this.startAngle,this.endAngle),{innerRadius:l,outerRadius:u}=this.normalizedRadii(),d=this.normalizedClipSector();if(o&&l<=0)return;const f=o?this.getAngleOffset(l+i):this.getAngleOffset(u-i),g=r?h+f+t:c-f-t,p=o?l+i:u-i,y=p*Math.cos(g),m=p*Math.sin(g);if(d!=null&&(!r&&!(g>=h-1e-6&&g<=d.endAngle-1e-6)||r&&!(g>=d.startAngle+1e-6&&g<=c-1e-6)||o&&p<d.innerRadius-1e-6||!o&&p>d.outerRadius+1e-6))return;const b=new Arc2(y,m,i,e,s);if(d!=null){o?(b.clipStart(arcRadialLineIntersectionAngle(y,m,i,e,s,d.endAngle)),b.clipEnd(arcRadialLineIntersectionAngle(y,m,i,e,s,d.startAngle))):(b.clipStart(arcRadialLineIntersectionAngle(y,m,i,e,s,d.startAngle)),b.clipEnd(arcRadialLineIntersectionAngle(y,m,i,e,s,d.endAngle)));let x,_;if(r?(x=arcCircleIntersectionAngle(y,m,i,e,s,d.innerRadius),_=arcCircleIntersectionAngle(y,m,i,e,s,d.outerRadius)):(x=arcCircleIntersectionAngle(y,m,i,e,s,d.outerRadius),_=arcCircleIntersectionAngle(y,m,i,e,s,d.innerRadius)),b.clipStart(x),b.clipEnd(_),x!=null){const{x:P,y:w}=b.pointAt(x),k=clockwiseAngle(Math.atan2(w,P),h);r?a?.clipStart(k):n.clipEnd(k)}if(_!=null){const{x:P,y:w}=b.pointAt(_),k=clockwiseAngle(Math.atan2(w,P),h);r?n.clipStart(k):a?.clipEnd(k)}}if(d!=null){const{x,y:_}=b.pointAt((b.a0+b.a1)/2);if(!isPointInSector(x,_,d))return}const{x:v,y:S}=b.pointAt(r===o?b.a0:b.a1),M=clockwiseAngle(Math.atan2(S,v),h),C=o?a:n;return r?C?.clipStart(M):C?.clipEnd(M),b}updatePath(){const{path:t,centerX:e,centerY:s,concentricEdgeInset:n,radialEdgeInset:a}=this;let{startOuterCornerRadius:r,endOuterCornerRadius:o,startInnerCornerRadius:h,endInnerCornerRadius:c}=this;const{startAngle:l,endAngle:u}=clockwiseAngles(this.startAngle,this.endAngle),{innerRadius:d,outerRadius:f}=this.normalizedRadii(),g=this.normalizedClipSector(),p=u-l,y=p>=2*Math.PI-1e-6;t.clear();const m=this.getAngleOffset(d),b=p-2*m,v=f-d,S=d>0&&b>0?2*d*Math.sin(b/2):0,M=f>0&&b>0?2*f*Math.sin(b/2):0;if(r=Math.floor(Math.max(0,Math.min(r,M/2,v/2))),o=Math.floor(Math.max(0,Math.min(o,M/2,v/2))),h=Math.floor(Math.max(0,Math.min(h,S/2,v/2))),c=Math.floor(Math.max(0,Math.min(c,S/2,v/2))),d===0&&f===0||d>f||S<0||M<=0)return;if((g?.startAngle??l)===(g?.endAngle??u))return;if(y&&this.clipSector==null&&r===0&&o===0&&h===0&&c===0){t.moveTo(e+f*Math.cos(l),s+f*Math.sin(l)),t.arc(e,s,f,l,u),d>n&&(t.moveTo(e+d*Math.cos(u),s+d*Math.sin(u)),t.arc(e,s,d,u,l,!0)),t.closePath();return}else if(this.clipSector==null&&Math.abs(d-f)<1e-6){t.arc(e,s,f,l,u,!1),t.arc(e,s,f,u,l,!0),t.closePath();return}const x=this.getAngleOffset(f);if(p<2*x)return;const P=(g?.innerRadius??d)>n,w=d<n||p<2*m,k=Math.max(r,h,o,c),N=k>0?Math.min(v/k,1):1;r*=N,o*=N,h*=N,c*=N;const L=radiiScalingFactor(f,p-2*x,-r,-o);if(r*=L,o*=L,!w&&P){const T=radiiScalingFactor(d,p-2*m,h,c);h*=T,c*=T}else h=0,c=0;const E=Math.max(r+h,o+c),z=E>0?Math.min(v/E,1):1;r*=z,o*=z,h*=z,c*=z;let B=0,F=0;const D=r/(f-r),I=o/(f-o);if(D>=0&&D<1-1e-6)B=Math.asin(D);else{B=p/2;const T=f/(1/Math.sin(B)+1);r=Math.min(T,r)}if(I>=0&&I<1-1e-6)F=Math.asin(I);else{F=p/2;const T=f/(1/Math.sin(F)+1);o=Math.min(T,o)}const j=Math.asin(h/(d+h)),Q=Math.asin(c/(d+c)),tt=g?.outerRadius??f,et=this.getAngleOffset(tt),W=new Arc2(0,0,tt,l+et,u-et),it=g?.innerRadius??d,st=this.getAngleOffset(it),q=P?new Arc2(0,0,it,l+st,u-st):void 0;g!=null&&(W.clipStart(g.startAngle),W.clipEnd(g.endAngle),q?.clipStart(g.startAngle),q?.clipEnd(g.endAngle));const nt=this.arc(r,B,l-Math.PI*.5,l+B,W,q,!0,!1),rt=this.arc(o,F,u-F,u+Math.PI*.5,W,q,!1,!1),at=this.arc(c,Q,u+Math.PI*.5,u+Math.PI-Q,W,q,!1,!0),V=this.arc(h,j,l+Math.PI+j,l+Math.PI*1.5,W,q,!0,!0);if(!(w&&P)){if(w){const T=p<Math.PI*.5?a*(1+Math.cos(p))/Math.sin(p):Number.NaN;let A;T>0&&T<f?A=Math.max(Math.hypot(a,T),d):A=a,A=Math.max(A,d);const O=l+p*.5;t.moveTo(e+A*Math.cos(O),s+A*Math.sin(O))}else if(!(V?.isValid()===!0||q?.isValid()===!0)){const T=l+p/2,A=d*Math.cos(T),O=d*Math.sin(T);t.moveTo(e+A,s+O)}}if(nt?.isValid()===!0){const{cx:T,cy:A,r:O,a0:G,a1:$}=nt;t.arc(e+T,s+A,O,G,$)}if(W.isValid()){const{r:T,a0:A,a1:O}=W;t.arc(e,s,T,A,O)}if(rt?.isValid()===!0){const{cx:T,cy:A,r:O,a0:G,a1:$}=rt;t.arc(e+T,s+A,O,G,$)}if(!w){if(at?.isValid()===!0){const{cx:T,cy:A,r:O,a0:G,a1:$}=at;t.arc(e+T,s+A,O,G,$)}if(q?.isValid()===!0){const{r:T,a0:A,a1:O}=q;t.arc(e,s,T,O,A,!0)}if(V?.isValid()===!0){const{cx:T,cy:A,r:O,a0:G,a1:$}=V;t.arc(e+T,s+A,O,G,$)}}t.closePath()}isPointInPath(i,t){const{startAngle:e,endAngle:s,innerRadius:n,outerRadius:a}=this.clipSector??this;return isPointInSector(i-this.centerX,t-this.centerY,{startAngle:e,endAngle:s,innerRadius:Math.min(n,a),outerRadius:Math.max(n,a)})}};Sector.className="Sector",__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"centerX",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"centerY",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"innerRadius",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"outerRadius",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"startAngle",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"endAngle",2),__decorateClass([(0,import_ag_charts_core41.SceneObjectChangeDetection)({equals:(i,t)=>i.equals(t)})],Sector.prototype,"clipSector",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"concentricEdgeInset",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"radialEdgeInset",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"startOuterCornerRadius",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"endOuterCornerRadius",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"startInnerCornerRadius",2),__decorateClass([(0,import_ag_charts_core41.SceneChangeDetection)()],Sector.prototype,"endInnerCornerRadius",2);var import_ag_charts_core42=require("ag-charts-core");