diff --git a/200.html b/200.html index 7cfbef3f..a46f5ed4 100644 --- a/200.html +++ b/200.html @@ -1,12 +1,12 @@
- + - - + + -=0;--f)if(!g()){this.updateRangeFromParsed(c,e,h,l);break}}return c}getAllParsedValues(e){const o=this._cachedMeta._parsed,n=[];let r,i,s;for(r=0,i=o.length;r=0&&e y&&(y=_),u=(d*u+b)/++d):(m(),t.lineTo(b,_),g=C,d=0,p=y=_),x=_}m()}function oc(t){const e=t.options,o=e.borderDash&&e.borderDash.length;return!t._decimated&&!t._loop&&!e.tension&&e.cubicInterpolationMode!=="monotone"&&!e.stepped&&!o?$P:DP}function IP(t){return t.stepped?$5:t.tension||t.cubicInterpolationMode==="monotone"?I5:hn}function NP(t,e,o,n){let r=e._path;r||(r=e._path=new Path2D,e.path(r,o,n)&&r.closePath()),a0(t,e.options),t.stroke(r)}function FP(t,e,o,n){const{segments:r,options:i}=e,s=oc(e);for(const a of r)a0(t,i,a.style),t.beginPath(),s(t,e,a,{start:o,end:o+n-1})&&t.closePath(),t.stroke()}const jP=typeof Path2D=="function";function HP(t,e,o,n){jP&&!e.options.segment?NP(t,e,o,n):FP(t,e,o,n)}class Wo extends Oo{constructor(e){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,e&&Object.assign(this,e)}updateControlPoints(e,o){const n=this.options;if((n.tension||n.cubicInterpolationMode==="monotone")&&!n.stepped&&!this._pointsUpdated){const r=n.spanGaps?this._loop:this._fullLoop;R5(this._points,n,e,r,o),this._pointsUpdated=!0}}set points(e){this._points=e,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=W5(this,this.options.segment))}first(){const e=this.segments,o=this.points;return e.length&&o[e[0].start]}last(){const e=this.segments,o=this.points,n=e.length;return n&&o[e[n-1].end]}interpolate(e,o){const n=this.options,r=e[o],i=this.points,s=qm(this,{property:o,start:r,end:r});if(!s.length)return;const a=[],l=IP(n);let c,u;for(c=0,u=s.length;ce!=="borderDash"&&e!=="fill"});function Jf(t,e,o,n){const r=t.options,{[o]:i}=t.getProps([o],n);return Math.abs(e-i) =0;--f)if(!g()){this.updateRangeFromParsed(c,e,h,l);break}}return c}getAllParsedValues(e){const o=this._cachedMeta._parsed,n=[];let r,i,s;for(r=0,i=o.length;r=0&&e y&&(y=_),u=(d*u+b)/++d):(m(),t.lineTo(b,_),g=C,d=0,p=y=_),x=_}m()}function oc(t){const e=t.options,o=e.borderDash&&e.borderDash.length;return!t._decimated&&!t._loop&&!e.tension&&e.cubicInterpolationMode!=="monotone"&&!e.stepped&&!o?$P:DP}function IP(t){return t.stepped?$5:t.tension||t.cubicInterpolationMode==="monotone"?I5:hn}function NP(t,e,o,n){let r=e._path;r||(r=e._path=new Path2D,e.path(r,o,n)&&r.closePath()),a0(t,e.options),t.stroke(r)}function FP(t,e,o,n){const{segments:r,options:i}=e,s=oc(e);for(const a of r)a0(t,i,a.style),t.beginPath(),s(t,e,a,{start:o,end:o+n-1})&&t.closePath(),t.stroke()}const jP=typeof Path2D=="function";function HP(t,e,o,n){jP&&!e.options.segment?NP(t,e,o,n):FP(t,e,o,n)}class zo extends Oo{constructor(e){super(),this.animated=!0,this.options=void 0,this._chart=void 0,this._loop=void 0,this._fullLoop=void 0,this._path=void 0,this._points=void 0,this._segments=void 0,this._decimated=!1,this._pointsUpdated=!1,this._datasetIndex=void 0,e&&Object.assign(this,e)}updateControlPoints(e,o){const n=this.options;if((n.tension||n.cubicInterpolationMode==="monotone")&&!n.stepped&&!this._pointsUpdated){const r=n.spanGaps?this._loop:this._fullLoop;R5(this._points,n,e,r,o),this._pointsUpdated=!0}}set points(e){this._points=e,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=z5(this,this.options.segment))}first(){const e=this.segments,o=this.points;return e.length&&o[e[0].start]}last(){const e=this.segments,o=this.points,n=e.length;return n&&o[e[n-1].end]}interpolate(e,o){const n=this.options,r=e[o],i=this.points,s=qm(this,{property:o,start:r,end:r});if(!s.length)return;const a=[],l=IP(n);let c,u;for(c=0,u=s.length;ce!=="borderDash"&&e!=="fill"});function Jf(t,e,o,n){const r=t.options,{[o]:i}=t.getProps([o],n);return Math.abs(e-i)r-i))}return t._cache.$bar}function a2(t){const e=t.iScale,o=s2(e,t.type);let n=e._length,r,i,s,a;const l=()=>{s===32767||s===-32768||(ni(a)&&(n=Math.min(n,Math.abs(s-a)||n)),a=s)};for(r=0,i=o.length;r0?r[t-1]:null,a=t=0;--n)o=Math.max(o,e[n].size(this.resolveDataElementOptions(n))/2);return o>0&&o}getLabelAndValue(e){const o=this._cachedMeta,n=this.chart.data.labels||[],{xScale:r,yScale:i}=o,s=this.getParsed(e),a=r.getLabelForValue(s.x),l=i.getLabelForValue(s.y),c=s._custom;return{label:n[e]||"",value:"("+a+", "+l+(c?", "+c:"")+")"}}update(e){const o=this._cachedMeta.data;this.updateElements(o,0,o.length,e)}updateElements(e,o,n,r){const i=r==="reset",{iScale:s,vScale:a}=this._cachedMeta,{sharedOptions:l,includeOptions:c}=this._getSharedOptions(o,r),u=s.axis,d=a.axis;for(let f=o;f{typeof p.beforeLayout=="function"&&p.beforeLayout()});const u=l.reduce((p,y)=>y.box.options&&y.box.options.display===!1?p:p+1,0)||1,d=Object.freeze({outerWidth:e,outerHeight:o,padding:r,availableWidth:i,availableHeight:s,vBoxMaxWidth:i/2/u,hBoxMaxHeight:s/2}),f=Object.assign({},r);Qm(f,ct(n));const h=Object.assign({maxPadding:f,w:i,h:s,x:r.left,y:r.top},r),g=P2(l.concat(c),d);xr(a.fullSize,h,d,g),xr(l,h,d,g),xr(c,h,d,g)&&xr(l,h,d,g),O2(h),$f(a.leftAndTop,h,d,g),h.x+=h.w,h.y+=h.h,$f(a.rightAndBottom,h,d,g),t.chartArea={left:h.left,top:h.top,right:h.left+h.w,bottom:h.top+h.h,height:h.h,width:h.w},ye(a.chartArea,p=>{const y=p.box;Object.assign(y,t.chartArea),y.update(h.w,h.h,{left:0,top:0,right:0,bottom:0})})}};class e0{acquireContext(e,o){}releaseContext(e){return!1}addEventListener(e,o,n){}removeEventListener(e,o,n){}getDevicePixelRatio(){return 1}getMaximumSize(e,o,n,r){return o=Math.max(0,o||e.width),n=n||e.height,{width:o,height:Math.max(0,r?Math.floor(o/r):n)}}isAttached(e){return!0}updateConfig(e){}}class M2 extends e0{acquireContext(e){return e&&e.getContext&&e.getContext("2d")||null}updateConfig(e){e.options.animation=!1}}const ys="$chartjs",A2={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},If=t=>t===null||t==="";function B2(t,e){const o=t.style,n=t.getAttribute("height"),r=t.getAttribute("width");if(t[ys]={initial:{height:n,width:r,style:{display:o.display,height:o.height,width:o.width}}},o.display=o.display||"block",o.boxSizing=o.boxSizing||"border-box",If(r)){const i=xf(t,"width");i!==void 0&&(t.width=i)}if(If(n))if(t.style.height==="")t.height=t.width/(e||2);else{const i=xf(t,"height");i!==void 0&&(t.height=i)}return t}const t0=D5?{passive:!0}:!1;function L2(t,e,o){t&&t.addEventListener(e,o,t0)}function D2(t,e,o){t&&t.canvas&&t.canvas.removeEventListener(e,o,t0)}function $2(t,e){const o=A2[t.type]||t.type,{x:n,y:r}=fn(t,e);return{type:o,chart:e,native:t,x:n!==void 0?n:null,y:r!==void 0?r:null}}function Js(t,e){for(const o of t)if(o===e||o.contains(e))return!0}function I2(t,e,o){const n=t.canvas,r=new MutationObserver(i=>{let s=!1;for(const a of i)s=s||Js(a.addedNodes,n),s=s&&!Js(a.removedNodes,n);s&&o()});return r.observe(document,{childList:!0,subtree:!0}),r}function N2(t,e,o){const n=t.canvas,r=new MutationObserver(i=>{let s=!1;for(const a of i)s=s||Js(a.removedNodes,n),s=s&&!Js(a.addedNodes,n);s&&o()});return r.observe(document,{childList:!0,subtree:!0}),r}const si=new Map;let Nf=0;function o0(){const t=window.devicePixelRatio;t!==Nf&&(Nf=t,si.forEach((e,o)=>{o.currentDevicePixelRatio!==t&&e()}))}function F2(t,e){si.size||window.addEventListener("resize",o0),si.set(t,e)}function j2(t){si.delete(t),si.size||window.removeEventListener("resize",o0)}function H2(t,e,o){const n=t.canvas,r=n&&du(n);if(!r)return;const i=Am((a,l)=>{const c=r.clientWidth;o(a,l),c{this.draw(i)}}]:[{z:n,draw:i=>{this.drawBackground(),this.drawGrid(i),this.drawTitle()}},{z:r,draw:()=>{this.drawBorder()}},{z:o,draw:i=>{this.drawLabels(i)}}]}getMatchingVisibleMetas(e){const o=this.chart.getSortedVisibleDatasetMetas(),n=this.axis+"AxisID",r=[];let i,s;for(i=0,s=o.length;i{const n=o.split("."),r=n.pop(),i=[t].concat(n).join("."),s=e[o].split("."),a=s.pop(),l=s.join(".");$e.route(i,r,l,a)})}function sP(t){return"id"in t&&"defaults"in t}class aP{constructor(){this.controllers=new Xi(Yt,"datasets",!0),this.elements=new Xi(Oo,"elements"),this.plugins=new Xi(Object,"plugins"),this.scales=new Xi(Mn,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...e){this._each("register",e)}remove(...e){this._each("unregister",e)}addControllers(...e){this._each("register",e,this.controllers)}addElements(...e){this._each("register",e,this.elements)}addPlugins(...e){this._each("register",e,this.plugins)}addScales(...e){this._each("register",e,this.scales)}getController(e){return this._get(e,this.controllers,"controller")}getElement(e){return this._get(e,this.elements,"element")}getPlugin(e){return this._get(e,this.plugins,"plugin")}getScale(e){return this._get(e,this.scales,"scale")}removeControllers(...e){this._each("unregister",e,this.controllers)}removeElements(...e){this._each("unregister",e,this.elements)}removePlugins(...e){this._each("unregister",e,this.plugins)}removeScales(...e){this._each("unregister",e,this.scales)}_each(e,o,n){[...o].forEach(r=>{const i=n||this._getRegistryForType(r);n||i.isForType(r)||i===this.plugins&&r.id?this._exec(e,i,r):ye(r,s=>{const a=n||this._getRegistryForType(s);this._exec(e,a,s)})})}_exec(e,o,n){const r=tu(e);Pe(n["before"+r],[],n),o[e](n),Pe(n["after"+r],[],n)}_getRegistryForType(e){for(let o=0;oa&&i>a;return{count:n,start:l,loop:e.loop,ilen:ca({chart:e,initial:o.initial,numSteps:s,currentStep:Math.min(n-o.start,s)}))}_refresh(){this._request||(this._running=!0,this._request=Mm.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(e=Date.now()){let o=0;this._charts.forEach((n,r)=>{if(!n.running||!n.items.length)return;const i=n.items;let s=i.length-1,a=!1,l;for(;s>=0;--s)l=i[s],l._active?(l._total>n.duration&&(n.duration=l._total),l.tick(e),a=!0):(i[s]=i[i.length-1],i.pop());a&&(r.draw(),this._notify(r,n,e,"progress")),i.length||(n.running=!1,this._notify(r,n,e,"complete"),n.initial=!1),o+=i.length}),this._lastDate=e,o===0&&(this._running=!1)}_getAnims(e){const o=this._charts;let n=o.get(e);return n||(n={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},o.set(e,n)),n}listen(e,o,n){this._getAnims(e).listeners[o].push(n)}add(e,o){!o||!o.length||this._getAnims(e).items.push(...o)}has(e){return this._getAnims(e).items.length>0}start(e){const o=this._charts.get(e);o&&(o.running=!0,o.start=Date.now(),o.duration=o.items.reduce((n,r)=>Math.max(n,r._duration),0),this._refresh())}running(e){if(!this._running)return!1;const o=this._charts.get(e);return!(!o||!o.running||!o.items.length)}stop(e){const o=this._charts.get(e);if(!o||!o.items.length)return;const n=o.items;let r=n.length-1;for(;r>=0;--r)n[r].cancel();o.items=[],this._notify(e,o,Date.now(),"complete")}remove(e){return this._charts.delete(e)}}var fo=new K5;const Cf="transparent",Y5={boolean(t,e,o){return o>.5?e:t},color(t,e,o){const n=gf(t||Cf),r=n.valid&&gf(e||Cf);return r&&r.valid?r.mix(n,o).hexString():e},number(t,e,o){return t+(e-t)*o}};class q5{constructor(e,o,n,r){const i=o[n];r=vr([e.to,r,i,e.from]);const s=vr([e.from,i,r]);this._active=!0,this._fn=e.fn||Y5[e.type||typeof s],this._easing=Fr[e.easing]||Fr.linear,this._start=Math.floor(Date.now()+(e.delay||0)),this._duration=this._total=Math.floor(e.duration),this._loop=!!e.loop,this._target=o,this._prop=n,this._from=s,this._to=r,this._promises=void 0}active(){return this._active}update(e,o,n){if(this._active){this._notify(!1);const r=this._target[this._prop],i=n-this._start,s=this._duration-i;this._start=n,this._duration=Math.floor(Math.max(s,e.duration)),this._total+=i,this._loop=!!e.loop,this._to=vr([e.to,o,r,e.from]),this._from=vr([e.from,r,o])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(e){const o=e-this._start,n=this._duration,r=this._prop,i=this._from,s=this._loop,a=this._to;let l;if(this._active=i!==a&&(s||or-i))}return t._cache.$bar}function a2(t){const e=t.iScale,o=s2(e,t.type);let n=e._length,r,i,s,a;const l=()=>{s===32767||s===-32768||(ni(a)&&(n=Math.min(n,Math.abs(s-a)||n)),a=s)};for(r=0,i=o.length;r0?r[t-1]:null,a=t=0;--n)o=Math.max(o,e[n].size(this.resolveDataElementOptions(n))/2);return o>0&&o}getLabelAndValue(e){const o=this._cachedMeta,n=this.chart.data.labels||[],{xScale:r,yScale:i}=o,s=this.getParsed(e),a=r.getLabelForValue(s.x),l=i.getLabelForValue(s.y),c=s._custom;return{label:n[e]||"",value:"("+a+", "+l+(c?", "+c:"")+")"}}update(e){const o=this._cachedMeta.data;this.updateElements(o,0,o.length,e)}updateElements(e,o,n,r){const i=r==="reset",{iScale:s,vScale:a}=this._cachedMeta,{sharedOptions:l,includeOptions:c}=this._getSharedOptions(o,r),u=s.axis,d=a.axis;for(let f=o;f{typeof p.beforeLayout=="function"&&p.beforeLayout()});const u=l.reduce((p,y)=>y.box.options&&y.box.options.display===!1?p:p+1,0)||1,d=Object.freeze({outerWidth:e,outerHeight:o,padding:r,availableWidth:i,availableHeight:s,vBoxMaxWidth:i/2/u,hBoxMaxHeight:s/2}),f=Object.assign({},r);Qm(f,ct(n));const h=Object.assign({maxPadding:f,w:i,h:s,x:r.left,y:r.top},r),g=P2(l.concat(c),d);xr(a.fullSize,h,d,g),xr(l,h,d,g),xr(c,h,d,g)&&xr(l,h,d,g),O2(h),$f(a.leftAndTop,h,d,g),h.x+=h.w,h.y+=h.h,$f(a.rightAndBottom,h,d,g),t.chartArea={left:h.left,top:h.top,right:h.left+h.w,bottom:h.top+h.h,height:h.h,width:h.w},ye(a.chartArea,p=>{const y=p.box;Object.assign(y,t.chartArea),y.update(h.w,h.h,{left:0,top:0,right:0,bottom:0})})}};class e0{acquireContext(e,o){}releaseContext(e){return!1}addEventListener(e,o,n){}removeEventListener(e,o,n){}getDevicePixelRatio(){return 1}getMaximumSize(e,o,n,r){return o=Math.max(0,o||e.width),n=n||e.height,{width:o,height:Math.max(0,r?Math.floor(o/r):n)}}isAttached(e){return!0}updateConfig(e){}}class M2 extends e0{acquireContext(e){return e&&e.getContext&&e.getContext("2d")||null}updateConfig(e){e.options.animation=!1}}const ys="$chartjs",A2={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},If=t=>t===null||t==="";function B2(t,e){const o=t.style,n=t.getAttribute("height"),r=t.getAttribute("width");if(t[ys]={initial:{height:n,width:r,style:{display:o.display,height:o.height,width:o.width}}},o.display=o.display||"block",o.boxSizing=o.boxSizing||"border-box",If(r)){const i=xf(t,"width");i!==void 0&&(t.width=i)}if(If(n))if(t.style.height==="")t.height=t.width/(e||2);else{const i=xf(t,"height");i!==void 0&&(t.height=i)}return t}const t0=D5?{passive:!0}:!1;function L2(t,e,o){t&&t.addEventListener(e,o,t0)}function D2(t,e,o){t&&t.canvas&&t.canvas.removeEventListener(e,o,t0)}function $2(t,e){const o=A2[t.type]||t.type,{x:n,y:r}=fn(t,e);return{type:o,chart:e,native:t,x:n!==void 0?n:null,y:r!==void 0?r:null}}function Js(t,e){for(const o of t)if(o===e||o.contains(e))return!0}function I2(t,e,o){const n=t.canvas,r=new MutationObserver(i=>{let s=!1;for(const a of i)s=s||Js(a.addedNodes,n),s=s&&!Js(a.removedNodes,n);s&&o()});return r.observe(document,{childList:!0,subtree:!0}),r}function N2(t,e,o){const n=t.canvas,r=new MutationObserver(i=>{let s=!1;for(const a of i)s=s||Js(a.removedNodes,n),s=s&&!Js(a.addedNodes,n);s&&o()});return r.observe(document,{childList:!0,subtree:!0}),r}const si=new Map;let Nf=0;function o0(){const t=window.devicePixelRatio;t!==Nf&&(Nf=t,si.forEach((e,o)=>{o.currentDevicePixelRatio!==t&&e()}))}function F2(t,e){si.size||window.addEventListener("resize",o0),si.set(t,e)}function j2(t){si.delete(t),si.size||window.removeEventListener("resize",o0)}function H2(t,e,o){const n=t.canvas,r=n&&du(n);if(!r)return;const i=Am((a,l)=>{const c=r.clientWidth;o(a,l),c{this.draw(i)}}]:[{z:n,draw:i=>{this.drawBackground(),this.drawGrid(i),this.drawTitle()}},{z:r,draw:()=>{this.drawBorder()}},{z:o,draw:i=>{this.drawLabels(i)}}]}getMatchingVisibleMetas(e){const o=this.chart.getSortedVisibleDatasetMetas(),n=this.axis+"AxisID",r=[];let i,s;for(i=0,s=o.length;i{const n=o.split("."),r=n.pop(),i=[t].concat(n).join("."),s=e[o].split("."),a=s.pop(),l=s.join(".");$e.route(i,r,l,a)})}function sP(t){return"id"in t&&"defaults"in t}class aP{constructor(){this.controllers=new Xi(Yt,"datasets",!0),this.elements=new Xi(Oo,"elements"),this.plugins=new Xi(Object,"plugins"),this.scales=new Xi(Mn,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...e){this._each("register",e)}remove(...e){this._each("unregister",e)}addControllers(...e){this._each("register",e,this.controllers)}addElements(...e){this._each("register",e,this.elements)}addPlugins(...e){this._each("register",e,this.plugins)}addScales(...e){this._each("register",e,this.scales)}getController(e){return this._get(e,this.controllers,"controller")}getElement(e){return this._get(e,this.elements,"element")}getPlugin(e){return this._get(e,this.plugins,"plugin")}getScale(e){return this._get(e,this.scales,"scale")}removeControllers(...e){this._each("unregister",e,this.controllers)}removeElements(...e){this._each("unregister",e,this.elements)}removePlugins(...e){this._each("unregister",e,this.plugins)}removeScales(...e){this._each("unregister",e,this.scales)}_each(e,o,n){[...o].forEach(r=>{const i=n||this._getRegistryForType(r);n||i.isForType(r)||i===this.plugins&&r.id?this._exec(e,i,r):ye(r,s=>{const a=n||this._getRegistryForType(s);this._exec(e,a,s)})})}_exec(e,o,n){const r=tu(e);Pe(n["before"+r],[],n),o[e](n),Pe(n["after"+r],[],n)}_getRegistryForType(e){for(let o=0;oa&&i>a;return{count:n,start:l,loop:e.loop,ilen:c-1?t.split(`
-`):t}function LT(t,e){const{element:o,datasetIndex:n,index:r}=e,i=t.getDatasetMeta(n).controller,{label:s,value:a}=i.getLabelAndValue(r);return{chart:t,label:s,parsed:i.getParsed(r),raw:t.data.datasets[n].data[r],formattedValue:a,dataset:i.getDataset(),dataIndex:r,datasetIndex:n,element:o}}function ch(t,e){const o=t.chart.ctx,{body:n,footer:r,title:i}=t,{boxWidth:s,boxHeight:a}=e,l=Ge(e.bodyFont),c=Ge(e.titleFont),u=Ge(e.footerFont),d=i.length,f=r.length,h=n.length,g=ct(e.padding);let p=g.height,y=0,x=n.reduce((b,_)=>b+_.before.length+_.lines.length+_.after.length,0);if(x+=t.beforeBody.length+t.afterBody.length,d&&(p+=d*c.lineHeight+(d-1)*e.titleSpacing+e.titleMarginBottom),x){const b=e.displayColors?Math.max(a,l.lineHeight):l.lineHeight;p+=h*b+(x-h)*l.lineHeight+(x-1)*e.bodySpacing}f&&(p+=e.footerMarginTop+f*u.lineHeight+(f-1)*e.footerSpacing);let v=0;const m=function(b){y=Math.max(y,o.measureText(b).width+v)};return o.save(),o.font=c.string,ye(t.title,m),o.font=l.string,ye(t.beforeBody.concat(t.afterBody),m),v=e.displayColors?s+2+e.boxPadding:0,ye(n,b=>{ye(b.before,m),ye(b.lines,m),ye(b.after,m)}),v=0,o.font=u.string,ye(t.footer,m),o.restore(),y+=g.width,{width:y,height:p}}function DT(t,e){const{y:o,height:n}=e;return oa)break;o.push({value:E})}return v&&f&&T!==a?o.length&&Nr(o[o.length-1].value,a,ph(a,b,t))?o[o.length-1].value=a:o.push({value:a}):(!v||T===a)&&o.push({value:T}),o}function ph(t,e,{horizontal:o,minRotation:n}){const r=Ut(n),i=(o?Math.sin(r):Math.cos(r))||.001,s=.75*e*(""+t).length;return Math.min(e/i,s)}class ea extends Mn{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(e,o){return de(e)||(typeof e=="number"||e instanceof Number)&&!isFinite(+e)?null:+e}handleTickRangeOptions(){const{beginAtZero:e}=this.options,{minDefined:o,maxDefined:n}=this.getUserBounds();let{min:r,max:i}=this;const s=l=>r=o?r:l,a=l=>i=n?i:l;if(e){const l=oo(r),c=oo(i);l<0&&c<0?a(0):l>0&&c>0&&s(0)}if(r===i){let l=i===0?1:Math.abs(i*.05);a(i+l),e||s(r-l)}this.min=r,this.max=i}getTickLimit(){const e=this.options.ticks;let{maxTicksLimit:o,stepSize:n}=e,r;return n?(r=Math.ceil(this.max/n)-Math.floor(this.min/n)+1,r>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${n} would result generating up to ${r} ticks. Limiting to 1000.`),r=1e3)):(r=this.computeTickLimit(),o=o||11),o&&(r=Math.min(o,r)),r}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const e=this.options,o=e.ticks;let n=this.getTickLimit();n=Math.max(2,n);const r={maxTicks:n,bounds:e.bounds,min:e.min,max:e.max,precision:o.precision,step:o.stepSize,count:o.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:o.minRotation||0,includeBounds:o.includeBounds!==!1},i=this._range||this,s=KT(r,i);return e.bounds==="ticks"&&Tm(s,this,"value"),e.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){const e=this.ticks;let o=this.min,n=this.max;if(super.configure(),this.options.offset&&e.length){const r=(n-o)/Math.max(e.length-1,1)/2;o-=r,n+=r}this._startValue=o,this._endValue=n,this._valueRange=n-o}getLabelForValue(e){return Si(e,this.chart.options.locale,this.options.ticks.format)}}class ac extends ea{determineDataLimits(){const{min:e,max:o}=this.getMinMax(!0);this.min=je(e)?e:0,this.max=je(o)?o:1,this.handleTickRangeOptions()}computeTickLimit(){const e=this.isHorizontal(),o=e?this.width:this.height,n=Ut(this.options.ticks.minRotation),r=(e?Math.sin(n):Math.cos(n))||.001,i=this._resolveTickFontOptions(0);return Math.ceil(o/Math.min(40,i.lineHeight/r))}getPixelForValue(e){return e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getValueForPixel(e){return this._startValue+this.getDecimalForPixel(e)*this._valueRange}}j(ac,"id","linear"),j(ac,"defaults",{ticks:{callback:ka.formatters.numeric}});const ai=t=>Math.floor(zo(t)),cn=(t,e)=>Math.pow(10,ai(t)+e);function mh(t){return t/Math.pow(10,ai(t))===1}function bh(t,e,o){const n=Math.pow(10,o),r=Math.floor(t/n);return Math.ceil(e/n)-r}function YT(t,e){const o=e-t;let n=ai(o);for(;bh(t,e,n)>10;)n++;for(;bh(t,e,n)<10;)n--;return Math.min(n,ai(t))}function qT(t,{min:e,max:o}){e=St(t.min,e);const n=[],r=ai(e);let i=YT(e,o),s=i<0?Math.pow(10,Math.abs(i)):1;const a=Math.pow(10,i),l=r>i?Math.pow(10,r):0,c=Math.round((e-l)*s)/s,u=Math.floor((e-l)/a/10)*a*10;let d=Math.floor((c-u)/Math.pow(10,i)),f=St(t.min,Math.round((l+u+d*Math.pow(10,i))*s)/s);for(;fa)break;o.push({value:E})}return v&&f&&T!==a?o.length&&Nr(o[o.length-1].value,a,ph(a,b,t))?o[o.length-1].value=a:o.push({value:a}):(!v||T===a)&&o.push({value:T}),o}function ph(t,e,{horizontal:o,minRotation:n}){const r=Ut(n),i=(o?Math.sin(r):Math.cos(r))||.001,s=.75*e*(""+t).length;return Math.min(e/i,s)}class ea extends Mn{constructor(e){super(e),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(e,o){return de(e)||(typeof e=="number"||e instanceof Number)&&!isFinite(+e)?null:+e}handleTickRangeOptions(){const{beginAtZero:e}=this.options,{minDefined:o,maxDefined:n}=this.getUserBounds();let{min:r,max:i}=this;const s=l=>r=o?r:l,a=l=>i=n?i:l;if(e){const l=oo(r),c=oo(i);l<0&&c<0?a(0):l>0&&c>0&&s(0)}if(r===i){let l=i===0?1:Math.abs(i*.05);a(i+l),e||s(r-l)}this.min=r,this.max=i}getTickLimit(){const e=this.options.ticks;let{maxTicksLimit:o,stepSize:n}=e,r;return n?(r=Math.ceil(this.max/n)-Math.floor(this.min/n)+1,r>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${n} would result generating up to ${r} ticks. Limiting to 1000.`),r=1e3)):(r=this.computeTickLimit(),o=o||11),o&&(r=Math.min(o,r)),r}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const e=this.options,o=e.ticks;let n=this.getTickLimit();n=Math.max(2,n);const r={maxTicks:n,bounds:e.bounds,min:e.min,max:e.max,precision:o.precision,step:o.stepSize,count:o.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:o.minRotation||0,includeBounds:o.includeBounds!==!1},i=this._range||this,s=KT(r,i);return e.bounds==="ticks"&&Tm(s,this,"value"),e.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}configure(){const e=this.ticks;let o=this.min,n=this.max;if(super.configure(),this.options.offset&&e.length){const r=(n-o)/Math.max(e.length-1,1)/2;o-=r,n+=r}this._startValue=o,this._endValue=n,this._valueRange=n-o}getLabelForValue(e){return Si(e,this.chart.options.locale,this.options.ticks.format)}}class ac extends ea{determineDataLimits(){const{min:e,max:o}=this.getMinMax(!0);this.min=je(e)?e:0,this.max=je(o)?o:1,this.handleTickRangeOptions()}computeTickLimit(){const e=this.isHorizontal(),o=e?this.width:this.height,n=Ut(this.options.ticks.minRotation),r=(e?Math.sin(n):Math.cos(n))||.001,i=this._resolveTickFontOptions(0);return Math.ceil(o/Math.min(40,i.lineHeight/r))}getPixelForValue(e){return e===null?NaN:this.getPixelForDecimal((e-this._startValue)/this._valueRange)}getValueForPixel(e){return this._startValue+this.getDecimalForPixel(e)*this._valueRange}}j(ac,"id","linear"),j(ac,"defaults",{ticks:{callback:ka.formatters.numeric}});const ai=t=>Math.floor(Wo(t)),cn=(t,e)=>Math.pow(10,ai(t)+e);function mh(t){return t/Math.pow(10,ai(t))===1}function bh(t,e,o){const n=Math.pow(10,o),r=Math.floor(t/n);return Math.ceil(e/n)-r}function YT(t,e){const o=e-t;let n=ai(o);for(;bh(t,e,n)>10;)n++;for(;bh(t,e,n)<10;)n--;return Math.min(n,ai(t))}function qT(t,{min:e,max:o}){e=St(t.min,e);const n=[],r=ai(e);let i=YT(e,o),s=i<0?Math.pow(10,Math.abs(i)):1;const a=Math.pow(10,i),l=r>i?Math.pow(10,r):0,c=Math.round((e-l)*s)/s,u=Math.floor((e-l)/a/10)*a*10;let d=Math.floor((c-u)/Math.pow(10,i)),f=St(t.min,Math.round((l+u+d*Math.pow(10,i))*s)/s);for(;f