/*! For license information please see 6121.f7286809e53e1c6d655a.chunk.js.LICENSE.txt */ !function(){try{var t="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},e=(new Error).stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="44385583-8059-4723-827a-84811c072356",t._sentryDebugIdIdentifier="sentry-dbid-44385583-8059-4723-827a-84811c072356")}catch(t){}}();var _global="undefined"!==typeof window?window:"undefined"!==typeof global?global:"undefined"!==typeof self?self:{};_global.SENTRY_RELEASE={id:"30b1ba65cc8722be7e184f4a401fb43e6b21634d"},(self.webpackChunkcloud_frontend=self.webpackChunkcloud_frontend||[]).push([[6121],{51891:(t,e,o)=>{o.d(e,{A:()=>Jt});var n=o(66118),r=o(12020);const i={modes:{point:(t,e)=>a(t,e,{intersect:!0}),nearest:(t,e,o)=>function(t,e,o){let n=Number.POSITIVE_INFINITY;return a(t,e,o).reduce(((t,i)=>{const s=i.getCenterPoint(),a=function(t,e,o){if("x"===o)return{x:t.x,y:e.y};if("y"===o)return{x:e.x,y:t.y};return e}(e,s,o.axis),d=(0,r.aE)(e,a);return dt._index-e._index)).slice(0,1)}(t,e,o),x:(t,e,o)=>a(t,e,{intersect:o.intersect,axis:"x"}),y:(t,e,o)=>a(t,e,{intersect:o.intersect,axis:"y"})}};function s(t,e,o){return(i.modes[o.mode]||i.modes.nearest)(t,e,o)}function a(t,e,o){return t.visibleElements.filter((t=>o.intersect?t.inRange(e.x,e.y):function(t,e,o){return"x"!==o&&"y"!==o?t.inRange(e.x,e.y,"x",!0)||t.inRange(e.x,e.y,"y",!0):t.inRange(e.x,e.y,o,!0)}(t,e,o.axis)))}const d=(t,e)=>e>t||t.length>e.length&&t.slice(0,e.length)===e,l=.001,c=(t,e,o)=>Math.min(o,Math.max(e,t));function h(t,e,o){for(const n of Object.keys(t))t[n]=c(t[n],e,o);return t}function u(t,{x:e,y:o,x2:n,y2:r},i,s){const a=s/2,d=t.x>=e-a-l&&t.x<=n+a+l,c=t.y>=o-a-l&&t.y<=r+a+l;return"x"===i?d:("y"===i||d)&&c}function f(t,e){const{centerX:o,centerY:n}=t.getProps(["centerX","centerY"],e);return{x:o,y:n}}const x=t=>"string"===typeof t&&t.endsWith("%"),y=t=>parseFloat(t)/100,p=t=>c(y(t),0,1);function b(t,e){return"start"===e?0:"end"===e?t:x(e)?p(e)*t:t/2}function g(t,e,o=!0){return"number"===typeof e?e:x(e)?(o?p(e):y(e))*t:t}function m(t,e="center"){return(0,r.i)(t)?{x:(0,r.v)(t.x,e),y:(0,r.v)(t.y,e)}:{x:t=(0,r.v)(t,e),y:t}}function v(t){return t&&((0,r.h)(t.xValue)||(0,r.h)(t.yValue))}function w(t,e,o,n=!1){const i=o.init;if(i)return!0===i?S(e,n):function(t,e,o){if(!0===o)return S(t,e);if((0,r.i)(o))return o}(e,n,(0,r.Q)(i,[{chart:t,properties:e,options:o}]))}function M(t,e,o){let n=!1;return e.forEach((e=>{(0,r.a7)(t[e])?(n=!0,o[e]=t[e]):(0,r.h)(o[e])&&delete o[e]})),n}function S({centerX:t,centerY:e},o){return o?{centerX:t,centerY:e,radius:0,width:0,height:0}:{x:t,y:e,x2:t,y2:e,width:0,height:0}}const k=new Map,C=t=>t.reduce((function(t,e){return t+=e.string}),"");function P(t){if(t&&"object"===typeof t){const e=t.toString();return"[object HTMLImageElement]"===e||"[object HTMLCanvasElement]"===e}}function D(t,{x:e,y:o},n){n&&(t.translate(e,o),t.rotate((0,r.t)(n)),t.translate(-e,-o))}function j(t,e){if(e&&e.borderWidth)return t.lineCap=e.borderCapStyle,t.setLineDash(e.borderDash),t.lineDashOffset=e.borderDashOffset,t.lineJoin=e.borderJoinStyle,t.lineWidth=e.borderWidth,t.strokeStyle=e.borderColor,!0}function T(t,e){t.shadowColor=e.backgroundShadowColor,t.shadowBlur=e.shadowBlur,t.shadowOffsetX=e.shadowOffsetX,t.shadowOffsetY=e.shadowOffsetY}function O(t,e){const o=e.content;if(P(o))return{width:g(o.width,e.width),height:g(o.height,e.height)};const n=e.font,i=(0,r.b)(n)?n.map((t=>(0,r.a0)(t))):[(0,r.a0)(n)],s=e.textStrokeWidth,a=(0,r.b)(o)?o:[o],d=a.join()+C(i)+s+(t._measureText?"-spriting":"");return k.has(d)||k.set(d,function(t,e,o,n){t.save();const r=e.length;let i=0,s=n;for(let a=0;a(0,r.a0)(t))):[(0,r.a0)(s)],d=o.color,l=(0,r.b)(d)?d:[d],h=function(t,e){const{x:o,width:n}=t,r=e.textAlign;return"center"===r?o+n/2:"end"===r||"right"===r?o+n:o}(e,o),u=e.y+o.textStrokeWidth/2;t.save(),t.textBaseline="middle",t.textAlign=o.textAlign,function(t,e){if(e.textStrokeWidth>0)return t.lineJoin="round",t.miterLimit=2,t.lineWidth=e.textStrokeWidth,t.strokeStyle=e.textStrokeColor,!0}(t,o)&&function(t,{x:e,y:o},n,r){t.beginPath();let i=0;n.forEach((function(n,s){const a=r[Math.min(s,r.length-1)],d=a.lineHeight;t.font=a.string,t.strokeText(n,e,o+d/2+i),i+=d})),t.stroke()}(t,{x:h,y:u},i,a),function(t,{x:e,y:o},n,{fonts:r,colors:i}){let s=0;n.forEach((function(n,a){const d=i[Math.min(a,i.length-1)],l=r[Math.min(a,r.length-1)],c=l.lineHeight;t.beginPath(),t.font=l.string,t.fillStyle=d,t.fillText(n,e,o+c/2+s),s+=c,t.fill()}))}(t,{x:h,y:u},i,{fonts:a,colors:l}),t.restore()}function I(t,e,o,n){const{radius:i,options:s}=e,a=s.pointStyle,d=s.rotation;let l=(d||0)*r.b3;if(P(a))return t.save(),t.translate(o,n),t.rotate(l),t.drawImage(a,-a.width/2,-a.height/2,a.width,a.height),void t.restore();(t=>isNaN(t)||t<=0)(i)||function(t,{x:e,y:o,radius:n,rotation:i,style:s,rad:a}){let d,l,c,h;switch(t.beginPath(),s){default:t.arc(e,o,n,0,r.T),t.closePath();break;case"triangle":t.moveTo(e+Math.sin(a)*n,o-Math.cos(a)*n),a+=r.b5,t.lineTo(e+Math.sin(a)*n,o-Math.cos(a)*n),a+=r.b5,t.lineTo(e+Math.sin(a)*n,o-Math.cos(a)*n),t.closePath();break;case"rectRounded":h=.516*n,c=n-h,d=Math.cos(a+r.b4)*c,l=Math.sin(a+r.b4)*c,t.arc(e-d,o-l,h,a-r.P,a-r.H),t.arc(e+l,o-d,h,a-r.H,a),t.arc(e+d,o+l,h,a,a+r.H),t.arc(e-l,o+d,h,a+r.H,a+r.P),t.closePath();break;case"rect":if(!i){c=Math.SQRT1_2*n,t.rect(e-c,o-c,2*c,2*c);break}a+=r.b4;case"rectRot":d=Math.cos(a)*n,l=Math.sin(a)*n,t.moveTo(e-d,o-l),t.lineTo(e+l,o-d),t.lineTo(e+d,o+l),t.lineTo(e-l,o+d),t.closePath();break;case"crossRot":a+=r.b4;case"cross":d=Math.cos(a)*n,l=Math.sin(a)*n,t.moveTo(e-d,o-l),t.lineTo(e+d,o+l),t.moveTo(e+l,o-d),t.lineTo(e-l,o+d);break;case"star":d=Math.cos(a)*n,l=Math.sin(a)*n,t.moveTo(e-d,o-l),t.lineTo(e+d,o+l),t.moveTo(e+l,o-d),t.lineTo(e-l,o+d),a+=r.b4,d=Math.cos(a)*n,l=Math.sin(a)*n,t.moveTo(e-d,o-l),t.lineTo(e+d,o+l),t.moveTo(e+l,o-d),t.lineTo(e-l,o+d);break;case"line":d=Math.cos(a)*n,l=Math.sin(a)*n,t.moveTo(e-d,o-l),t.lineTo(e+d,o+l);break;case"dash":t.moveTo(e,o),t.lineTo(e+Math.cos(a)*n,o+Math.sin(a)*n)}t.fill()}(t,{x:o,y:n,radius:i,rotation:d,style:a,rad:l})}const X={xScaleID:{min:"xMin",max:"xMax",start:"left",end:"right",startProp:"x",endProp:"x2"},yScaleID:{min:"yMin",max:"yMax",start:"bottom",end:"top",startProp:"y",endProp:"y2"}};function E(t,e,o){return e="number"===typeof e?e:t.parse(e),(0,r.g)(e)?t.getPixelForValue(e):o}function W(t,e,o){const n=e[o];if(n||"scaleID"===o)return n;const r=o.charAt(0),i=Object.values(t).filter((t=>t.axis&&t.axis===r));return i.length?i[0].id:r}function R(t,e){if(t){const o=t.options.reverse;return{start:E(t,e.min,o?e.end:e.start),end:E(t,e.max,o?e.start:e.end)}}}function _(t,e){const{chartArea:o,scales:n}=t,r=n[W(n,e,"xScaleID")],i=n[W(n,e,"yScaleID")];let s=o.width/2,a=o.height/2;return r&&(s=E(r,e.xValue,r.left+r.width/2)),i&&(a=E(i,e.yValue,i.top+i.height/2)),{x:s,y:a}}function z(t,e){const o=t.scales,n=o[W(o,e,"xScaleID")],r=o[W(o,e,"yScaleID")];if(!n&&!r)return{};let{left:i,right:s}=n||t.chartArea,{top:a,bottom:d}=r||t.chartArea;const l=$(n,{min:e.xMin,max:e.xMax,start:i,end:s});i=l.start,s=l.end;const c=$(r,{min:e.yMin,max:e.yMax,start:d,end:a});return a=c.start,d=c.end,{x:i,y:a,x2:s,y2:d,width:s-i,height:d-a,centerX:i+(s-i)/2,centerY:a+(d-a)/2}}function H(t,e){if(!v(e)){const o=z(t,e);let n=e.radius;n&&!isNaN(n)||(n=Math.min(o.width,o.height)/2,e.radius=n);const r=2*n,i=o.centerX+e.xAdjust,s=o.centerY+e.yAdjust;return{x:i-n,y:s-n,x2:i+n,y2:s+n,centerX:i,centerY:s,width:r,height:r,radius:n}}return function(t,e){const o=_(t,e),n=2*e.radius;return{x:o.x-e.radius+e.xAdjust,y:o.y-e.radius+e.yAdjust,x2:o.x+e.radius+e.xAdjust,y2:o.y+e.radius+e.yAdjust,centerX:o.x+e.xAdjust,centerY:o.y+e.yAdjust,radius:e.radius,width:n,height:n}}(t,e)}function N(t,e){const{scales:o,chartArea:n}=t,r=o[e.scaleID],i={x:n.left,y:n.top,x2:n.right,y2:n.bottom};return r?function(t,e,o){const n=E(t,o.value,NaN),r=E(t,o.endValue,n);t.isHorizontal()?(e.x=n,e.x2=r):(e.y=n,e.y2=r)}(r,i,e):function(t,e,o){for(const n of Object.keys(X)){const r=t[W(t,o,n)];if(r){const{min:t,max:i,start:s,end:a,startProp:d,endProp:l}=X[n],c=R(r,{min:o[t],max:o[i],start:r[s],end:r[a]});e[d]=c.start,e[l]=c.end}}}(o,i,e),i}function V(t,e,o){const n=z(t,e);return n.initProperties=w(t,n,e,o),n.elements=[{type:"label",optionScope:"label",properties:L(t,n,e),initProperties:n.initProperties}],n}function $(t,e){const o=R(t,e)||e;return{start:Math.min(o.start,o.end),end:Math.max(o.start,o.end)}}function B(t,e){const{start:o,end:n,borderWidth:r}=t,{position:i,padding:{start:s,end:a},adjust:d}=e;return o+r/2+d+b(n-r-o-s-a-e.size,i)}function L(t,e,o){const n=o.label;n.backgroundColor="transparent",n.callout.display=!1;const i=m(n.position),s=(0,r.E)(n.padding),a=O(t.ctx,n),d=function({properties:t,options:e},o,n,r){const{x:i,x2:s,width:a}=t;return B({start:i,end:s,size:a,borderWidth:e.borderWidth},{position:n.x,padding:{start:r.left,end:r.right},adjust:e.label.xAdjust,size:o.width})}({properties:e,options:o},a,i,s),l=function({properties:t,options:e},o,n,r){const{y:i,y2:s,height:a}=t;return B({start:i,end:s,size:a,borderWidth:e.borderWidth},{position:n.y,padding:{start:r.top,end:r.bottom},adjust:e.label.yAdjust,size:o.height})}({properties:e,options:o},a,i,s),c=a.width+s.width,h=a.height+s.height;return{x:d,y:l,x2:d+c,y2:l+h,width:c,height:h,centerX:d+c/2,centerY:l+h/2,rotation:n.rotation}}function J(t,e,o){const n=Math.cos(o),r=Math.sin(o),i=e.x,s=e.y;return{x:i+n*(t.x-i)-r*(t.y-s),y:s+r*(t.x-i)+n*(t.y-s)}}const F=["enter","leave"],Q=F.concat("click");function U(t,e,o){if(t.listened)switch(e.type){case"mousemove":case"mouseout":return function(t,e,o){if(!t.moveListened)return;let n;n="mousemove"===e.type?s(t,e,o.interaction):[];const r=t.hovered;t.hovered=n;const i={state:t,event:e};let a=q(i,"leave",r,n);return q(i,"enter",n,r)||a}(t,e,o);case"click":return function(t,e,o){const n=t.listeners,r=s(t,e,o.interaction);let i;for(const s of r)i=G(s.options.click||n.click,s,e)||i;return i}(t,e,o)}}function q({state:t,event:e},o,n,r){let i;for(const s of n)r.indexOf(s)<0&&(i=G(s.options[o]||t.listeners[o],s,e)||i);return i}function G(t,e,o){return!0===(0,r.Q)(t,[e.$context,o])}const K=["afterDraw","beforeDraw"];function Z(t,e,o){if(t.hooked){const n=e.options[o]||t.hooks[o];return(0,r.Q)(n,[e.$context])}}function tt(t,e,o){const n=function(t,e,o){const n=e.axis,i=e.id,s=n+"ScaleID",a={min:(0,r.v)(e.min,Number.NEGATIVE_INFINITY),max:(0,r.v)(e.max,Number.POSITIVE_INFINITY)};for(const r of o)r.scaleID===i?rt(r,e,["value","endValue"],a):W(t,r,s)===i&&rt(r,e,[n+"Min",n+"Max",n+"Value"],a);return a}(t.scales,e,o);let i=et(e,n,"min","suggestedMin");i=et(e,n,"max","suggestedMax")||i,i&&(0,r.a7)(e.handleTickRangeOptions)&&e.handleTickRangeOptions()}function et(t,e,o,n){if((0,r.g)(e[o])&&!function(t,e,o){return(0,r.h)(t[e])||(0,r.h)(t[o])}(t.options,o,n)){const n=t[o]!==e[o];return t[o]=e[o],n}}function ot(t,e){for(const o of["scaleID","xScaleID","yScaleID"]){const n=W(e,t,o);n&&!e[n]&&nt(t,o)&&console.warn(`No scale found with id '${n}' for annotation '${t.id}'`)}}function nt(t,e){if("scaleID"===e)return!0;const o=e.charAt(0);for(const n of["Min","Max","Value"])if((0,r.h)(t[o+n]))return!0;return!1}function rt(t,e,o,n){for(const i of o){const o=t[i];if((0,r.h)(o)){const t=e.parse(o);n.min=Math.min(n.min,t),n.max=Math.max(n.max,t)}}}class it extends n.Hg{inRange(t,e,o,n){const{x:i,y:s}=J({x:t,y:e},this.getCenterPoint(n),(0,r.t)(-this.options.rotation));return u({x:i,y:s},this.getProps(["x","y","x2","y2"],n),o,this.options.borderWidth)}getCenterPoint(t){return f(this,t)}draw(t){t.save(),D(t,this.getCenterPoint(),this.options.rotation),A(t,this,this.options),t.restore()}get label(){return this.elements&&this.elements[0]}resolveElementProperties(t,e){return V(t,e)}}it.id="boxAnnotation",it.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,label:{backgroundColor:"transparent",borderWidth:0,callout:{display:!1},color:"black",content:null,display:!1,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:void 0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0},it.defaultRoutes={borderColor:"color",backgroundColor:"color"},it.descriptors={label:{_fallback:!0}};const st=["left","bottom","top","right"];class at extends n.Hg{inRange(t,e,o,n){const{x:i,y:s}=J({x:t,y:e},this.getCenterPoint(n),(0,r.t)(-this.rotation));return u({x:i,y:s},this.getProps(["x","y","x2","y2"],n),o,this.options.borderWidth)}getCenterPoint(t){return f(this,t)}draw(t){const e=this.options,o=!(0,r.h)(this._visible)||this._visible;e.display&&e.content&&o&&(t.save(),D(t,this.getCenterPoint(),this.rotation),function(t,e){const{pointX:o,pointY:n,options:i}=e,s=i.callout,a=s&&s.display&&function(t,e){const o=e.position;if(st.includes(o))return o;return function(t,e){const{x:o,y:n,x2:i,y2:s,width:a,height:d,pointX:l,pointY:c,centerX:h,centerY:u,rotation:f}=t,x={x:h,y:u},y=e.start,p=g(a,y),b=g(d,y),m=[o,o+p,o+p,i],v=[n+b,s,n,s],w=[];for(let g=0;g<4;g++){const t=J({x:m[g],y:v[g]},x,(0,r.t)(f));w.push({position:st[g],distance:(0,r.aE)(t,{x:l,y:c})})}return w.sort(((t,e)=>t.distance-e.distance))[0].position}(t,e)}(e,s);if(!a||function(t,e,o){const{pointX:n,pointY:r}=t,i=e.margin;let s=n,a=r;"left"===o?s+=i:"right"===o?s-=i:"top"===o?a+=i:"bottom"===o&&(a-=i);return t.inRange(s,a)}(e,s,a))return;t.save(),t.beginPath();const d=j(t,s);if(!d)return t.restore();const{separatorStart:l,separatorEnd:c}=function(t,e){const{x:o,y:n,x2:r,y2:i}=t,s=function(t,e){const{width:o,height:n,options:r}=t,i=r.callout.margin+r.borderWidth/2;if("right"===e)return o+i;if("bottom"===e)return n+i;return-i}(t,e);let a,d;"left"===e||"right"===e?(a={x:o+s,y:n},d={x:a.x,y:i}):(a={x:o,y:n+s},d={x:r,y:a.y});return{separatorStart:a,separatorEnd:d}}(e,a),{sideStart:h,sideEnd:u}=function(t,e,o){const{y:n,width:r,height:i,options:s}=t,a=s.callout.start,d=function(t,e){const o=e.side;if("left"===t||"top"===t)return-o;return o}(e,s.callout);let l,c;"left"===e||"right"===e?(l={x:o.x,y:n+g(i,a)},c={x:l.x+d,y:l.y}):(l={x:o.x+g(r,a),y:o.y},c={x:l.x,y:l.y+d});return{sideStart:l,sideEnd:c}}(e,a,l);(s.margin>0||0===i.borderWidth)&&(t.moveTo(l.x,l.y),t.lineTo(c.x,c.y));t.moveTo(h.x,h.y),t.lineTo(u.x,u.y);const f=J({x:o,y:n},e.getCenterPoint(),(0,r.t)(-e.rotation));t.lineTo(f.x,f.y),t.stroke(),t.restore()}(t,this),A(t,this,e),Y(t,function({x:t,y:e,width:o,height:n,options:i}){const s=i.borderWidth/2,a=(0,r.E)(i.padding);return{x:t+a.left+s,y:e+a.top+s,width:o-a.left-a.right-i.borderWidth,height:n-a.top-a.bottom-i.borderWidth}}(this),e),t.restore())}resolveElementProperties(t,e){let o;if(v(e))o=_(t,e);else{const{centerX:n,centerY:r}=z(t,e);o={x:n,y:r}}const n=(0,r.E)(e.padding),i=function(t,e,o,n){const r=e.width+n.width+o.borderWidth,i=e.height+n.height+o.borderWidth,s=m(o.position,"center"),a=dt(t.x,r,o.xAdjust,s.x),d=dt(t.y,i,o.yAdjust,s.y);return{x:a,y:d,x2:a+r,y2:d+i,width:r,height:i,centerX:a+r/2,centerY:d+i/2}}(o,O(t.ctx,e),e,n);return{initProperties:w(t,i,e),pointX:o.x,pointY:o.y,...i,rotation:e.rotation}}}function dt(t,e,o=0,n){return t-b(e,n)+o}at.id="labelAnnotation",at.defaults={adjustScaleRange:!0,backgroundColor:"transparent",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:0,borderShadowColor:"transparent",borderWidth:0,callout:{borderCapStyle:"butt",borderColor:void 0,borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:1,display:!1,margin:5,position:"auto",side:5,start:"50%"},color:"black",content:null,display:!0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:void 0},height:void 0,init:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0},at.defaultRoutes={borderColor:"color"};const lt=(t,e,o)=>({x:t.x+o*(e.x-t.x),y:t.y+o*(e.y-t.y)}),ct=(t,e,o)=>lt(e,o,Math.abs((t-e.y)/(o.y-e.y))).x,ht=(t,e,o)=>lt(e,o,Math.abs((t-e.x)/(o.x-e.x))).y,ut=t=>t*t,ft=(t,e,o,n)=>(1-n)*(1-n)*t+2*(1-n)*n*e+n*n*o,xt=(t,e,o,n)=>({x:ft(t.x,e.x,o.x,n),y:ft(t.y,e.y,o.y,n)}),yt=(t,e,o,n)=>2*(1-n)*(e-t)+2*n*(o-e),pt=(t,e,o,n)=>-Math.atan2(yt(t.x,e.x,o.x,n),yt(t.y,e.y,o.y,n))+.5*r.P;class bt extends n.Hg{inRange(t,e,o,n){const r=this.options.borderWidth/2;if("x"!==o&&"y"!==o){const o={mouseX:t,mouseY:e},{path:i,ctx:s}=this;if(i){j(s,this.options);const{chart:r}=this.$context,a=t*r.currentDevicePixelRatio,d=e*r.currentDevicePixelRatio,l=s.isPointInStroke(i,a,d)||vt(this,o,n);return s.restore(),l}return function(t,{mouseX:e,mouseY:o},n=.001,r){const{x:i,y:s,x2:a,y2:d}=t.getProps(["x","y","x2","y2"],r),l=a-i,c=d-s,h=ut(l)+ut(c),u=0===h?-1:((e-i)*l+(o-s)*c)/h;let f,x;u<0?(f=i,x=s):u>1?(f=a,x=d):(f=i+u*l,x=s+u*c);return ut(e-f)+ut(o-x)<=n}(this,o,ut(r),n)||vt(this,o,n)}return function(t,{mouseX:e,mouseY:o},n,{hBorderWidth:r,useFinalPosition:i}){const s=((t,e,{x:o,y:n,x2:r,y2:i},s)=>"y"===s?{start:Math.min(n,i),end:Math.max(n,i),value:e}:{start:Math.min(o,r),end:Math.max(o,r),value:t})(e,o,t.getProps(["x","y","x2","y2"],i),n);return s.value>=s.start-r&&s.value<=s.end+r||vt(t,{mouseX:e,mouseY:o},i,n)}(this,{mouseX:t,mouseY:e},o,{hBorderWidth:r,useFinalPosition:n})}getCenterPoint(t){return f(this,t)}draw(t){const{x:e,y:o,x2:n,y2:i,cp:s,options:a}=this;if(t.save(),!j(t,a))return t.restore();T(t,a);const d=Math.sqrt(Math.pow(n-e,2)+Math.pow(i-o,2));if(a.curve&&s)return function(t,e,o,n){const{x:i,y:s,x2:a,y2:d,options:l}=e,{startOpts:c,endOpts:h,startAdjust:u,endAdjust:f}=St(e),x={x:i,y:s},y={x:a,y:d},p=pt(x,o,y,0),b=pt(x,o,y,1)-r.P,g=xt(x,o,y,u/n),m=xt(x,o,y,1-f/n),v=new Path2D;t.beginPath(),v.moveTo(g.x,g.y),v.quadraticCurveTo(o.x,o.y,m.x,m.y),t.shadowColor=l.borderShadowColor,t.stroke(v),e.path=v,e.ctx=t,Pt(t,g,{angle:p,adjust:u},c),Pt(t,m,{angle:b,adjust:f},h)}(t,this,s,d),t.restore();const{startOpts:l,endOpts:c,startAdjust:h,endAdjust:u}=St(this),f=Math.atan2(i-o,n-e);t.translate(e,o),t.rotate(f),t.beginPath(),t.moveTo(0+h,0),t.lineTo(d-u,0),t.shadowColor=a.borderShadowColor,t.stroke(),Ct(t,0,h,l),Ct(t,d,-u,c),t.restore()}get label(){return this.elements&&this.elements[0]}resolveElementProperties(t,e){const o=N(t,e),{x:n,y:i,x2:s,y2:a}=o,d=function({x:t,y:e,x2:o,y2:n},{top:r,right:i,bottom:s,left:a}){return!(ti&&o>i||es&&n>s)}(o,t.chartArea),l=d?function(t,e,o){const{x:n,y:r}=mt(t,e,o),{x:i,y:s}=mt(e,t,o);return{x:n,y:r,x2:i,y2:s,width:Math.abs(i-n),height:Math.abs(s-r)}}({x:n,y:i},{x:s,y:a},t.chartArea):{x:n,y:i,x2:s,y2:a,width:Math.abs(s-n),height:Math.abs(a-i)};if(l.centerX=(s+n)/2,l.centerY=(a+i)/2,l.initProperties=w(t,l,e),e.curve){const t={x:l.x,y:l.y},o={x:l.x2,y:l.y2};l.cp=function(t,e,o){const{x:n,y:r,x2:i,y2:s,centerX:a,centerY:d}=t,l=Math.atan2(s-r,i-n),c=m(e.controlPoint,0);return J({x:a+g(o,c.x,!1),y:d+g(o,c.y,!1)},{x:a,y:d},l)}(l,e,(0,r.aE)(t,o))}const c=function(t,e,o){const n=o.borderWidth,i=(0,r.E)(o.padding),s=O(t.ctx,o),a=s.width+i.width+n,d=s.height+i.height+n;return function(t,e,o,n){const{width:i,height:s,padding:a}=o,{xAdjust:d,yAdjust:l}=e,c={x:t.x,y:t.y},h={x:t.x2,y:t.y2},u="auto"===e.rotation?function(t){const{x:e,y:o,x2:n,y2:i}=t,s=Math.atan2(i-o,n-e);return s>r.P/2?s-r.P:sr&&(e=ht(r,{x:t,y:e},o),t=r),ei&&(t=ct(i,{x:t,y:e},o),e=i),{x:t,y:e}}function vt(t,{mouseX:e,mouseY:o},n,r){const i=t.label;return i.options.display&&i.inRange(e,o,r,n)}function wt(t,e,o,n){const{labelSize:r,padding:i}=e,s=t.w*n.dx,a=t.h*n.dy,d=s>0&&(r.w/2+i.left-n.x)/s,l=a>0&&(r.h/2+i.top-n.y)/a;return c(Math.max(d,l),0,.25)}function Mt(t,e){const{size:o,min:n,max:r,padding:i}=e,s=o/2;return o>r-n?(r+n)/2:(n>=t-i-s&&(t=n+i+s),r<=t+i+s&&(t=r-i-s),t)}function St(t){const e=t.options,o=e.arrowHeads&&e.arrowHeads.start,n=e.arrowHeads&&e.arrowHeads.end;return{startOpts:o,endOpts:n,startAdjust:kt(t,o),endAdjust:kt(t,n)}}function kt(t,e){if(!e||!e.display)return 0;const{length:o,width:n}=e,r=t.options.borderWidth/2,i={x:o,y:n+r},s={x:0,y:r};return Math.abs(ct(0,i,s))}function Ct(t,e,o,n){if(!n||!n.display)return;const{length:r,width:i,fill:s,backgroundColor:a,borderColor:d}=n,l=Math.abs(e-r)+o;t.beginPath(),T(t,n),j(t,n),t.moveTo(l,-i),t.lineTo(e+o,0),t.lineTo(l,i),!0===s?(t.fillStyle=a||d,t.closePath(),t.fill(),t.shadowColor="transparent"):t.shadowColor=n.borderShadowColor,t.stroke()}function Pt(t,{x:e,y:o},{angle:n,adjust:r},i){i&&i.display&&(t.save(),t.translate(e,o),t.rotate(n),Ct(t,0,-r,i),t.restore())}bt.defaults={adjustScaleRange:!0,arrowHeads:{display:!1,end:Object.assign({},gt),fill:!1,length:12,start:Object.assign({},gt),width:6},borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:2,curve:!1,controlPoint:{y:"-50%"},display:!0,endValue:void 0,init:void 0,label:{backgroundColor:"rgba(0,0,0,0.8)",backgroundShadowColor:"transparent",borderCapStyle:"butt",borderColor:"black",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderRadius:6,borderShadowColor:"transparent",borderWidth:0,callout:Object.assign({},at.defaults.callout),color:"#fff",content:null,display:!1,drawTime:void 0,font:{family:void 0,lineHeight:void 0,size:void 0,style:void 0,weight:"bold"},height:void 0,opacity:void 0,padding:6,position:"center",rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,textAlign:"center",textStrokeColor:void 0,textStrokeWidth:0,width:void 0,xAdjust:0,yAdjust:0,z:void 0},scaleID:void 0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,value:void 0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0},bt.descriptors={arrowHeads:{start:{_fallback:!0},end:{_fallback:!0},_fallback:!0}},bt.defaultRoutes={borderColor:"color"};class Dt extends n.Hg{inRange(t,e,o,n){const i=this.options.rotation,s=this.options.borderWidth;if("x"!==o&&"y"!==o)return function(t,e,o,n){const{width:i,height:s,centerX:a,centerY:d}=e,l=i/2,c=s/2;if(l<=0||c<=0)return!1;const h=(0,r.t)(o||0),u=n/2||0,f=Math.cos(h),x=Math.sin(h),y=Math.pow(f*(t.x-a)+x*(t.y-d),2),p=Math.pow(x*(t.x-a)-f*(t.y-d),2);return y/Math.pow(l+u,2)+p/Math.pow(c+u,2)<=1.0001}({x:t,y:e},this.getProps(["width","height","centerX","centerY"],n),i,s);const{x:a,y:d,x2:c,y2:h}=this.getProps(["x","y","x2","y2"],n),u=s/2,f="y"===o?{start:d,end:h}:{start:a,end:c},x=J({x:t,y:e},this.getCenterPoint(n),(0,r.t)(-i));return x[o]>=f.start-u-l&&x[o]<=f.end+u+l}getCenterPoint(t){return f(this,t)}draw(t){const{width:e,height:o,centerX:n,centerY:i,options:s}=this;t.save(),D(t,this.getCenterPoint(),s.rotation),T(t,this.options),t.beginPath(),t.fillStyle=s.backgroundColor;const a=j(t,s);t.ellipse(n,i,o/2,e/2,r.P/2,0,2*r.P),t.fill(),a&&(t.shadowColor=s.borderShadowColor,t.stroke()),t.restore()}get label(){return this.elements&&this.elements[0]}resolveElementProperties(t,e){return V(t,e,!0)}}Dt.id="ellipseAnnotation",Dt.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,label:Object.assign({},it.defaults.label),rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xMax:void 0,xMin:void 0,xScaleID:void 0,yMax:void 0,yMin:void 0,yScaleID:void 0,z:0},Dt.defaultRoutes={borderColor:"color",backgroundColor:"color"},Dt.descriptors={label:{_fallback:!0}};class jt extends n.Hg{inRange(t,e,o,n){const{x:r,y:i,x2:s,y2:a,width:d}=this.getProps(["x","y","x2","y2","width"],n),l=this.options.borderWidth;if("x"!==o&&"y"!==o)return function(t,e,o,n){if(!t||!e||o<=0)return!1;const r=n/2;return Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2)<=Math.pow(o+r,2)}({x:t,y:e},this.getCenterPoint(n),d/2,l);const c=l/2,h="y"===o?{start:i,end:a,value:e}:{start:r,end:s,value:t};return h.value>=h.start-c&&h.value<=h.end+c}getCenterPoint(t){return f(this,t)}draw(t){const e=this.options,o=e.borderWidth;if(e.radius<.1)return;t.save(),t.fillStyle=e.backgroundColor,T(t,e);const n=j(t,e);I(t,this,this.centerX,this.centerY),n&&!P(e.pointStyle)&&(t.shadowColor=e.borderShadowColor,t.stroke()),t.restore(),e.borderWidth=o}resolveElementProperties(t,e){const o=H(t,e);return o.initProperties=w(t,o,e,!0),o}}jt.id="pointAnnotation",jt.defaults={adjustScaleRange:!0,backgroundShadowColor:"transparent",borderDash:[],borderDashOffset:0,borderShadowColor:"transparent",borderWidth:1,display:!0,init:void 0,pointStyle:"circle",radius:10,rotation:0,shadowBlur:0,shadowOffsetX:0,shadowOffsetY:0,xAdjust:0,xMax:void 0,xMin:void 0,xScaleID:void 0,xValue:void 0,yAdjust:0,yMax:void 0,yMin:void 0,yScaleID:void 0,yValue:void 0,z:0},jt.defaultRoutes={borderColor:"color",backgroundColor:"color"};class Tt extends n.Hg{inRange(t,e,o,n){if("x"!==o&&"y"!==o)return this.options.radius>=.1&&this.elements.length>1&&function(t,e,o,n){let r=!1,i=t[t.length-1].getProps(["bX","bY"],n);for(const s of t){const t=s.getProps(["bX","bY"],n);t.bY>o!==i.bY>o&&e<(i.bX-t.bX)*(o-t.bY)/(i.bY-t.bY)+t.bX&&(r=!r),i=t}return r}(this.elements,t,e,n);const i=J({x:t,y:e},this.getCenterPoint(n),(0,r.t)(-this.options.rotation)),s=this.elements.map((t=>"y"===o?t.bY:t.bX)),a=Math.min(...s),d=Math.max(...s);return i[o]>=a&&i[o]<=d}getCenterPoint(t){return f(this,t)}draw(t){const{elements:e,options:o}=this;t.save(),t.beginPath(),t.fillStyle=o.backgroundColor,T(t,o);const n=j(t,o);let r=!0;for(const i of e)r?(t.moveTo(i.x,i.y),r=!1):t.lineTo(i.x,i.y);t.closePath(),t.fill(),n&&(t.shadowColor=o.borderShadowColor,t.stroke()),t.restore()}resolveElementProperties(t,e){const o=H(t,e),{sides:n,rotation:i}=e,s=[],a=2*r.P/n;let d=i*r.b3;for(let r=0;r{r.d.describe(`elements.${At[t].id}`,{_fallback:"plugins.annotation.common"})}));const Yt={update:Object.assign},It=Q.concat(K),Xt=(t,e)=>(0,r.i)(e)?Vt(t,e):t,Et=t=>"color"===t||"font"===t;function Wt(t="line"){return At[t]?t:(console.warn(`Unknown annotation type: '${t}', defaulting to 'line'`),"line")}function Rt(t,e,o,i){const s=function(t,e,o){if("reset"===o||"none"===o||"resize"===o)return Yt;return new n.Qw(t,e)}(t,o.animations,i),a=e.annotations,d=function(t,e){const o=e.length,n=t.length;if(no&&t.splice(o,n-o);return t}(e.elements,a);for(let n=0;nXt(t,i))):o[n]=Xt(s,i)}return o}function $t(t,e,o){return e.$context||(e.$context=Object.assign(Object.create(t.getContext()),{element:e,id:o.id,type:"annotation"}))}const Bt=new Map,Lt=Q.concat(K);var Jt={id:"annotation",version:"2.2.1",beforeRegister(){!function(t,e,o,n=!0){const r=o.split(".");let i=0;for(const s of e.split(".")){const a=r[i++];if(parseInt(s,10){const e=i[t];(0,r.i)(e)&&(e.id=t,n.push(e))})):(0,r.b)(i)&&n.push(...i),function(t,e){for(const o of t)ot(o,e)}(n,t.scales)},afterDataLimits(t,e){const o=Bt.get(t);tt(t,e.scale,o.annotations.filter((t=>t.display&&t.adjustScaleRange)))},afterUpdate(t,e,o){const n=Bt.get(t);!function(t,e,o){e.listened=M(o,Q,e.listeners),e.moveListened=!1,e._getElements=s,F.forEach((t=>{(0,r.a7)(o[t])&&(e.moveListened=!0)})),e.listened&&e.moveListened||e.annotations.forEach((t=>{!e.listened&&(0,r.a7)(t.click)&&(e.listened=!0),e.moveListened||F.forEach((o=>{(0,r.a7)(t[o])&&(e.listened=!0,e.moveListened=!0)}))}))}(0,n,o),Rt(t,n,o,e.mode),n.visibleElements=n.elements.filter((t=>!t.skip&&t.options.display)),function(t,e,o){const n=e.visibleElements;e.hooked=M(o,K,e.hooks),e.hooked||n.forEach((t=>{e.hooked||K.forEach((o=>{(0,r.a7)(t.options[o])&&(e.hooked=!0)}))}))}(0,n,o)},beforeDatasetsDraw(t,e,o){Ft(t,"beforeDatasetsDraw",o.clip)},afterDatasetsDraw(t,e,o){Ft(t,"afterDatasetsDraw",o.clip)},beforeDraw(t,e,o){Ft(t,"beforeDraw",o.clip)},afterDraw(t,e,o){Ft(t,"afterDraw",o.clip)},beforeEvent(t,e,o){U(Bt.get(t),e.event,o)&&(e.changed=!0)},afterDestroy(t){Bt.delete(t)},_getState:t=>Bt.get(t),defaults:{animations:{numbers:{properties:["x","y","x2","y2","width","height","centerX","centerY","pointX","pointY","radius"],type:"number"}},clip:!0,interaction:{mode:void 0,axis:void 0,intersect:void 0},common:{drawTime:"afterDatasetsDraw",init:!1,label:{}}},descriptors:{_indexable:!1,_scriptable:t=>!Lt.includes(t)&&"init"!==t,annotations:{_allKeys:!1,_fallback:(t,e)=>`elements.${At[Wt(e.type)].id}`},interaction:{_fallback:!0},common:{label:{_indexable:Et,_fallback:!0},_indexable:Et}},additionalOptionScopes:[""]};function Ft(t,e,o){const{ctx:n,chartArea:i}=t,s=Bt.get(t);o&&(0,r.Y)(n,i);const a=function(t,e){const o=[];for(const n of t)if(n.options.drawTime===e&&o.push({element:n,main:!0}),n.elements&&n.elements.length)for(const t of n.elements)t.options.display&&t.options.drawTime===e&&o.push({element:t});return o}(s.visibleElements,e).sort(((t,e)=>t.element.options.z-e.element.options.z));for(const r of a)Qt(n,i,s,r);o&&(0,r.$)(n)}function Qt(t,e,o,n){const r=n.element;n.main?(Z(o,r,"beforeDraw"),r.draw(t,e),Z(o,r,"afterDraw")):r.draw(t,e)}},18107:(t,e,o)=>{var n=o(46518),r=o(48981),i=o(26198),s=o(91291),a=o(6469);n({target:"Array",proto:!0},{at:function(t){var e=r(this),o=i(e),n=s(t),a=n>=0?n:o+n;return a<0||a>=o?void 0:e[a]}}),a("at")},34504:(t,e,o)=>{o(18107)},78898:(t,e,o)=>{var n=o(46518),r=o(68183).charAt,i=o(67750),s=o(91291),a=o(655);n({target:"String",proto:!0,forced:!0},{at:function(t){var e=a(i(this)),o=e.length,n=s(t),d=n>=0?n:o+n;return d<0||d>=o?void 0:r(e,d)}})}}]);