@sysvale/cuida 3.0.0-beta.116 → 3.0.0-beta.117
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@sysvale/cuida.es.js +873 -861
- package/dist/@sysvale/cuida.umd.js +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
* Released under the MIT License
|
|
40
40
|
*/class W9{constructor(){this._request=null,this._charts=new Map,this._running=!1,this._lastDate=void 0}_notify(t,n,s,i){const a=n.listeners[i],o=n.duration;a.forEach(c=>c({chart:t,initial:n.initial,numSteps:o,currentStep:Math.min(s-n.start,o)}))}_refresh(){this._request||(this._running=!0,this._request=Um.call(window,()=>{this._update(),this._request=null,this._running&&this._refresh()}))}_update(t=Date.now()){let n=0;this._charts.forEach((s,i)=>{if(!s.running||!s.items.length)return;const a=s.items;let o=a.length-1,c=!1,d;for(;o>=0;--o)d=a[o],d._active?(d._total>s.duration&&(s.duration=d._total),d.tick(t),c=!0):(a[o]=a[a.length-1],a.pop());c&&(i.draw(),this._notify(i,s,t,"progress")),a.length||(s.running=!1,this._notify(i,s,t,"complete"),s.initial=!1),n+=a.length}),this._lastDate=t,n===0&&(this._running=!1)}_getAnims(t){const n=this._charts;let s=n.get(t);return s||(s={running:!1,initial:!0,items:[],listeners:{complete:[],progress:[]}},n.set(t,s)),s}listen(t,n,s){this._getAnims(t).listeners[n].push(s)}add(t,n){!n||!n.length||this._getAnims(t).items.push(...n)}has(t){return this._getAnims(t).items.length>0}start(t){const n=this._charts.get(t);!n||(n.running=!0,n.start=Date.now(),n.duration=n.items.reduce((s,i)=>Math.max(s,i._duration),0),this._refresh())}running(t){if(!this._running)return!1;const n=this._charts.get(t);return!(!n||!n.running||!n.items.length)}stop(t){const n=this._charts.get(t);if(!n||!n.items.length)return;const s=n.items;let i=s.length-1;for(;i>=0;--i)s[i].cancel();n.items=[],this._notify(t,n,Date.now(),"complete")}remove(t){return this._charts.delete(t)}}var Ci=new W9;const xg="transparent",j9={boolean(e,t,n){return n>.5?t:e},color(e,t,n){const s=Qm(e||xg),i=s.valid&&Qm(t||xg);return i&&i.valid?i.mix(s,n).hexString():t},number(e,t,n){return e+(t-e)*n}};class Y9{constructor(t,n,s,i){const a=n[s];i=vl([t.to,i,a,t.from]);const o=vl([t.from,a,i]);this._active=!0,this._fn=t.fn||j9[t.type||typeof o],this._easing=fl[t.easing]||fl.linear,this._start=Math.floor(Date.now()+(t.delay||0)),this._duration=this._total=Math.floor(t.duration),this._loop=!!t.loop,this._target=n,this._prop=s,this._from=o,this._to=i,this._promises=void 0}active(){return this._active}update(t,n,s){if(this._active){this._notify(!1);const i=this._target[this._prop],a=s-this._start,o=this._duration-a;this._start=s,this._duration=Math.floor(Math.max(o,t.duration)),this._total+=a,this._loop=!!t.loop,this._to=vl([t.to,n,i,t.from]),this._from=vl([t.from,i,n])}}cancel(){this._active&&(this.tick(Date.now()),this._active=!1,this._notify(!1))}tick(t){const n=t-this._start,s=this._duration,i=this._prop,a=this._from,o=this._loop,c=this._to;let d;if(this._active=a!==c&&(o||n<s),!this._active){this._target[i]=c,this._notify(!0);return}if(n<0){this._target[i]=a;return}d=n/s%2,d=o&&d>1?2-d:d,d=this._easing(Math.min(1,Math.max(0,d))),this._target[i]=this._fn(a,c,d)}wait(){const t=this._promises||(this._promises=[]);return new Promise((n,s)=>{t.push({res:n,rej:s})})}_notify(t){const n=t?"res":"rej",s=this._promises||[];for(let i=0;i<s.length;i++)s[i][n]()}}class Sg{constructor(t,n){this._chart=t,this._properties=new Map,this.configure(n)}configure(t){if(!Kt(t))return;const n=Object.keys(ze.animation),s=this._properties;Object.getOwnPropertyNames(t).forEach(i=>{const a=t[i];if(!Kt(a))return;const o={};for(const c of n)o[c]=a[c];(Se(a.properties)&&a.properties||[i]).forEach(c=>{(c===i||!s.has(c))&&s.set(c,o)})})}_animateOptions(t,n){const s=n.options,i=G9(t,s);if(!i)return[];const a=this._createAnimations(i,s);return s.$shared&&U9(t.options.$animations,s).then(()=>{t.options=s},()=>{}),a}_createAnimations(t,n){const s=this._properties,i=[],a=t.$animations||(t.$animations={}),o=Object.keys(n),c=Date.now();let d;for(d=o.length-1;d>=0;--d){const h=o[d];if(h.charAt(0)==="$")continue;if(h==="options"){i.push(...this._animateOptions(t,n));continue}const f=n[h];let m=a[h];const v=s.get(h);if(m)if(v&&m.active()){m.update(v,f,c);continue}else m.cancel();if(!v||!v.duration){t[h]=f;continue}a[h]=m=new Y9(v,t,h,f),i.push(m)}return i}update(t,n){if(this._properties.size===0){Object.assign(t,n);return}const s=this._createAnimations(t,n);if(s.length)return Ci.add(this._chart,s),!0}}function U9(e,t){const n=[],s=Object.keys(t);for(let i=0;i<s.length;i++){const a=e[s[i]];a&&a.active()&&n.push(a.wait())}return Promise.all(n)}function G9(e,t){if(!t)return;let n=e.options;if(!n){e.options=t;return}return n.$shared&&(e.options=n=Object.assign({},n,{$shared:!1,$animations:{}})),n}function kg(e,t){const n=e&&e.options||{},s=n.reverse,i=n.min===void 0?t:0,a=n.max===void 0?t:0;return{start:s?a:i,end:s?i:a}}function K9(e,t,n){if(n===!1)return!1;const s=kg(e,n),i=kg(t,n);return{top:i.end,right:s.end,bottom:i.start,left:s.start}}function Z9(e){let t,n,s,i;return Kt(e)?(t=e.top,n=e.right,s=e.bottom,i=e.left):t=n=s=i=e,{top:t,right:n,bottom:s,left:i,disabled:e===!1}}function Cg(e,t){const n=[],s=e._getSortedDatasetMetas(t);let i,a;for(i=0,a=s.length;i<a;++i)n.push(s[i].index);return n}function Og(e,t,n,s={}){const i=e.keys,a=s.mode==="single";let o,c,d,h;if(t!==null){for(o=0,c=i.length;o<c;++o){if(d=+i[o],d===n){if(s.all)continue;break}h=e.values[d],Pe(h)&&(a||t===0||oi(t)===oi(h))&&(t+=h)}return t}}function X9(e){const t=Object.keys(e),n=new Array(t.length);let s,i,a;for(s=0,i=t.length;s<i;++s)a=t[s],n[s]={x:a,y:e[a]};return n}function Mg(e,t){const n=e&&e.options.stacked;return n||n===void 0&&t.stack!==void 0}function J9(e,t,n){return`${e.id}.${t.id}.${n.stack||n.type}`}function Q9(e){const{min:t,max:n,minDefined:s,maxDefined:i}=e.getUserBounds();return{min:s?t:Number.NEGATIVE_INFINITY,max:i?n:Number.POSITIVE_INFINITY}}function q9(e,t,n){const s=e[t]||(e[t]={});return s[n]||(s[n]={})}function Dg(e,t,n,s){for(const i of t.getMatchingVisibleMetas(s).reverse()){const a=e[i.index];if(n&&a>0||!n&&a<0)return i.index}return null}function Eg(e,t){const{chart:n,_cachedMeta:s}=e,i=n._stacks||(n._stacks={}),{iScale:a,vScale:o,index:c}=s,d=a.axis,h=o.axis,f=J9(a,o,s),m=t.length;let v;for(let y=0;y<m;++y){const w=t[y],{[d]:x,[h]:k}=w,D=w._stacks||(w._stacks={});v=D[h]=q9(i,f,x),v[c]=k,v._top=Dg(v,o,!0,s.type),v._bottom=Dg(v,o,!1,s.type);const E=v._visualValues||(v._visualValues={});E[c]=k}}function vh(e,t){const n=e.scales;return Object.keys(n).filter(s=>n[s].axis===t).shift()}function $9(e,t){return sa(e,{active:!1,dataset:void 0,datasetIndex:t,index:t,mode:"default",type:"dataset"})}function tx(e,t,n){return sa(e,{active:!1,dataIndex:t,parsed:void 0,raw:void 0,element:n,index:t,mode:"default",type:"data"})}function _l(e,t){const n=e.controller.index,s=e.vScale&&e.vScale.axis;if(!!s){t=t||e._parsed;for(const i of t){const a=i._stacks;if(!a||a[s]===void 0||a[s][n]===void 0)return;delete a[s][n],a[s]._visualValues!==void 0&&a[s]._visualValues[n]!==void 0&&delete a[s]._visualValues[n]}}}const _h=e=>e==="reset"||e==="none",Tg=(e,t)=>t?e:Object.assign({},e),ex=(e,t,n)=>e&&!t.hidden&&t._stacked&&{keys:Cg(n,!0),values:null};class Rs{constructor(t,n){this.chart=t,this._ctx=t.ctx,this.index=n,this._cachedDataOpts={},this._cachedMeta=this.getMeta(),this._type=this._cachedMeta.type,this.options=void 0,this._parsing=!1,this._data=void 0,this._objectData=void 0,this._sharedOptions=void 0,this._drawStart=void 0,this._drawCount=void 0,this.enableOptionSharing=!1,this.supportsDecimation=!1,this.$context=void 0,this._syncList=[],this.datasetElementType=new.target.datasetElementType,this.dataElementType=new.target.dataElementType,this.initialize()}initialize(){const t=this._cachedMeta;this.configure(),this.linkScales(),t._stacked=Mg(t.vScale,t),this.addElements(),this.options.fill&&!this.chart.isPluginEnabled("filler")&&console.warn("Tried to use the 'fill' option without the 'Filler' plugin enabled. Please import and register the 'Filler' plugin and make sure it is not disabled in the options")}updateIndex(t){this.index!==t&&_l(this._cachedMeta),this.index=t}linkScales(){const t=this.chart,n=this._cachedMeta,s=this.getDataset(),i=(m,v,y,w)=>m==="x"?v:m==="r"?w:y,a=n.xAxisID=Vt(s.xAxisID,vh(t,"x")),o=n.yAxisID=Vt(s.yAxisID,vh(t,"y")),c=n.rAxisID=Vt(s.rAxisID,vh(t,"r")),d=n.indexAxis,h=n.iAxisID=i(d,a,o,c),f=n.vAxisID=i(d,o,a,c);n.xScale=this.getScaleForId(a),n.yScale=this.getScaleForId(o),n.rScale=this.getScaleForId(c),n.iScale=this.getScaleForId(h),n.vScale=this.getScaleForId(f)}getDataset(){return this.chart.data.datasets[this.index]}getMeta(){return this.chart.getDatasetMeta(this.index)}getScaleForId(t){return this.chart.scales[t]}_getOtherScale(t){const n=this._cachedMeta;return t===n.iScale?n.vScale:n.iScale}reset(){this._update("reset")}_destroy(){const t=this._cachedMeta;this._data&&jm(this._data,this),t._stacked&&_l(t)}_dataCheck(){const t=this.getDataset(),n=t.data||(t.data=[]),s=this._data;if(Kt(n))this._data=X9(n);else if(s!==n){if(s){jm(s,this);const i=this._cachedMeta;_l(i),i._parsed=[]}n&&Object.isExtensible(n)&&Rw(n,this),this._syncList=[],this._data=n}}addElements(){const t=this._cachedMeta;this._dataCheck(),this.datasetElementType&&(t.dataset=new this.datasetElementType)}buildOrUpdateElements(t){const n=this._cachedMeta,s=this.getDataset();let i=!1;this._dataCheck();const a=n._stacked;n._stacked=Mg(n.vScale,n),n.stack!==s.stack&&(i=!0,_l(n),n.stack=s.stack),this._resyncElements(t),(i||a!==n._stacked)&&Eg(this,n._parsed)}configure(){const t=this.chart.config,n=t.datasetScopeKeys(this._type),s=t.getOptionScopes(this.getDataset(),n,!0);this.options=t.createResolver(s,this.getContext()),this._parsing=this.options.parsing,this._cachedDataOpts={}}parse(t,n){const{_cachedMeta:s,_data:i}=this,{iScale:a,_stacked:o}=s,c=a.axis;let d=t===0&&n===i.length?!0:s._sorted,h=t>0&&s._parsed[t-1],f,m,v;if(this._parsing===!1)s._parsed=i,s._sorted=!0,v=i;else{Se(i[t])?v=this.parseArrayData(s,i,t,n):Kt(i[t])?v=this.parseObjectData(s,i,t,n):v=this.parsePrimitiveData(s,i,t,n);const y=()=>m[c]===null||h&&m[c]<h[c];for(f=0;f<n;++f)s._parsed[f+t]=m=v[f],d&&(y()&&(d=!1),h=m);s._sorted=d}o&&Eg(this,v)}parsePrimitiveData(t,n,s,i){const{iScale:a,vScale:o}=t,c=a.axis,d=o.axis,h=a.getLabels(),f=a===o,m=new Array(i);let v,y,w;for(v=0,y=i;v<y;++v)w=v+s,m[v]={[c]:f||a.parse(h[w],w),[d]:o.parse(n[w],w)};return m}parseArrayData(t,n,s,i){const{xScale:a,yScale:o}=t,c=new Array(i);let d,h,f,m;for(d=0,h=i;d<h;++d)f=d+s,m=n[f],c[d]={x:a.parse(m[0],f),y:o.parse(m[1],f)};return c}parseObjectData(t,n,s,i){const{xScale:a,yScale:o}=t,{xAxisKey:c="x",yAxisKey:d="y"}=this._parsing,h=new Array(i);let f,m,v,y;for(f=0,m=i;f<m;++f)v=f+s,y=n[v],h[f]={x:a.parse(ta(y,c),v),y:o.parse(ta(y,d),v)};return h}getParsed(t){return this._cachedMeta._parsed[t]}getDataElement(t){return this._cachedMeta.data[t]}applyStack(t,n,s){const i=this.chart,a=this._cachedMeta,o=n[t.axis],c={keys:Cg(i,!0),values:n._stacks[t.axis]._visualValues};return Og(c,o,a.index,{mode:s})}updateRangeFromParsed(t,n,s,i){const a=s[n.axis];let o=a===null?NaN:a;const c=i&&s._stacks[n.axis];i&&c&&(i.values=c,o=Og(i,a,this._cachedMeta.index)),t.min=Math.min(t.min,o),t.max=Math.max(t.max,o)}getMinMax(t,n){const s=this._cachedMeta,i=s._parsed,a=s._sorted&&t===s.iScale,o=i.length,c=this._getOtherScale(t),d=ex(n,s,this.chart),h={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY},{min:f,max:m}=Q9(c);let v,y;function w(){y=i[v];const x=y[c.axis];return!Pe(y[t.axis])||f>x||m<x}for(v=0;v<o&&!(!w()&&(this.updateRangeFromParsed(h,t,y,d),a));++v);if(a){for(v=o-1;v>=0;--v)if(!w()){this.updateRangeFromParsed(h,t,y,d);break}}return h}getAllParsedValues(t){const n=this._cachedMeta._parsed,s=[];let i,a,o;for(i=0,a=n.length;i<a;++i)o=n[i][t.axis],Pe(o)&&s.push(o);return s}getMaxOverflow(){return!1}getLabelAndValue(t){const n=this._cachedMeta,s=n.iScale,i=n.vScale,a=this.getParsed(t);return{label:s?""+s.getLabelForValue(a[s.axis]):"",value:i?""+i.getLabelForValue(a[i.axis]):""}}_update(t){const n=this._cachedMeta;this.update(t||"default"),n._clip=Z9(Vt(this.options.clip,K9(n.xScale,n.yScale,this.getMaxOverflow())))}update(t){}draw(){const t=this._ctx,n=this.chart,s=this._cachedMeta,i=s.data||[],a=n.chartArea,o=[],c=this._drawStart||0,d=this._drawCount||i.length-c,h=this.options.drawActiveElementsOnTop;let f;for(s.dataset&&s.dataset.draw(t,a,c,d),f=c;f<c+d;++f){const m=i[f];m.hidden||(m.active&&h?o.push(m):m.draw(t,a))}for(f=0;f<o.length;++f)o[f].draw(t,a)}getStyle(t,n){const s=n?"active":"default";return t===void 0&&this._cachedMeta.dataset?this.resolveDatasetElementOptions(s):this.resolveDataElementOptions(t||0,s)}getContext(t,n,s){const i=this.getDataset();let a;if(t>=0&&t<this._cachedMeta.data.length){const o=this._cachedMeta.data[t];a=o.$context||(o.$context=tx(this.getContext(),t,o)),a.parsed=this.getParsed(t),a.raw=i.data[t],a.index=a.dataIndex=t}else a=this.$context||(this.$context=$9(this.chart.getContext(),this.index)),a.dataset=i,a.index=a.datasetIndex=this.index;return a.active=!!n,a.mode=s,a}resolveDatasetElementOptions(t){return this._resolveElementOptions(this.datasetElementType.id,t)}resolveDataElementOptions(t,n){return this._resolveElementOptions(this.dataElementType.id,n,t)}_resolveElementOptions(t,n="default",s){const i=n==="active",a=this._cachedDataOpts,o=t+"-"+n,c=a[o],d=this.enableOptionSharing&&dl(s);if(c)return Tg(c,d);const h=this.chart.config,f=h.datasetElementScopeKeys(this._type,t),m=i?[`${t}Hover`,"hover",t,""]:[t,""],v=h.getOptionScopes(this.getDataset(),f),y=Object.keys(ze.elements[t]),w=()=>this.getContext(s,i,n),x=h.resolveNamedOptions(v,y,w,m);return x.$shared&&(x.$shared=d,a[o]=Object.freeze(Tg(x,d))),x}_resolveAnimations(t,n,s){const i=this.chart,a=this._cachedDataOpts,o=`animation-${n}`,c=a[o];if(c)return c;let d;if(i.options.animation!==!1){const f=this.chart.config,m=f.datasetAnimationScopeKeys(this._type,n),v=f.getOptionScopes(this.getDataset(),m);d=f.createResolver(v,this.getContext(t,s,n))}const h=new Sg(i,d&&d.animations);return d&&d._cacheable&&(a[o]=Object.freeze(h)),h}getSharedOptions(t){if(!!t.$shared)return this._sharedOptions||(this._sharedOptions=Object.assign({},t))}includeOptions(t,n){return!n||_h(t)||this.chart._animationsDisabled}_getSharedOptions(t,n){const s=this.resolveDataElementOptions(t,n),i=this._sharedOptions,a=this.getSharedOptions(s),o=this.includeOptions(n,a)||a!==i;return this.updateSharedOptions(a,n,s),{sharedOptions:a,includeOptions:o}}updateElement(t,n,s,i){_h(i)?Object.assign(t,s):this._resolveAnimations(n,i).update(t,s)}updateSharedOptions(t,n,s){t&&!_h(n)&&this._resolveAnimations(void 0,n).update(t,s)}_setStyle(t,n,s,i){t.active=i;const a=this.getStyle(n,i);this._resolveAnimations(n,s,i).update(t,{options:!i&&this.getSharedOptions(a)||a})}removeHoverStyle(t,n,s){this._setStyle(t,s,"active",!1)}setHoverStyle(t,n,s){this._setStyle(t,s,"active",!0)}_removeDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!1)}_setDatasetHoverStyle(){const t=this._cachedMeta.dataset;t&&this._setStyle(t,void 0,"active",!0)}_resyncElements(t){const n=this._data,s=this._cachedMeta.data;for(const[c,d,h]of this._syncList)this[c](d,h);this._syncList=[];const i=s.length,a=n.length,o=Math.min(a,i);o&&this.parse(0,o),a>i?this._insertElements(i,a-i,t):a<i&&this._removeElements(a,i-a)}_insertElements(t,n,s=!0){const i=this._cachedMeta,a=i.data,o=t+n;let c;const d=h=>{for(h.length+=n,c=h.length-1;c>=o;c--)h[c]=h[c-n]};for(d(a),c=t;c<o;++c)a[c]=new this.dataElementType;this._parsing&&d(i._parsed),this.parse(t,n),s&&this.updateElements(a,t,n,"reset")}updateElements(t,n,s,i){}_removeElements(t,n){const s=this._cachedMeta;if(this._parsing){const i=s._parsed.splice(t,n);s._stacked&&_l(s,i)}s.data.splice(t,n)}_sync(t){if(this._parsing)this._syncList.push(t);else{const[n,s,i]=t;this[n](s,i)}this.chart._dataChanges.push([this.index,...t])}_onDataPush(){const t=arguments.length;this._sync(["_insertElements",this.getDataset().data.length-t,t])}_onDataPop(){this._sync(["_removeElements",this._cachedMeta.data.length-1,1])}_onDataShift(){this._sync(["_removeElements",0,1])}_onDataSplice(t,n){n&&this._sync(["_removeElements",t,n]);const s=arguments.length-2;s&&this._sync(["_insertElements",t,s])}_onDataUnshift(){this._sync(["_insertElements",0,arguments.length])}}nt(Rs,"defaults",{}),nt(Rs,"datasetElementType",null),nt(Rs,"dataElementType",null);function nx(e,t){if(!e._cache.$bar){const n=e.getMatchingVisibleMetas(t);let s=[];for(let i=0,a=n.length;i<a;i++)s=s.concat(n[i].controller.getAllParsedValues(e));e._cache.$bar=Ym(s.sort((i,a)=>i-a))}return e._cache.$bar}function sx(e){const t=e.iScale,n=nx(t,e.type);let s=t._length,i,a,o,c;const d=()=>{o===32767||o===-32768||(dl(c)&&(s=Math.min(s,Math.abs(o-c)||s)),c=o)};for(i=0,a=n.length;i<a;++i)o=t.getPixelForValue(n[i]),d();for(c=void 0,i=0,a=t.ticks.length;i<a;++i)o=t.getPixelForTick(i),d();return s}function ix(e,t,n,s){const i=n.barThickness;let a,o;return ee(i)?(a=t.min*n.categoryPercentage,o=n.barPercentage):(a=i*s,o=1),{chunk:a/s,ratio:o,start:t.pixels[e]-a/2}}function ax(e,t,n,s){const i=t.pixels,a=i[e];let o=e>0?i[e-1]:null,c=e<i.length-1?i[e+1]:null;const d=n.categoryPercentage;o===null&&(o=a-(c===null?t.end-t.start:c-a)),c===null&&(c=a+a-o);const h=a-(a-Math.min(o,c))/2*d;return{chunk:Math.abs(c-o)/2*d/s,ratio:n.barPercentage,start:h}}function ox(e,t,n,s){const i=n.parse(e[0],s),a=n.parse(e[1],s),o=Math.min(i,a),c=Math.max(i,a);let d=o,h=c;Math.abs(o)>Math.abs(c)&&(d=c,h=o),t[n.axis]=h,t._custom={barStart:d,barEnd:h,start:i,end:a,min:o,max:c}}function Ig(e,t,n,s){return Se(e)?ox(e,t,n,s):t[n.axis]=n.parse(e,s),t}function Ag(e,t,n,s){const i=e.iScale,a=e.vScale,o=i.getLabels(),c=i===a,d=[];let h,f,m,v;for(h=n,f=n+s;h<f;++h)v=t[h],m={},m[i.axis]=c||i.parse(o[h],h),d.push(Ig(v,m,a,h));return d}function yh(e){return e&&e.barStart!==void 0&&e.barEnd!==void 0}function rx(e,t,n){return e!==0?oi(e):(t.isHorizontal()?1:-1)*(t.min>=n?1:-1)}function lx(e){let t,n,s,i,a;return e.horizontal?(t=e.base>e.x,n="left",s="right"):(t=e.base<e.y,n="bottom",s="top"),t?(i="end",a="start"):(i="start",a="end"),{start:n,end:s,reverse:t,top:i,bottom:a}}function cx(e,t,n,s){let i=t.borderSkipped;const a={};if(!i){e.borderSkipped=a;return}if(i===!0){e.borderSkipped={top:!0,right:!0,bottom:!0,left:!0};return}const{start:o,end:c,reverse:d,top:h,bottom:f}=lx(e);i==="middle"&&n&&(e.enableBorderRadius=!0,(n._top||0)===s?i=h:(n._bottom||0)===s?i=f:(a[Vg(f,o,c,d)]=!0,i=h)),a[Vg(i,o,c,d)]=!0,e.borderSkipped=a}function Vg(e,t,n,s){return s?(e=dx(e,t,n),e=Bg(e,n,t)):e=Bg(e,t,n),e}function dx(e,t,n){return e===t?n:e===n?t:e}function Bg(e,t,n){return e==="start"?t:e==="end"?n:e}function ux(e,{inflateAmount:t},n){e.inflateAmount=t==="auto"?n===1?.33:0:t}class yl extends Rs{parsePrimitiveData(t,n,s,i){return Ag(t,n,s,i)}parseArrayData(t,n,s,i){return Ag(t,n,s,i)}parseObjectData(t,n,s,i){const{iScale:a,vScale:o}=t,{xAxisKey:c="x",yAxisKey:d="y"}=this._parsing,h=a.axis==="x"?c:d,f=o.axis==="x"?c:d,m=[];let v,y,w,x;for(v=s,y=s+i;v<y;++v)x=n[v],w={},w[a.axis]=a.parse(ta(x,h),v),m.push(Ig(ta(x,f),w,o,v));return m}updateRangeFromParsed(t,n,s,i){super.updateRangeFromParsed(t,n,s,i);const a=s._custom;a&&n===this._cachedMeta.vScale&&(t.min=Math.min(t.min,a.min),t.max=Math.max(t.max,a.max))}getMaxOverflow(){return 0}getLabelAndValue(t){const n=this._cachedMeta,{iScale:s,vScale:i}=n,a=this.getParsed(t),o=a._custom,c=yh(o)?"["+o.start+", "+o.end+"]":""+i.getLabelForValue(a[i.axis]);return{label:""+s.getLabelForValue(a[s.axis]),value:c}}initialize(){this.enableOptionSharing=!0,super.initialize();const t=this._cachedMeta;t.stack=this.getDataset().stack}update(t){const n=this._cachedMeta;this.updateElements(n.data,0,n.data.length,t)}updateElements(t,n,s,i){const a=i==="reset",{index:o,_cachedMeta:{vScale:c}}=this,d=c.getBasePixel(),h=c.isHorizontal(),f=this._getRuler(),{sharedOptions:m,includeOptions:v}=this._getSharedOptions(n,i);for(let y=n;y<n+s;y++){const w=this.getParsed(y),x=a||ee(w[c.axis])?{base:d,head:d}:this._calculateBarValuePixels(y),k=this._calculateBarIndexPixels(y,f),D=(w._stacks||{})[c.axis],E={horizontal:h,base:x.base,enableBorderRadius:!D||yh(w._custom)||o===D._top||o===D._bottom,x:h?x.head:k.center,y:h?k.center:x.head,height:h?k.size:Math.abs(x.size),width:h?Math.abs(x.size):k.size};v&&(E.options=m||this.resolveDataElementOptions(y,t[y].active?"active":i));const B=E.options||t[y].options;cx(E,B,D,o),ux(E,B,f.ratio),this.updateElement(t[y],y,E,i)}}_getStacks(t,n){const{iScale:s}=this._cachedMeta,i=s.getMatchingVisibleMetas(this._type).filter(d=>d.controller.options.grouped),a=s.options.stacked,o=[],c=d=>{const h=d.controller.getParsed(n),f=h&&h[d.vScale.axis];if(ee(f)||isNaN(f))return!0};for(const d of i)if(!(n!==void 0&&c(d))&&((a===!1||o.indexOf(d.stack)===-1||a===void 0&&d.stack===void 0)&&o.push(d.stack),d.index===t))break;return o.length||o.push(void 0),o}_getStackCount(t){return this._getStacks(void 0,t).length}_getStackIndex(t,n,s){const i=this._getStacks(t,s),a=n!==void 0?i.indexOf(n):-1;return a===-1?i.length-1:a}_getRuler(){const t=this.options,n=this._cachedMeta,s=n.iScale,i=[];let a,o;for(a=0,o=n.data.length;a<o;++a)i.push(s.getPixelForValue(this.getParsed(a)[s.axis],a));const c=t.barThickness;return{min:c||sx(n),pixels:i,start:s._startPixel,end:s._endPixel,stackCount:this._getStackCount(),scale:s,grouped:t.grouped,ratio:c?1:t.categoryPercentage*t.barPercentage}}_calculateBarValuePixels(t){const{_cachedMeta:{vScale:n,_stacked:s,index:i},options:{base:a,minBarLength:o}}=this,c=a||0,d=this.getParsed(t),h=d._custom,f=yh(h);let m=d[n.axis],v=0,y=s?this.applyStack(n,d,s):m,w,x;y!==m&&(v=y-m,y=m),f&&(m=h.barStart,y=h.barEnd-h.barStart,m!==0&&oi(m)!==oi(h.barEnd)&&(v=0),v+=m);const k=!ee(a)&&!f?a:v;let D=n.getPixelForValue(k);if(this.chart.getDataVisibility(t)?w=n.getPixelForValue(v+y):w=D,x=w-D,Math.abs(x)<o){x=rx(x,n,c)*o,m===c&&(D-=x/2);const E=n.getPixelForDecimal(0),B=n.getPixelForDecimal(1),S=Math.min(E,B),A=Math.max(E,B);D=Math.max(Math.min(D,A),S),w=D+x,s&&!f&&(d._stacks[n.axis]._visualValues[i]=n.getValueForPixel(w)-n.getValueForPixel(D))}if(D===n.getPixelForValue(c)){const E=oi(x)*n.getLineWidthForValue(c)/2;D+=E,x-=E}return{size:x,base:D,head:w,center:w+x/2}}_calculateBarIndexPixels(t,n){const s=n.scale,i=this.options,a=i.skipNull,o=Vt(i.maxBarThickness,1/0);let c,d;if(n.grouped){const h=a?this._getStackCount(t):n.stackCount,f=i.barThickness==="flex"?ax(t,n,i,h):ix(t,n,i,h),m=this._getStackIndex(this.index,this._cachedMeta.stack,a?t:void 0);c=f.start+f.chunk*m+f.chunk/2,d=Math.min(o,f.chunk*f.ratio)}else c=s.getPixelForValue(this.getParsed(t)[s.axis],t),d=Math.min(o,n.min*n.ratio);return{base:c-d/2,head:c+d/2,center:c,size:d}}draw(){const t=this._cachedMeta,n=t.vScale,s=t.data,i=s.length;let a=0;for(;a<i;++a)this.getParsed(a)[n.axis]!==null&&s[a].draw(this._ctx)}}nt(yl,"id","bar"),nt(yl,"defaults",{datasetElementType:!1,dataElementType:"bar",categoryPercentage:.8,barPercentage:.9,grouped:!0,animations:{numbers:{type:"number",properties:["x","y","base","width","height"]}}}),nt(yl,"overrides",{scales:{_index_:{type:"category",offset:!0,grid:{offset:!0}},_value_:{type:"linear",beginAtZero:!0}}});class _d extends Rs{initialize(){this.enableOptionSharing=!0,super.initialize()}parsePrimitiveData(t,n,s,i){const a=super.parsePrimitiveData(t,n,s,i);for(let o=0;o<a.length;o++)a[o]._custom=this.resolveDataElementOptions(o+s).radius;return a}parseArrayData(t,n,s,i){const a=super.parseArrayData(t,n,s,i);for(let o=0;o<a.length;o++){const c=n[s+o];a[o]._custom=Vt(c[2],this.resolveDataElementOptions(o+s).radius)}return a}parseObjectData(t,n,s,i){const a=super.parseObjectData(t,n,s,i);for(let o=0;o<a.length;o++){const c=n[s+o];a[o]._custom=Vt(c&&c.r&&+c.r,this.resolveDataElementOptions(o+s).radius)}return a}getMaxOverflow(){const t=this._cachedMeta.data;let n=0;for(let s=t.length-1;s>=0;--s)n=Math.max(n,t[s].size(this.resolveDataElementOptions(s))/2);return n>0&&n}getLabelAndValue(t){const n=this._cachedMeta,s=this.chart.data.labels||[],{xScale:i,yScale:a}=n,o=this.getParsed(t),c=i.getLabelForValue(o.x),d=a.getLabelForValue(o.y),h=o._custom;return{label:s[t]||"",value:"("+c+", "+d+(h?", "+h:"")+")"}}update(t){const n=this._cachedMeta.data;this.updateElements(n,0,n.length,t)}updateElements(t,n,s,i){const a=i==="reset",{iScale:o,vScale:c}=this._cachedMeta,{sharedOptions:d,includeOptions:h}=this._getSharedOptions(n,i),f=o.axis,m=c.axis;for(let v=n;v<n+s;v++){const y=t[v],w=!a&&this.getParsed(v),x={},k=x[f]=a?o.getPixelForDecimal(.5):o.getPixelForValue(w[f]),D=x[m]=a?c.getBasePixel():c.getPixelForValue(w[m]);x.skip=isNaN(k)||isNaN(D),h&&(x.options=d||this.resolveDataElementOptions(v,y.active?"active":i),a&&(x.options.radius=0)),this.updateElement(y,v,x,i)}}resolveDataElementOptions(t,n){const s=this.getParsed(t);let i=super.resolveDataElementOptions(t,n);i.$shared&&(i=Object.assign({},i,{$shared:!1}));const a=i.radius;return n!=="active"&&(i.radius=0),i.radius+=Vt(s&&s._custom,a),i}}nt(_d,"id","bubble"),nt(_d,"defaults",{datasetElementType:!1,dataElementType:"point",animations:{numbers:{type:"number",properties:["x","y","borderWidth","radius"]}}}),nt(_d,"overrides",{scales:{x:{type:"linear"},y:{type:"linear"}}});function hx(e,t,n){let s=1,i=1,a=0,o=0;if(t<ke){const c=e,d=c+t,h=Math.cos(c),f=Math.sin(c),m=Math.cos(d),v=Math.sin(d),y=(B,S,A)=>hl(B,c,d,!0)?1:Math.max(S,S*n,A,A*n),w=(B,S,A)=>hl(B,c,d,!0)?-1:Math.min(S,S*n,A,A*n),x=y(0,h,m),k=y(Ne,f,v),D=w(De,h,m),E=w(De+Ne,f,v);s=(x-D)/2,i=(k-E)/2,a=-(x+D)/2,o=-(k+E)/2}return{ratioX:s,ratioY:i,offsetX:a,offsetY:o}}class Ga extends Rs{constructor(t,n){super(t,n),this.enableOptionSharing=!0,this.innerRadius=void 0,this.outerRadius=void 0,this.offsetX=void 0,this.offsetY=void 0}linkScales(){}parse(t,n){const s=this.getDataset().data,i=this._cachedMeta;if(this._parsing===!1)i._parsed=s;else{let a=d=>+s[d];if(Kt(s[t])){const{key:d="value"}=this._parsing;a=h=>+ta(s[h],d)}let o,c;for(o=t,c=t+n;o<c;++o)i._parsed[o]=a(o)}}_getRotation(){return Fs(this.options.rotation-90)}_getCircumference(){return Fs(this.options.circumference)}_getRotationExtents(){let t=ke,n=-ke;for(let s=0;s<this.chart.data.datasets.length;++s)if(this.chart.isDatasetVisible(s)&&this.chart.getDatasetMeta(s).type===this._type){const i=this.chart.getDatasetMeta(s).controller,a=i._getRotation(),o=i._getCircumference();t=Math.min(t,a),n=Math.max(n,a+o)}return{rotation:t,circumference:n-t}}update(t){const n=this.chart,{chartArea:s}=n,i=this._cachedMeta,a=i.data,o=this.getMaxBorderWidth()+this.getMaxOffset(a)+this.options.spacing,c=Math.max((Math.min(s.width,s.height)-o)/2,0),d=Math.min(Ow(this.options.cutout,c),1),h=this._getRingWeight(this.index),{circumference:f,rotation:m}=this._getRotationExtents(),{ratioX:v,ratioY:y,offsetX:w,offsetY:x}=hx(m,f,d),k=(s.width-o)/v,D=(s.height-o)/y,E=Math.max(Math.min(k,D)/2,0),B=Vm(this.options.radius,E),S=Math.max(B*d,0),A=(B-S)/this._getVisibleDatasetWeightTotal();this.offsetX=w*B,this.offsetY=x*B,i.total=this.calculateTotal(),this.outerRadius=B-A*this._getRingWeightOffset(this.index),this.innerRadius=Math.max(this.outerRadius-A*h,0),this.updateElements(a,0,a.length,t)}_circumference(t,n){const s=this.options,i=this._cachedMeta,a=this._getCircumference();return n&&s.animation.animateRotate||!this.chart.getDataVisibility(t)||i._parsed[t]===null||i.data[t].hidden?0:this.calculateCircumference(i._parsed[t]*a/ke)}updateElements(t,n,s,i){const a=i==="reset",o=this.chart,c=o.chartArea,h=o.options.animation,f=(c.left+c.right)/2,m=(c.top+c.bottom)/2,v=a&&h.animateScale,y=v?0:this.innerRadius,w=v?0:this.outerRadius,{sharedOptions:x,includeOptions:k}=this._getSharedOptions(n,i);let D=this._getRotation(),E;for(E=0;E<n;++E)D+=this._circumference(E,a);for(E=n;E<n+s;++E){const B=this._circumference(E,a),S=t[E],A={x:f+this.offsetX,y:m+this.offsetY,startAngle:D,endAngle:D+B,circumference:B,outerRadius:w,innerRadius:y};k&&(A.options=x||this.resolveDataElementOptions(E,S.active?"active":i)),D+=B,this.updateElement(S,E,A,i)}}calculateTotal(){const t=this._cachedMeta,n=t.data;let s=0,i;for(i=0;i<n.length;i++){const a=t._parsed[i];a!==null&&!isNaN(a)&&this.chart.getDataVisibility(i)&&!n[i].hidden&&(s+=Math.abs(a))}return s}calculateCircumference(t){const n=this._cachedMeta.total;return n>0&&!isNaN(t)?ke*(Math.abs(t)/n):0}getLabelAndValue(t){const n=this._cachedMeta,s=this.chart,i=s.data.labels||[],a=pl(n._parsed[t],s.options.locale);return{label:i[t]||"",value:a}}getMaxBorderWidth(t){let n=0;const s=this.chart;let i,a,o,c,d;if(!t){for(i=0,a=s.data.datasets.length;i<a;++i)if(s.isDatasetVisible(i)){o=s.getDatasetMeta(i),t=o.data,c=o.controller;break}}if(!t)return 0;for(i=0,a=t.length;i<a;++i)d=c.resolveDataElementOptions(i),d.borderAlign!=="inner"&&(n=Math.max(n,d.borderWidth||0,d.hoverBorderWidth||0));return n}getMaxOffset(t){let n=0;for(let s=0,i=t.length;s<i;++s){const a=this.resolveDataElementOptions(s);n=Math.max(n,a.offset||0,a.hoverOffset||0)}return n}_getRingWeightOffset(t){let n=0;for(let s=0;s<t;++s)this.chart.isDatasetVisible(s)&&(n+=this._getRingWeight(s));return n}_getRingWeight(t){return Math.max(Vt(this.chart.data.datasets[t].weight,1),0)}_getVisibleDatasetWeightTotal(){return this._getRingWeightOffset(this.chart.data.datasets.length)||1}}nt(Ga,"id","doughnut"),nt(Ga,"defaults",{datasetElementType:!1,dataElementType:"arc",animation:{animateRotate:!0,animateScale:!1},animations:{numbers:{type:"number",properties:["circumference","endAngle","innerRadius","outerRadius","startAngle","x","y","offset","borderWidth","spacing"]}},cutout:"50%",rotation:0,circumference:360,radius:"100%",spacing:0,indexAxis:"r"}),nt(Ga,"descriptors",{_scriptable:t=>t!=="spacing",_indexable:t=>t!=="spacing"&&!t.startsWith("borderDash")&&!t.startsWith("hoverBorderDash")}),nt(Ga,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data;if(n.labels.length&&n.datasets.length){const{labels:{pointStyle:s,color:i}}=t.legend.options;return n.labels.map((a,o)=>{const d=t.getDatasetMeta(0).controller.getStyle(o);return{text:a,fillStyle:d.backgroundColor,strokeStyle:d.borderColor,fontColor:i,lineWidth:d.borderWidth,pointStyle:s,hidden:!t.getDataVisibility(o),index:o}})}return[]}},onClick(t,n,s){s.chart.toggleDataVisibility(n.index),s.chart.update()}}}});class bl extends Rs{initialize(){this.enableOptionSharing=!0,this.supportsDecimation=!0,super.initialize()}update(t){const n=this._cachedMeta,{dataset:s,data:i=[],_dataset:a}=n,o=this.chart._animationsDisabled;let{start:c,count:d}=Km(n,i,o);this._drawStart=c,this._drawCount=d,Zm(n)&&(c=0,d=i.length),s._chart=this.chart,s._datasetIndex=this.index,s._decimated=!!a._decimated,s.points=i;const h=this.resolveDatasetElementOptions(t);this.options.showLine||(h.borderWidth=0),h.segment=this.options.segment,this.updateElement(s,void 0,{animated:!o,options:h},t),this.updateElements(i,c,d,t)}updateElements(t,n,s,i){const a=i==="reset",{iScale:o,vScale:c,_stacked:d,_dataset:h}=this._cachedMeta,{sharedOptions:f,includeOptions:m}=this._getSharedOptions(n,i),v=o.axis,y=c.axis,{spanGaps:w,segment:x}=this.options,k=zo(w)?w:Number.POSITIVE_INFINITY,D=this.chart._animationsDisabled||a||i==="none",E=n+s,B=t.length;let S=n>0&&this.getParsed(n-1);for(let A=0;A<B;++A){const I=t[A],F=D?I:{};if(A<n||A>=E){F.skip=!0;continue}const L=this.getParsed(A),W=ee(L[y]),X=F[v]=o.getPixelForValue(L[v],A),Z=F[y]=a||W?c.getBasePixel():c.getPixelForValue(d?this.applyStack(c,L,d):L[y],A);F.skip=isNaN(X)||isNaN(Z)||W,F.stop=A>0&&Math.abs(L[v]-S[v])>k,x&&(F.parsed=L,F.raw=h.data[A]),m&&(F.options=f||this.resolveDataElementOptions(A,I.active?"active":i)),D||this.updateElement(I,A,F,i),S=L}}getMaxOverflow(){const t=this._cachedMeta,n=t.dataset,s=n.options&&n.options.borderWidth||0,i=t.data||[];if(!i.length)return s;const a=i[0].size(this.resolveDataElementOptions(0)),o=i[i.length-1].size(this.resolveDataElementOptions(i.length-1));return Math.max(s,a,o)/2}draw(){const t=this._cachedMeta;t.dataset.updateControlPoints(this.chart.chartArea,t.iScale.axis),super.draw()}}nt(bl,"id","line"),nt(bl,"defaults",{datasetElementType:"line",dataElementType:"point",showLine:!0,spanGaps:!1}),nt(bl,"overrides",{scales:{_index_:{type:"category"},_value_:{type:"linear"}}});class Ho extends Rs{constructor(t,n){super(t,n),this.innerRadius=void 0,this.outerRadius=void 0}getLabelAndValue(t){const n=this._cachedMeta,s=this.chart,i=s.data.labels||[],a=pl(n._parsed[t].r,s.options.locale);return{label:i[t]||"",value:a}}parseObjectData(t,n,s,i){return cg.bind(this)(t,n,s,i)}update(t){const n=this._cachedMeta.data;this._updateRadius(),this.updateElements(n,0,n.length,t)}getMinMax(){const t=this._cachedMeta,n={min:Number.POSITIVE_INFINITY,max:Number.NEGATIVE_INFINITY};return t.data.forEach((s,i)=>{const a=this.getParsed(i).r;!isNaN(a)&&this.chart.getDataVisibility(i)&&(a<n.min&&(n.min=a),a>n.max&&(n.max=a))}),n}_updateRadius(){const t=this.chart,n=t.chartArea,s=t.options,i=Math.min(n.right-n.left,n.bottom-n.top),a=Math.max(i/2,0),o=Math.max(s.cutoutPercentage?a/100*s.cutoutPercentage:1,0),c=(a-o)/t.getVisibleDatasetCount();this.outerRadius=a-c*this.index,this.innerRadius=this.outerRadius-c}updateElements(t,n,s,i){const a=i==="reset",o=this.chart,d=o.options.animation,h=this._cachedMeta.rScale,f=h.xCenter,m=h.yCenter,v=h.getIndexAngle(0)-.5*De;let y=v,w;const x=360/this.countVisibleElements();for(w=0;w<n;++w)y+=this._computeAngle(w,i,x);for(w=n;w<n+s;w++){const k=t[w];let D=y,E=y+this._computeAngle(w,i,x),B=o.getDataVisibility(w)?h.getDistanceFromCenterForValue(this.getParsed(w).r):0;y=E,a&&(d.animateScale&&(B=0),d.animateRotate&&(D=E=v));const S={x:f,y:m,innerRadius:0,outerRadius:B,startAngle:D,endAngle:E,options:this.resolveDataElementOptions(w,k.active?"active":i)};this.updateElement(k,w,S,i)}}countVisibleElements(){const t=this._cachedMeta;let n=0;return t.data.forEach((s,i)=>{!isNaN(this.getParsed(i).r)&&this.chart.getDataVisibility(i)&&n++}),n}_computeAngle(t,n,s){return this.chart.getDataVisibility(t)?Fs(this.resolveDataElementOptions(t,n).angle||s):0}}nt(Ho,"id","polarArea"),nt(Ho,"defaults",{dataElementType:"arc",animation:{animateRotate:!0,animateScale:!0},animations:{numbers:{type:"number",properties:["x","y","startAngle","endAngle","innerRadius","outerRadius"]}},indexAxis:"r",startAngle:0}),nt(Ho,"overrides",{aspectRatio:1,plugins:{legend:{labels:{generateLabels(t){const n=t.data;if(n.labels.length&&n.datasets.length){const{labels:{pointStyle:s,color:i}}=t.legend.options;return n.labels.map((a,o)=>{const d=t.getDatasetMeta(0).controller.getStyle(o);return{text:a,fillStyle:d.backgroundColor,strokeStyle:d.borderColor,fontColor:i,lineWidth:d.borderWidth,pointStyle:s,hidden:!t.getDataVisibility(o),index:o}})}return[]}},onClick(t,n,s){s.chart.toggleDataVisibility(n.index),s.chart.update()}}},scales:{r:{type:"radialLinear",angleLines:{display:!1},beginAtZero:!0,grid:{circular:!0},pointLabels:{display:!1},startAngle:0}}});class yd extends Ga{}nt(yd,"id","pie"),nt(yd,"defaults",{cutout:0,rotation:0,circumference:360,radius:"100%"});class bd extends Rs{getLabelAndValue(t){const n=this._cachedMeta.vScale,s=this.getParsed(t);return{label:n.getLabels()[t],value:""+n.getLabelForValue(s[n.axis])}}parseObjectData(t,n,s,i){return cg.bind(this)(t,n,s,i)}update(t){const n=this._cachedMeta,s=n.dataset,i=n.data||[],a=n.iScale.getLabels();if(s.points=i,t!=="resize"){const o=this.resolveDatasetElementOptions(t);this.options.showLine||(o.borderWidth=0);const c={_loop:!0,_fullLoop:a.length===i.length,options:o};this.updateElement(s,void 0,c,t)}this.updateElements(i,0,i.length,t)}updateElements(t,n,s,i){const a=this._cachedMeta.rScale,o=i==="reset";for(let c=n;c<n+s;c++){const d=t[c],h=this.resolveDataElementOptions(c,d.active?"active":i),f=a.getPointPositionForValue(c,this.getParsed(c).r),m=o?a.xCenter:f.x,v=o?a.yCenter:f.y,y={x:m,y:v,angle:f.angle,skip:isNaN(m)||isNaN(v),options:h};this.updateElement(d,c,y,i)}}}nt(bd,"id","radar"),nt(bd,"defaults",{datasetElementType:"line",dataElementType:"point",indexAxis:"r",showLine:!0,elements:{line:{fill:"start"}}}),nt(bd,"overrides",{aspectRatio:1,scales:{r:{type:"radialLinear"}}});class wd extends Rs{getLabelAndValue(t){const n=this._cachedMeta,s=this.chart.data.labels||[],{xScale:i,yScale:a}=n,o=this.getParsed(t),c=i.getLabelForValue(o.x),d=a.getLabelForValue(o.y);return{label:s[t]||"",value:"("+c+", "+d+")"}}update(t){const n=this._cachedMeta,{data:s=[]}=n,i=this.chart._animationsDisabled;let{start:a,count:o}=Km(n,s,i);if(this._drawStart=a,this._drawCount=o,Zm(n)&&(a=0,o=s.length),this.options.showLine){const{dataset:c,_dataset:d}=n;c._chart=this.chart,c._datasetIndex=this.index,c._decimated=!!d._decimated,c.points=s;const h=this.resolveDatasetElementOptions(t);h.segment=this.options.segment,this.updateElement(c,void 0,{animated:!i,options:h},t)}this.updateElements(s,a,o,t)}addElements(){const{showLine:t}=this.options;!this.datasetElementType&&t&&(this.datasetElementType=this.chart.registry.getElement("line")),super.addElements()}updateElements(t,n,s,i){const a=i==="reset",{iScale:o,vScale:c,_stacked:d,_dataset:h}=this._cachedMeta,f=this.resolveDataElementOptions(n,i),m=this.getSharedOptions(f),v=this.includeOptions(i,m),y=o.axis,w=c.axis,{spanGaps:x,segment:k}=this.options,D=zo(x)?x:Number.POSITIVE_INFINITY,E=this.chart._animationsDisabled||a||i==="none";let B=n>0&&this.getParsed(n-1);for(let S=n;S<n+s;++S){const A=t[S],I=this.getParsed(S),F=E?A:{},L=ee(I[w]),W=F[y]=o.getPixelForValue(I[y],S),X=F[w]=a||L?c.getBasePixel():c.getPixelForValue(d?this.applyStack(c,I,d):I[w],S);F.skip=isNaN(W)||isNaN(X)||L,F.stop=S>0&&Math.abs(I[y]-B[y])>D,k&&(F.parsed=I,F.raw=h.data[S]),v&&(F.options=m||this.resolveDataElementOptions(S,A.active?"active":i)),E||this.updateElement(A,S,F,i),B=I}this.updateSharedOptions(m,i,f)}getMaxOverflow(){const t=this._cachedMeta,n=t.data||[];if(!this.options.showLine){let c=0;for(let d=n.length-1;d>=0;--d)c=Math.max(c,n[d].size(this.resolveDataElementOptions(d))/2);return c>0&&c}const s=t.dataset,i=s.options&&s.options.borderWidth||0;if(!n.length)return i;const a=n[0].size(this.resolveDataElementOptions(0)),o=n[n.length-1].size(this.resolveDataElementOptions(n.length-1));return Math.max(i,a,o)/2}}nt(wd,"id","scatter"),nt(wd,"defaults",{datasetElementType:!1,dataElementType:"point",showLine:!1,fill:!1}),nt(wd,"overrides",{interaction:{mode:"point"},scales:{x:{type:"linear"},y:{type:"linear"}}});var fx=Object.freeze({__proto__:null,BarController:yl,BubbleController:_d,DoughnutController:Ga,LineController:bl,PieController:yd,PolarAreaController:Ho,RadarController:bd,ScatterController:wd});function Ka(){throw new Error("This method is not implemented: Check that a complete date adapter is provided.")}class bh{constructor(t){nt(this,"options");this.options=t||{}}static override(t){Object.assign(bh.prototype,t)}init(){}formats(){return Ka()}parse(){return Ka()}format(){return Ka()}add(){return Ka()}diff(){return Ka()}startOf(){return Ka()}endOf(){return Ka()}}var px={_date:bh};function mx(e,t,n,s){const{controller:i,data:a,_sorted:o}=e,c=i._cachedMeta.iScale;if(c&&t===c.axis&&t!=="r"&&o&&a.length){const d=c._reversePixels?Lw:Si;if(s){if(i._sharedOptions){const h=a[0],f=typeof h.getRange=="function"&&h.getRange(t);if(f){const m=d(a,t,n-f),v=d(a,t,n+f);return{lo:m.lo,hi:v.hi}}}}else return d(a,t,n)}return{lo:0,hi:a.length-1}}function wl(e,t,n,s,i){const a=e.getSortedVisibleDatasetMetas(),o=n[t];for(let c=0,d=a.length;c<d;++c){const{index:h,data:f}=a[c],{lo:m,hi:v}=mx(a[c],t,o,i);for(let y=m;y<=v;++y){const w=f[y];w.skip||s(w,h,y)}}}function gx(e){const t=e.indexOf("x")!==-1,n=e.indexOf("y")!==-1;return function(s,i){const a=t?Math.abs(s.x-i.x):0,o=n?Math.abs(s.y-i.y):0;return Math.sqrt(Math.pow(a,2)+Math.pow(o,2))}}function wh(e,t,n,s,i){const a=[];return!i&&!e.isPointInArea(t)||wl(e,n,t,function(c,d,h){!i&&!ki(c,e.chartArea,0)||c.inRange(t.x,t.y,s)&&a.push({element:c,datasetIndex:d,index:h})},!0),a}function vx(e,t,n,s){let i=[];function a(o,c,d){const{startAngle:h,endAngle:f}=o.getProps(["startAngle","endAngle"],s),{angle:m}=Hm(o,{x:t.x,y:t.y});hl(m,h,f)&&i.push({element:o,datasetIndex:c,index:d})}return wl(e,n,t,a),i}function _x(e,t,n,s,i,a){let o=[];const c=gx(n);let d=Number.POSITIVE_INFINITY;function h(f,m,v){const y=f.inRange(t.x,t.y,i);if(s&&!y)return;const w=f.getCenterPoint(i);if(!(!!a||e.isPointInArea(w))&&!y)return;const k=c(t,w);k<d?(o=[{element:f,datasetIndex:m,index:v}],d=k):k===d&&o.push({element:f,datasetIndex:m,index:v})}return wl(e,n,t,h),o}function xh(e,t,n,s,i,a){return!a&&!e.isPointInArea(t)?[]:n==="r"&&!s?vx(e,t,n,i):_x(e,t,n,s,i,a)}function Pg(e,t,n,s,i){const a=[],o=n==="x"?"inXRange":"inYRange";let c=!1;return wl(e,n,t,(d,h,f)=>{d[o](t[n],i)&&(a.push({element:d,datasetIndex:h,index:f}),c=c||d.inRange(t.x,t.y,i))}),s&&!c?[]:a}var yx={evaluateInteractionItems:wl,modes:{index(e,t,n,s){const i=Ya(t,e),a=n.axis||"x",o=n.includeInvisible||!1,c=n.intersect?wh(e,i,a,s,o):xh(e,i,a,!1,s,o),d=[];return c.length?(e.getSortedVisibleDatasetMetas().forEach(h=>{const f=c[0].index,m=h.data[f];m&&!m.skip&&d.push({element:m,datasetIndex:h.index,index:f})}),d):[]},dataset(e,t,n,s){const i=Ya(t,e),a=n.axis||"xy",o=n.includeInvisible||!1;let c=n.intersect?wh(e,i,a,s,o):xh(e,i,a,!1,s,o);if(c.length>0){const d=c[0].datasetIndex,h=e.getDatasetMeta(d).data;c=[];for(let f=0;f<h.length;++f)c.push({element:h[f],datasetIndex:d,index:f})}return c},point(e,t,n,s){const i=Ya(t,e),a=n.axis||"xy",o=n.includeInvisible||!1;return wh(e,i,a,s,o)},nearest(e,t,n,s){const i=Ya(t,e),a=n.axis||"xy",o=n.includeInvisible||!1;return xh(e,i,a,n.intersect,s,o)},x(e,t,n,s){const i=Ya(t,e);return Pg(e,i,"x",n.intersect,s)},y(e,t,n,s){const i=Ya(t,e);return Pg(e,i,"y",n.intersect,s)}}};const Ng=["left","top","right","bottom"];function xl(e,t){return e.filter(n=>n.pos===t)}function zg(e,t){return e.filter(n=>Ng.indexOf(n.pos)===-1&&n.box.axis===t)}function Sl(e,t){return e.sort((n,s)=>{const i=t?s:n,a=t?n:s;return i.weight===a.weight?i.index-a.index:i.weight-a.weight})}function bx(e){const t=[];let n,s,i,a,o,c;for(n=0,s=(e||[]).length;n<s;++n)i=e[n],{position:a,options:{stack:o,stackWeight:c=1}}=i,t.push({index:n,box:i,pos:a,horizontal:i.isHorizontal(),weight:i.weight,stack:o&&a+o,stackWeight:c});return t}function wx(e){const t={};for(const n of e){const{stack:s,pos:i,stackWeight:a}=n;if(!s||!Ng.includes(i))continue;const o=t[s]||(t[s]={count:0,placed:0,weight:0,size:0});o.count++,o.weight+=a}return t}function xx(e,t){const n=wx(e),{vBoxMaxWidth:s,hBoxMaxHeight:i}=t;let a,o,c;for(a=0,o=e.length;a<o;++a){c=e[a];const{fullSize:d}=c.box,h=n[c.stack],f=h&&c.stackWeight/h.weight;c.horizontal?(c.width=f?f*s:d&&t.availableWidth,c.height=i):(c.width=s,c.height=f?f*i:d&&t.availableHeight)}return n}function Sx(e){const t=bx(e),n=Sl(t.filter(h=>h.box.fullSize),!0),s=Sl(xl(t,"left"),!0),i=Sl(xl(t,"right")),a=Sl(xl(t,"top"),!0),o=Sl(xl(t,"bottom")),c=zg(t,"x"),d=zg(t,"y");return{fullSize:n,leftAndTop:s.concat(a),rightAndBottom:i.concat(d).concat(o).concat(c),chartArea:xl(t,"chartArea"),vertical:s.concat(i).concat(d),horizontal:a.concat(o).concat(c)}}function Lg(e,t,n,s){return Math.max(e[n],t[n])+Math.max(e[s],t[s])}function Fg(e,t){e.top=Math.max(e.top,t.top),e.left=Math.max(e.left,t.left),e.bottom=Math.max(e.bottom,t.bottom),e.right=Math.max(e.right,t.right)}function kx(e,t,n,s){const{pos:i,box:a}=n,o=e.maxPadding;if(!Kt(i)){n.size&&(e[i]-=n.size);const m=s[n.stack]||{size:0,count:1};m.size=Math.max(m.size,n.horizontal?a.height:a.width),n.size=m.size/m.count,e[i]+=n.size}a.getPadding&&Fg(o,a.getPadding());const c=Math.max(0,t.outerWidth-Lg(o,e,"left","right")),d=Math.max(0,t.outerHeight-Lg(o,e,"top","bottom")),h=c!==e.w,f=d!==e.h;return e.w=c,e.h=d,n.horizontal?{same:h,other:f}:{same:f,other:h}}function Cx(e){const t=e.maxPadding;function n(s){const i=Math.max(t[s]-e[s],0);return e[s]+=i,i}e.y+=n("top"),e.x+=n("left"),n("right"),n("bottom")}function Ox(e,t){const n=t.maxPadding;function s(i){const a={left:0,top:0,right:0,bottom:0};return i.forEach(o=>{a[o]=Math.max(t[o],n[o])}),a}return s(e?["left","right"]:["top","bottom"])}function kl(e,t,n,s){const i=[];let a,o,c,d,h,f;for(a=0,o=e.length,h=0;a<o;++a){c=e[a],d=c.box,d.update(c.width||t.w,c.height||t.h,Ox(c.horizontal,t));const{same:m,other:v}=kx(t,n,c,s);h|=m&&i.length,f=f||v,d.fullSize||i.push(c)}return h&&kl(i,t,n,s)||f}function xd(e,t,n,s,i){e.top=n,e.left=t,e.right=t+s,e.bottom=n+i,e.width=s,e.height=i}function Rg(e,t,n,s){const i=n.padding;let{x:a,y:o}=t;for(const c of e){const d=c.box,h=s[c.stack]||{count:1,placed:0,weight:1},f=c.stackWeight/h.weight||1;if(c.horizontal){const m=t.w*f,v=h.size||d.height;dl(h.start)&&(o=h.start),d.fullSize?xd(d,i.left,o,n.outerWidth-i.right-i.left,v):xd(d,t.left+h.placed,o,m,v),h.start=o,h.placed+=m,o=d.bottom}else{const m=t.h*f,v=h.size||d.width;dl(h.start)&&(a=h.start),d.fullSize?xd(d,a,i.top,v,n.outerHeight-i.bottom-i.top):xd(d,a,t.top+h.placed,v,m),h.start=a,h.placed+=m,a=d.right}}t.x=a,t.y=o}var mn={addBox(e,t){e.boxes||(e.boxes=[]),t.fullSize=t.fullSize||!1,t.position=t.position||"top",t.weight=t.weight||0,t._layers=t._layers||function(){return[{z:0,draw(n){t.draw(n)}}]},e.boxes.push(t)},removeBox(e,t){const n=e.boxes?e.boxes.indexOf(t):-1;n!==-1&&e.boxes.splice(n,1)},configure(e,t,n){t.fullSize=n.fullSize,t.position=n.position,t.weight=n.weight},update(e,t,n,s){if(!e)return;const i=pn(e.options.layout.padding),a=Math.max(t-i.width,0),o=Math.max(n-i.height,0),c=Sx(e.boxes),d=c.vertical,h=c.horizontal;ue(e.boxes,x=>{typeof x.beforeLayout=="function"&&x.beforeLayout()});const f=d.reduce((x,k)=>k.box.options&&k.box.options.display===!1?x:x+1,0)||1,m=Object.freeze({outerWidth:t,outerHeight:n,padding:i,availableWidth:a,availableHeight:o,vBoxMaxWidth:a/2/f,hBoxMaxHeight:o/2}),v=Object.assign({},i);Fg(v,pn(s));const y=Object.assign({maxPadding:v,w:a,h:o,x:i.left,y:i.top},i),w=xx(d.concat(h),m);kl(c.fullSize,y,m,w),kl(d,y,m,w),kl(h,y,m,w)&&kl(d,y,m,w),Cx(y),Rg(c.leftAndTop,y,m,w),y.x+=y.w,y.y+=y.h,Rg(c.rightAndBottom,y,m,w),e.chartArea={left:y.left,top:y.top,right:y.left+y.w,bottom:y.top+y.h,height:y.h,width:y.w},ue(c.chartArea,x=>{const k=x.box;Object.assign(k,e.chartArea),k.update(y.w,y.h,{left:0,top:0,right:0,bottom:0})})}};class Hg{acquireContext(t,n){}releaseContext(t){return!1}addEventListener(t,n,s){}removeEventListener(t,n,s){}getDevicePixelRatio(){return 1}getMaximumSize(t,n,s,i){return n=Math.max(0,n||t.width),s=s||t.height,{width:n,height:Math.max(0,i?Math.floor(n/i):s)}}isAttached(t){return!0}updateConfig(t){}}class Mx extends Hg{acquireContext(t){return t&&t.getContext&&t.getContext("2d")||null}updateConfig(t){t.options.animation=!1}}const Sd="$chartjs",Dx={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"},Wg=e=>e===null||e==="";function Ex(e,t){const n=e.style,s=e.getAttribute("height"),i=e.getAttribute("width");if(e[Sd]={initial:{height:s,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",n.boxSizing=n.boxSizing||"border-box",Wg(i)){const a=fg(e,"width");a!==void 0&&(e.width=a)}if(Wg(s))if(e.style.height==="")e.height=e.width/(t||2);else{const a=fg(e,"height");a!==void 0&&(e.height=a)}return e}const jg=I9?{passive:!0}:!1;function Tx(e,t,n){e.addEventListener(t,n,jg)}function Ix(e,t,n){e.canvas.removeEventListener(t,n,jg)}function Ax(e,t){const n=Dx[e.type]||e.type,{x:s,y:i}=Ya(e,t);return{type:n,chart:t,native:e,x:s!==void 0?s:null,y:i!==void 0?i:null}}function kd(e,t){for(const n of e)if(n===t||n.contains(t))return!0}function Vx(e,t,n){const s=e.canvas,i=new MutationObserver(a=>{let o=!1;for(const c of a)o=o||kd(c.addedNodes,s),o=o&&!kd(c.removedNodes,s);o&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}function Bx(e,t,n){const s=e.canvas,i=new MutationObserver(a=>{let o=!1;for(const c of a)o=o||kd(c.removedNodes,s),o=o&&!kd(c.addedNodes,s);o&&n()});return i.observe(document,{childList:!0,subtree:!0}),i}const Cl=new Map;let Yg=0;function Ug(){const e=window.devicePixelRatio;e!==Yg&&(Yg=e,Cl.forEach((t,n)=>{n.currentDevicePixelRatio!==e&&t()}))}function Px(e,t){Cl.size||window.addEventListener("resize",Ug),Cl.set(e,t)}function Nx(e){Cl.delete(e),Cl.size||window.removeEventListener("resize",Ug)}function zx(e,t,n){const s=e.canvas,i=s&&gh(s);if(!i)return;const a=Gm((c,d)=>{const h=i.clientWidth;n(c,d),h<i.clientWidth&&n()},window),o=new ResizeObserver(c=>{const d=c[0],h=d.contentRect.width,f=d.contentRect.height;h===0&&f===0||a(h,f)});return o.observe(i),Px(e,a),o}function Sh(e,t,n){n&&n.disconnect(),t==="resize"&&Nx(e)}function Lx(e,t,n){const s=e.canvas,i=Gm(a=>{e.ctx!==null&&n(Ax(a,e))},e);return Tx(s,t,i),i}class Fx extends Hg{acquireContext(t,n){const s=t&&t.getContext&&t.getContext("2d");return s&&s.canvas===t?(Ex(t,n),s):null}releaseContext(t){const n=t.canvas;if(!n[Sd])return!1;const s=n[Sd].initial;["height","width"].forEach(a=>{const o=s[a];ee(o)?n.removeAttribute(a):n.setAttribute(a,o)});const i=s.style||{};return Object.keys(i).forEach(a=>{n.style[a]=i[a]}),n.width=n.width,delete n[Sd],!0}addEventListener(t,n,s){this.removeEventListener(t,n);const i=t.$proxies||(t.$proxies={}),o={attach:Vx,detach:Bx,resize:zx}[n]||Lx;i[n]=o(t,n,s)}removeEventListener(t,n){const s=t.$proxies||(t.$proxies={}),i=s[n];if(!i)return;({attach:Sh,detach:Sh,resize:Sh}[n]||Ix)(t,n,i),s[n]=void 0}getDevicePixelRatio(){return window.devicePixelRatio}getMaximumSize(t,n,s,i){return T9(t,n,s,i)}isAttached(t){const n=gh(t);return!!(n&&n.isConnected)}}function Rx(e){return!ug()||typeof OffscreenCanvas<"u"&&e instanceof OffscreenCanvas?Mx:Fx}class Hs{constructor(){nt(this,"x");nt(this,"y");nt(this,"active",!1);nt(this,"options");nt(this,"$animations")}tooltipPosition(t){const{x:n,y:s}=this.getProps(["x","y"],t);return{x:n,y:s}}hasValue(){return zo(this.x)&&zo(this.y)}getProps(t,n){const s=this.$animations;if(!n||!s)return this;const i={};return t.forEach(a=>{i[a]=s[a]&&s[a].active()?s[a]._to:this[a]}),i}}nt(Hs,"defaults",{}),nt(Hs,"defaultRoutes");function Hx(e,t){const n=e.options.ticks,s=Wx(e),i=Math.min(n.maxTicksLimit||s,s),a=n.major.enabled?Yx(t):[],o=a.length,c=a[0],d=a[o-1],h=[];if(o>i)return Ux(t,h,a,o/i),h;const f=jx(a,t,i);if(o>0){let m,v;const y=o>1?Math.round((d-c)/(o-1)):null;for(Cd(t,h,f,ee(y)?0:c-y,c),m=0,v=o-1;m<v;m++)Cd(t,h,f,a[m],a[m+1]);return Cd(t,h,f,d,ee(y)?t.length:d+y),h}return Cd(t,h,f),h}function Wx(e){const t=e.options.offset,n=e._tickSize(),s=e._length/n+(t?0:1),i=e._maxLength/n;return Math.floor(Math.min(s,i))}function jx(e,t,n){const s=Gx(e),i=t.length/n;if(!s)return Math.max(i,1);const a=Bw(s);for(let o=0,c=a.length-1;o<c;o++){const d=a[o];if(d>i)return d}return Math.max(i,1)}function Yx(e){const t=[];let n,s;for(n=0,s=e.length;n<s;n++)e[n].major&&t.push(n);return t}function Ux(e,t,n,s){let i=0,a=n[0],o;for(s=Math.ceil(s),o=0;o<e.length;o++)o===a&&(t.push(e[o]),i++,a=n[i*s])}function Cd(e,t,n,s,i){const a=Vt(s,0),o=Math.min(Vt(i,e.length),e.length);let c=0,d,h,f;for(n=Math.ceil(n),i&&(d=i-s,n=d/Math.floor(d/n)),f=a;f<0;)c++,f=Math.round(a+c*n);for(h=Math.max(a,0);h<o;h++)h===f&&(t.push(e[h]),c++,f=Math.round(a+c*n))}function Gx(e){const t=e.length;let n,s;if(t<2)return!1;for(s=e[0],n=1;n<t;++n)if(e[n]-e[n-1]!==s)return!1;return s}const Kx=e=>e==="left"?"right":e==="right"?"left":e,Gg=(e,t,n)=>t==="top"||t==="left"?e[t]+n:e[t]-n,Kg=(e,t)=>Math.min(t||e,e);function Zg(e,t){const n=[],s=e.length/t,i=e.length;let a=0;for(;a<i;a+=s)n.push(e[Math.floor(a)]);return n}function Zx(e,t,n){const s=e.ticks.length,i=Math.min(t,s-1),a=e._startPixel,o=e._endPixel,c=1e-6;let d=e.getPixelForTick(i),h;if(!(n&&(s===1?h=Math.max(d-a,o-d):t===0?h=(e.getPixelForTick(1)-d)/2:h=(d-e.getPixelForTick(i-1))/2,d+=i<t?h:-h,d<a-c||d>o+c)))return d}function Xx(e,t){ue(e,n=>{const s=n.gc,i=s.length/2;let a;if(i>t){for(a=0;a<i;++a)delete n.data[s[a]];s.splice(0,i)}})}function Ol(e){return e.drawTicks?e.tickLength:0}function Xg(e,t){if(!e.display)return 0;const n=$e(e.font,t),s=pn(e.padding);return(Se(e.text)?e.text.length:1)*n.lineHeight+s.height}function Jx(e,t){return sa(e,{scale:t,type:"scale"})}function Qx(e,t,n){return sa(e,{tick:n,index:t,type:"tick"})}function qx(e,t,n){let s=oh(e);return(n&&t!=="right"||!n&&t==="right")&&(s=Kx(s)),s}function $x(e,t,n,s){const{top:i,left:a,bottom:o,right:c,chart:d}=e,{chartArea:h,scales:f}=d;let m=0,v,y,w;const x=o-i,k=c-a;if(e.isHorizontal()){if(y=fn(s,a,c),Kt(n)){const D=Object.keys(n)[0],E=n[D];w=f[D].getPixelForValue(E)+x-t}else n==="center"?w=(h.bottom+h.top)/2+x-t:w=Gg(e,n,t);v=c-a}else{if(Kt(n)){const D=Object.keys(n)[0],E=n[D];y=f[D].getPixelForValue(E)-k+t}else n==="center"?y=(h.left+h.right)/2-k+t:y=Gg(e,n,t);w=fn(s,o,i),m=n==="left"?-Ne:Ne}return{titleX:y,titleY:w,maxWidth:v,rotation:m}}class Za extends Hs{constructor(t){super(),this.id=t.id,this.type=t.type,this.options=void 0,this.ctx=t.ctx,this.chart=t.chart,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this._margins={left:0,right:0,top:0,bottom:0},this.maxWidth=void 0,this.maxHeight=void 0,this.paddingTop=void 0,this.paddingBottom=void 0,this.paddingLeft=void 0,this.paddingRight=void 0,this.axis=void 0,this.labelRotation=void 0,this.min=void 0,this.max=void 0,this._range=void 0,this.ticks=[],this._gridLineItems=null,this._labelItems=null,this._labelSizes=null,this._length=0,this._maxLength=0,this._longestTextCache={},this._startPixel=void 0,this._endPixel=void 0,this._reversePixels=!1,this._userMax=void 0,this._userMin=void 0,this._suggestedMax=void 0,this._suggestedMin=void 0,this._ticksLength=0,this._borderValue=0,this._cache={},this._dataLimitsCached=!1,this.$context=void 0}init(t){this.options=t.setContext(this.getContext()),this.axis=t.axis,this._userMin=this.parse(t.min),this._userMax=this.parse(t.max),this._suggestedMin=this.parse(t.suggestedMin),this._suggestedMax=this.parse(t.suggestedMax)}parse(t,n){return t}getUserBounds(){let{_userMin:t,_userMax:n,_suggestedMin:s,_suggestedMax:i}=this;return t=Gn(t,Number.POSITIVE_INFINITY),n=Gn(n,Number.NEGATIVE_INFINITY),s=Gn(s,Number.POSITIVE_INFINITY),i=Gn(i,Number.NEGATIVE_INFINITY),{min:Gn(t,s),max:Gn(n,i),minDefined:Pe(t),maxDefined:Pe(n)}}getMinMax(t){let{min:n,max:s,minDefined:i,maxDefined:a}=this.getUserBounds(),o;if(i&&a)return{min:n,max:s};const c=this.getMatchingVisibleMetas();for(let d=0,h=c.length;d<h;++d)o=c[d].controller.getMinMax(this,t),i||(n=Math.min(n,o.min)),a||(s=Math.max(s,o.max));return n=a&&n>s?s:n,s=i&&n>s?n:s,{min:Gn(n,Gn(s,n)),max:Gn(s,Gn(n,s))}}getPadding(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}}getTicks(){return this.ticks}getLabels(){const t=this.chart.data;return this.options.labels||(this.isHorizontal()?t.xLabels:t.yLabels)||t.labels||[]}getLabelItems(t=this.chart.chartArea){return this._labelItems||(this._labelItems=this._computeLabelItems(t))}beforeLayout(){this._cache={},this._dataLimitsCached=!1}beforeUpdate(){we(this.options.beforeUpdate,[this])}update(t,n,s){const{beginAtZero:i,grace:a,ticks:o}=this.options,c=o.sampleSize;this.beforeUpdate(),this.maxWidth=t,this.maxHeight=n,this._margins=s=Object.assign({left:0,right:0,top:0,bottom:0},s),this.ticks=null,this._labelSizes=null,this._gridLineItems=null,this._labelItems=null,this.beforeSetDimensions(),this.setDimensions(),this.afterSetDimensions(),this._maxLength=this.isHorizontal()?this.width+s.left+s.right:this.height+s.top+s.bottom,this._dataLimitsCached||(this.beforeDataLimits(),this.determineDataLimits(),this.afterDataLimits(),this._range=l9(this,a,i),this._dataLimitsCached=!0),this.beforeBuildTicks(),this.ticks=this.buildTicks()||[],this.afterBuildTicks();const d=c<this.ticks.length;this._convertTicksToLabels(d?Zg(this.ticks,c):this.ticks),this.configure(),this.beforeCalculateLabelRotation(),this.calculateLabelRotation(),this.afterCalculateLabelRotation(),o.display&&(o.autoSkip||o.source==="auto")&&(this.ticks=Hx(this,this.ticks),this._labelSizes=null,this.afterAutoSkip()),d&&this._convertTicksToLabels(this.ticks),this.beforeFit(),this.fit(),this.afterFit(),this.afterUpdate()}configure(){let t=this.options.reverse,n,s;this.isHorizontal()?(n=this.left,s=this.right):(n=this.top,s=this.bottom,t=!t),this._startPixel=n,this._endPixel=s,this._reversePixels=t,this._length=s-n,this._alignToPixels=this.options.alignToPixels}afterUpdate(){we(this.options.afterUpdate,[this])}beforeSetDimensions(){we(this.options.beforeSetDimensions,[this])}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=0,this.right=this.width):(this.height=this.maxHeight,this.top=0,this.bottom=this.height),this.paddingLeft=0,this.paddingTop=0,this.paddingRight=0,this.paddingBottom=0}afterSetDimensions(){we(this.options.afterSetDimensions,[this])}_callHooks(t){this.chart.notifyPlugins(t,this.getContext()),we(this.options[t],[this])}beforeDataLimits(){this._callHooks("beforeDataLimits")}determineDataLimits(){}afterDataLimits(){this._callHooks("afterDataLimits")}beforeBuildTicks(){this._callHooks("beforeBuildTicks")}buildTicks(){return[]}afterBuildTicks(){this._callHooks("afterBuildTicks")}beforeTickToLabelConversion(){we(this.options.beforeTickToLabelConversion,[this])}generateTickLabels(t){const n=this.options.ticks;let s,i,a;for(s=0,i=t.length;s<i;s++)a=t[s],a.label=we(n.callback,[a.value,s,t],this)}afterTickToLabelConversion(){we(this.options.afterTickToLabelConversion,[this])}beforeCalculateLabelRotation(){we(this.options.beforeCalculateLabelRotation,[this])}calculateLabelRotation(){const t=this.options,n=t.ticks,s=Kg(this.ticks.length,t.ticks.maxTicksLimit),i=n.minRotation||0,a=n.maxRotation;let o=i,c,d,h;if(!this._isVisible()||!n.display||i>=a||s<=1||!this.isHorizontal()){this.labelRotation=i;return}const f=this._getLabelSizes(),m=f.widest.width,v=f.highest.height,y=an(this.chart.width-m,0,this.maxWidth);c=t.offset?this.maxWidth/s:y/(s-1),m+6>c&&(c=y/(s-(t.offset?.5:1)),d=this.maxHeight-Ol(t.grid)-n.padding-Xg(t.title,this.chart.options.font),h=Math.sqrt(m*m+v*v),o=sh(Math.min(Math.asin(an((f.highest.height+6)/c,-1,1)),Math.asin(an(d/h,-1,1))-Math.asin(an(v/h,-1,1)))),o=Math.max(i,Math.min(a,o))),this.labelRotation=o}afterCalculateLabelRotation(){we(this.options.afterCalculateLabelRotation,[this])}afterAutoSkip(){}beforeFit(){we(this.options.beforeFit,[this])}fit(){const t={width:0,height:0},{chart:n,options:{ticks:s,title:i,grid:a}}=this,o=this._isVisible(),c=this.isHorizontal();if(o){const d=Xg(i,n.options.font);if(c?(t.width=this.maxWidth,t.height=Ol(a)+d):(t.height=this.maxHeight,t.width=Ol(a)+d),s.display&&this.ticks.length){const{first:h,last:f,widest:m,highest:v}=this._getLabelSizes(),y=s.padding*2,w=Fs(this.labelRotation),x=Math.cos(w),k=Math.sin(w);if(c){const D=s.mirror?0:k*m.width+x*v.height;t.height=Math.min(this.maxHeight,t.height+D+y)}else{const D=s.mirror?0:x*m.width+k*v.height;t.width=Math.min(this.maxWidth,t.width+D+y)}this._calculatePadding(h,f,k,x)}}this._handleMargins(),c?(this.width=this._length=n.width-this._margins.left-this._margins.right,this.height=t.height):(this.width=t.width,this.height=this._length=n.height-this._margins.top-this._margins.bottom)}_calculatePadding(t,n,s,i){const{ticks:{align:a,padding:o},position:c}=this.options,d=this.labelRotation!==0,h=c!=="top"&&this.axis==="x";if(this.isHorizontal()){const f=this.getPixelForTick(0)-this.left,m=this.right-this.getPixelForTick(this.ticks.length-1);let v=0,y=0;d?h?(v=i*t.width,y=s*n.height):(v=s*t.height,y=i*n.width):a==="start"?y=n.width:a==="end"?v=t.width:a!=="inner"&&(v=t.width/2,y=n.width/2),this.paddingLeft=Math.max((v-f+o)*this.width/(this.width-f),0),this.paddingRight=Math.max((y-m+o)*this.width/(this.width-m),0)}else{let f=n.height/2,m=t.height/2;a==="start"?(f=0,m=t.height):a==="end"&&(f=n.height,m=0),this.paddingTop=f+o,this.paddingBottom=m+o}}_handleMargins(){this._margins&&(this._margins.left=Math.max(this.paddingLeft,this._margins.left),this._margins.top=Math.max(this.paddingTop,this._margins.top),this._margins.right=Math.max(this.paddingRight,this._margins.right),this._margins.bottom=Math.max(this.paddingBottom,this._margins.bottom))}afterFit(){we(this.options.afterFit,[this])}isHorizontal(){const{axis:t,position:n}=this.options;return n==="top"||n==="bottom"||t==="x"}isFullSize(){return this.options.fullSize}_convertTicksToLabels(t){this.beforeTickToLabelConversion(),this.generateTickLabels(t);let n,s;for(n=0,s=t.length;n<s;n++)ee(t[n].label)&&(t.splice(n,1),s--,n--);this.afterTickToLabelConversion()}_getLabelSizes(){let t=this._labelSizes;if(!t){const n=this.options.ticks.sampleSize;let s=this.ticks;n<s.length&&(s=Zg(s,n)),this._labelSizes=t=this._computeLabelSizes(s,s.length,this.options.ticks.maxTicksLimit)}return t}_computeLabelSizes(t,n,s){const{ctx:i,_longestTextCache:a}=this,o=[],c=[],d=Math.floor(n/Kg(n,s));let h=0,f=0,m,v,y,w,x,k,D,E,B,S,A;for(m=0;m<n;m+=d){if(w=t[m].label,x=this._resolveTickFontOptions(m),i.font=k=x.string,D=a[k]=a[k]||{data:{},gc:[]},E=x.lineHeight,B=S=0,!ee(w)&&!Se(w))B=ud(i,D.data,D.gc,B,w),S=E;else if(Se(w))for(v=0,y=w.length;v<y;++v)A=w[v],!ee(A)&&!Se(A)&&(B=ud(i,D.data,D.gc,B,A),S+=E);o.push(B),c.push(S),h=Math.max(B,h),f=Math.max(S,f)}Xx(a,n);const I=o.indexOf(h),F=c.indexOf(f),L=W=>({width:o[W]||0,height:c[W]||0});return{first:L(0),last:L(n-1),widest:L(I),highest:L(F),widths:o,heights:c}}getLabelForValue(t){return t}getPixelForValue(t,n){return NaN}getValueForPixel(t){}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getPixelForDecimal(t){this._reversePixels&&(t=1-t);const n=this._startPixel+t*this._length;return zw(this._alignToPixels?Ra(this.chart,n,0):n)}getDecimalForPixel(t){const n=(t-this._startPixel)/this._length;return this._reversePixels?1-n:n}getBasePixel(){return this.getPixelForValue(this.getBaseValue())}getBaseValue(){const{min:t,max:n}=this;return t<0&&n<0?n:t>0&&n>0?t:0}getContext(t){const n=this.ticks||[];if(t>=0&&t<n.length){const s=n[t];return s.$context||(s.$context=Qx(this.getContext(),t,s))}return this.$context||(this.$context=Jx(this.chart.getContext(),this))}_tickSize(){const t=this.options.ticks,n=Fs(this.labelRotation),s=Math.abs(Math.cos(n)),i=Math.abs(Math.sin(n)),a=this._getLabelSizes(),o=t.autoSkipPadding||0,c=a?a.widest.width+o:0,d=a?a.highest.height+o:0;return this.isHorizontal()?d*s>c*i?c/s:d/i:d*i<c*s?d/s:c/i}_isVisible(){const t=this.options.display;return t!=="auto"?!!t:this.getMatchingVisibleMetas().length>0}_computeGridLineItems(t){const n=this.axis,s=this.chart,i=this.options,{grid:a,position:o,border:c}=i,d=a.offset,h=this.isHorizontal(),m=this.ticks.length+(d?1:0),v=Ol(a),y=[],w=c.setContext(this.getContext()),x=w.display?w.width:0,k=x/2,D=function(ft){return Ra(s,ft,x)};let E,B,S,A,I,F,L,W,X,Z,Q,et;if(o==="top")E=D(this.bottom),F=this.bottom-v,W=E-k,Z=D(t.top)+k,et=t.bottom;else if(o==="bottom")E=D(this.top),Z=t.top,et=D(t.bottom)-k,F=E+k,W=this.top+v;else if(o==="left")E=D(this.right),I=this.right-v,L=E-k,X=D(t.left)+k,Q=t.right;else if(o==="right")E=D(this.left),X=t.left,Q=D(t.right)-k,I=E+k,L=this.left+v;else if(n==="x"){if(o==="center")E=D((t.top+t.bottom)/2+.5);else if(Kt(o)){const ft=Object.keys(o)[0],lt=o[ft];E=D(this.chart.scales[ft].getPixelForValue(lt))}Z=t.top,et=t.bottom,F=E+k,W=F+v}else if(n==="y"){if(o==="center")E=D((t.left+t.right)/2);else if(Kt(o)){const ft=Object.keys(o)[0],lt=o[ft];E=D(this.chart.scales[ft].getPixelForValue(lt))}I=E-k,L=I-v,X=t.left,Q=t.right}const gt=Vt(i.ticks.maxTicksLimit,m),ot=Math.max(1,Math.ceil(m/gt));for(B=0;B<m;B+=ot){const ft=this.getContext(B),lt=a.setContext(ft),vt=c.setContext(ft),xt=lt.lineWidth,ct=lt.color,R=vt.dash||[],q=vt.dashOffset,rt=lt.tickWidth,pt=lt.tickColor,$=lt.tickBorderDash||[],_t=lt.tickBorderDashOffset;S=Zx(this,B,d),S!==void 0&&(A=Ra(s,S,xt),h?I=L=X=Q=A:F=W=Z=et=A,y.push({tx1:I,ty1:F,tx2:L,ty2:W,x1:X,y1:Z,x2:Q,y2:et,width:xt,color:ct,borderDash:R,borderDashOffset:q,tickWidth:rt,tickColor:pt,tickBorderDash:$,tickBorderDashOffset:_t}))}return this._ticksLength=m,this._borderValue=E,y}_computeLabelItems(t){const n=this.axis,s=this.options,{position:i,ticks:a}=s,o=this.isHorizontal(),c=this.ticks,{align:d,crossAlign:h,padding:f,mirror:m}=a,v=Ol(s.grid),y=v+f,w=m?-f:y,x=-Fs(this.labelRotation),k=[];let D,E,B,S,A,I,F,L,W,X,Z,Q,et="middle";if(i==="top")I=this.bottom-w,F=this._getXAxisLabelAlignment();else if(i==="bottom")I=this.top+w,F=this._getXAxisLabelAlignment();else if(i==="left"){const ot=this._getYAxisLabelAlignment(v);F=ot.textAlign,A=ot.x}else if(i==="right"){const ot=this._getYAxisLabelAlignment(v);F=ot.textAlign,A=ot.x}else if(n==="x"){if(i==="center")I=(t.top+t.bottom)/2+y;else if(Kt(i)){const ot=Object.keys(i)[0],ft=i[ot];I=this.chart.scales[ot].getPixelForValue(ft)+y}F=this._getXAxisLabelAlignment()}else if(n==="y"){if(i==="center")A=(t.left+t.right)/2-y;else if(Kt(i)){const ot=Object.keys(i)[0],ft=i[ot];A=this.chart.scales[ot].getPixelForValue(ft)}F=this._getYAxisLabelAlignment(v).textAlign}n==="y"&&(d==="start"?et="top":d==="end"&&(et="bottom"));const gt=this._getLabelSizes();for(D=0,E=c.length;D<E;++D){B=c[D],S=B.label;const ot=a.setContext(this.getContext(D));L=this.getPixelForTick(D)+a.labelOffset,W=this._resolveTickFontOptions(D),X=W.lineHeight,Z=Se(S)?S.length:1;const ft=Z/2,lt=ot.color,vt=ot.textStrokeColor,xt=ot.textStrokeWidth;let ct=F;o?(A=L,F==="inner"&&(D===E-1?ct=this.options.reverse?"left":"right":D===0?ct=this.options.reverse?"right":"left":ct="center"),i==="top"?h==="near"||x!==0?Q=-Z*X+X/2:h==="center"?Q=-gt.highest.height/2-ft*X+X:Q=-gt.highest.height+X/2:h==="near"||x!==0?Q=X/2:h==="center"?Q=gt.highest.height/2-ft*X:Q=gt.highest.height-Z*X,m&&(Q*=-1),x!==0&&!ot.showLabelBackdrop&&(A+=X/2*Math.sin(x))):(I=L,Q=(1-Z)*X/2);let R;if(ot.showLabelBackdrop){const q=pn(ot.backdropPadding),rt=gt.heights[D],pt=gt.widths[D];let $=Q-q.top,_t=0-q.left;switch(et){case"middle":$-=rt/2;break;case"bottom":$-=rt;break}switch(F){case"center":_t-=pt/2;break;case"right":_t-=pt;break}R={left:_t,top:$,width:pt+q.width,height:rt+q.height,color:ot.backdropColor}}k.push({label:S,font:W,textOffset:Q,options:{rotation:x,color:lt,strokeColor:vt,strokeWidth:xt,textAlign:ct,textBaseline:et,translation:[A,I],backdrop:R}})}return k}_getXAxisLabelAlignment(){const{position:t,ticks:n}=this.options;if(-Fs(this.labelRotation))return t==="top"?"left":"right";let i="center";return n.align==="start"?i="left":n.align==="end"?i="right":n.align==="inner"&&(i="inner"),i}_getYAxisLabelAlignment(t){const{position:n,ticks:{crossAlign:s,mirror:i,padding:a}}=this.options,o=this._getLabelSizes(),c=t+a,d=o.widest.width;let h,f;return n==="left"?i?(f=this.right+a,s==="near"?h="left":s==="center"?(h="center",f+=d/2):(h="right",f+=d)):(f=this.right-c,s==="near"?h="right":s==="center"?(h="center",f-=d/2):(h="left",f=this.left)):n==="right"?i?(f=this.left+a,s==="near"?h="right":s==="center"?(h="center",f-=d/2):(h="left",f-=d)):(f=this.left+c,s==="near"?h="left":s==="center"?(h="center",f+=d/2):(h="right",f=this.right)):h="right",{textAlign:h,x:f}}_computeLabelArea(){if(this.options.ticks.mirror)return;const t=this.chart,n=this.options.position;if(n==="left"||n==="right")return{top:0,left:this.left,bottom:t.height,right:this.right};if(n==="top"||n==="bottom")return{top:this.top,left:0,bottom:this.bottom,right:t.width}}drawBackground(){const{ctx:t,options:{backgroundColor:n},left:s,top:i,width:a,height:o}=this;n&&(t.save(),t.fillStyle=n,t.fillRect(s,i,a,o),t.restore())}getLineWidthForValue(t){const n=this.options.grid;if(!this._isVisible()||!n.display)return 0;const i=this.ticks.findIndex(a=>a.value===t);return i>=0?n.setContext(this.getContext(i)).lineWidth:0}drawGrid(t){const n=this.options.grid,s=this.ctx,i=this._gridLineItems||(this._gridLineItems=this._computeGridLineItems(t));let a,o;const c=(d,h,f)=>{!f.width||!f.color||(s.save(),s.lineWidth=f.width,s.strokeStyle=f.color,s.setLineDash(f.borderDash||[]),s.lineDashOffset=f.borderDashOffset,s.beginPath(),s.moveTo(d.x,d.y),s.lineTo(h.x,h.y),s.stroke(),s.restore())};if(n.display)for(a=0,o=i.length;a<o;++a){const d=i[a];n.drawOnChartArea&&c({x:d.x1,y:d.y1},{x:d.x2,y:d.y2},d),n.drawTicks&&c({x:d.tx1,y:d.ty1},{x:d.tx2,y:d.ty2},{color:d.tickColor,width:d.tickWidth,borderDash:d.tickBorderDash,borderDashOffset:d.tickBorderDashOffset})}}drawBorder(){const{chart:t,ctx:n,options:{border:s,grid:i}}=this,a=s.setContext(this.getContext()),o=s.display?a.width:0;if(!o)return;const c=i.setContext(this.getContext(0)).lineWidth,d=this._borderValue;let h,f,m,v;this.isHorizontal()?(h=Ra(t,this.left,o)-o/2,f=Ra(t,this.right,c)+c/2,m=v=d):(m=Ra(t,this.top,o)-o/2,v=Ra(t,this.bottom,c)+c/2,h=f=d),n.save(),n.lineWidth=a.width,n.strokeStyle=a.color,n.beginPath(),n.moveTo(h,m),n.lineTo(f,v),n.stroke(),n.restore()}drawLabels(t){if(!this.options.ticks.display)return;const s=this.ctx,i=this._computeLabelArea();i&&hd(s,i);const a=this.getLabelItems(t);for(const o of a){const c=o.options,d=o.font,h=o.label,f=o.textOffset;Ha(s,h,0,f,d,c)}i&&fd(s)}drawTitle(){const{ctx:t,options:{position:n,title:s,reverse:i}}=this;if(!s.display)return;const a=$e(s.font),o=pn(s.padding),c=s.align;let d=a.lineHeight/2;n==="bottom"||n==="center"||Kt(n)?(d+=o.bottom,Se(s.text)&&(d+=a.lineHeight*(s.text.length-1))):d+=o.top;const{titleX:h,titleY:f,maxWidth:m,rotation:v}=$x(this,d,n,c);Ha(t,s.text,0,0,a,{color:s.color,maxWidth:m,rotation:v,textAlign:qx(c,n,i),textBaseline:"middle",translation:[h,f]})}draw(t){!this._isVisible()||(this.drawBackground(),this.drawGrid(t),this.drawBorder(),this.drawTitle(),this.drawLabels(t))}_layers(){const t=this.options,n=t.ticks&&t.ticks.z||0,s=Vt(t.grid&&t.grid.z,-1),i=Vt(t.border&&t.border.z,0);return!this._isVisible()||this.draw!==Za.prototype.draw?[{z:n,draw:a=>{this.draw(a)}}]:[{z:s,draw:a=>{this.drawBackground(),this.drawGrid(a),this.drawTitle()}},{z:i,draw:()=>{this.drawBorder()}},{z:n,draw:a=>{this.drawLabels(a)}}]}getMatchingVisibleMetas(t){const n=this.chart.getSortedVisibleDatasetMetas(),s=this.axis+"AxisID",i=[];let a,o;for(a=0,o=n.length;a<o;++a){const c=n[a];c[s]===this.id&&(!t||c.type===t)&&i.push(c)}return i}_resolveTickFontOptions(t){const n=this.options.ticks.setContext(this.getContext(t));return $e(n.font)}_maxDigits(){const t=this._resolveTickFontOptions(0).lineHeight;return(this.isHorizontal()?this.width:this.height)/t}}class Od{constructor(t,n,s){this.type=t,this.scope=n,this.override=s,this.items=Object.create(null)}isForType(t){return Object.prototype.isPrototypeOf.call(this.type.prototype,t.prototype)}register(t){const n=Object.getPrototypeOf(t);let s;nS(n)&&(s=this.register(n));const i=this.items,a=t.id,o=this.scope+"."+a;if(!a)throw new Error("class does not have id: "+t);return a in i||(i[a]=t,tS(t,o,s),this.override&&ze.override(t.id,t.overrides)),o}get(t){return this.items[t]}unregister(t){const n=this.items,s=t.id,i=this.scope;s in n&&delete n[s],i&&s in ze[i]&&(delete ze[i][s],this.override&&delete Fa[s])}}function tS(e,t,n){const s=ll(Object.create(null),[n?ze.get(n):{},ze.get(t),e.defaults]);ze.set(t,s),e.defaultRoutes&&eS(t,e.defaultRoutes),e.descriptors&&ze.describe(t,e.descriptors)}function eS(e,t){Object.keys(t).forEach(n=>{const s=n.split("."),i=s.pop(),a=[e].concat(s).join("."),o=t[n].split("."),c=o.pop(),d=o.join(".");ze.route(a,i,d,c)})}function nS(e){return"id"in e&&"defaults"in e}class sS{constructor(){this.controllers=new Od(Rs,"datasets",!0),this.elements=new Od(Hs,"elements"),this.plugins=new Od(Object,"plugins"),this.scales=new Od(Za,"scales"),this._typedRegistries=[this.controllers,this.scales,this.elements]}add(...t){this._each("register",t)}remove(...t){this._each("unregister",t)}addControllers(...t){this._each("register",t,this.controllers)}addElements(...t){this._each("register",t,this.elements)}addPlugins(...t){this._each("register",t,this.plugins)}addScales(...t){this._each("register",t,this.scales)}getController(t){return this._get(t,this.controllers,"controller")}getElement(t){return this._get(t,this.elements,"element")}getPlugin(t){return this._get(t,this.plugins,"plugin")}getScale(t){return this._get(t,this.scales,"scale")}removeControllers(...t){this._each("unregister",t,this.controllers)}removeElements(...t){this._each("unregister",t,this.elements)}removePlugins(...t){this._each("unregister",t,this.plugins)}removeScales(...t){this._each("unregister",t,this.scales)}_each(t,n,s){[...n].forEach(i=>{const a=s||this._getRegistryForType(i);s||a.isForType(i)||a===this.plugins&&i.id?this._exec(t,a,i):ue(i,o=>{const c=s||this._getRegistryForType(o);this._exec(t,c,o)})})}_exec(t,n,s){const i=nh(t);we(s["before"+i],[],s),n[t](s),we(s["after"+i],[],s)}_getRegistryForType(t){for(let n=0;n<this._typedRegistries.length;n++){const s=this._typedRegistries[n];if(s.isForType(t))return s}return this.plugins}_get(t,n,s){const i=n.get(t);if(i===void 0)throw new Error('"'+t+'" is not a registered '+s+".");return i}}var ri=new sS;class iS{constructor(){this._init=[]}notify(t,n,s,i){n==="beforeInit"&&(this._init=this._createDescriptors(t,!0),this._notify(this._init,t,"install"));const a=i?this._descriptors(t).filter(i):this._descriptors(t),o=this._notify(a,t,n,s);return n==="afterDestroy"&&(this._notify(a,t,"stop"),this._notify(this._init,t,"uninstall")),o}_notify(t,n,s,i){i=i||{};for(const a of t){const o=a.plugin,c=o[s],d=[n,i,a.options];if(we(c,d,o)===!1&&i.cancelable)return!1}return!0}invalidate(){ee(this._cache)||(this._oldCache=this._cache,this._cache=void 0)}_descriptors(t){if(this._cache)return this._cache;const n=this._cache=this._createDescriptors(t);return this._notifyStateChanges(t),n}_createDescriptors(t,n){const s=t&&t.config,i=Vt(s.options&&s.options.plugins,{}),a=aS(s);return i===!1&&!n?[]:rS(t,a,i,n)}_notifyStateChanges(t){const n=this._oldCache||[],s=this._cache,i=(a,o)=>a.filter(c=>!o.some(d=>c.plugin.id===d.plugin.id));this._notify(i(n,s),t,"stop"),this._notify(i(s,n),t,"start")}}function aS(e){const t={},n=[],s=Object.keys(ri.plugins.items);for(let a=0;a<s.length;a++)n.push(ri.getPlugin(s[a]));const i=e.plugins||[];for(let a=0;a<i.length;a++){const o=i[a];n.indexOf(o)===-1&&(n.push(o),t[o.id]=!0)}return{plugins:n,localIds:t}}function oS(e,t){return!t&&e===!1?null:e===!0?{}:e}function rS(e,{plugins:t,localIds:n},s,i){const a=[],o=e.getContext();for(const c of t){const d=c.id,h=oS(s[d],i);h!==null&&a.push({plugin:c,options:lS(e.config,{plugin:c,local:n[d]},h,o)})}return a}function lS(e,{plugin:t,local:n},s,i){const a=e.pluginScopeKeys(t),o=e.getOptionScopes(s,a);return n&&t.defaults&&o.push(t.defaults),e.createResolver(o,i,[""],{scriptable:!1,indexable:!1,allKeys:!0})}function kh(e,t){const n=ze.datasets[e]||{};return((t.datasets||{})[e]||{}).indexAxis||t.indexAxis||n.indexAxis||"x"}function cS(e,t){let n=e;return e==="_index_"?n=t:e==="_value_"&&(n=t==="x"?"y":"x"),n}function dS(e,t){return e===t?"_index_":"_value_"}function Jg(e){if(e==="x"||e==="y"||e==="r")return e}function uS(e){if(e==="top"||e==="bottom")return"x";if(e==="left"||e==="right")return"y"}function Ch(e,...t){if(Jg(e))return e;for(const n of t){const s=n.axis||uS(n.position)||e.length>1&&Jg(e[0].toLowerCase());if(s)return s}throw new Error(`Cannot determine type of '${e}' axis. Please provide 'axis' or 'position' option.`)}function Qg(e,t,n){if(n[t+"AxisID"]===e)return{axis:t}}function hS(e,t){if(t.data&&t.data.datasets){const n=t.data.datasets.filter(s=>s.xAxisID===e||s.yAxisID===e);if(n.length)return Qg(e,"x",n[0])||Qg(e,"y",n[0])}return{}}function fS(e,t){const n=Fa[e.type]||{scales:{}},s=t.scales||{},i=kh(e.type,t),a=Object.create(null);return Object.keys(s).forEach(o=>{const c=s[o];if(!Kt(c))return console.error(`Invalid scale configuration for scale: ${o}`);if(c._proxy)return console.warn(`Ignoring resolver passed as options for scale: ${o}`);const d=Ch(o,c,hS(o,e),ze.scales[c.type]),h=dS(d,i),f=n.scales||{};a[o]=cl(Object.create(null),[{axis:d},c,f[d],f[h]])}),e.data.datasets.forEach(o=>{const c=o.type||e.type,d=o.indexAxis||kh(c,t),f=(Fa[c]||{}).scales||{};Object.keys(f).forEach(m=>{const v=cS(m,d),y=o[v+"AxisID"]||v;a[y]=a[y]||Object.create(null),cl(a[y],[{axis:v},s[y],f[m]])})}),Object.keys(a).forEach(o=>{const c=a[o];cl(c,[ze.scales[c.type],ze.scale])}),a}function qg(e){const t=e.options||(e.options={});t.plugins=Vt(t.plugins,{}),t.scales=fS(e,t)}function $g(e){return e=e||{},e.datasets=e.datasets||[],e.labels=e.labels||[],e}function pS(e){return e=e||{},e.data=$g(e.data),qg(e),e}const t2=new Map,e2=new Set;function Md(e,t){let n=t2.get(e);return n||(n=t(),t2.set(e,n),e2.add(n)),n}const Ml=(e,t,n)=>{const s=ta(t,n);s!==void 0&&e.add(s)};class mS{constructor(t){this._config=pS(t),this._scopeCache=new Map,this._resolverCache=new Map}get platform(){return this._config.platform}get type(){return this._config.type}set type(t){this._config.type=t}get data(){return this._config.data}set data(t){this._config.data=$g(t)}get options(){return this._config.options}set options(t){this._config.options=t}get plugins(){return this._config.plugins}update(){const t=this._config;this.clearCache(),qg(t)}clearCache(){this._scopeCache.clear(),this._resolverCache.clear()}datasetScopeKeys(t){return Md(t,()=>[[`datasets.${t}`,""]])}datasetAnimationScopeKeys(t,n){return Md(`${t}.transition.${n}`,()=>[[`datasets.${t}.transitions.${n}`,`transitions.${n}`],[`datasets.${t}`,""]])}datasetElementScopeKeys(t,n){return Md(`${t}-${n}`,()=>[[`datasets.${t}.elements.${n}`,`datasets.${t}`,`elements.${n}`,""]])}pluginScopeKeys(t){const n=t.id,s=this.type;return Md(`${s}-plugin-${n}`,()=>[[`plugins.${n}`,...t.additionalOptionScopes||[]]])}_cachedScopes(t,n){const s=this._scopeCache;let i=s.get(t);return(!i||n)&&(i=new Map,s.set(t,i)),i}getOptionScopes(t,n,s){const{options:i,type:a}=this,o=this._cachedScopes(t,s),c=o.get(n);if(c)return c;const d=new Set;n.forEach(f=>{t&&(d.add(t),f.forEach(m=>Ml(d,t,m))),f.forEach(m=>Ml(d,i,m)),f.forEach(m=>Ml(d,Fa[a]||{},m)),f.forEach(m=>Ml(d,ze,m)),f.forEach(m=>Ml(d,ch,m))});const h=Array.from(d);return h.length===0&&h.push(Object.create(null)),e2.has(n)&&o.set(n,h),h}chartOptionScopes(){const{options:t,type:n}=this;return[t,Fa[n]||{},ze.datasets[n]||{},{type:n},ze,ch]}resolveNamedOptions(t,n,s,i=[""]){const a={$shared:!0},{resolver:o,subPrefixes:c}=n2(this._resolverCache,t,i);let d=o;if(vS(o,n)){a.$shared=!1,s=ea(s)?s():s;const h=this.createResolver(t,s,c);d=Lo(o,s,h)}for(const h of n)a[h]=d[h];return a}createResolver(t,n,s=[""],i){const{resolver:a}=n2(this._resolverCache,t,s);return Kt(n)?Lo(a,n,void 0,i):a}}function n2(e,t,n){let s=e.get(t);s||(s=new Map,e.set(t,s));const i=n.join();let a=s.get(i);return a||(a={resolver:fh(t,n),subPrefixes:n.filter(c=>!c.toLowerCase().includes("hover"))},s.set(i,a)),a}const gS=e=>Kt(e)&&Object.getOwnPropertyNames(e).reduce((t,n)=>t||ea(e[n]),!1);function vS(e,t){const{isScriptable:n,isIndexable:s}=sg(e);for(const i of t){const a=n(i),o=s(i),c=(o||a)&&e[i];if(a&&(ea(c)||gS(c))||o&&Se(c))return!0}return!1}var _S="4.3.0";const yS=["top","bottom","left","right","chartArea"];function s2(e,t){return e==="top"||e==="bottom"||yS.indexOf(e)===-1&&t==="x"}function i2(e,t){return function(n,s){return n[e]===s[e]?n[t]-s[t]:n[e]-s[e]}}function a2(e){const t=e.chart,n=t.options.animation;t.notifyPlugins("afterRender"),we(n&&n.onComplete,[e],t)}function bS(e){const t=e.chart,n=t.options.animation;we(n&&n.onProgress,[e],t)}function o2(e){return ug()&&typeof e=="string"?e=document.getElementById(e):e&&e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas),e}const Dd={},r2=e=>{const t=o2(e);return Object.values(Dd).filter(n=>n.canvas===t).pop()};function wS(e,t,n){const s=Object.keys(e);for(const i of s){const a=+i;if(a>=t){const o=e[i];delete e[i],(n>0||a>t)&&(e[a+n]=o)}}}function xS(e,t,n,s){return!n||e.type==="mouseout"?null:s?t:e}function SS(e){const{xScale:t,yScale:n}=e;if(t&&n)return{left:t.left,right:t.right,top:n.top,bottom:n.bottom}}class fs{static register(...t){ri.add(...t),l2()}static unregister(...t){ri.remove(...t),l2()}constructor(t,n){const s=this.config=new mS(n),i=o2(t),a=r2(i);if(a)throw new Error("Canvas is already in use. Chart with ID '"+a.id+"' must be destroyed before the canvas with ID '"+a.canvas.id+"' can be reused.");const o=s.createResolver(s.chartOptionScopes(),this.getContext());this.platform=new(s.platform||Rx(i)),this.platform.updateConfig(s);const c=this.platform.acquireContext(i,o.aspectRatio),d=c&&c.canvas,h=d&&d.height,f=d&&d.width;if(this.id=Cw(),this.ctx=c,this.canvas=d,this.width=f,this.height=h,this._options=o,this._aspectRatio=this.aspectRatio,this._layers=[],this._metasets=[],this._stacks=void 0,this.boxes=[],this.currentDevicePixelRatio=void 0,this.chartArea=void 0,this._active=[],this._lastEvent=void 0,this._listeners={},this._responsiveListeners=void 0,this._sortedMetasets=[],this.scales={},this._plugins=new iS,this.$proxies={},this._hiddenIndices={},this.attached=!1,this._animationsDisabled=void 0,this.$context=void 0,this._doResize=Hw(m=>this.update(m),o.resizeDelay||0),this._dataChanges=[],Dd[this.id]=this,!c||!d){console.error("Failed to create chart: can't acquire context from the given item");return}Ci.listen(this,"complete",a2),Ci.listen(this,"progress",bS),this._initialize(),this.attached&&this.update()}get aspectRatio(){const{options:{aspectRatio:t,maintainAspectRatio:n},width:s,height:i,_aspectRatio:a}=this;return ee(t)?n&&a?a:i?s/i:null:t}get data(){return this.config.data}set data(t){this.config.data=t}get options(){return this._options}set options(t){this.config.options=t}get registry(){return ri}_initialize(){return this.notifyPlugins("beforeInit"),this.options.responsive?this.resize():hg(this,this.options.devicePixelRatio),this.bindEvents(),this.notifyPlugins("afterInit"),this}clear(){return tg(this.canvas,this.ctx),this}stop(){return Ci.stop(this),this}resize(t,n){Ci.running(this)?this._resizeBeforeDraw={width:t,height:n}:this._resize(t,n)}_resize(t,n){const s=this.options,i=this.canvas,a=s.maintainAspectRatio&&this.aspectRatio,o=this.platform.getMaximumSize(i,t,n,a),c=s.devicePixelRatio||this.platform.getDevicePixelRatio(),d=this.width?"resize":"attach";this.width=o.width,this.height=o.height,this._aspectRatio=this.aspectRatio,hg(this,c,!0)&&(this.notifyPlugins("resize",{size:o}),we(s.onResize,[this,o],this),this.attached&&this._doResize(d)&&this.render())}ensureScalesHaveIDs(){const n=this.options.scales||{};ue(n,(s,i)=>{s.id=i})}buildOrUpdateScales(){const t=this.options,n=t.scales,s=this.scales,i=Object.keys(s).reduce((o,c)=>(o[c]=!1,o),{});let a=[];n&&(a=a.concat(Object.keys(n).map(o=>{const c=n[o],d=Ch(o,c),h=d==="r",f=d==="x";return{options:c,dposition:h?"chartArea":f?"bottom":"left",dtype:h?"radialLinear":f?"category":"linear"}}))),ue(a,o=>{const c=o.options,d=c.id,h=Ch(d,c),f=Vt(c.type,o.dtype);(c.position===void 0||s2(c.position,h)!==s2(o.dposition))&&(c.position=o.dposition),i[d]=!0;let m=null;if(d in s&&s[d].type===f)m=s[d];else{const v=ri.getScale(f);m=new v({id:d,type:f,ctx:this.ctx,chart:this}),s[m.id]=m}m.init(c,t)}),ue(i,(o,c)=>{o||delete s[c]}),ue(s,o=>{mn.configure(this,o,o.options),mn.addBox(this,o)})}_updateMetasets(){const t=this._metasets,n=this.data.datasets.length,s=t.length;if(t.sort((i,a)=>i.index-a.index),s>n){for(let i=n;i<s;++i)this._destroyDatasetMeta(i);t.splice(n,s-n)}this._sortedMetasets=t.slice(0).sort(i2("order","index"))}_removeUnreferencedMetasets(){const{_metasets:t,data:{datasets:n}}=this;t.length>n.length&&delete this._stacks,t.forEach((s,i)=>{n.filter(a=>a===s._dataset).length===0&&this._destroyDatasetMeta(i)})}buildOrUpdateControllers(){const t=[],n=this.data.datasets;let s,i;for(this._removeUnreferencedMetasets(),s=0,i=n.length;s<i;s++){const a=n[s];let o=this.getDatasetMeta(s);const c=a.type||this.config.type;if(o.type&&o.type!==c&&(this._destroyDatasetMeta(s),o=this.getDatasetMeta(s)),o.type=c,o.indexAxis=a.indexAxis||kh(c,this.options),o.order=a.order||0,o.index=s,o.label=""+a.label,o.visible=this.isDatasetVisible(s),o.controller)o.controller.updateIndex(s),o.controller.linkScales();else{const d=ri.getController(c),{datasetElementType:h,dataElementType:f}=ze.datasets[c];Object.assign(d,{dataElementType:ri.getElement(f),datasetElementType:h&&ri.getElement(h)}),o.controller=new d(this,s),t.push(o.controller)}}return this._updateMetasets(),t}_resetElements(){ue(this.data.datasets,(t,n)=>{this.getDatasetMeta(n).controller.reset()},this)}reset(){this._resetElements(),this.notifyPlugins("reset")}update(t){const n=this.config;n.update();const s=this._options=n.createResolver(n.chartOptionScopes(),this.getContext()),i=this._animationsDisabled=!s.animation;if(this._updateScales(),this._checkEventBindings(),this._updateHiddenIndices(),this._plugins.invalidate(),this.notifyPlugins("beforeUpdate",{mode:t,cancelable:!0})===!1)return;const a=this.buildOrUpdateControllers();this.notifyPlugins("beforeElementsUpdate");let o=0;for(let h=0,f=this.data.datasets.length;h<f;h++){const{controller:m}=this.getDatasetMeta(h),v=!i&&a.indexOf(m)===-1;m.buildOrUpdateElements(v),o=Math.max(+m.getMaxOverflow(),o)}o=this._minPadding=s.layout.autoPadding?o:0,this._updateLayout(o),i||ue(a,h=>{h.reset()}),this._updateDatasets(t),this.notifyPlugins("afterUpdate",{mode:t}),this._layers.sort(i2("z","_idx"));const{_active:c,_lastEvent:d}=this;d?this._eventHandler(d,!0):c.length&&this._updateHoverStyles(c,c,!0),this.render()}_updateScales(){ue(this.scales,t=>{mn.removeBox(this,t)}),this.ensureScalesHaveIDs(),this.buildOrUpdateScales()}_checkEventBindings(){const t=this.options,n=new Set(Object.keys(this._listeners)),s=new Set(t.events);(!Nm(n,s)||!!this._responsiveListeners!==t.responsive)&&(this.unbindEvents(),this.bindEvents())}_updateHiddenIndices(){const{_hiddenIndices:t}=this,n=this._getUniformDataChanges()||[];for(const{method:s,start:i,count:a}of n){const o=s==="_removeElements"?-a:a;wS(t,i,o)}}_getUniformDataChanges(){const t=this._dataChanges;if(!t||!t.length)return;this._dataChanges=[];const n=this.data.datasets.length,s=a=>new Set(t.filter(o=>o[0]===a).map((o,c)=>c+","+o.splice(1).join(","))),i=s(0);for(let a=1;a<n;a++)if(!Nm(i,s(a)))return;return Array.from(i).map(a=>a.split(",")).map(a=>({method:a[1],start:+a[2],count:+a[3]}))}_updateLayout(t){if(this.notifyPlugins("beforeLayout",{cancelable:!0})===!1)return;mn.update(this,this.width,this.height,t);const n=this.chartArea,s=n.width<=0||n.height<=0;this._layers=[],ue(this.boxes,i=>{s&&i.position==="chartArea"||(i.configure&&i.configure(),this._layers.push(...i._layers()))},this),this._layers.forEach((i,a)=>{i._idx=a}),this.notifyPlugins("afterLayout")}_updateDatasets(t){if(this.notifyPlugins("beforeDatasetsUpdate",{mode:t,cancelable:!0})!==!1){for(let n=0,s=this.data.datasets.length;n<s;++n)this.getDatasetMeta(n).controller.configure();for(let n=0,s=this.data.datasets.length;n<s;++n)this._updateDataset(n,ea(t)?t({datasetIndex:n}):t);this.notifyPlugins("afterDatasetsUpdate",{mode:t})}}_updateDataset(t,n){const s=this.getDatasetMeta(t),i={meta:s,index:t,mode:n,cancelable:!0};this.notifyPlugins("beforeDatasetUpdate",i)!==!1&&(s.controller._update(n),i.cancelable=!1,this.notifyPlugins("afterDatasetUpdate",i))}render(){this.notifyPlugins("beforeRender",{cancelable:!0})!==!1&&(Ci.has(this)?this.attached&&!Ci.running(this)&&Ci.start(this):(this.draw(),a2({chart:this})))}draw(){let t;if(this._resizeBeforeDraw){const{width:s,height:i}=this._resizeBeforeDraw;this._resize(s,i),this._resizeBeforeDraw=null}if(this.clear(),this.width<=0||this.height<=0||this.notifyPlugins("beforeDraw",{cancelable:!0})===!1)return;const n=this._layers;for(t=0;t<n.length&&n[t].z<=0;++t)n[t].draw(this.chartArea);for(this._drawDatasets();t<n.length;++t)n[t].draw(this.chartArea);this.notifyPlugins("afterDraw")}_getSortedDatasetMetas(t){const n=this._sortedMetasets,s=[];let i,a;for(i=0,a=n.length;i<a;++i){const o=n[i];(!t||o.visible)&&s.push(o)}return s}getSortedVisibleDatasetMetas(){return this._getSortedDatasetMetas(!0)}_drawDatasets(){if(this.notifyPlugins("beforeDatasetsDraw",{cancelable:!0})===!1)return;const t=this.getSortedVisibleDatasetMetas();for(let n=t.length-1;n>=0;--n)this._drawDataset(t[n]);this.notifyPlugins("afterDatasetsDraw")}_drawDataset(t){const n=this.ctx,s=t._clip,i=!s.disabled,a=SS(t)||this.chartArea,o={meta:t,index:t.index,cancelable:!0};this.notifyPlugins("beforeDatasetDraw",o)!==!1&&(i&&hd(n,{left:s.left===!1?0:a.left-s.left,right:s.right===!1?this.width:a.right+s.right,top:s.top===!1?0:a.top-s.top,bottom:s.bottom===!1?this.height:a.bottom+s.bottom}),t.controller.draw(),i&&fd(n),o.cancelable=!1,this.notifyPlugins("afterDatasetDraw",o))}isPointInArea(t){return ki(t,this.chartArea,this._minPadding)}getElementsAtEventForMode(t,n,s,i){const a=yx.modes[n];return typeof a=="function"?a(this,t,s,i):[]}getDatasetMeta(t){const n=this.data.datasets[t],s=this._metasets;let i=s.filter(a=>a&&a._dataset===n).pop();return i||(i={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null,order:n&&n.order||0,index:t,_dataset:n,_parsed:[],_sorted:!1},s.push(i)),i}getContext(){return this.$context||(this.$context=sa(null,{chart:this,type:"chart"}))}getVisibleDatasetCount(){return this.getSortedVisibleDatasetMetas().length}isDatasetVisible(t){const n=this.data.datasets[t];if(!n)return!1;const s=this.getDatasetMeta(t);return typeof s.hidden=="boolean"?!s.hidden:!n.hidden}setDatasetVisibility(t,n){const s=this.getDatasetMeta(t);s.hidden=!n}toggleDataVisibility(t){this._hiddenIndices[t]=!this._hiddenIndices[t]}getDataVisibility(t){return!this._hiddenIndices[t]}_updateVisibility(t,n,s){const i=s?"show":"hide",a=this.getDatasetMeta(t),o=a.controller._resolveAnimations(void 0,i);dl(n)?(a.data[n].hidden=!s,this.update()):(this.setDatasetVisibility(t,s),o.update(a,{visible:s}),this.update(c=>c.datasetIndex===t?i:void 0))}hide(t,n){this._updateVisibility(t,n,!1)}show(t,n){this._updateVisibility(t,n,!0)}_destroyDatasetMeta(t){const n=this._metasets[t];n&&n.controller&&n.controller._destroy(),delete this._metasets[t]}_stop(){let t,n;for(this.stop(),Ci.remove(this),t=0,n=this.data.datasets.length;t<n;++t)this._destroyDatasetMeta(t)}destroy(){this.notifyPlugins("beforeDestroy");const{canvas:t,ctx:n}=this;this._stop(),this.config.clearCache(),t&&(this.unbindEvents(),tg(t,n),this.platform.releaseContext(n),this.canvas=null,this.ctx=null),delete Dd[this.id],this.notifyPlugins("afterDestroy")}toBase64Image(...t){return this.canvas.toDataURL(...t)}bindEvents(){this.bindUserEvents(),this.options.responsive?this.bindResponsiveEvents():this.attached=!0}bindUserEvents(){const t=this._listeners,n=this.platform,s=(a,o)=>{n.addEventListener(this,a,o),t[a]=o},i=(a,o,c)=>{a.offsetX=o,a.offsetY=c,this._eventHandler(a)};ue(this.options.events,a=>s(a,i))}bindResponsiveEvents(){this._responsiveListeners||(this._responsiveListeners={});const t=this._responsiveListeners,n=this.platform,s=(d,h)=>{n.addEventListener(this,d,h),t[d]=h},i=(d,h)=>{t[d]&&(n.removeEventListener(this,d,h),delete t[d])},a=(d,h)=>{this.canvas&&this.resize(d,h)};let o;const c=()=>{i("attach",c),this.attached=!0,this.resize(),s("resize",a),s("detach",o)};o=()=>{this.attached=!1,i("resize",a),this._stop(),this._resize(0,0),s("attach",c)},n.isAttached(this.canvas)?c():o()}unbindEvents(){ue(this._listeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._listeners={},ue(this._responsiveListeners,(t,n)=>{this.platform.removeEventListener(this,n,t)}),this._responsiveListeners=void 0}updateHoverStyle(t,n,s){const i=s?"set":"remove";let a,o,c,d;for(n==="dataset"&&(a=this.getDatasetMeta(t[0].datasetIndex),a.controller["_"+i+"DatasetHoverStyle"]()),c=0,d=t.length;c<d;++c){o=t[c];const h=o&&this.getDatasetMeta(o.datasetIndex).controller;h&&h[i+"HoverStyle"](o.element,o.datasetIndex,o.index)}}getActiveElements(){return this._active||[]}setActiveElements(t){const n=this._active||[],s=t.map(({datasetIndex:a,index:o})=>{const c=this.getDatasetMeta(a);if(!c)throw new Error("No dataset found at index "+a);return{datasetIndex:a,element:c.data[o],index:o}});!od(s,n)&&(this._active=s,this._lastEvent=null,this._updateHoverStyles(s,n))}notifyPlugins(t,n,s){return this._plugins.notify(this,t,n,s)}isPluginEnabled(t){return this._plugins._cache.filter(n=>n.plugin.id===t).length===1}_updateHoverStyles(t,n,s){const i=this.options.hover,a=(d,h)=>d.filter(f=>!h.some(m=>f.datasetIndex===m.datasetIndex&&f.index===m.index)),o=a(n,t),c=s?t:a(t,n);o.length&&this.updateHoverStyle(o,i.mode,!1),c.length&&i.mode&&this.updateHoverStyle(c,i.mode,!0)}_eventHandler(t,n){const s={event:t,replay:n,cancelable:!0,inChartArea:this.isPointInArea(t)},i=o=>(o.options.events||this.options.events).includes(t.native.type);if(this.notifyPlugins("beforeEvent",s,i)===!1)return;const a=this._handleEvent(t,n,s.inChartArea);return s.cancelable=!1,this.notifyPlugins("afterEvent",s,i),(a||s.changed)&&this.render(),this}_handleEvent(t,n,s){const{_active:i=[],options:a}=this,o=n,c=this._getActiveElements(t,i,s,o),d=Iw(t),h=xS(t,this._lastEvent,s,d);s&&(this._lastEvent=null,we(a.onHover,[t,c,this],this),d&&we(a.onClick,[t,c,this],this));const f=!od(c,i);return(f||n)&&(this._active=c,this._updateHoverStyles(c,i,n)),this._lastEvent=h,f}_getActiveElements(t,n,s,i){if(t.type==="mouseout")return[];if(!s)return n;const a=this.options.hover;return this.getElementsAtEventForMode(t,a.mode,a,i)}}nt(fs,"defaults",ze),nt(fs,"instances",Dd),nt(fs,"overrides",Fa),nt(fs,"registry",ri),nt(fs,"version",_S),nt(fs,"getChart",r2);function l2(){return ue(fs.instances,e=>e._plugins.invalidate())}function kS(e,t,n){const{startAngle:s,pixelMargin:i,x:a,y:o,outerRadius:c,innerRadius:d}=t;let h=i/c;e.beginPath(),e.arc(a,o,c,s-h,n+h),d>i?(h=i/d,e.arc(a,o,d,n+h,s-h,!0)):e.arc(a,o,i,n+Ne,s-Ne),e.closePath(),e.clip()}function CS(e){return hh(e,["outerStart","outerEnd","innerStart","innerEnd"])}function OS(e,t,n,s){const i=CS(e.options.borderRadius),a=(n-t)/2,o=Math.min(a,s*t/2),c=d=>{const h=(n-Math.min(a,d))*s/2;return an(d,0,Math.min(a,h))};return{outerStart:c(i.outerStart),outerEnd:c(i.outerEnd),innerStart:an(i.innerStart,0,o),innerEnd:an(i.innerEnd,0,o)}}function Wo(e,t,n,s){return{x:n+e*Math.cos(t),y:s+e*Math.sin(t)}}function Ed(e,t,n,s,i,a){const{x:o,y:c,startAngle:d,pixelMargin:h,innerRadius:f}=t,m=Math.max(t.outerRadius+s+n-h,0),v=f>0?f+s+n+h:0;let y=0;const w=i-d;if(s){const ot=f>0?f-s:0,ft=m>0?m-s:0,lt=(ot+ft)/2,vt=lt!==0?w*lt/(lt+s):w;y=(w-vt)/2}const x=Math.max(.001,w*m-n/De)/m,k=(w-x)/2,D=d+k+y,E=i-k-y,{outerStart:B,outerEnd:S,innerStart:A,innerEnd:I}=OS(t,v,m,E-D),F=m-B,L=m-S,W=D+B/F,X=E-S/L,Z=v+A,Q=v+I,et=D+A/Z,gt=E-I/Q;if(e.beginPath(),a){const ot=(W+X)/2;if(e.arc(o,c,m,W,ot),e.arc(o,c,m,ot,X),S>0){const xt=Wo(L,X,o,c);e.arc(xt.x,xt.y,S,X,E+Ne)}const ft=Wo(Q,E,o,c);if(e.lineTo(ft.x,ft.y),I>0){const xt=Wo(Q,gt,o,c);e.arc(xt.x,xt.y,I,E+Ne,gt+Math.PI)}const lt=(E-I/v+(D+A/v))/2;if(e.arc(o,c,v,E-I/v,lt,!0),e.arc(o,c,v,lt,D+A/v,!0),A>0){const xt=Wo(Z,et,o,c);e.arc(xt.x,xt.y,A,et+Math.PI,D-Ne)}const vt=Wo(F,D,o,c);if(e.lineTo(vt.x,vt.y),B>0){const xt=Wo(F,W,o,c);e.arc(xt.x,xt.y,B,D-Ne,W)}}else{e.moveTo(o,c);const ot=Math.cos(W)*m+o,ft=Math.sin(W)*m+c;e.lineTo(ot,ft);const lt=Math.cos(X)*m+o,vt=Math.sin(X)*m+c;e.lineTo(lt,vt)}e.closePath()}function MS(e,t,n,s,i){const{fullCircles:a,startAngle:o,circumference:c}=t;let d=t.endAngle;if(a){Ed(e,t,n,s,d,i);for(let h=0;h<a;++h)e.fill();isNaN(c)||(d=o+(c%ke||ke))}return Ed(e,t,n,s,d,i),e.fill(),d}function DS(e,t,n,s,i){const{fullCircles:a,startAngle:o,circumference:c,options:d}=t,{borderWidth:h,borderJoinStyle:f,borderDash:m,borderDashOffset:v}=d,y=d.borderAlign==="inner";if(!h)return;e.setLineDash(m||[]),e.lineDashOffset=v,y?(e.lineWidth=h*2,e.lineJoin=f||"round"):(e.lineWidth=h,e.lineJoin=f||"bevel");let w=t.endAngle;if(a){Ed(e,t,n,s,w,i);for(let x=0;x<a;++x)e.stroke();isNaN(c)||(w=o+(c%ke||ke))}y&&kS(e,t,w),a||(Ed(e,t,n,s,w,i),e.stroke())}class Dl extends Hs{constructor(n){super();nt(this,"circumference");nt(this,"endAngle");nt(this,"fullCircles");nt(this,"innerRadius");nt(this,"outerRadius");nt(this,"pixelMargin");nt(this,"startAngle");this.options=void 0,this.circumference=void 0,this.startAngle=void 0,this.endAngle=void 0,this.innerRadius=void 0,this.outerRadius=void 0,this.pixelMargin=0,this.fullCircles=0,n&&Object.assign(this,n)}inRange(n,s,i){const a=this.getProps(["x","y"],i),{angle:o,distance:c}=Hm(a,{x:n,y:s}),{startAngle:d,endAngle:h,innerRadius:f,outerRadius:m,circumference:v}=this.getProps(["startAngle","endAngle","innerRadius","outerRadius","circumference"],i),y=(this.options.spacing+this.options.borderWidth)/2,x=Vt(v,h-d)>=ke||hl(o,d,h),k=xi(c,f+y,m+y);return x&&k}getCenterPoint(n){const{x:s,y:i,startAngle:a,endAngle:o,innerRadius:c,outerRadius:d}=this.getProps(["x","y","startAngle","endAngle","innerRadius","outerRadius"],n),{offset:h,spacing:f}=this.options,m=(a+o)/2,v=(c+d+f+h)/2;return{x:s+Math.cos(m)*v,y:i+Math.sin(m)*v}}tooltipPosition(n){return this.getCenterPoint(n)}draw(n){const{options:s,circumference:i}=this,a=(s.offset||0)/4,o=(s.spacing||0)/2,c=s.circular;if(this.pixelMargin=s.borderAlign==="inner"?.33:0,this.fullCircles=i>ke?Math.floor(i/ke):0,i===0||this.innerRadius<0||this.outerRadius<0)return;n.save();const d=(this.startAngle+this.endAngle)/2;n.translate(Math.cos(d)*a,Math.sin(d)*a);const h=1-Math.sin(Math.min(De,i||0)),f=a*h;n.fillStyle=s.backgroundColor,n.strokeStyle=s.borderColor,MS(n,this,f,o,c),DS(n,this,f,o,c),n.restore()}}nt(Dl,"id","arc"),nt(Dl,"defaults",{borderAlign:"center",borderColor:"#fff",borderDash:[],borderDashOffset:0,borderJoinStyle:void 0,borderRadius:0,borderWidth:2,offset:0,spacing:0,angle:void 0,circular:!0}),nt(Dl,"defaultRoutes",{backgroundColor:"backgroundColor"}),nt(Dl,"descriptors",{_scriptable:!0,_indexable:n=>n!=="borderDash"});function c2(e,t,n=t){e.lineCap=Vt(n.borderCapStyle,t.borderCapStyle),e.setLineDash(Vt(n.borderDash,t.borderDash)),e.lineDashOffset=Vt(n.borderDashOffset,t.borderDashOffset),e.lineJoin=Vt(n.borderJoinStyle,t.borderJoinStyle),e.lineWidth=Vt(n.borderWidth,t.borderWidth),e.strokeStyle=Vt(n.borderColor,t.borderColor)}function ES(e,t,n){e.lineTo(n.x,n.y)}function TS(e){return e.stepped?$w:e.tension||e.cubicInterpolationMode==="monotone"?t9:ES}function d2(e,t,n={}){const s=e.length,{start:i=0,end:a=s-1}=n,{start:o,end:c}=t,d=Math.max(i,o),h=Math.min(a,c),f=i<o&&a<o||i>c&&a>c;return{count:s,start:d,loop:t.loop,ilen:h<d&&!f?s+h-d:h-d}}function IS(e,t,n,s){const{points:i,options:a}=t,{count:o,start:c,loop:d,ilen:h}=d2(i,n,s),f=TS(a);let{move:m=!0,reverse:v}=s||{},y,w,x;for(y=0;y<=h;++y)w=i[(c+(v?h-y:y))%o],!w.skip&&(m?(e.moveTo(w.x,w.y),m=!1):f(e,x,w,v,a.stepped),x=w);return d&&(w=i[(c+(v?h:0))%o],f(e,x,w,v,a.stepped)),!!d}function AS(e,t,n,s){const i=t.points,{count:a,start:o,ilen:c}=d2(i,n,s),{move:d=!0,reverse:h}=s||{};let f=0,m=0,v,y,w,x,k,D;const E=S=>(o+(h?c-S:S))%a,B=()=>{x!==k&&(e.lineTo(f,k),e.lineTo(f,x),e.lineTo(f,D))};for(d&&(y=i[E(0)],e.moveTo(y.x,y.y)),v=0;v<=c;++v){if(y=i[E(v)],y.skip)continue;const S=y.x,A=y.y,I=S|0;I===w?(A<x?x=A:A>k&&(k=A),f=(m*f+S)/++m):(B(),e.lineTo(S,A),w=I,m=0,x=k=A),D=A}B()}function Oh(e){const t=e.options,n=t.borderDash&&t.borderDash.length;return!e._decimated&&!e._loop&&!t.tension&&t.cubicInterpolationMode!=="monotone"&&!t.stepped&&!n?AS:IS}function VS(e){return e.stepped?A9:e.tension||e.cubicInterpolationMode==="monotone"?V9:Ua}function BS(e,t,n,s){let i=t._path;i||(i=t._path=new Path2D,t.path(i,n,s)&&i.closePath()),c2(e,t.options),e.stroke(i)}function PS(e,t,n,s){const{segments:i,options:a}=t,o=Oh(t);for(const c of i)c2(e,a,c.style),e.beginPath(),o(e,t,c,{start:n,end:n+s-1})&&e.closePath(),e.stroke()}const NS=typeof Path2D=="function";function zS(e,t,n,s){NS&&!t.options.segment?BS(e,t,n,s):PS(e,t,n,s)}class ia extends Hs{constructor(t){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,t&&Object.assign(this,t)}updateControlPoints(t,n){const s=this.options;if((s.tension||s.cubicInterpolationMode==="monotone")&&!s.stepped&&!this._pointsUpdated){const i=s.spanGaps?this._loop:this._fullLoop;k9(this._points,s,t,i,n),this._pointsUpdated=!0}}set points(t){this._points=t,delete this._segments,delete this._path,this._pointsUpdated=!1}get points(){return this._points}get segments(){return this._segments||(this._segments=F9(this,this.options.segment))}first(){const t=this.segments,n=this.points;return t.length&&n[t[0].start]}last(){const t=this.segments,n=this.points,s=t.length;return s&&n[t[s-1].end]}interpolate(t,n){const s=this.options,i=t[n],a=this.points,o=yg(this,{property:n,start:i,end:i});if(!o.length)return;const c=[],d=VS(s);let h,f;for(h=0,f=o.length;h<f;++h){const{start:m,end:v}=o[h],y=a[m],w=a[v];if(y===w){c.push(y);continue}const x=Math.abs((i-y[n])/(w[n]-y[n])),k=d(y,w,x,s.stepped);k[n]=t[n],c.push(k)}return c.length===1?c[0]:c}pathSegment(t,n,s){return Oh(this)(t,this,n,s)}path(t,n,s){const i=this.segments,a=Oh(this);let o=this._loop;n=n||0,s=s||this.points.length-n;for(const c of i)o&=a(t,this,c,{start:n,end:n+s-1});return!!o}draw(t,n,s,i){const a=this.options||{};(this.points||[]).length&&a.borderWidth&&(t.save(),zS(t,this,s,i),t.restore()),this.animated&&(this._pointsUpdated=!1,this._path=void 0)}}nt(ia,"id","line"),nt(ia,"defaults",{borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",borderWidth:3,capBezierPoints:!0,cubicInterpolationMode:"default",fill:!1,spanGaps:!1,stepped:!1,tension:0}),nt(ia,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"}),nt(ia,"descriptors",{_scriptable:!0,_indexable:t=>t!=="borderDash"&&t!=="fill"});function u2(e,t,n,s){const i=e.options,{[n]:a}=e.getProps([n],s);return Math.abs(t-a)<i.radius+i.hitRadius}class Td extends Hs{constructor(n){super();nt(this,"parsed");nt(this,"skip");nt(this,"stop");this.options=void 0,this.parsed=void 0,this.skip=void 0,this.stop=void 0,n&&Object.assign(this,n)}inRange(n,s,i){const a=this.options,{x:o,y:c}=this.getProps(["x","y"],i);return Math.pow(n-o,2)+Math.pow(s-c,2)<Math.pow(a.hitRadius+a.radius,2)}inXRange(n,s){return u2(this,n,"x",s)}inYRange(n,s){return u2(this,n,"y",s)}getCenterPoint(n){const{x:s,y:i}=this.getProps(["x","y"],n);return{x:s,y:i}}size(n){n=n||this.options||{};let s=n.radius||0;s=Math.max(s,s&&n.hoverRadius||0);const i=s&&n.borderWidth||0;return(s+i)*2}draw(n,s){const i=this.options;this.skip||i.radius<.1||!ki(this,s,this.size(i)/2)||(n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.fillStyle=i.backgroundColor,uh(n,i,this.x,this.y))}getRange(){const n=this.options||{};return n.radius+n.hitRadius}}nt(Td,"id","point"),nt(Td,"defaults",{borderWidth:1,hitRadius:1,hoverBorderWidth:1,hoverRadius:4,pointStyle:"circle",radius:3,rotation:0}),nt(Td,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});function h2(e,t){const{x:n,y:s,base:i,width:a,height:o}=e.getProps(["x","y","base","width","height"],t);let c,d,h,f,m;return e.horizontal?(m=o/2,c=Math.min(n,i),d=Math.max(n,i),h=s-m,f=s+m):(m=a/2,c=n-m,d=n+m,h=Math.min(s,i),f=Math.max(s,i)),{left:c,top:h,right:d,bottom:f}}function aa(e,t,n,s){return e?0:an(t,n,s)}function LS(e,t,n){const s=e.options.borderWidth,i=e.borderSkipped,a=ng(s);return{t:aa(i.top,a.top,0,n),r:aa(i.right,a.right,0,t),b:aa(i.bottom,a.bottom,0,n),l:aa(i.left,a.left,0,t)}}function FS(e,t,n){const{enableBorderRadius:s}=e.getProps(["enableBorderRadius"]),i=e.options.borderRadius,a=Wa(i),o=Math.min(t,n),c=e.borderSkipped,d=s||Kt(i);return{topLeft:aa(!d||c.top||c.left,a.topLeft,0,o),topRight:aa(!d||c.top||c.right,a.topRight,0,o),bottomLeft:aa(!d||c.bottom||c.left,a.bottomLeft,0,o),bottomRight:aa(!d||c.bottom||c.right,a.bottomRight,0,o)}}function RS(e){const t=h2(e),n=t.right-t.left,s=t.bottom-t.top,i=LS(e,n/2,s/2),a=FS(e,n/2,s/2);return{outer:{x:t.left,y:t.top,w:n,h:s,radius:a},inner:{x:t.left+i.l,y:t.top+i.t,w:n-i.l-i.r,h:s-i.t-i.b,radius:{topLeft:Math.max(0,a.topLeft-Math.max(i.t,i.l)),topRight:Math.max(0,a.topRight-Math.max(i.t,i.r)),bottomLeft:Math.max(0,a.bottomLeft-Math.max(i.b,i.l)),bottomRight:Math.max(0,a.bottomRight-Math.max(i.b,i.r))}}}}function Mh(e,t,n,s){const i=t===null,a=n===null,c=e&&!(i&&a)&&h2(e,s);return c&&(i||xi(t,c.left,c.right))&&(a||xi(n,c.top,c.bottom))}function HS(e){return e.topLeft||e.topRight||e.bottomLeft||e.bottomRight}function WS(e,t){e.rect(t.x,t.y,t.w,t.h)}function Dh(e,t,n={}){const s=e.x!==n.x?-t:0,i=e.y!==n.y?-t:0,a=(e.x+e.w!==n.x+n.w?t:0)-s,o=(e.y+e.h!==n.y+n.h?t:0)-i;return{x:e.x+s,y:e.y+i,w:e.w+a,h:e.h+o,radius:e.radius}}class Id extends Hs{constructor(t){super(),this.options=void 0,this.horizontal=void 0,this.base=void 0,this.width=void 0,this.height=void 0,this.inflateAmount=void 0,t&&Object.assign(this,t)}draw(t){const{inflateAmount:n,options:{borderColor:s,backgroundColor:i}}=this,{inner:a,outer:o}=RS(this),c=HS(o.radius)?gl:WS;t.save(),(o.w!==a.w||o.h!==a.h)&&(t.beginPath(),c(t,Dh(o,n,a)),t.clip(),c(t,Dh(a,-n,o)),t.fillStyle=s,t.fill("evenodd")),t.beginPath(),c(t,Dh(a,n)),t.fillStyle=i,t.fill(),t.restore()}inRange(t,n,s){return Mh(this,t,n,s)}inXRange(t,n){return Mh(this,t,null,n)}inYRange(t,n){return Mh(this,null,t,n)}getCenterPoint(t){const{x:n,y:s,base:i,horizontal:a}=this.getProps(["x","y","base","horizontal"],t);return{x:a?(n+i)/2:n,y:a?s:(s+i)/2}}getRange(t){return t==="x"?this.width/2:this.height/2}}nt(Id,"id","bar"),nt(Id,"defaults",{borderSkipped:"start",borderWidth:0,borderRadius:0,inflateAmount:"auto",pointStyle:void 0}),nt(Id,"defaultRoutes",{backgroundColor:"backgroundColor",borderColor:"borderColor"});var jS=Object.freeze({__proto__:null,ArcElement:Dl,BarElement:Id,LineElement:ia,PointElement:Td});const Eh=["rgb(54, 162, 235)","rgb(255, 99, 132)","rgb(255, 159, 64)","rgb(255, 205, 86)","rgb(75, 192, 192)","rgb(153, 102, 255)","rgb(201, 203, 207)"],f2=Eh.map(e=>e.replace("rgb(","rgba(").replace(")",", 0.5)"));function p2(e){return Eh[e%Eh.length]}function m2(e){return f2[e%f2.length]}function YS(e,t){return e.borderColor=p2(t),e.backgroundColor=m2(t),++t}function US(e,t){return e.backgroundColor=e.data.map(()=>p2(t++)),t}function GS(e,t){return e.backgroundColor=e.data.map(()=>m2(t++)),t}function KS(e){let t=0;return(n,s)=>{const i=e.getDatasetMeta(s).controller;i instanceof Ga?t=US(n,t):i instanceof Ho?t=GS(n,t):i&&(t=YS(n,t))}}function g2(e){let t;for(t in e)if(e[t].borderColor||e[t].backgroundColor)return!0;return!1}function ZS(e){return e&&(e.borderColor||e.backgroundColor)}var XS={id:"colors",defaults:{enabled:!0,forceOverride:!1},beforeLayout(e,t,n){if(!n.enabled)return;const{data:{datasets:s},options:i}=e.config,{elements:a}=i;if(!n.forceOverride&&(g2(s)||ZS(i)||a&&g2(a)))return;const o=KS(e);s.forEach(o)}};function JS(e,t,n,s,i){const a=i.samples||s;if(a>=n)return e.slice(t,t+n);const o=[],c=(n-2)/(a-2);let d=0;const h=t+n-1;let f=t,m,v,y,w,x;for(o[d++]=e[f],m=0;m<a-2;m++){let k=0,D=0,E;const B=Math.floor((m+1)*c)+1+t,S=Math.min(Math.floor((m+2)*c)+1,n)+t,A=S-B;for(E=B;E<S;E++)k+=e[E].x,D+=e[E].y;k/=A,D/=A;const I=Math.floor(m*c)+1+t,F=Math.min(Math.floor((m+1)*c)+1,n)+t,{x:L,y:W}=e[f];for(y=w=-1,E=I;E<F;E++)w=.5*Math.abs((L-k)*(e[E].y-W)-(L-e[E].x)*(D-W)),w>y&&(y=w,v=e[E],x=E);o[d++]=v,f=x}return o[d++]=e[h],o}function QS(e,t,n,s){let i=0,a=0,o,c,d,h,f,m,v,y,w,x;const k=[],D=t+n-1,E=e[t].x,S=e[D].x-E;for(o=t;o<t+n;++o){c=e[o],d=(c.x-E)/S*s,h=c.y;const A=d|0;if(A===f)h<w?(w=h,m=o):h>x&&(x=h,v=o),i=(a*i+c.x)/++a;else{const I=o-1;if(!ee(m)&&!ee(v)){const F=Math.min(m,v),L=Math.max(m,v);F!==y&&F!==I&&k.push({...e[F],x:i}),L!==y&&L!==I&&k.push({...e[L],x:i})}o>0&&I!==y&&k.push(e[I]),k.push(c),f=A,a=0,w=x=h,m=v=y=o}}return k}function v2(e){if(e._decimated){const t=e._data;delete e._decimated,delete e._data,Object.defineProperty(e,"data",{configurable:!0,enumerable:!0,writable:!0,value:t})}}function _2(e){e.data.datasets.forEach(t=>{v2(t)})}function qS(e,t){const n=t.length;let s=0,i;const{iScale:a}=e,{min:o,max:c,minDefined:d,maxDefined:h}=a.getUserBounds();return d&&(s=an(Si(t,a.axis,o).lo,0,n-1)),h?i=an(Si(t,a.axis,c).hi+1,s,n)-s:i=n-s,{start:s,count:i}}var $S={id:"decimation",defaults:{algorithm:"min-max",enabled:!1},beforeElementsUpdate:(e,t,n)=>{if(!n.enabled){_2(e);return}const s=e.width;e.data.datasets.forEach((i,a)=>{const{_data:o,indexAxis:c}=i,d=e.getDatasetMeta(a),h=o||i.data;if(vl([c,e.options.indexAxis])==="y"||!d.controller.supportsDecimation)return;const f=e.scales[d.xAxisID];if(f.type!=="linear"&&f.type!=="time"||e.options.parsing)return;let{start:m,count:v}=qS(d,h);const y=n.threshold||4*s;if(v<=y){v2(i);return}ee(o)&&(i._data=h,delete i.data,Object.defineProperty(i,"data",{configurable:!0,enumerable:!0,get:function(){return this._decimated},set:function(x){this._data=x}}));let w;switch(n.algorithm){case"lttb":w=JS(h,m,v,s,n);break;case"min-max":w=QS(h,m,v,s);break;default:throw new Error(`Unsupported decimation algorithm '${n.algorithm}'`)}i._decimated=w})},destroy(e){_2(e)}};function tk(e,t,n){const s=e.segments,i=e.points,a=t.points,o=[];for(const c of s){let{start:d,end:h}=c;h=Ih(d,h,i);const f=Th(n,i[d],i[h],c.loop);if(!t.segments){o.push({source:c,target:f,start:i[d],end:i[h]});continue}const m=yg(t,f);for(const v of m){const y=Th(n,a[v.start],a[v.end],v.loop),w=_g(c,i,y);for(const x of w)o.push({source:x,target:v,start:{[n]:y2(f,y,"start",Math.max)},end:{[n]:y2(f,y,"end",Math.min)}})}}return o}function Th(e,t,n,s){if(s)return;let i=t[e],a=n[e];return e==="angle"&&(i=Kn(i),a=Kn(a)),{property:e,start:i,end:a}}function ek(e,t){const{x:n=null,y:s=null}=e||{},i=t.points,a=[];return t.segments.forEach(({start:o,end:c})=>{c=Ih(o,c,i);const d=i[o],h=i[c];s!==null?(a.push({x:d.x,y:s}),a.push({x:h.x,y:s})):n!==null&&(a.push({x:n,y:d.y}),a.push({x:n,y:h.y}))}),a}function Ih(e,t,n){for(;t>e;t--){const s=n[t];if(!isNaN(s.x)&&!isNaN(s.y))break}return t}function y2(e,t,n,s){return e&&t?s(e[n],t[n]):e?e[n]:t?t[n]:0}function b2(e,t){let n=[],s=!1;return Se(e)?(s=!0,n=e):n=ek(e,t),n.length?new ia({points:n,options:{tension:0},_loop:s,_fullLoop:s}):null}function w2(e){return e&&e.fill!==!1}function nk(e,t,n){let i=e[t].fill;const a=[t];let o;if(!n)return i;for(;i!==!1&&a.indexOf(i)===-1;){if(!Pe(i))return i;if(o=e[i],!o)return!1;if(o.visible)return i;a.push(i),i=o.fill}return!1}function sk(e,t,n){const s=rk(e);if(Kt(s))return isNaN(s.value)?!1:s;let i=parseFloat(s);return Pe(i)&&Math.floor(i)===i?ik(s[0],t,i,n):["origin","start","end","stack","shape"].indexOf(s)>=0&&s}function ik(e,t,n,s){return(e==="-"||e==="+")&&(n=t+n),n===t||n<0||n>=s?!1:n}function ak(e,t){let n=null;return e==="start"?n=t.bottom:e==="end"?n=t.top:Kt(e)?n=t.getPixelForValue(e.value):t.getBasePixel&&(n=t.getBasePixel()),n}function ok(e,t,n){let s;return e==="start"?s=n:e==="end"?s=t.options.reverse?t.min:t.max:Kt(e)?s=e.value:s=t.getBaseValue(),s}function rk(e){const t=e.options,n=t.fill;let s=Vt(n&&n.target,n);return s===void 0&&(s=!!t.backgroundColor),s===!1||s===null?!1:s===!0?"origin":s}function lk(e){const{scale:t,index:n,line:s}=e,i=[],a=s.segments,o=s.points,c=ck(t,n);c.push(b2({x:null,y:t.bottom},s));for(let d=0;d<a.length;d++){const h=a[d];for(let f=h.start;f<=h.end;f++)dk(i,o[f],c)}return new ia({points:i,options:{}})}function ck(e,t){const n=[],s=e.getMatchingVisibleMetas("line");for(let i=0;i<s.length;i++){const a=s[i];if(a.index===t)break;a.hidden||n.unshift(a.dataset)}return n}function dk(e,t,n){const s=[];for(let i=0;i<n.length;i++){const a=n[i],{first:o,last:c,point:d}=uk(a,t,"x");if(!(!d||o&&c)){if(o)s.unshift(d);else if(e.push(d),!c)break}}e.push(...s)}function uk(e,t,n){const s=e.interpolate(t,n);if(!s)return{};const i=s[n],a=e.segments,o=e.points;let c=!1,d=!1;for(let h=0;h<a.length;h++){const f=a[h],m=o[f.start][n],v=o[f.end][n];if(xi(i,m,v)){c=i===m,d=i===v;break}}return{first:c,last:d,point:s}}class x2{constructor(t){this.x=t.x,this.y=t.y,this.radius=t.radius}pathSegment(t,n,s){const{x:i,y:a,radius:o}=this;return n=n||{start:0,end:ke},t.arc(i,a,o,n.end,n.start,!0),!s.bounds}interpolate(t){const{x:n,y:s,radius:i}=this,a=t.angle;return{x:n+Math.cos(a)*i,y:s+Math.sin(a)*i,angle:a}}}function hk(e){const{chart:t,fill:n,line:s}=e;if(Pe(n))return fk(t,n);if(n==="stack")return lk(e);if(n==="shape")return!0;const i=pk(e);return i instanceof x2?i:b2(i,s)}function fk(e,t){const n=e.getDatasetMeta(t);return n&&e.isDatasetVisible(t)?n.dataset:null}function pk(e){return(e.scale||{}).getPointPositionForValue?gk(e):mk(e)}function mk(e){const{scale:t={},fill:n}=e,s=ak(n,t);if(Pe(s)){const i=t.isHorizontal();return{x:i?s:null,y:i?null:s}}return null}function gk(e){const{scale:t,fill:n}=e,s=t.options,i=t.getLabels().length,a=s.reverse?t.max:t.min,o=ok(n,t,a),c=[];if(s.grid.circular){const d=t.getPointPositionForValue(0,a);return new x2({x:d.x,y:d.y,radius:t.getDistanceFromCenterForValue(o)})}for(let d=0;d<i;++d)c.push(t.getPointPositionForValue(d,o));return c}function Ah(e,t,n){const s=hk(t),{line:i,scale:a,axis:o}=t,c=i.options,d=c.fill,h=c.backgroundColor,{above:f=h,below:m=h}=d||{};s&&i.points.length&&(hd(e,n),vk(e,{line:i,target:s,above:f,below:m,area:n,scale:a,axis:o}),fd(e))}function vk(e,t){const{line:n,target:s,above:i,below:a,area:o,scale:c}=t,d=n._loop?"angle":t.axis;e.save(),d==="x"&&a!==i&&(S2(e,s,o.top),k2(e,{line:n,target:s,color:i,scale:c,property:d}),e.restore(),e.save(),S2(e,s,o.bottom)),k2(e,{line:n,target:s,color:a,scale:c,property:d}),e.restore()}function S2(e,t,n){const{segments:s,points:i}=t;let a=!0,o=!1;e.beginPath();for(const c of s){const{start:d,end:h}=c,f=i[d],m=i[Ih(d,h,i)];a?(e.moveTo(f.x,f.y),a=!1):(e.lineTo(f.x,n),e.lineTo(f.x,f.y)),o=!!t.pathSegment(e,c,{move:o}),o?e.closePath():e.lineTo(m.x,n)}e.lineTo(t.first().x,n),e.closePath(),e.clip()}function k2(e,t){const{line:n,target:s,property:i,color:a,scale:o}=t,c=tk(n,s,i);for(const{source:d,target:h,start:f,end:m}of c){const{style:{backgroundColor:v=a}={}}=d,y=s!==!0;e.save(),e.fillStyle=v,_k(e,o,y&&Th(i,f,m)),e.beginPath();const w=!!n.pathSegment(e,d);let x;if(y){w?e.closePath():C2(e,s,m,i);const k=!!s.pathSegment(e,h,{move:w,reverse:!0});x=w&&k,x||C2(e,s,f,i)}e.closePath(),e.fill(x?"evenodd":"nonzero"),e.restore()}}function _k(e,t,n){const{top:s,bottom:i}=t.chart.chartArea,{property:a,start:o,end:c}=n||{};a==="x"&&(e.beginPath(),e.rect(o,s,c-o,i-s),e.clip())}function C2(e,t,n,s){const i=t.interpolate(n,s);i&&e.lineTo(i.x,i.y)}var yk={id:"filler",afterDatasetsUpdate(e,t,n){const s=(e.data.datasets||[]).length,i=[];let a,o,c,d;for(o=0;o<s;++o)a=e.getDatasetMeta(o),c=a.dataset,d=null,c&&c.options&&c instanceof ia&&(d={visible:e.isDatasetVisible(o),index:o,fill:sk(c,o,s),chart:e,axis:a.controller.options.indexAxis,scale:a.vScale,line:c}),a.$filler=d,i.push(d);for(o=0;o<s;++o)d=i[o],!(!d||d.fill===!1)&&(d.fill=nk(i,o,n.propagate))},beforeDraw(e,t,n){const s=n.drawTime==="beforeDraw",i=e.getSortedVisibleDatasetMetas(),a=e.chartArea;for(let o=i.length-1;o>=0;--o){const c=i[o].$filler;!c||(c.line.updateControlPoints(a,c.axis),s&&c.fill&&Ah(e.ctx,c,a))}},beforeDatasetsDraw(e,t,n){if(n.drawTime!=="beforeDatasetsDraw")return;const s=e.getSortedVisibleDatasetMetas();for(let i=s.length-1;i>=0;--i){const a=s[i].$filler;w2(a)&&Ah(e.ctx,a,e.chartArea)}},beforeDatasetDraw(e,t,n){const s=t.meta.$filler;!w2(s)||n.drawTime!=="beforeDatasetDraw"||Ah(e.ctx,s,e.chartArea)},defaults:{propagate:!0,drawTime:"beforeDatasetDraw"}};const O2=(e,t)=>{let{boxHeight:n=t,boxWidth:s=t}=e;return e.usePointStyle&&(n=Math.min(n,t),s=e.pointStyleWidth||Math.min(s,t)),{boxWidth:s,boxHeight:n,itemHeight:Math.max(t,n)}},bk=(e,t)=>e!==null&&t!==null&&e.datasetIndex===t.datasetIndex&&e.index===t.index;class M2 extends Hs{constructor(t){super(),this._added=!1,this.legendHitBoxes=[],this._hoveredItem=null,this.doughnutMode=!1,this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this.legendItems=void 0,this.columnSizes=void 0,this.lineWidths=void 0,this.maxHeight=void 0,this.maxWidth=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.height=void 0,this.width=void 0,this._margins=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,n,s){this.maxWidth=t,this.maxHeight=n,this._margins=s,this.setDimensions(),this.buildLabels(),this.fit()}setDimensions(){this.isHorizontal()?(this.width=this.maxWidth,this.left=this._margins.left,this.right=this.width):(this.height=this.maxHeight,this.top=this._margins.top,this.bottom=this.height)}buildLabels(){const t=this.options.labels||{};let n=we(t.generateLabels,[this.chart],this)||[];t.filter&&(n=n.filter(s=>t.filter(s,this.chart.data))),t.sort&&(n=n.sort((s,i)=>t.sort(s,i,this.chart.data))),this.options.reverse&&n.reverse(),this.legendItems=n}fit(){const{options:t,ctx:n}=this;if(!t.display){this.width=this.height=0;return}const s=t.labels,i=$e(s.font),a=i.size,o=this._computeTitleHeight(),{boxWidth:c,itemHeight:d}=O2(s,a);let h,f;n.font=i.string,this.isHorizontal()?(h=this.maxWidth,f=this._fitRows(o,a,c,d)+10):(f=this.maxHeight,h=this._fitCols(o,i,c,d)+10),this.width=Math.min(h,t.maxWidth||this.maxWidth),this.height=Math.min(f,t.maxHeight||this.maxHeight)}_fitRows(t,n,s,i){const{ctx:a,maxWidth:o,options:{labels:{padding:c}}}=this,d=this.legendHitBoxes=[],h=this.lineWidths=[0],f=i+c;let m=t;a.textAlign="left",a.textBaseline="middle";let v=-1,y=-f;return this.legendItems.forEach((w,x)=>{const k=s+n/2+a.measureText(w.text).width;(x===0||h[h.length-1]+k+2*c>o)&&(m+=f,h[h.length-(x>0?0:1)]=0,y+=f,v++),d[x]={left:0,top:y,row:v,width:k,height:i},h[h.length-1]+=k+c}),m}_fitCols(t,n,s,i){const{ctx:a,maxHeight:o,options:{labels:{padding:c}}}=this,d=this.legendHitBoxes=[],h=this.columnSizes=[],f=o-t;let m=c,v=0,y=0,w=0,x=0;return this.legendItems.forEach((k,D)=>{const{itemWidth:E,itemHeight:B}=wk(s,n,a,k,i);D>0&&y+B+2*c>f&&(m+=v+c,h.push({width:v,height:y}),w+=v+c,x++,v=y=0),d[D]={left:w,top:y,col:x,width:E,height:B},v=Math.max(v,E),y+=B+c}),m+=v,h.push({width:v,height:y}),m}adjustHitBoxes(){if(!this.options.display)return;const t=this._computeTitleHeight(),{legendHitBoxes:n,options:{align:s,labels:{padding:i},rtl:a}}=this,o=Ro(a,this.left,this.width);if(this.isHorizontal()){let c=0,d=fn(s,this.left+i,this.right-this.lineWidths[c]);for(const h of n)c!==h.row&&(c=h.row,d=fn(s,this.left+i,this.right-this.lineWidths[c])),h.top+=this.top+t+i,h.left=o.leftForLtr(o.x(d),h.width),d+=h.width+i}else{let c=0,d=fn(s,this.top+t+i,this.bottom-this.columnSizes[c].height);for(const h of n)h.col!==c&&(c=h.col,d=fn(s,this.top+t+i,this.bottom-this.columnSizes[c].height)),h.top=d,h.left+=this.left+i,h.left=o.leftForLtr(o.x(h.left),h.width),d+=h.height+i}}isHorizontal(){return this.options.position==="top"||this.options.position==="bottom"}draw(){if(this.options.display){const t=this.ctx;hd(t,this),this._draw(),fd(t)}}_draw(){const{options:t,columnSizes:n,lineWidths:s,ctx:i}=this,{align:a,labels:o}=t,c=ze.color,d=Ro(t.rtl,this.left,this.width),h=$e(o.font),{padding:f}=o,m=h.size,v=m/2;let y;this.drawTitle(),i.textAlign=d.textAlign("left"),i.textBaseline="middle",i.lineWidth=.5,i.font=h.string;const{boxWidth:w,boxHeight:x,itemHeight:k}=O2(o,m),D=function(I,F,L){if(isNaN(w)||w<=0||isNaN(x)||x<0)return;i.save();const W=Vt(L.lineWidth,1);if(i.fillStyle=Vt(L.fillStyle,c),i.lineCap=Vt(L.lineCap,"butt"),i.lineDashOffset=Vt(L.lineDashOffset,0),i.lineJoin=Vt(L.lineJoin,"miter"),i.lineWidth=W,i.strokeStyle=Vt(L.strokeStyle,c),i.setLineDash(Vt(L.lineDash,[])),o.usePointStyle){const X={radius:x*Math.SQRT2/2,pointStyle:L.pointStyle,rotation:L.rotation,borderWidth:W},Z=d.xPlus(I,w/2),Q=F+v;eg(i,X,Z,Q,o.pointStyleWidth&&w)}else{const X=F+Math.max((m-x)/2,0),Z=d.leftForLtr(I,w),Q=Wa(L.borderRadius);i.beginPath(),Object.values(Q).some(et=>et!==0)?gl(i,{x:Z,y:X,w,h:x,radius:Q}):i.rect(Z,X,w,x),i.fill(),W!==0&&i.stroke()}i.restore()},E=function(I,F,L){Ha(i,L.text,I,F+k/2,h,{strikethrough:L.hidden,textAlign:d.textAlign(L.textAlign)})},B=this.isHorizontal(),S=this._computeTitleHeight();B?y={x:fn(a,this.left+f,this.right-s[0]),y:this.top+f+S,line:0}:y={x:this.left+f,y:fn(a,this.top+S+f,this.bottom-n[0].height),line:0},pg(this.ctx,t.textDirection);const A=k+f;this.legendItems.forEach((I,F)=>{i.strokeStyle=I.fontColor,i.fillStyle=I.fontColor;const L=i.measureText(I.text).width,W=d.textAlign(I.textAlign||(I.textAlign=o.textAlign)),X=w+v+L;let Z=y.x,Q=y.y;d.setWidth(this.width),B?F>0&&Z+X+f>this.right&&(Q=y.y+=A,y.line++,Z=y.x=fn(a,this.left+f,this.right-s[y.line])):F>0&&Q+A>this.bottom&&(Z=y.x=Z+n[y.line].width+f,y.line++,Q=y.y=fn(a,this.top+S+f,this.bottom-n[y.line].height));const et=d.x(Z);if(D(et,Q,I),Z=Ww(W,Z+w+v,B?Z+X:this.right,t.rtl),E(d.x(Z),Q,I),B)y.x+=X+f;else if(typeof I.text!="string"){const gt=h.lineHeight;y.y+=D2(I,gt)}else y.y+=A}),mg(this.ctx,t.textDirection)}drawTitle(){const t=this.options,n=t.title,s=$e(n.font),i=pn(n.padding);if(!n.display)return;const a=Ro(t.rtl,this.left,this.width),o=this.ctx,c=n.position,d=s.size/2,h=i.top+d;let f,m=this.left,v=this.width;if(this.isHorizontal())v=Math.max(...this.lineWidths),f=this.top+h,m=fn(t.align,m,this.right-v);else{const w=this.columnSizes.reduce((x,k)=>Math.max(x,k.height),0);f=h+fn(t.align,this.top,this.bottom-w-t.labels.padding-this._computeTitleHeight())}const y=fn(c,m,m+v);o.textAlign=a.textAlign(oh(c)),o.textBaseline="middle",o.strokeStyle=n.color,o.fillStyle=n.color,o.font=s.string,Ha(o,n.text,y,f,s)}_computeTitleHeight(){const t=this.options.title,n=$e(t.font),s=pn(t.padding);return t.display?n.lineHeight+s.height:0}_getLegendItemAt(t,n){let s,i,a;if(xi(t,this.left,this.right)&&xi(n,this.top,this.bottom)){for(a=this.legendHitBoxes,s=0;s<a.length;++s)if(i=a[s],xi(t,i.left,i.left+i.width)&&xi(n,i.top,i.top+i.height))return this.legendItems[s]}return null}handleEvent(t){const n=this.options;if(!kk(t.type,n))return;const s=this._getLegendItemAt(t.x,t.y);if(t.type==="mousemove"||t.type==="mouseout"){const i=this._hoveredItem,a=bk(i,s);i&&!a&&we(n.onLeave,[t,i,this],this),this._hoveredItem=s,s&&!a&&we(n.onHover,[t,s,this],this)}else s&&we(n.onClick,[t,s,this],this)}}function wk(e,t,n,s,i){const a=xk(s,e,t,n),o=Sk(i,s,t.lineHeight);return{itemWidth:a,itemHeight:o}}function xk(e,t,n,s){let i=e.text;return i&&typeof i!="string"&&(i=i.reduce((a,o)=>a.length>o.length?a:o)),t+n.size/2+s.measureText(i).width}function Sk(e,t,n){let s=e;return typeof t.text!="string"&&(s=D2(t,n)),s}function D2(e,t){const n=e.text?e.text.length+.5:0;return t*n}function kk(e,t){return!!((e==="mousemove"||e==="mouseout")&&(t.onHover||t.onLeave)||t.onClick&&(e==="click"||e==="mouseup"))}var Ck={id:"legend",_element:M2,start(e,t,n){const s=e.legend=new M2({ctx:e.ctx,options:n,chart:e});mn.configure(e,s,n),mn.addBox(e,s)},stop(e){mn.removeBox(e,e.legend),delete e.legend},beforeUpdate(e,t,n){const s=e.legend;mn.configure(e,s,n),s.options=n},afterUpdate(e){const t=e.legend;t.buildLabels(),t.adjustHitBoxes()},afterEvent(e,t){t.replay||e.legend.handleEvent(t.event)},defaults:{display:!0,position:"top",align:"center",fullSize:!0,reverse:!1,weight:1e3,onClick(e,t,n){const s=t.datasetIndex,i=n.chart;i.isDatasetVisible(s)?(i.hide(s),t.hidden=!0):(i.show(s),t.hidden=!1)},onHover:null,onLeave:null,labels:{color:e=>e.chart.options.color,boxWidth:40,padding:10,generateLabels(e){const t=e.data.datasets,{labels:{usePointStyle:n,pointStyle:s,textAlign:i,color:a,useBorderRadius:o,borderRadius:c}}=e.legend.options;return e._getSortedDatasetMetas().map(d=>{const h=d.controller.getStyle(n?0:void 0),f=pn(h.borderWidth);return{text:t[d.index].label,fillStyle:h.backgroundColor,fontColor:a,hidden:!d.visible,lineCap:h.borderCapStyle,lineDash:h.borderDash,lineDashOffset:h.borderDashOffset,lineJoin:h.borderJoinStyle,lineWidth:(f.width+f.height)/4,strokeStyle:h.borderColor,pointStyle:s||h.pointStyle,rotation:h.rotation,textAlign:i||h.textAlign,borderRadius:o&&(c||h.borderRadius),datasetIndex:d.index}},this)}},title:{color:e=>e.chart.options.color,display:!1,position:"center",text:""}},descriptors:{_scriptable:e=>!e.startsWith("on"),labels:{_scriptable:e=>!["generateLabels","filter","sort"].includes(e)}}};class Vh extends Hs{constructor(t){super(),this.chart=t.chart,this.options=t.options,this.ctx=t.ctx,this._padding=void 0,this.top=void 0,this.bottom=void 0,this.left=void 0,this.right=void 0,this.width=void 0,this.height=void 0,this.position=void 0,this.weight=void 0,this.fullSize=void 0}update(t,n){const s=this.options;if(this.left=0,this.top=0,!s.display){this.width=this.height=this.right=this.bottom=0;return}this.width=this.right=t,this.height=this.bottom=n;const i=Se(s.text)?s.text.length:1;this._padding=pn(s.padding);const a=i*$e(s.font).lineHeight+this._padding.height;this.isHorizontal()?this.height=a:this.width=a}isHorizontal(){const t=this.options.position;return t==="top"||t==="bottom"}_drawArgs(t){const{top:n,left:s,bottom:i,right:a,options:o}=this,c=o.align;let d=0,h,f,m;return this.isHorizontal()?(f=fn(c,s,a),m=n+t,h=a-s):(o.position==="left"?(f=s+t,m=fn(c,i,n),d=De*-.5):(f=a-t,m=fn(c,n,i),d=De*.5),h=i-n),{titleX:f,titleY:m,maxWidth:h,rotation:d}}draw(){const t=this.ctx,n=this.options;if(!n.display)return;const s=$e(n.font),a=s.lineHeight/2+this._padding.top,{titleX:o,titleY:c,maxWidth:d,rotation:h}=this._drawArgs(a);Ha(t,n.text,0,0,s,{color:n.color,maxWidth:d,rotation:h,textAlign:oh(n.align),textBaseline:"middle",translation:[o,c]})}}function Ok(e,t){const n=new Vh({ctx:e.ctx,options:t,chart:e});mn.configure(e,n,t),mn.addBox(e,n),e.titleBlock=n}var Mk={id:"title",_element:Vh,start(e,t,n){Ok(e,n)},stop(e){const t=e.titleBlock;mn.removeBox(e,t),delete e.titleBlock},beforeUpdate(e,t,n){const s=e.titleBlock;mn.configure(e,s,n),s.options=n},defaults:{align:"center",display:!1,font:{weight:"bold"},fullSize:!0,padding:10,position:"top",text:"",weight:2e3},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const Ad=new WeakMap;var Dk={id:"subtitle",start(e,t,n){const s=new Vh({ctx:e.ctx,options:n,chart:e});mn.configure(e,s,n),mn.addBox(e,s),Ad.set(e,s)},stop(e){mn.removeBox(e,Ad.get(e)),Ad.delete(e)},beforeUpdate(e,t,n){const s=Ad.get(e);mn.configure(e,s,n),s.options=n},defaults:{align:"center",display:!1,font:{weight:"normal"},fullSize:!0,padding:0,position:"top",text:"",weight:1500},defaultRoutes:{color:"color"},descriptors:{_scriptable:!0,_indexable:!1}};const El={average(e){if(!e.length)return!1;let t,n,s=0,i=0,a=0;for(t=0,n=e.length;t<n;++t){const o=e[t].element;if(o&&o.hasValue()){const c=o.tooltipPosition();s+=c.x,i+=c.y,++a}}return{x:s/a,y:i/a}},nearest(e,t){if(!e.length)return!1;let n=t.x,s=t.y,i=Number.POSITIVE_INFINITY,a,o,c;for(a=0,o=e.length;a<o;++a){const d=e[a].element;if(d&&d.hasValue()){const h=d.getCenterPoint(),f=ih(t,h);f<i&&(i=f,c=d)}}if(c){const d=c.tooltipPosition();n=d.x,s=d.y}return{x:n,y:s}}};function li(e,t){return t&&(Se(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function Oi(e){return(typeof e=="string"||e instanceof String)&&e.indexOf(`
|
|
41
41
|
`)>-1?e.split(`
|
|
42
|
-
`):e}function Ek(e,t){const{element:n,datasetIndex:s,index:i}=t,a=e.getDatasetMeta(s).controller,{label:o,value:c}=a.getLabelAndValue(i);return{chart:e,label:o,parsed:a.getParsed(i),raw:e.data.datasets[s].data[i],formattedValue:c,dataset:a.getDataset(),dataIndex:i,datasetIndex:s,element:n}}function E2(e,t){const n=e.chart.ctx,{body:s,footer:i,title:a}=e,{boxWidth:o,boxHeight:c}=t,d=$e(t.bodyFont),h=$e(t.titleFont),f=$e(t.footerFont),m=a.length,v=i.length,y=s.length,w=pn(t.padding);let x=w.height,k=0,D=s.reduce((S,A)=>S+A.before.length+A.lines.length+A.after.length,0);if(D+=e.beforeBody.length+e.afterBody.length,m&&(x+=m*h.lineHeight+(m-1)*t.titleSpacing+t.titleMarginBottom),D){const S=t.displayColors?Math.max(c,d.lineHeight):d.lineHeight;x+=y*S+(D-y)*d.lineHeight+(D-1)*t.bodySpacing}v&&(x+=t.footerMarginTop+v*f.lineHeight+(v-1)*t.footerSpacing);let E=0;const B=function(S){k=Math.max(k,n.measureText(S).width+E)};return n.save(),n.font=h.string,ue(e.title,B),n.font=d.string,ue(e.beforeBody.concat(e.afterBody),B),E=t.displayColors?o+2+t.boxPadding:0,ue(s,S=>{ue(S.before,B),ue(S.lines,B),ue(S.after,B)}),E=0,n.font=f.string,ue(e.footer,B),n.restore(),k+=w.width,{width:k,height:x}}function Tk(e,t){const{y:n,height:s}=t;return n<s/2?"top":n>e.height-s/2?"bottom":"center"}function Ik(e,t,n,s){const{x:i,width:a}=s,o=n.caretSize+n.caretPadding;if(e==="left"&&i+a+o>t.width||e==="right"&&i-a-o<0)return!0}function Ak(e,t,n,s){const{x:i,width:a}=n,{width:o,chartArea:{left:c,right:d}}=e;let h="center";return s==="center"?h=i<=(c+d)/2?"left":"right":i<=a/2?h="left":i>=o-a/2&&(h="right"),Ik(h,e,t,n)&&(h="center"),h}function T2(e,t,n){const s=n.yAlign||t.yAlign||Tk(e,n);return{xAlign:n.xAlign||t.xAlign||Ak(e,t,n,s),yAlign:s}}function Vk(e,t){let{x:n,width:s}=e;return t==="right"?n-=s:t==="center"&&(n-=s/2),n}function Bk(e,t,n){let{y:s,height:i}=e;return t==="top"?s+=n:t==="bottom"?s-=i+n:s-=i/2,s}function I2(e,t,n,s){const{caretSize:i,caretPadding:a,cornerRadius:o}=e,{xAlign:c,yAlign:d}=n,h=i+a,{topLeft:f,topRight:m,bottomLeft:v,bottomRight:y}=Wa(o);let w=Vk(t,c);const x=Bk(t,d,h);return d==="center"?c==="left"?w+=h:c==="right"&&(w-=h):c==="left"?w-=Math.max(f,v)+i:c==="right"&&(w+=Math.max(m,y)+i),{x:an(w,0,s.width-t.width),y:an(x,0,s.height-t.height)}}function Vd(e,t,n){const s=pn(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-s.right:e.x+s.left}function A2(e){return li([],Oi(e))}function Pk(e,t,n){return sa(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function V2(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const B2={beforeTitle:wi,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,s=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(s>0&&t.dataIndex<s)return n[t.dataIndex]}return""},afterTitle:wi,beforeBody:wi,beforeLabel:wi,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const n=e.formattedValue;return ee(n)||(t+=n),t},labelColor(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:wi,afterBody:wi,beforeFooter:wi,footer:wi,afterFooter:wi};function Bn(e,t,n,s){const i=e[t].call(n,s);return typeof i>"u"?B2[t].call(n,s):i}class Bh extends Hs{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,s=this.options.setContext(this.getContext()),i=s.enabled&&n.options.animation&&s.animations,a=new Sg(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(a)),a}getContext(){return this.$context||(this.$context=Pk(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:s}=n,i=Bn(s,"beforeTitle",this,t),a=Bn(s,"title",this,t),o=Bn(s,"afterTitle",this,t);let c=[];return c=li(c,Oi(i)),c=li(c,Oi(a)),c=li(c,Oi(o)),c}getBeforeBody(t,n){return A2(Bn(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:s}=n,i=[];return ue(t,a=>{const o={before:[],lines:[],after:[]},c=V2(s,a);li(o.before,Oi(Bn(c,"beforeLabel",this,a))),li(o.lines,Bn(c,"label",this,a)),li(o.after,Oi(Bn(c,"afterLabel",this,a))),i.push(o)}),i}getAfterBody(t,n){return A2(Bn(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:s}=n,i=Bn(s,"beforeFooter",this,t),a=Bn(s,"footer",this,t),o=Bn(s,"afterFooter",this,t);let c=[];return c=li(c,Oi(i)),c=li(c,Oi(a)),c=li(c,Oi(o)),c}_createItems(t){const n=this._active,s=this.chart.data,i=[],a=[],o=[];let c=[],d,h;for(d=0,h=n.length;d<h;++d)c.push(Ek(this.chart,n[d]));return t.filter&&(c=c.filter((f,m,v)=>t.filter(f,m,v,s))),t.itemSort&&(c=c.sort((f,m)=>t.itemSort(f,m,s))),ue(c,f=>{const m=V2(t.callbacks,f);i.push(Bn(m,"labelColor",this,f)),a.push(Bn(m,"labelPointStyle",this,f)),o.push(Bn(m,"labelTextColor",this,f))}),this.labelColors=i,this.labelPointStyles=a,this.labelTextColors=o,this.dataPoints=c,c}update(t,n){const s=this.options.setContext(this.getContext()),i=this._active;let a,o=[];if(!i.length)this.opacity!==0&&(a={opacity:0});else{const c=El[s.position].call(this,i,this._eventPosition);o=this._createItems(s),this.title=this.getTitle(o,s),this.beforeBody=this.getBeforeBody(o,s),this.body=this.getBody(o,s),this.afterBody=this.getAfterBody(o,s),this.footer=this.getFooter(o,s);const d=this._size=E2(this,s),h=Object.assign({},c,d),f=T2(this.chart,s,h),m=I2(s,h,f,this.chart);this.xAlign=f.xAlign,this.yAlign=f.yAlign,a={opacity:1,x:m.x,y:m.y,width:d.width,height:d.height,caretX:c.x,caretY:c.y}}this._tooltipItems=o,this.$context=void 0,a&&this._resolveAnimations().update(this,a),t&&s.external&&s.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,s,i){const a=this.getCaretPosition(t,s,i);n.lineTo(a.x1,a.y1),n.lineTo(a.x2,a.y2),n.lineTo(a.x3,a.y3)}getCaretPosition(t,n,s){const{xAlign:i,yAlign:a}=this,{caretSize:o,cornerRadius:c}=s,{topLeft:d,topRight:h,bottomLeft:f,bottomRight:m}=Wa(c),{x:v,y}=t,{width:w,height:x}=n;let k,D,E,B,S,A;return a==="center"?(S=y+x/2,i==="left"?(k=v,D=k-o,B=S+o,A=S-o):(k=v+w,D=k+o,B=S-o,A=S+o),E=k):(i==="left"?D=v+Math.max(d,f)+o:i==="right"?D=v+w-Math.max(h,m)-o:D=this.caretX,a==="top"?(B=y,S=B-o,k=D-o,E=D+o):(B=y+x,S=B+o,k=D+o,E=D-o),A=B),{x1:k,x2:D,x3:E,y1:B,y2:S,y3:A}}drawTitle(t,n,s){const i=this.title,a=i.length;let o,c,d;if(a){const h=Ro(s.rtl,this.x,this.width);for(t.x=Vd(this,s.titleAlign,s),n.textAlign=h.textAlign(s.titleAlign),n.textBaseline="middle",o=$e(s.titleFont),c=s.titleSpacing,n.fillStyle=s.titleColor,n.font=o.string,d=0;d<a;++d)n.fillText(i[d],h.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+c,d+1===a&&(t.y+=s.titleMarginBottom-c)}}_drawColorBox(t,n,s,i,a){const o=this.labelColors[s],c=this.labelPointStyles[s],{boxHeight:d,boxWidth:h}=a,f=$e(a.bodyFont),m=Vd(this,"left",a),v=i.x(m),y=d<f.lineHeight?(f.lineHeight-d)/2:0,w=n.y+y;if(a.usePointStyle){const x={radius:Math.min(h,d)/2,pointStyle:c.pointStyle,rotation:c.rotation,borderWidth:1},k=i.leftForLtr(v,h)+h/2,D=w+d/2;t.strokeStyle=a.multiKeyBackground,t.fillStyle=a.multiKeyBackground,uh(t,x,k,D),t.strokeStyle=o.borderColor,t.fillStyle=o.backgroundColor,uh(t,x,k,D)}else{t.lineWidth=Kt(o.borderWidth)?Math.max(...Object.values(o.borderWidth)):o.borderWidth||1,t.strokeStyle=o.borderColor,t.setLineDash(o.borderDash||[]),t.lineDashOffset=o.borderDashOffset||0;const x=i.leftForLtr(v,h),k=i.leftForLtr(i.xPlus(v,1),h-2),D=Wa(o.borderRadius);Object.values(D).some(E=>E!==0)?(t.beginPath(),t.fillStyle=a.multiKeyBackground,gl(t,{x,y:w,w:h,h:d,radius:D}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),gl(t,{x:k,y:w+1,w:h-2,h:d-2,radius:D}),t.fill()):(t.fillStyle=a.multiKeyBackground,t.fillRect(x,w,h,d),t.strokeRect(x,w,h,d),t.fillStyle=o.backgroundColor,t.fillRect(k,w+1,h-2,d-2))}t.fillStyle=this.labelTextColors[s]}drawBody(t,n,s){const{body:i}=this,{bodySpacing:a,bodyAlign:o,displayColors:c,boxHeight:d,boxWidth:h,boxPadding:f}=s,m=$e(s.bodyFont);let v=m.lineHeight,y=0;const w=Ro(s.rtl,this.x,this.width),x=function(L){n.fillText(L,w.x(t.x+y),t.y+v/2),t.y+=v+a},k=w.textAlign(o);let D,E,B,S,A,I,F;for(n.textAlign=o,n.textBaseline="middle",n.font=m.string,t.x=Vd(this,k,s),n.fillStyle=s.bodyColor,ue(this.beforeBody,x),y=c&&k!=="right"?o==="center"?h/2+f:h+2+f:0,S=0,I=i.length;S<I;++S){for(D=i[S],E=this.labelTextColors[S],n.fillStyle=E,ue(D.before,x),B=D.lines,c&&B.length&&(this._drawColorBox(n,t,S,w,s),v=Math.max(m.lineHeight,d)),A=0,F=B.length;A<F;++A)x(B[A]),v=m.lineHeight;ue(D.after,x)}y=0,v=m.lineHeight,ue(this.afterBody,x),t.y-=a}drawFooter(t,n,s){const i=this.footer,a=i.length;let o,c;if(a){const d=Ro(s.rtl,this.x,this.width);for(t.x=Vd(this,s.footerAlign,s),t.y+=s.footerMarginTop,n.textAlign=d.textAlign(s.footerAlign),n.textBaseline="middle",o=$e(s.footerFont),n.fillStyle=s.footerColor,n.font=o.string,c=0;c<a;++c)n.fillText(i[c],d.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+s.footerSpacing}}drawBackground(t,n,s,i){const{xAlign:a,yAlign:o}=this,{x:c,y:d}=t,{width:h,height:f}=s,{topLeft:m,topRight:v,bottomLeft:y,bottomRight:w}=Wa(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(c+m,d),o==="top"&&this.drawCaret(t,n,s,i),n.lineTo(c+h-v,d),n.quadraticCurveTo(c+h,d,c+h,d+v),o==="center"&&a==="right"&&this.drawCaret(t,n,s,i),n.lineTo(c+h,d+f-w),n.quadraticCurveTo(c+h,d+f,c+h-w,d+f),o==="bottom"&&this.drawCaret(t,n,s,i),n.lineTo(c+y,d+f),n.quadraticCurveTo(c,d+f,c,d+f-y),o==="center"&&a==="left"&&this.drawCaret(t,n,s,i),n.lineTo(c,d+m),n.quadraticCurveTo(c,d,c+m,d),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,s=this.$animations,i=s&&s.x,a=s&&s.y;if(i||a){const o=El[t.position].call(this,this._active,this._eventPosition);if(!o)return;const c=this._size=E2(this,t),d=Object.assign({},o,this._size),h=T2(n,t,d),f=I2(t,d,h,n);(i._to!==f.x||a._to!==f.y)&&(this.xAlign=h.xAlign,this.yAlign=h.yAlign,this.width=c.width,this.height=c.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,f))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let s=this.opacity;if(!s)return;this._updateAnimationTarget(n);const i={width:this.width,height:this.height},a={x:this.x,y:this.y};s=Math.abs(s)<.001?0:s;const o=pn(n.padding),c=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&c&&(t.save(),t.globalAlpha=s,this.drawBackground(a,t,i,n),pg(t,n.textDirection),a.y+=o.top,this.drawTitle(a,t,n),this.drawBody(a,t,n),this.drawFooter(a,t,n),mg(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const s=this._active,i=t.map(({datasetIndex:c,index:d})=>{const h=this.chart.getDatasetMeta(c);if(!h)throw new Error("Cannot find a dataset at index "+c);return{datasetIndex:c,element:h.data[d],index:d}}),a=!od(s,i),o=this._positionChanged(i,n);(a||o)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,s=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,a=this._active||[],o=this._getActiveElements(t,a,n,s),c=this._positionChanged(o,t),d=n||!od(o,a)||c;return d&&(this._active=o,(i.enabled||i.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),d}_getActiveElements(t,n,s,i){const a=this.options;if(t.type==="mouseout")return[];if(!i)return n;const o=this.chart.getElementsAtEventForMode(t,a.mode,a,s);return a.reverse&&o.reverse(),o}_positionChanged(t,n){const{caretX:s,caretY:i,options:a}=this,o=El[a.position].call(this,t,n);return o!==!1&&(s!==o.x||i!==o.y)}}nt(Bh,"positioners",El);var Nk={id:"tooltip",_element:Bh,positioners:El,afterInit(e,t,n){n&&(e.tooltip=new Bh({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:B2},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]},zk=Object.freeze({__proto__:null,Colors:XS,Decimation:$S,Filler:yk,Legend:Ck,SubTitle:Dk,Title:Mk,Tooltip:Nk});const Lk=(e,t,n,s)=>(typeof t=="string"?(n=e.push(t)-1,s.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function Fk(e,t,n,s){const i=e.indexOf(t);if(i===-1)return Lk(e,t,n,s);const a=e.lastIndexOf(t);return i!==a?n:i}const Rk=(e,t)=>e===null?null:an(Math.round(e),0,t);function P2(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class Ph extends Za{constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const n=this._addedLabels;if(n.length){const s=this.getLabels();for(const{index:i,label:a}of n)s[i]===a&&s.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,n){if(ee(t))return null;const s=this.getLabels();return n=isFinite(n)&&s[n]===t?n:Fk(s,t,Vt(n,t),this._addedLabels),Rk(n,s.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let{min:s,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(s=0),n||(i=this.getLabels().length-1)),this.min=s,this.max=i}buildTicks(){const t=this.min,n=this.max,s=this.options.offset,i=[];let a=this.getLabels();a=t===0&&n===a.length-1?a:a.slice(t,n+1),this._valueRange=Math.max(a.length-(s?0:1),1),this._startValue=this.min-(s?.5:0);for(let o=t;o<=n;o++)i.push({value:o});return i}getLabelForValue(t){return P2.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}nt(Ph,"id","category"),nt(Ph,"defaults",{ticks:{callback:P2}});function Hk(e,t){const n=[],{bounds:i,step:a,min:o,max:c,precision:d,count:h,maxTicks:f,maxDigits:m,includeBounds:v}=e,y=a||1,w=f-1,{min:x,max:k}=t,D=!ee(o),E=!ee(c),B=!ee(h),S=(k-x)/(m+1);let A=Lm((k-x)/w/y)*y,I,F,L,W;if(A<1e-14&&!D&&!E)return[{value:x},{value:k}];W=Math.ceil(k/A)-Math.floor(x/A),W>w&&(A=Lm(W*A/w/y)*y),ee(d)||(I=Math.pow(10,d),A=Math.ceil(A*I)/I),i==="ticks"?(F=Math.floor(x/A)*A,L=Math.ceil(k/A)*A):(F=x,L=k),D&&E&&a&&Pw((c-o)/a,A/1e3)?(W=Math.round(Math.min((c-o)/A,f)),A=(c-o)/W,F=o,L=c):B?(F=D?o:F,L=E?c:L,W=h-1,A=(L-F)/W):(W=(L-F)/A,ul(W,Math.round(W),A/1e3)?W=Math.round(W):W=Math.ceil(W));const X=Math.max(Rm(A),Rm(F));I=Math.pow(10,ee(d)?X:d),F=Math.round(F*I)/I,L=Math.round(L*I)/I;let Z=0;for(D&&(v&&F!==o?(n.push({value:o}),F<o&&Z++,ul(Math.round((F+Z*A)*I)/I,o,N2(o,S,e))&&Z++):F<o&&Z++);Z<W;++Z){const Q=Math.round((F+Z*A)*I)/I;if(E&&Q>c)break;n.push({value:Q})}return E&&v&&L!==c?n.length&&ul(n[n.length-1].value,c,N2(c,S,e))?n[n.length-1].value=c:n.push({value:c}):(!E||L===c)&&n.push({value:L}),n}function N2(e,t,{horizontal:n,minRotation:s}){const i=Fs(s),a=(n?Math.sin(i):Math.cos(i))||.001,o=.75*t*(""+e).length;return Math.min(t/a,o)}class Bd extends Za{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return ee(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:s}=this.getUserBounds();let{min:i,max:a}=this;const o=d=>i=n?i:d,c=d=>a=s?a:d;if(t){const d=oi(i),h=oi(a);d<0&&h<0?c(0):d>0&&h>0&&o(0)}if(i===a){let d=a===0?1:Math.abs(a*.05);c(a+d),t||o(i-d)}this.min=i,this.max=a}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:s}=t,i;return s?(i=Math.ceil(this.max/s)-Math.floor(this.min/s)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${s} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let s=this.getTickLimit();s=Math.max(2,s);const i={maxTicks:s,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},a=this._range||this,o=Hk(i,a);return t.bounds==="ticks"&&Fm(o,this,"value"),t.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const t=this.ticks;let n=this.min,s=this.max;if(super.configure(),this.options.offset&&t.length){const i=(s-n)/Math.max(t.length-1,1)/2;n-=i,s+=i}this._startValue=n,this._endValue=s,this._valueRange=s-n}getLabelForValue(t){return pl(t,this.chart.options.locale,this.options.ticks.format)}}class Nh extends Bd{determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Pe(t)?t:0,this.max=Pe(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,s=Fs(this.options.ticks.minRotation),i=(t?Math.sin(s):Math.cos(s))||.001,a=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,a.lineHeight/i))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}nt(Nh,"id","linear"),nt(Nh,"defaults",{ticks:{callback:dd.formatters.numeric}});const Tl=e=>Math.floor(na(e)),Xa=(e,t)=>Math.pow(10,Tl(e)+t);function z2(e){return e/Math.pow(10,Tl(e))===1}function L2(e,t,n){const s=Math.pow(10,n),i=Math.floor(e/s);return Math.ceil(t/s)-i}function Wk(e,t){const n=t-e;let s=Tl(n);for(;L2(e,t,s)>10;)s++;for(;L2(e,t,s)<10;)s--;return Math.min(s,Tl(e))}function jk(e,{min:t,max:n}){t=Gn(e.min,t);const s=[],i=Tl(t);let a=Wk(t,n),o=a<0?Math.pow(10,Math.abs(a)):1;const c=Math.pow(10,a),d=i>a?Math.pow(10,i):0,h=Math.round((t-d)*o)/o,f=Math.floor((t-d)/c/10)*c*10;let m=Math.floor((h-f)/Math.pow(10,a)),v=Gn(e.min,Math.round((d+f+m*Math.pow(10,a))*o)/o);for(;v<n;)s.push({value:v,major:z2(v),significand:m}),m>=10?m=m<15?15:20:m++,m>=20&&(a++,m=2,o=a>=0?1:o),v=Math.round((d+f+m*Math.pow(10,a))*o)/o;const y=Gn(e.max,v);return s.push({value:y,major:z2(y),significand:m}),s}class zh extends Za{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,n){const s=Bd.prototype.parse.apply(this,[t,n]);if(s===0){this._zero=!0;return}return Pe(s)&&s>0?s:null}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Pe(t)?Math.max(0,t):null,this.max=Pe(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!Pe(this._userMin)&&(this.min=t===Xa(this.min,0)?Xa(this.min,-1):Xa(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let s=this.min,i=this.max;const a=c=>s=t?s:c,o=c=>i=n?i:c;s===i&&(s<=0?(a(1),o(10)):(a(Xa(s,-1)),o(Xa(i,1)))),s<=0&&a(Xa(i,-1)),i<=0&&o(Xa(s,1)),this.min=s,this.max=i}buildTicks(){const t=this.options,n={min:this._userMin,max:this._userMax},s=jk(n,this);return t.bounds==="ticks"&&Fm(s,this,"value"),t.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}getLabelForValue(t){return t===void 0?"0":pl(t,this.chart.options.locale,this.options.ticks.format)}configure(){const t=this.min;super.configure(),this._startValue=na(t),this._valueRange=na(this.max)-na(t)}getPixelForValue(t){return(t===void 0||t===0)&&(t=this.min),t===null||isNaN(t)?NaN:this.getPixelForDecimal(t===this.min?0:(na(t)-this._startValue)/this._valueRange)}getValueForPixel(t){const n=this.getDecimalForPixel(t);return Math.pow(10,this._startValue+n*this._valueRange)}}nt(zh,"id","logarithmic"),nt(zh,"defaults",{ticks:{callback:dd.formatters.logarithmic,major:{enabled:!0}}});function Lh(e){const t=e.ticks;if(t.display&&e.display){const n=pn(t.backdropPadding);return Vt(t.font&&t.font.size,ze.font.size)+n.height}return 0}function Yk(e,t,n){return n=Se(n)?n:[n],{w:qw(e,t.string,n),h:n.length*t.lineHeight}}function F2(e,t,n,s,i){return e===s||e===i?{start:t-n/2,end:t+n/2}:e<s||e>i?{start:t-n,end:t}:{start:t,end:t+n}}function Uk(e){const t={l:e.left+e._padding.left,r:e.right-e._padding.right,t:e.top+e._padding.top,b:e.bottom-e._padding.bottom},n=Object.assign({},t),s=[],i=[],a=e._pointLabels.length,o=e.options.pointLabels,c=o.centerPointLabels?De/a:0;for(let d=0;d<a;d++){const h=o.setContext(e.getPointLabelContext(d));i[d]=h.padding;const f=e.getPointPosition(d,e.drawingArea+i[d],c),m=$e(h.font),v=Yk(e.ctx,m,e._pointLabels[d]);s[d]=v;const y=Kn(e.getIndexAngle(d)+c),w=Math.round(sh(y)),x=F2(w,f.x,v.w,0,180),k=F2(w,f.y,v.h,90,270);Gk(n,t,y,x,k)}e.setCenterPoint(t.l-n.l,n.r-t.r,t.t-n.t,n.b-t.b),e._pointLabelItems=Xk(e,s,i)}function Gk(e,t,n,s,i){const a=Math.abs(Math.sin(n)),o=Math.abs(Math.cos(n));let c=0,d=0;s.start<t.l?(c=(t.l-s.start)/a,e.l=Math.min(e.l,t.l-c)):s.end>t.r&&(c=(s.end-t.r)/a,e.r=Math.max(e.r,t.r+c)),i.start<t.t?(d=(t.t-i.start)/o,e.t=Math.min(e.t,t.t-d)):i.end>t.b&&(d=(i.end-t.b)/o,e.b=Math.max(e.b,t.b+d))}function Kk(e,t,n){const s=e.drawingArea,{extra:i,additionalAngle:a,padding:o,size:c}=n,d=e.getPointPosition(t,s+i+o,a),h=Math.round(sh(Kn(d.angle+Ne))),f=qk(d.y,c.h,h),m=Jk(h),v=Qk(d.x,c.w,m);return{visible:!0,x:d.x,y:f,textAlign:m,left:v,top:f,right:v+c.w,bottom:f+c.h}}function Zk(e,t){if(!t)return!0;const{left:n,top:s,right:i,bottom:a}=e;return!(ki({x:n,y:s},t)||ki({x:n,y:a},t)||ki({x:i,y:s},t)||ki({x:i,y:a},t))}function Xk(e,t,n){const s=[],i=e._pointLabels.length,a=e.options,{centerPointLabels:o,display:c}=a.pointLabels,d={extra:Lh(a)/2,additionalAngle:o?De/i:0};let h;for(let f=0;f<i;f++){d.padding=n[f],d.size=t[f];const m=Kk(e,f,d);s.push(m),c==="auto"&&(m.visible=Zk(m,h),m.visible&&(h=m))}return s}function Jk(e){return e===0||e===180?"center":e<180?"left":"right"}function Qk(e,t,n){return n==="right"?e-=t:n==="center"&&(e-=t/2),e}function qk(e,t,n){return n===90||n===270?e-=t/2:(n>270||n<90)&&(e-=t),e}function $k(e,t,n){const{left:s,top:i,right:a,bottom:o}=n,{backdropColor:c}=t;if(!ee(c)){const d=Wa(t.borderRadius),h=pn(t.backdropPadding);e.fillStyle=c;const f=s-h.left,m=i-h.top,v=a-s+h.width,y=o-i+h.height;Object.values(d).some(w=>w!==0)?(e.beginPath(),gl(e,{x:f,y:m,w:v,h:y,radius:d}),e.fill()):e.fillRect(f,m,v,y)}}function tC(e,t){const{ctx:n,options:{pointLabels:s}}=e;for(let i=t-1;i>=0;i--){const a=e._pointLabelItems[i];if(!a.visible)continue;const o=s.setContext(e.getPointLabelContext(i));$k(n,o,a);const c=$e(o.font),{x:d,y:h,textAlign:f}=a;Ha(n,e._pointLabels[i],d,h+c.lineHeight/2,c,{color:o.color,textAlign:f,textBaseline:"middle"})}}function R2(e,t,n,s){const{ctx:i}=e;if(n)i.arc(e.xCenter,e.yCenter,t,0,ke);else{let a=e.getPointPosition(0,t);i.moveTo(a.x,a.y);for(let o=1;o<s;o++)a=e.getPointPosition(o,t),i.lineTo(a.x,a.y)}}function eC(e,t,n,s,i){const a=e.ctx,o=t.circular,{color:c,lineWidth:d}=t;!o&&!s||!c||!d||n<0||(a.save(),a.strokeStyle=c,a.lineWidth=d,a.setLineDash(i.dash),a.lineDashOffset=i.dashOffset,a.beginPath(),R2(e,n,o,s),a.closePath(),a.stroke(),a.restore())}function nC(e,t,n){return sa(e,{label:n,index:t,type:"pointLabel"})}class Il extends Bd{constructor(t){super(t),this.xCenter=void 0,this.yCenter=void 0,this.drawingArea=void 0,this._pointLabels=[],this._pointLabelItems=[]}setDimensions(){const t=this._padding=pn(Lh(this.options)/2),n=this.width=this.maxWidth-t.width,s=this.height=this.maxHeight-t.height;this.xCenter=Math.floor(this.left+n/2+t.left),this.yCenter=Math.floor(this.top+s/2+t.top),this.drawingArea=Math.floor(Math.min(n,s)/2)}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!1);this.min=Pe(t)&&!isNaN(t)?t:0,this.max=Pe(n)&&!isNaN(n)?n:0,this.handleTickRangeOptions()}computeTickLimit(){return Math.ceil(this.drawingArea/Lh(this.options))}generateTickLabels(t){Bd.prototype.generateTickLabels.call(this,t),this._pointLabels=this.getLabels().map((n,s)=>{const i=we(this.options.pointLabels.callback,[n,s],this);return i||i===0?i:""}).filter((n,s)=>this.chart.getDataVisibility(s))}fit(){const t=this.options;t.display&&t.pointLabels.display?Uk(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,n,s,i){this.xCenter+=Math.floor((t-n)/2),this.yCenter+=Math.floor((s-i)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,n,s,i))}getIndexAngle(t){const n=ke/(this._pointLabels.length||1),s=this.options.startAngle||0;return Kn(t*n+Fs(s))}getDistanceFromCenterForValue(t){if(ee(t))return NaN;const n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*n:(t-this.min)*n}getValueForDistanceFromCenter(t){if(ee(t))return NaN;const n=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(t){const n=this._pointLabels||[];if(t>=0&&t<n.length){const s=n[t];return nC(this.getContext(),t,s)}}getPointPosition(t,n,s=0){const i=this.getIndexAngle(t)-Ne+s;return{x:Math.cos(i)*n+this.xCenter,y:Math.sin(i)*n+this.yCenter,angle:i}}getPointPositionForValue(t,n){return this.getPointPosition(t,this.getDistanceFromCenterForValue(n))}getBasePosition(t){return this.getPointPositionForValue(t||0,this.getBaseValue())}getPointLabelPosition(t){const{left:n,top:s,right:i,bottom:a}=this._pointLabelItems[t];return{left:n,top:s,right:i,bottom:a}}drawBackground(){const{backgroundColor:t,grid:{circular:n}}=this.options;if(t){const s=this.ctx;s.save(),s.beginPath(),R2(this,this.getDistanceFromCenterForValue(this._endValue),n,this._pointLabels.length),s.closePath(),s.fillStyle=t,s.fill(),s.restore()}}drawGrid(){const t=this.ctx,n=this.options,{angleLines:s,grid:i,border:a}=n,o=this._pointLabels.length;let c,d,h;if(n.pointLabels.display&&tC(this,o),i.display&&this.ticks.forEach((f,m)=>{if(m!==0){d=this.getDistanceFromCenterForValue(f.value);const v=this.getContext(m),y=i.setContext(v),w=a.setContext(v);eC(this,y,d,o,w)}}),s.display){for(t.save(),c=o-1;c>=0;c--){const f=s.setContext(this.getPointLabelContext(c)),{color:m,lineWidth:v}=f;!v||!m||(t.lineWidth=v,t.strokeStyle=m,t.setLineDash(f.borderDash),t.lineDashOffset=f.borderDashOffset,d=this.getDistanceFromCenterForValue(n.ticks.reverse?this.min:this.max),h=this.getPointPosition(c,d),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(h.x,h.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,n=this.options,s=n.ticks;if(!s.display)return;const i=this.getIndexAngle(0);let a,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(i),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((c,d)=>{if(d===0&&!n.reverse)return;const h=s.setContext(this.getContext(d)),f=$e(h.font);if(a=this.getDistanceFromCenterForValue(this.ticks[d].value),h.showLabelBackdrop){t.font=f.string,o=t.measureText(c.label).width,t.fillStyle=h.backdropColor;const m=pn(h.backdropPadding);t.fillRect(-o/2-m.left,-a-f.size/2-m.top,o+m.width,f.size+m.height)}Ha(t,c.label,0,-a,f,{color:h.color})}),t.restore()}drawTitle(){}}nt(Il,"id","radialLinear"),nt(Il,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:dd.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback(t){return t},padding:5,centerPointLabels:!1}}),nt(Il,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),nt(Il,"descriptors",{angleLines:{_fallback:"grid"}});const Pd={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Pn=Object.keys(Pd);function sC(e,t){return e-t}function H2(e,t){if(ee(t))return null;const n=e._adapter,{parser:s,round:i,isoWeekday:a}=e._parseOpts;let o=t;return typeof s=="function"&&(o=s(o)),Pe(o)||(o=typeof s=="string"?n.parse(o,s):n.parse(o)),o===null?null:(i&&(o=i==="week"&&(zo(a)||a===!0)?n.startOf(o,"isoWeek",a):n.startOf(o,i)),+o)}function W2(e,t,n,s){const i=Pn.length;for(let a=Pn.indexOf(e);a<i-1;++a){const o=Pd[Pn[a]],c=o.steps?o.steps:Number.MAX_SAFE_INTEGER;if(o.common&&Math.ceil((n-t)/(c*o.size))<=s)return Pn[a]}return Pn[i-1]}function iC(e,t,n,s,i){for(let a=Pn.length-1;a>=Pn.indexOf(n);a--){const o=Pn[a];if(Pd[o].common&&e._adapter.diff(i,s,o)>=t-1)return o}return Pn[n?Pn.indexOf(n):0]}function aC(e){for(let t=Pn.indexOf(e)+1,n=Pn.length;t<n;++t)if(Pd[Pn[t]].common)return Pn[t]}function j2(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:s,hi:i}=ah(n,t),a=n[s]>=t?n[s]:n[i];e[a]=!0}}function oC(e,t,n,s){const i=e._adapter,a=+i.startOf(t[0].value,s),o=t[t.length-1].value;let c,d;for(c=a;c<=o;c=+i.add(c,1,s))d=n[c],d>=0&&(t[d].major=!0);return t}function Y2(e,t,n){const s=[],i={},a=t.length;let o,c;for(o=0;o<a;++o)c=t[o],i[c]=o,s.push({value:c,major:!1});return a===0||!n?s:oC(e,s,i,n)}class Al extends Za{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,n={}){const s=t.time||(t.time={}),i=this._adapter=new px._date(t.adapters.date);i.init(n),cl(s.displayFormats,i.formats()),this._parseOpts={parser:s.parser,round:s.round,isoWeekday:s.isoWeekday},super.init(t),this._normalized=n.normalized}parse(t,n){return t===void 0?null:H2(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,n=this._adapter,s=t.time.unit||"day";let{min:i,max:a,minDefined:o,maxDefined:c}=this.getUserBounds();function d(h){!o&&!isNaN(h.min)&&(i=Math.min(i,h.min)),!c&&!isNaN(h.max)&&(a=Math.max(a,h.max))}(!o||!c)&&(d(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&d(this.getMinMax(!1))),i=Pe(i)&&!isNaN(i)?i:+n.startOf(Date.now(),s),a=Pe(a)&&!isNaN(a)?a:+n.endOf(Date.now(),s)+1,this.min=Math.min(i,a-1),this.max=Math.max(i+1,a)}_getLabelBounds(){const t=this.getLabelTimestamps();let n=Number.POSITIVE_INFINITY,s=Number.NEGATIVE_INFINITY;return t.length&&(n=t[0],s=t[t.length-1]),{min:n,max:s}}buildTicks(){const t=this.options,n=t.time,s=t.ticks,i=s.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const a=this.min,o=this.max,c=Fw(i,a,o);return this._unit=n.unit||(s.autoSkip?W2(n.minUnit,this.min,this.max,this._getLabelCapacity(a)):iC(this,c.length,n.minUnit,this.min,this.max)),this._majorUnit=!s.major.enabled||this._unit==="year"?void 0:aC(this._unit),this.initOffsets(i),t.reverse&&c.reverse(),Y2(this,c,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let n=0,s=0,i,a;this.options.offset&&t.length&&(i=this.getDecimalForValue(t[0]),t.length===1?n=1-i:n=(this.getDecimalForValue(t[1])-i)/2,a=this.getDecimalForValue(t[t.length-1]),t.length===1?s=a:s=(a-this.getDecimalForValue(t[t.length-2]))/2);const o=t.length<3?.5:.25;n=an(n,0,o),s=an(s,0,o),this._offsets={start:n,end:s,factor:1/(n+1+s)}}_generate(){const t=this._adapter,n=this.min,s=this.max,i=this.options,a=i.time,o=a.unit||W2(a.minUnit,n,s,this._getLabelCapacity(n)),c=Vt(i.ticks.stepSize,1),d=o==="week"?a.isoWeekday:!1,h=zo(d)||d===!0,f={};let m=n,v,y;if(h&&(m=+t.startOf(m,"isoWeek",d)),m=+t.startOf(m,h?"day":o),t.diff(s,n,o)>1e5*c)throw new Error(n+" and "+s+" are too far apart with stepSize of "+c+" "+o);const w=i.ticks.source==="data"&&this.getDataTimestamps();for(v=m,y=0;v<s;v=+t.add(v,c,o),y++)j2(f,v,w);return(v===s||i.bounds==="ticks"||y===1)&&j2(f,v,w),Object.keys(f).sort((x,k)=>x-k).map(x=>+x)}getLabelForValue(t){const n=this._adapter,s=this.options.time;return s.tooltipFormat?n.format(t,s.tooltipFormat):n.format(t,s.displayFormats.datetime)}format(t,n){const i=this.options.time.displayFormats,a=this._unit,o=n||i[a];return this._adapter.format(t,o)}_tickFormatFunction(t,n,s,i){const a=this.options,o=a.ticks.callback;if(o)return we(o,[t,n,s],this);const c=a.time.displayFormats,d=this._unit,h=this._majorUnit,f=d&&c[d],m=h&&c[h],v=s[n],y=h&&m&&v&&v.major;return this._adapter.format(t,i||(y?m:f))}generateTickLabels(t){let n,s,i;for(n=0,s=t.length;n<s;++n)i=t[n],i.label=this._tickFormatFunction(i.value,n,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const n=this._offsets,s=this.getDecimalForValue(t);return this.getPixelForDecimal((n.start+s)*n.factor)}getValueForPixel(t){const n=this._offsets,s=this.getDecimalForPixel(t)/n.factor-n.end;return this.min+s*(this.max-this.min)}_getLabelSize(t){const n=this.options.ticks,s=this.ctx.measureText(t).width,i=Fs(this.isHorizontal()?n.maxRotation:n.minRotation),a=Math.cos(i),o=Math.sin(i),c=this._resolveTickFontOptions(0).size;return{w:s*a+c*o,h:s*o+c*a}}_getLabelCapacity(t){const n=this.options.time,s=n.displayFormats,i=s[n.unit]||s.millisecond,a=this._tickFormatFunction(t,0,Y2(this,[t],this._majorUnit),i),o=this._getLabelSize(a),c=Math.floor(this.isHorizontal()?this.width/o.w:this.height/o.h)-1;return c>0?c:1}getDataTimestamps(){let t=this._cache.data||[],n,s;if(t.length)return t;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,s=i.length;n<s;++n)t=t.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let n,s;if(t.length)return t;const i=this.getLabels();for(n=0,s=i.length;n<s;++n)t.push(H2(this,i[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return Ym(t.sort(sC))}}nt(Al,"id","time"),nt(Al,"defaults",{bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}});function Nd(e,t,n){let s=0,i=e.length-1,a,o,c,d;n?(t>=e[s].pos&&t<=e[i].pos&&({lo:s,hi:i}=Si(e,"pos",t)),{pos:a,time:c}=e[s],{pos:o,time:d}=e[i]):(t>=e[s].time&&t<=e[i].time&&({lo:s,hi:i}=Si(e,"time",t)),{time:a,pos:c}=e[s],{time:o,pos:d}=e[i]);const h=o-a;return h?c+(d-c)*(t-a)/h:c}class Fh extends Al{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=Nd(n,this.min),this._tableRange=Nd(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:s}=this,i=[],a=[];let o,c,d,h,f;for(o=0,c=t.length;o<c;++o)h=t[o],h>=n&&h<=s&&i.push(h);if(i.length<2)return[{time:n,pos:0},{time:s,pos:1}];for(o=0,c=i.length;o<c;++o)f=i[o+1],d=i[o-1],h=i[o],Math.round((f+d)/2)!==h&&a.push({time:h,pos:o/(c-1)});return a}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),s=this.getLabelTimestamps();return n.length&&s.length?t=this.normalize(n.concat(s)):t=n.length?n:s,t=this._cache.all=t,t}getDecimalForValue(t){return(Nd(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,s=this.getDecimalForPixel(t)/n.factor-n.end;return Nd(this._table,s*this._tableRange+this._minPos,!0)}}nt(Fh,"id","timeseries"),nt(Fh,"defaults",Al.defaults);var rC=Object.freeze({__proto__:null,CategoryScale:Ph,LinearScale:Nh,LogarithmicScale:zh,RadialLinearScale:Il,TimeScale:Al,TimeSeriesScale:Fh});const Rh=[fx,jS,zk,rC],U2={data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},datasetIdKey:{type:String,default:"label"},updateMode:{type:String,default:void 0}},lC={type:{type:String,required:!0},...U2},cC=l.version[0]==="2"?(e,t)=>Object.assign(e,{attrs:t}):(e,t)=>Object.assign(e,t);function jo(e){return l.isProxy(e)?l.toRaw(e):e}function dC(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;return l.isProxy(t)?new Proxy(e,{}):e}function uC(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function G2(e,t){e.labels=t}function K2(e,t,n){const s=[];e.datasets=t.map(i=>{const a=e.datasets.find(o=>o[n]===i[n]);return!a||!i.data||s.includes(a)?{...i}:(s.push(a),Object.assign(a,i),a)})}function hC(e,t){const n={labels:[],datasets:[]};return G2(n,e.labels),K2(n,e.datasets,t),n}const fC=l.defineComponent({props:lC,setup(e,t){let{expose:n}=t;const s=l.ref(null),i=l.shallowRef(null);n({chart:i});const a=()=>{if(!s.value)return;const{type:d,data:h,options:f,plugins:m,datasetIdKey:v}=e,y=hC(h,v),w=dC(y,h);i.value=new fs(s.value,{type:d,data:w,options:{...f},plugins:m})},o=()=>{const d=l.toRaw(i.value);d&&(d.destroy(),i.value=null)},c=d=>{d.update(e.updateMode)};return l.onMounted(a),l.onBeforeUnmount(o),l.watch([()=>e.options,()=>e.data],(d,h)=>{let[f,m]=d,[v,y]=h;const w=l.toRaw(i.value);if(!w)return;let x=!1;if(f){const k=jo(f),D=jo(v);k&&k!==D&&(uC(w,k),x=!0)}if(m){const k=jo(m.labels),D=jo(y.labels),E=jo(m.datasets),B=jo(y.datasets);k!==D&&(G2(w.config.data,k),x=!0),E&&E!==B&&(K2(w.config.data,E,e.datasetIdKey),x=!0)}x&&c(w)},{deep:!0}),()=>l.h("canvas",{ref:s})}});function zd(e,t){return fs.register(t),l.defineComponent({props:U2,setup(n,s){let{expose:i}=s;const a=l.shallowRef(null),o=c=>{a.value=c==null?void 0:c.chart};return i({chart:a}),()=>l.h(fC,cC({ref:o},{type:e,...n}))}})}const Z2=zd("bar",yl),pC=zd("line",bl),mC=zd("pie",yd),gC=zd("polarArea",Ho),oa={gp50:"#f3fcf8",gp100:"#e2f8ef",gp200:"#abedd3",gp300:"#6ddfb1",gp400:"#2db981",gp500:"#239f6d",gp600:"#1c7d56",gp700:"#136746",ta50:"#eefcfa",ta100:"#dcf9f6",ta200:"#a2f1e5",ta300:"#51e6d0",ta400:"#20c5ad",ta500:"#18aa94",ta600:"#138675",ta700:"#0f6b5d",ts50:"#f5fbff",ts100:"#e6f6fe",ts200:"#C2EDFF",ts300:"#7BD0F4",ts400:"#42AAD7",ts500:"#1F86B2",ts600:"#18698B",ts700:"#155875",bn50:"#f6f9fe",bn100:"#e6effe",bn200:"#b4cdf8",bn300:"#729ee9",bn400:"#467bd8",bn500:"#2f64c1",bn600:"#2051a7",bn700:"#19438a",in50:"#f5f6ff",in100:"#ebefff",in200:"#CED6FD",in300:"#9bacf8",in400:"#6a7cd7",in500:"#4b5caf",in600:"#374486",in700:"#2f396f",vr50:"#faf5ff",vr100:"#f7f0ff",vr200:"#E6D2F9",vr300:"#CEABED",vr400:"#a772d5",vr500:"#8955B9",vr600:"#6B3A98",vr700:"#5c3082",pp50:"#fff5fb",pp100:"#ffebf7",pp200:"#F9C8E2",pp300:"#EF8FC0",pp400:"#DA629F",pp500:"#BE377C",pp600:"#A12663",pp700:"#88255a",rc50:"#fef6f7",rc100:"#ffebed",rc200:"#FABDC5",rc300:"#F98B98",rc400:"#F3596C",rc500:"#E03E52",rc600:"#C92C3F",rc700:"#b22435",og50:"#fef7f6",og100:"#ffefeb",og200:"#FFD6CC",og300:"#FDAF9B",og400:"#FF8567",og500:"#F06442",og600:"#D64B29",og700:"#bc4224",al50:"#fefbf6",al100:"#fdf3e2",al200:"#ffe5b8",al300:"#fdd286",al400:"#f6bd5a",al500:"#eda831",al600:"#d89013",al700:"#c08011",n0:"#FFFFFF",n10:"#FAFCFE",n20:"#F4F8FB",n30:"#E7EDF3",n40:"#DFE5EC",n50:"#D6DCE3",n100:"#C3CCD5",n200:"#ACB8C3",n300:"#99A6B2",n400:"#8794A1",n500:"#647382",n600:"#52616F",n700:"#3B4754",n800:"#28333E",n900:"#1D262F",palete:'["Light Neutrals", "Light", #FFFFFF, #FAFCFE, #F4F8FB, #E7EDF3, #DFE5EC, "$n-0", "$n-10", "$n-20", "$n-30", "$n-40"], ["Mid Neutrals", "Gray", #D6DCE3, #C3CCD5, #ACB8C3, #99A6B2, #8794A1, "$n-50", "$n-100", "$n-200", "$n-300", "$n-400"], ["Dark Neutrals", "Dark", #647382, #52616F, #3B4754, #28333E, #1D262F, "$n-500", "$n-600", "$n-700", "$n-800", "$n-900"], ["Piccolo Green", "Green", #f3fcf8, #e2f8ef, #abedd3, #6ddfb1, #2db981, #239f6d, #1c7d56, #136746, "$gp-50", "$gp-100", "$gp-200", "$gp-300", "$gp-400", "$gp-500", "$gp-600", "$gp-700"], ["Aquaman Teal", "Teal", #eefcfa, #dcf9f6, #a2f1e5, #51e6d0, #20c5ad, #18aa94, #138675, #0f6b5d, "$ta-50", "$ta-100", "$ta-200", "$ta-300", "$ta-400", "$ta-500", "$ta-600", "$ta-700"], ["Sulivan Turquoise", "Turquoise", #f5fbff, #e6f6fe, #C2EDFF, #7BD0F4, #42AAD7, #1F86B2, #18698B, #155875, "$ts-50", "$ts-100", "$ts-200", "$ts-300", "$ts-400", "$ts-500", "$ts-600", "$ts-700"], ["Nocturne Blue", "Blue", #f6f9fe, #e6effe, #b4cdf8, #729ee9, #467bd8, #2f64c1, #2051a7, #19438a, "$bn-50", "$bn-100", "$bn-200", "$bn-300", "$bn-400", "$bn-500", "$bn-600", "$bn-700"], ["Nightwing Indigo", "Indigo", #f5f6ff, #ebefff, #CED6FD, #9bacf8, #6a7cd7, #4b5caf, #374486, #2f396f, "$in-50", "$in-100", "$in-200", "$in-300", "$in-400", "$in-500", "$in-600", "$in-700"], ["Raven Violet", "Violet", #faf5ff, #f7f0ff, #E6D2F9, #CEABED, #a772d5, #8955B9, #6B3A98, #5c3082, "$vr-50", "$vr-100", "$vr-200", "$vr-300", "$vr-400", "$vr-500", "$vr-600", "$vr-700"], ["Peppa Pink", "Pink", #fff5fb, #ffebf7, #F9C8E2, #EF8FC0, #DA629F, #BE377C, #A12663, #88255a, "$pp-50", "$pp-100", "$pp-200", "$pp-300", "$pp-400", "$pp-500", "$pp-600", "$pp-700"], ["Carmen Red", "Red", #fef6f7, #ffebed, #FABDC5, #F98B98, #F3596C, #E03E52, #C92C3F, #b22435, "$rc-50", "$rc-100", "$rc-200", "$rc-300", "$rc-400", "$rc-500", "$rc-600", "$rc-700"], ["Goku Orange", "Orange", #fef7f6, #ffefeb, #FFD6CC, #FDAF9B, #FF8567, #F06442, #D64B29, #bc4224, "$og-50", "$og-100", "$og-200", "$og-300", "$og-400", "$og-500", "$og-600", "$og-700"], ["Lisa Amber", "Amber", #fefbf6, #fdf3e2, #ffe5b8, #fdd286, #f6bd5a, #eda831, #d89013, #c08011, "$al-50", "$al-100", "$al-200", "$al-300", "$al-400", "$al-500", "$al-600", "$al-700"]'},Yo=e=>{let t=[],n={};const s=/(\[[^[\]]*\])/g,i=e.match(s);for(let a=0;a<i.length;a++){i[a]=i[a].replace("[",""),i[a]=i[a].replace("]","");let o=i[a].split(",");n.colorName=o[0].trim().replace(/"/g,""),n.variantName=o[1].trim().replace(/"/g,""),n.color400=o[6],n.colorShades=[],n.colorTokens=[],n.colorData=[];let c=!1;for(let d=2,h=2;d<o.length;d++,h++)o[d].includes("#")?(n.colorShades.push(o[d].trim()),n.colorData[h-2]={},n.colorData[h-2].shade=o[d].trim()):o[d].includes("$")&&(n.colorTokens.push(o[d].trim().replace(/"/g,"")),n.colorData[h-2].token=o[d].trim().replace(/"/g,"")),!c&&o[d+1].includes("$")&&(h=1,c=!0);t.push(n),n={}}return t},O1t="";fs.register(...Rh);const vC={components:{Bar:Z2},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},barWidth:{type:Number,default:1}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{responsive:!0,maintainAspectRatio:!1,categoryPercentage:null,plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0},barWidth:{handler(e){e>=.1&&e<=1?this.chartOptions.categoryPercentage=e:this.chartOptions.categoryPercentage=1},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};this.chartOptions.plugins.legend.display=!0,e.forEach(s=>{const i=s.name;let a;e.length===1&&(a=2,n[i]=t[a],this.chartOptions.plugins.legend.display=!1),n[i]||(a=Object.keys(n).length%t.length,n[i]=t[a]),s.backgroundColor=n[i],s.borderRadius=6})}}},_C={class:"responsive-container"};function yC(e,t,n,s,i,a){const o=l.resolveComponent("Bar");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",_C,[l.createVNode(o,{is:"bar",data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const bC=st(vC,[["render",yC],["__scopeId","data-v-1e55dea1"]]),M1t="";fs.register(...Rh);const wC={components:{Line:pC},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},showLabelName:{type:Boolean,required:!0,default:!0},fill:{type:Boolean,default:!1},isDashed:{type:Boolean,default:!1},borderDash:{type:Array,default:()=>[]},smoothing:{type:Number,default:.3}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{interaction:{intersect:!1},scales:{x:{display:!0,title:{display:!0}},y:{display:!0,title:{display:!0}}},tension:this.smoothing,responsive:!0,maintainAspectRatio:!1,pieceLabel:{mode:"percentage",precision:1},plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}},fill:this.fill}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0},isDashed:{handler(e){e===!0&&this.checkDashed()},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:this.showLabelName?i.name:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?this.fill?t.colorShades.map(s=>s+"80"):t.colorShades:[]},setColors(e,t){const n={};e.forEach((s,i)=>{const a=s.name;n[a]||(n[a]=t.slice()),s.data.length>0&&(s.backgroundColor=n[a][i%n[a].length],s.borderColor=n[a][i%n[a].length]),s.borderRadius=6})},checkDashed(){this.chartOptions.borderDash=[this.borderDash[0],this.borderDash[1]]}}},xC={class:"responsive-container"};function SC(e,t,n,s,i,a){const o=l.resolveComponent("Line");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",xC,[l.createVNode(o,{data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const kC=st(wC,[["render",SC],["__scopeId","data-v-0c78f7f1"]]),D1t="",CC={components:{Pie:mC},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","teal","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},colors:{type:Array,default:()=>[],validator:e=>{const t=["green","teal","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"];return e.every(n=>t.includes(n))}}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{responsive:!0,maintainAspectRatio:!1,pieceLabel:{mode:"percentage",precision:1},plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},computed:{isColorsSet(){return this.colors&&this.colors.length>0},computedBackgroundColors(){return this.colors.map(e=>{const t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));if(t)return t.color400})}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.isColorsSet?this.computedBackgroundColors:this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};e.forEach(s=>{const i=s.name;n[i]||(n[i]=t.slice()),s.backgroundColor=n[i].splice(0,s.data.length),s.borderRadius=6})}}},OC={class:"responsive-container"};function MC(e,t,n,s,i,a){const o=l.resolveComponent("Pie");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",OC,[l.createVNode(o,{data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const DC=st(CC,[["render",MC],["__scopeId","data-v-df415374"]]),E1t="",EC={components:{PolarArea:gC},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},isVisiblePointNames:{type:Boolean,default:!1}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{responsive:!0,scales:{r:{pointLabels:{display:this.isVisiblePointNames,centerPointLabels:!0,font:{size:12}}}},maintainAspectRatio:!1,pieceLabel:{mode:"percentage",precision:1},plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:this.showLabelName?i.name:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};e.forEach(s=>{const i=s.name;n[i]||(n[i]=t.slice()),s.backgroundColor=n[i].splice(0,s.data.length),s.borderRadius=6})}}},TC={class:"responsive-container"};function IC(e,t,n,s,i,a){const o=l.resolveComponent("PolarArea");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",TC,[l.createVNode(o,{data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const AC=st(EC,[["render",IC],["__scopeId","data-v-386a0dc0"]]),T1t="";fs.register(...Rh);const VC={components:{Bar:Z2},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},barWidth:{type:Number,default:1}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{scales:{x:{stacked:!0},y:{stacked:!0}},responsive:!0,maintainAspectRatio:!1,categoryPercentage:null,plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0},barWidth:{handler(e){e>=.1&&e<=1?this.chartOptions.categoryPercentage=e:this.chartOptions.categoryPercentage=1},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};this.chartOptions.plugins.legend.display=!0,e.forEach(s=>{const i=s.name;let a;e.length===1&&(a=2,n[i]=t[a],this.chartOptions.plugins.legend.display=!1),n[i]||(a=Object.keys(n).length%t.length,n[i]=t[a]),s.backgroundColor=n[i],s.borderRadius=6})}}},BC={class:"responsive-container"};function PC(e,t,n,s,i,a){const o=l.resolveComponent("Bar");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",BC,[l.createVNode(o,{is:"bar",data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const NC=st(VC,[["render",PC],["__scopeId","data-v-ed4bef4e"]]),I1t="",Hh={props:{padding:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingTop:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingRight:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingBottom:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingLeft:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},margin:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginTop:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginRight:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginBottom:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginLeft:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12}},computed:{paddingTopResolver(){let e=this.paddingTop>12?12:+this.paddingTop;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},paddingRightResolver(){let e=this.paddingRight>12?12:+this.paddingRight;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},paddingBottomResolver(){let e=this.paddingBottom>12?12:+this.paddingBottom;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},paddingLeftResolver(){let e=this.paddingLeft>12?12:+this.paddingLeft;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},marginTopResolver(){let e=this.marginTop>12?12:+this.marginTop;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`},marginRightResolver(){let e=this.marginRight>12?12:+this.marginRight;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`},marginBottomResolver(){let e=this.marginBottom>12?12:+this.marginBottom;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`},marginLeftResolver(){let e=this.marginLeft>12?12:+this.marginLeft;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`}},methods:{basePropertyResolver(e){return e>=0&&e<=12?e:e<0?0:12}}},X2=()=>{l.useCssVars(e=>({"6d4c0f4d":e.marginBottomResolver,d6616fae:e.marginLeftResolver,"0baf3274":e.marginRightResolver,"7c666dff":e.marginTopResolver,"561264d4":e.paddingBottomResolver,17295920:e.paddingLeftResolver,e3e47742:e.paddingRightResolver,"9def4450":e.paddingTopResolver}))},J2=Hh.setup;Hh.setup=J2?(e,t)=>(X2(),J2(e,t)):X2;const zC=Hh,LC={class:"spacer"};function FC(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",LC,[l.renderSlot(e.$slots,"default",{},void 0,!0)])}const Ld=st(zC,[["render",FC],["__scopeId","data-v-5aebf225"]]);function Wh(e,t=24){let n=e/8,s=n%4;return`${n>t?t:n-s+4}px`}const A1t="",jh={components:{CdsSpacer:Ld,CdsClickable:Qi},props:{elevated:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},padding:{type:[Number,String],default:4,validator:e=>e<=12},clickable:{type:Boolean,default:!1},variant:{type:String,default:"gray"}},data(){return{width:0}},computed:{widthResolver(){return this.fluid?"100%":"fit-content"},borderRadiusResolver(){return this.rounder(this.width,12)}},mounted(){this.width=this.$refs["cds-box"].getBoundingClientRect().width},methods:{rounder:Wh,handleClick(){this.clickable&&this.$emit("boxClick",!0)}}},Q2=()=>{l.useCssVars(e=>({"8bf1f4e6":e.widthResolver,"337f1943":e.borderRadiusResolver}))},q2=jh.setup;jh.setup=q2?(e,t)=>(Q2(),q2(e,t)):Q2;const RC=jh;function HC(e,t,n,s,i,a){const o=l.resolveComponent("cds-spacer"),c=l.resolveComponent("cds-clickable");return l.openBlock(),l.createElementBlock("div",{ref:"cds-box",class:l.normalizeClass(n.elevated?"box--elevated":`box--${n.variant}`)},[l.createVNode(c,{class:"box__container",clickable:n.clickable,onClick:a.handleClick},{default:l.withCtx(()=>[l.createVNode(o,{"padding-top":n.padding,"padding-right":n.padding,"padding-bottom":n.padding,"padding-left":n.padding},{default:l.withCtx(()=>[l.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["padding-top","padding-right","padding-bottom","padding-left"])]),_:3},8,["clickable","onClick"])],2)}const Vl=st(RC,[["render",HC],["__scopeId","data-v-34f9c778"]]);var Yh={exports:{}};(function(e,t){var n=9007199254740991,s="[object Arguments]",i="[object Function]",a="[object GeneratorFunction]",o="[object Map]",c="[object Object]",d="[object Promise]",h="[object Set]",f="[object WeakMap]",m="[object DataView]",v=/[\\^$.*+?()[\]{}|]/g,y=/^\[object .+?Constructor\]$/,w=typeof qe=="object"&&qe&&qe.Object===Object&&qe,x=typeof self=="object"&&self&&self.Object===Object&&self,k=w||x||Function("return this")(),D=t&&!t.nodeType&&t,E=D&&!0&&e&&!e.nodeType&&e,B=E&&E.exports===D;function S(tt,Ht){return tt==null?void 0:tt[Ht]}function A(tt){var Ht=!1;if(tt!=null&&typeof tt.toString!="function")try{Ht=!!(tt+"")}catch{}return Ht}function I(tt,Ht){return function(oe){return tt(Ht(oe))}}var F=Function.prototype,L=Object.prototype,W=k["__core-js_shared__"],X=function(){var tt=/[^.]+$/.exec(W&&W.keys&&W.keys.IE_PROTO||"");return tt?"Symbol(src)_1."+tt:""}(),Z=F.toString,Q=L.hasOwnProperty,et=L.toString,gt=RegExp("^"+Z.call(Q).replace(v,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ot=B?k.Buffer:void 0,ft=L.propertyIsEnumerable,lt=ot?ot.isBuffer:void 0,vt=I(Object.keys,Object),xt=Nt(k,"DataView"),ct=Nt(k,"Map"),R=Nt(k,"Promise"),q=Nt(k,"Set"),rt=Nt(k,"WeakMap"),pt=!ft.call({valueOf:1},"valueOf"),$=$t(xt),_t=$t(ct),Mt=$t(R),ut=$t(q),Bt=$t(rt);function Lt(tt){return et.call(tt)}function Pt(tt){if(!Xe(tt)||le(tt))return!1;var Ht=Ke(tt)||A(tt)?gt:y;return Ht.test($t(tt))}function Nt(tt,Ht){var oe=S(tt,Ht);return Pt(oe)?oe:void 0}var jt=Lt;(xt&&jt(new xt(new ArrayBuffer(1)))!=m||ct&&jt(new ct)!=o||R&&jt(R.resolve())!=d||q&&jt(new q)!=h||rt&&jt(new rt)!=f)&&(jt=function(tt){var Ht=et.call(tt),oe=Ht==c?tt.constructor:void 0,$n=oe?$t(oe):void 0;if($n)switch($n){case $:return m;case _t:return o;case Mt:return d;case ut:return h;case Bt:return f}return Ht});function le(tt){return!!X&&X in tt}function he(tt){var Ht=tt&&tt.constructor,oe=typeof Ht=="function"&&Ht.prototype||L;return tt===oe}function $t(tt){if(tt!=null){try{return Z.call(tt)}catch{}try{return tt+""}catch{}}return""}function Et(tt){return Ee(tt)&&Q.call(tt,"callee")&&(!ft.call(tt,"callee")||et.call(tt)==s)}var ve=Array.isArray;function Ge(tt){return tt!=null&&Ze(tt.length)&&!Ke(tt)}function Ee(tt){return ks(tt)&&Ge(tt)}var _e=lt||Je;function on(tt){if(Ge(tt)&&(ve(tt)||typeof tt=="string"||typeof tt.splice=="function"||_e(tt)||Et(tt)))return!tt.length;var Ht=jt(tt);if(Ht==o||Ht==h)return!tt.size;if(pt||he(tt))return!vt(tt).length;for(var oe in tt)if(Q.call(tt,oe))return!1;return!0}function Ke(tt){var Ht=Xe(tt)?et.call(tt):"";return Ht==i||Ht==a}function Ze(tt){return typeof tt=="number"&&tt>-1&&tt%1==0&&tt<=n}function Xe(tt){var Ht=typeof tt;return!!tt&&(Ht=="object"||Ht=="function")}function ks(tt){return!!tt&&typeof tt=="object"}function Je(){return!1}e.exports=on})(Yh,Yh.exports);const We=Yh.exports,V1t="",WC={components:{CdsIcon:Me,CdsSpacer:Ld,CdsClickable:Qi},props:{items:{type:Array,default:()=>[],required:!0}},methods:{resolveRoute({route:e,path:t}){const n=We(e)?t:e;return n instanceof String?{path:n}:n},routerPushTo(e){return this.resolveRoute(e)?this.resolveRoute(e).path:null}}},jC={class:"breadcrumb"};function YC(e,t,n,s,i,a){const o=l.resolveComponent("cds-icon"),c=l.resolveComponent("cds-spacer"),d=l.resolveComponent("router-link"),h=l.resolveComponent("cds-clickable");return l.openBlock(),l.createElementBlock("nav",null,[l.createElementVNode("ul",jC,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.items,(f,m)=>(l.openBlock(),l.createElementBlock("li",{key:`${m}-${f.name}-item`,role:"presentation"},[m===0?(l.openBlock(),l.createBlock(h,{key:0,clickable:""},{default:l.withCtx(()=>[l.createVNode(d,{to:a.routerPushTo(f),class:"breadcrumb__link"},{default:l.withCtx(()=>[n.items.length<=2?(l.openBlock(),l.createBlock(o,{key:0,height:"16",width:"16",name:"arrow-left-outline"})):(l.openBlock(),l.createBlock(o,{key:1,height:"15",width:"15",name:"home-outline"})),l.createVNode(c,{"margin-left":"2"},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(f.label),1)]),_:2},1024)]),_:2},1032,["to"])]),_:2},1024)):(l.openBlock(),l.createBlock(c,{key:1,class:"breadcrumb__item","margin-right":"1","margin-left":"1"},{default:l.withCtx(()=>[l.createVNode(o,{height:"16",width:"16",name:"caret-right-outline",class:"breadcrumb__separator"}),l.createVNode(d,{to:a.routerPushTo(f),class:"breadcrumb__link"},{default:l.withCtx(()=>[l.createVNode(h,{clickable:""},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(f.label),1)]),_:2},1024)]),_:2},1032,["to"])]),_:2},1024))]))),128))])])}const UC=st(WC,[["render",YC],["__scopeId","data-v-c2046c1c"]]),B1t="",Uh={props:{src:{type:String,required:!0},fallbackSrc:{type:String,required:!1},width:{type:[Number,String],default:null},height:{type:[Number,String],default:null},alt:{type:String,default:"Imagem"},opacity:{type:[Number,String],default:1},dimmed:{type:Boolean,default:!1},blackAndWhite:{type:Boolean,default:!1},roundedCorners:{type:Boolean,default:!1}},data(){return{innerSrc:this.src}},computed:{heightResolver(){return this.height?`${this.height}px`:"auto"},widthResolver(){return this.width?`${this.width}px`:"auto"},opacityResolver(){return this.width?`${this.width}px`:"auto"},radiusResolver(){return this.roundedCorners?Wh(this.width):"0px"},grayScaleResolver(){return this.blackAndWhite?"grayscale(100%)":this.dimmed?"grayscale(35%)":"grayscale(0%)"}},methods:{rounder:Wh,imageSrcResolver(){this.innerSrc=this.fallbackSrc}}},$2=()=>{l.useCssVars(e=>({"21136de6":e.radiusResolver,e10ed842:e.grayScaleResolver,"31ae2d7b":e.heightResolver,"1e7f7c9d":e.opacity,"775376fe":e.widthResolver}))},tv=Uh.setup;Uh.setup=tv?(e,t)=>($2(),tv(e,t)):$2;const GC=Uh,KC=["src","alt"];function ZC(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("img",l.mergeProps(e.$attrs,{src:i.innerSrc,alt:n.alt,class:"cds__image",onError:t[0]||(t[0]=(...o)=>a.imageSrcResolver&&a.imageSrcResolver(...o))}),null,16,KC)}const ev=st(GC,[["render",ZC],["__scopeId","data-v-79754f28"]]),Gh=(e,t)=>Object.keys(e).some(n=>n===t),P1t="",Kh={components:{CdsBox:Vl,CdsImage:ev},props:{title:{type:String,default:""},content:{type:String,default:""},imageSrc:{type:String,default:""},imageAlt:{type:String,default:"imagem do card"},imageWidth:{type:[String,Number],default:300},imageHeight:{type:[String,Number],default:180},bodyWidth:{type:[String,Number],default:300},horizontal:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1}},computed:{imageWidthResolver(){return this.horizontal?"fit-content":`${this.imageWidth}px`},bodyWidthResolver(){return`${this.bodyWidth}px`}},methods:{hasSlot:Gh,handleClick(){this.clickable&&this.$emit("cardClick",!0)}}},nv=()=>{l.useCssVars(e=>({"8d304056":e.bodyWidthResolver,"4730bd46":e.imageWidthResolver}))},sv=Kh.setup;Kh.setup=sv?(e,t)=>(nv(),sv(e,t)):nv;const XC=Kh,JC={class:"card__extra-container"},QC={class:"card__extra"},qC={key:0},$C={key:1,class:"card__image"},tO={key:2,class:"card__icon"},eO={class:"card__spacer"},nO={key:0,class:"card__header"},sO={key:1},iO={class:"card__header"},aO={key:2,class:"card__body"},oO={key:3},rO={class:"card__body"},lO={key:4,class:"card__footer"};function cO(e,t,n,s,i,a){const o=l.resolveComponent("cds-image"),c=l.resolveComponent("cds-box");return l.openBlock(),l.createBlock(c,{padding:"0",clickable:n.clickable,onBoxClick:a.handleClick},{default:l.withCtx(()=>[l.createElementVNode("div",JC,[l.createElementVNode("div",QC,[l.renderSlot(e.$slots,"extra",{},void 0,!0)])]),l.createElementVNode("div",{class:l.normalizeClass({"card--horizontal":this.horizontal})},[a.hasSlot(e.$slots,"image")?(l.openBlock(),l.createElementBlock("div",qC,[l.renderSlot(e.$slots,"image",{},void 0,!0)])):n.imageSrc?(l.openBlock(),l.createElementBlock("div",$C,[l.createVNode(o,{src:n.imageSrc,width:n.imageWidth,height:n.imageHeight,alt:n.imageAlt},null,8,["src","width","height","alt"])])):a.hasSlot(e.$slots,"icon")?(l.openBlock(),l.createElementBlock("div",tO,[l.renderSlot(e.$slots,"icon",{},void 0,!0)])):l.createCommentVNode("",!0),l.createElementVNode("div",eO,[a.hasSlot(e.$slots,"header")?(l.openBlock(),l.createElementBlock("div",nO,[l.renderSlot(e.$slots,"header",{},void 0,!0)])):(l.openBlock(),l.createElementBlock("div",sO,[l.createElementVNode("p",iO,l.toDisplayString(n.title),1)])),a.hasSlot(e.$slots,"body")?(l.openBlock(),l.createElementBlock("div",aO,[l.renderSlot(e.$slots,"body",{},void 0,!0)])):(l.openBlock(),l.createElementBlock("div",oO,[l.createElementVNode("p",rO,l.toDisplayString(n.content),1)])),a.hasSlot(e.$slots,"footer")?(l.openBlock(),l.createElementBlock("div",lO,[l.renderSlot(e.$slots,"footer",{},void 0,!0)])):l.createCommentVNode("",!0)])],2)]),_:3},8,["clickable","onBoxClick"])}const dO=st(XC,[["render",cO],["__scopeId","data-v-ef799654"]]),N1t="",uO={components:{CdsButton:Po},props:{title:{type:String,default:"T\xEDtulo do AlertCard",required:!0},text:{type:String,default:"Subt\xEDtulo do AlertCard"},image:{type:String,default:"",required:!0},imageDescription:{type:String,default:"Imagem de CalloutCard"},actionButtonVariant:{type:String,default:"green"},actionButtonText:{type:String,default:"Ok"},actionButtonSecondary:{type:Boolean,default:!1},actionButtonDisabled:{type:Boolean,default:!1},compact:{type:Boolean,default:!1}},methods:{resolveClass(e){return this.compact?`${e}--compact`:e}}},hO={id:"callout-card"},fO={class:"image__container"},pO=["src","alt"],mO={class:"content__title"},gO={class:"content__text"};function vO(e,t,n,s,i,a){const o=l.resolveComponent("cds-button");return l.openBlock(),l.createElementBlock("span",hO,[l.createElementVNode("div",{class:l.normalizeClass(a.resolveClass("callout-card__container"))},[l.createElementVNode("div",fO,[l.createElementVNode("img",{class:l.normalizeClass(a.resolveClass("image__content")),src:n.image,alt:n.imageDescription},null,10,pO)]),l.createElementVNode("div",{class:l.normalizeClass(a.resolveClass("content__container"))},[l.createElementVNode("div",{class:l.normalizeClass(a.resolveClass("content"))},[l.createElementVNode("p",mO,l.toDisplayString(n.title),1),l.createElementVNode("span",gO,[l.renderSlot(e.$slots,"text",{},()=>[l.createTextVNode(l.toDisplayString(n.text),1)])])],2),l.createElementVNode("div",null,[l.renderSlot(e.$slots,"action",{},()=>[l.createVNode(o,{id:"content-button",variant:n.actionButtonVariant,text:n.actionButtonText,secondary:n.actionButtonSecondary,disabled:n.actionButtonDisabled,onClick:t[0]||(t[0]=c=>e.$emit("action-button-click",!0))},null,8,["variant","text","secondary","disabled"])])])],2)],2)])}const _O=st(uO,[["render",vO]]),z1t="",yO={props:{propertyName:{type:String,default:"Dados",required:!1},perPage:{type:Number,required:!0},total:{type:Number,required:!0},simple:{type:Boolean,default:!1,required:!1},fluid:{type:Boolean,default:!1,required:!1}},data(){return{currentNumberOfItemsMin:1,currentNumberOfItemsMax:this.perPage}},computed:{numberOfPages(){return Math.ceil(this.total/this.perPage)},disabledForward(){return this.currentNumberOfItemsMax>=this.total||this.simple&&this.currentNumberOfItemsMin>=this.numberOfPages},disabledBack(){return this.currentNumberOfItemsMin===1}},methods:{handleClickBack(){if(!this.disabledBack){if(this.simple&&this.currentNumberOfItemsMin>1){this.currentNumberOfItemsMin-=1,this.$emit("click-back",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1});return}else if(this.simple&&this.currentNumberOfItemsMin===1)return;this.currentNumberOfItemsMin-this.perPage<=0?(this.currentNumberOfItemsMin=1,this.currentNumberOfItemsMax=this.perPage,this.$emit("click-back",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1})):(this.currentNumberOfItemsMax-=this.currentNumberOfItemsMax-this.currentNumberOfItemsMin+1,this.currentNumberOfItemsMin-=this.perPage,this.$emit("click-back",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax}))}},handleClickForward(){if(!this.disabledForward){if(this.simple&&this.currentNumberOfItemsMin<this.numberOfPages){this.currentNumberOfItemsMin+=1,this.$emit("click-forward",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1});return}else if(this.simple&&this.currentNumberOfItemsMin===this.numberOfPages)return;this.currentNumberOfItemsMax+this.perPage>this.total?(this.currentNumberOfItemsMin=this.currentNumberOfItemsMax+1,this.currentNumberOfItemsMax=this.total,this.$emit("click-forward",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1})):(this.currentNumberOfItemsMin=this.currentNumberOfItemsMax+1,this.currentNumberOfItemsMax+=this.perPage,this.$emit("click-forward",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1}))}}}},bO={key:0,class:"carousel-controller__text"},wO={key:1,class:"carousel-controller__text"},xO={class:"carousel-controller__property"};function SO(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",null,[l.createElementVNode("div",{class:l.normalizeClass(["carousel-controller",{"carousel-controller--fluid":n.fluid}])},[l.createElementVNode("span",{class:l.normalizeClass({"carousel-controller__previous-button--disabled":a.disabledBack,"carousel-controller__previous-button":!a.disabledBack}),onClick:t[0]||(t[0]=(...o)=>a.handleClickBack&&a.handleClickBack(...o))},null,2),l.createElementVNode("div",null,[n.simple?(l.openBlock(),l.createElementBlock("span",wO,l.toDisplayString(i.currentNumberOfItemsMin)+" de "+l.toDisplayString(a.numberOfPages),1)):(l.openBlock(),l.createElementBlock("span",bO,l.toDisplayString(i.currentNumberOfItemsMin)+"-"+l.toDisplayString(i.currentNumberOfItemsMax)+" de "+l.toDisplayString(n.total),1)),l.createElementVNode("span",xO,l.toDisplayString(n.propertyName),1)]),l.createElementVNode("span",{class:l.normalizeClass({"carousel-controller__next-button--disabled":a.disabledForward,"carousel-controller__next-button":!a.disabledForward}),onClick:t[1]||(t[1]=(...o)=>a.handleClickForward&&a.handleClickForward(...o))},null,2)],2)])}const kO=st(yO,[["render",SO],["__scopeId","data-v-fcb19a0a"]]);function iv(e,t){return`${e}--${t}`}const L1t="",CO={props:{modelValue:{type:Boolean,default:!1,required:!0},label:{type:String,default:"checkbox content"},variant:{type:String,default:"green"},indeterminate:{type:Boolean,default:!1},prominent:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},data(){return{isChecked:this.modelValue,isIndeterminate:this.indeterminate}},computed:{resolveCheckboxClass(){const e=this.disabled?"cds-checkbox__input--disabled":"",t=iv("cds-checkbox__input",this.variant);let n=this.isChecked?"cds-checkbox__input--checked":"cds-checkbox__input--unchecked";return n=this.isIndeterminate?"cds-checkbox__input--indeterminate":n,`${t} ${n} ${e}`}},watch:{modelValue:{handler(e,t){e!==t&&(this.isChecked=this.modelValue)},immediate:!0},indeterminate:{handler(e,t){e!==t&&(this.isIndeterminate=this.indeterminate)},immediate:!0}},methods:{toggleValue(){this.disabled||(this.isChecked=this.isIndeterminate?!1:!this.isChecked,this.isIndeterminate=!1,this.$emit("update:modelValue",this.isChecked),this.$emit("update:indeterminate",!1))}}},OO={class:"cds-checkbox__container"},MO={class:"cds-checkbox__input"},DO=["id","value","name","disabled"],EO=["for"],TO=["for"];function IO(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",OO,[l.createElementVNode("div",MO,[l.createElementVNode("input",{id:e.$attrs.id||"cds-checkbox-option-input",value:n.modelValue,type:"checkbox",name:e.$attrs.name||"cds-checkbox-option",disabled:n.disabled},null,8,DO),l.createElementVNode("label",{for:e.$attrs.id||"cds-checkbox-option-input",class:l.normalizeClass(a.resolveCheckboxClass),onClick:t[0]||(t[0]=(...o)=>a.toggleValue&&a.toggleValue(...o))},null,10,EO)]),l.createElementVNode("label",{class:l.normalizeClass(["cds-checkbox__label",{"cds-checkbox__label--disabled":n.disabled,"cds-checkbox__label--prominent":n.prominent&&n.modelValue}]),for:e.$attrs.id||"cds-checkbox-option-input",onClick:t[1]||(t[1]=(...o)=>a.toggleValue&&a.toggleValue(...o))},l.toDisplayString(n.label),11,TO)])}const Zh=st(CO,[["render",IO],["__scopeId","data-v-0758b096"]]),F1t="",AO={props:{modelValue:{type:Boolean,default:!1,required:!0},title:{type:String,default:"Visualizar mais"}},data(){return{internalValue:this.modelValue}},watch:{internalValue(e){this.$emit("update:modelValue",e)},modelValue(e){this.internalValue=e}},methods:{triggerExpanded(){this.internalValue=!this.internalValue}}},VO={id:"collapsible-container"},BO={class:"collapsible-container__title"},PO={key:0,class:"collapsible-container__content"};function NO(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("span",VO,[l.createElementVNode("div",{class:"collapsible-container__item",onClick:t[0]||(t[0]=(...o)=>a.triggerExpanded&&a.triggerExpanded(...o))},[l.createElementVNode("span",{class:l.normalizeClass(i.internalValue?"collapsible-container__chevron--opened":"collapsible-container__chevron--closed")},null,2),l.renderSlot(e.$slots,"title",{},()=>[l.createElementVNode("span",BO,l.toDisplayString(n.title),1)])]),i.internalValue?(l.openBlock(),l.createElementBlock("div",PO,[l.renderSlot(e.$slots,"default")])):l.createCommentVNode("",!0)])}const zO=st(AO,[["render",NO]]),Xh=e=>{var t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]:null},LO=.2126,FO=.7152,RO=.0722,HO=2.4,WO={POOR:3,GOOD:4.5,VERYGOOD:7,SUPER:12},jO=(e,t,n="GOOD")=>{let s=Xh(e),i=Xh(t);var a=av(...s),o=av(...i),c=Math.max(a,o),d=Math.min(a,o);return(c+.05)/(d+.05)>=WO[n]};function av(e,t,n){var s=[e,t,n].map(i=>(i/=255,i<=.03928?i/12.92:Math.pow((i+.055)/1.055,HO)));return s[0]*LO+s[1]*FO+s[2]*RO}const R1t="",Jh={components:{CdsPopover:Z1,CdsIcon:Me},props:{modelValue:{type:String,required:!0},label:{type:String,default:"Label"},inline:{type:Boolean,default:!1},popoverHeight:{type:Number,default:190},swatch:{type:Array,default:()=>[]}},data(){return{selectedColor:this.modelValue,sassColorVariables:oa,showPopover:!1}},computed:{iconColorResolver(){return this.ContrastChecker(this.selectedColor,"#FFFFFF","POOR")?"swatch__icon--white":"swatch__icon--black"},palete(){return this.paleteBuilder(this.sassColorVariables.palete)}},watch:{modelValue:{handler(e,t){e!==t&&(this.selectedColor=e)},immediate:!0}},methods:{paleteBuilder:Yo,ContrastChecker:jO,SwatchSelection(e){let t="";this.selectedColor=this.sassColorVariables[e.replace(/-|\$/gi,"")],this.palete.forEach(n=>{n.colorTokens.find(s=>s===e)&&(t=n.variantName.toLowerCase())}),this.$emit("update:modelValue",this.selectedColor),this.$emit("variant-chosen",t)},isCurrentColorSelected(e){return this.selectedColor===this.sassColorVariables[e.replace(/-|\$/gi,"")]}}},ov=()=>{l.useCssVars(e=>({f73e5680:e.selectedColor}))},rv=Jh.setup;Jh.setup=rv?(e,t)=>(ov(),rv(e,t)):ov;const YO=Jh,UO=e=>(l.pushScopeId("data-v-a4ff5e3b"),e=e(),l.popScopeId(),e),GO={key:0},KO={class:"color-picker__label"},ZO=["onClick"],XO={key:1},JO=[UO(()=>l.createElementVNode("div",{class:"color-picker__preview"},null,-1))],QO=["onClick"];function qO(e,t,n,s,i,a){const o=l.resolveComponent("cds-icon"),c=l.resolveComponent("cds-popover");return n.inline?(l.openBlock(),l.createElementBlock("div",GO,[l.createElementVNode("div",KO,l.toDisplayString(n.label),1),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.swatch,(d,h)=>(l.openBlock(),l.createElementBlock("div",{key:h,class:"color-picker__container"},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(d,(f,m)=>(l.openBlock(),l.createElementBlock("div",{key:m},[l.createElementVNode("div",{class:l.normalizeClass(`color-picker__swatch--${f.replace("$","")}`),onClick:v=>a.SwatchSelection(f)},[a.isCurrentColorSelected(f)?(l.openBlock(),l.createBlock(o,{key:0,height:"22",width:"22",name:"check-outline",class:l.normalizeClass(["swatch__icon",a.iconColorResolver])},null,8,["class"])):l.createCommentVNode("",!0)],10,ZO)]))),128))]))),128))])):(l.openBlock(),l.createElementBlock("div",XO,[l.createElementVNode("div",{id:"color-picker",class:"color-picker__trigger",onClick:t[0]||(t[0]=l.withModifiers(d=>i.showPopover=!i.showPopover,["stop"]))},JO),l.createVNode(c,{modelValue:i.showPopover,"onUpdate:modelValue":t[1]||(t[1]=d=>i.showPopover=d),"right-aligned":!1,"target-id":"color-picker",height:n.popoverHeight,"fit-content-width":""},{default:l.withCtx(()=>[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.swatch,(d,h)=>(l.openBlock(),l.createElementBlock("div",{key:h,class:"popover__container"},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(d,(f,m)=>(l.openBlock(),l.createElementBlock("div",{key:m},[l.createElementVNode("div",{class:l.normalizeClass(`color-picker__swatch--${f.replace("$","")}`),onClick:v=>a.SwatchSelection(f)},[a.isCurrentColorSelected(f)?(l.openBlock(),l.createBlock(o,{key:0,height:"22",width:"22",name:"check-outline",class:l.normalizeClass(["swatch__icon",a.iconColorResolver])},null,8,["class"])):l.createCommentVNode("",!0)],10,QO)]))),128))]))),128))]),_:1},8,["modelValue","height"])]))}const $O=st(YO,[["render",qO],["__scopeId","data-v-a4ff5e3b"]]),W1t="",tM={props:{title:{type:String,default:"",required:!1},description:{type:String,default:"",required:!1},showAction:{type:Boolean,default:!1,required:!1},action:{type:String,default:"Action",required:!1},fluid:{type:Boolean,default:!1}}},eM={class:"dashboard-card"},nM={class:"dashboard-card__header"},sM={key:0,class:"dashboard-card__title"},iM={key:1,class:"dashboard-card__title"},aM={key:0,class:"dashboard-card__description"},oM={key:1,class:"dashboard-card__description"},rM={key:0};function lM(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",eM,[l.createElementVNode("div",null,[l.createElementVNode("div",nM,[n.title.length>0?(l.openBlock(),l.createElementBlock("p",sM,l.toDisplayString(n.title),1)):(l.openBlock(),l.createElementBlock("p",iM,[l.renderSlot(e.$slots,"title-slot",{},void 0,!0)])),l.createElementVNode("div",null,[l.renderSlot(e.$slots,"status-slot",{},void 0,!0)])]),n.description.length>0?(l.openBlock(),l.createElementBlock("p",aM,l.toDisplayString(n.description),1)):(l.openBlock(),l.createElementBlock("p",oM,[l.renderSlot(e.$slots,"description-slot",{},void 0,!0)]))]),l.createElementVNode("div",{class:"dashboard-card__action",onClick:t[0]||(t[0]=o=>e.$emit("action-button-click"))},[l.renderSlot(e.$slots,"action-slot",{},()=>[n.showAction?(l.openBlock(),l.createElementBlock("div",rM,l.toDisplayString(n.action),1)):l.createCommentVNode("",!0)],!0)])])}const cM=st(tM,[["render",lM],["__scopeId","data-v-cd0db219"]]);class Ja extends Error{}class dM extends Ja{constructor(t){super(`Invalid DateTime: ${t.toMessage()}`)}}class uM extends Ja{constructor(t){super(`Invalid Interval: ${t.toMessage()}`)}}class hM extends Ja{constructor(t){super(`Invalid Duration: ${t.toMessage()}`)}}class Bl extends Ja{}class lv extends Ja{constructor(t){super(`Invalid unit ${t}`)}}class ps extends Ja{}class ra extends Ja{constructor(){super("Zone is an abstract class")}}const it="numeric",Ws="short",Zn="long",Fd={year:it,month:it,day:it},cv={year:it,month:Ws,day:it},fM={year:it,month:Ws,day:it,weekday:Ws},dv={year:it,month:Zn,day:it},uv={year:it,month:Zn,day:it,weekday:Zn},hv={hour:it,minute:it},fv={hour:it,minute:it,second:it},pv={hour:it,minute:it,second:it,timeZoneName:Ws},mv={hour:it,minute:it,second:it,timeZoneName:Zn},gv={hour:it,minute:it,hourCycle:"h23"},vv={hour:it,minute:it,second:it,hourCycle:"h23"},_v={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:Ws},yv={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:Zn},bv={year:it,month:it,day:it,hour:it,minute:it},wv={year:it,month:it,day:it,hour:it,minute:it,second:it},xv={year:it,month:Ws,day:it,hour:it,minute:it},Sv={year:it,month:Ws,day:it,hour:it,minute:it,second:it},pM={year:it,month:Ws,day:it,weekday:Ws,hour:it,minute:it},kv={year:it,month:Zn,day:it,hour:it,minute:it,timeZoneName:Ws},Cv={year:it,month:Zn,day:it,hour:it,minute:it,second:it,timeZoneName:Ws},Ov={year:it,month:Zn,day:it,weekday:Zn,hour:it,minute:it,timeZoneName:Zn},Mv={year:it,month:Zn,day:it,weekday:Zn,hour:it,minute:it,second:it,timeZoneName:Zn};class Pl{get type(){throw new ra}get name(){throw new ra}get ianaName(){return this.name}get isUniversal(){throw new ra}offsetName(t,n){throw new ra}formatOffset(t,n){throw new ra}offset(t){throw new ra}equals(t){throw new ra}get isValid(){throw new ra}}let Qh=null;class Rd extends Pl{static get instance(){return Qh===null&&(Qh=new Rd),Qh}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(t,{format:n,locale:s}){return Lv(t,n,s)}formatOffset(t,n){return Fl(this.offset(t),n)}offset(t){return-new Date(t).getTimezoneOffset()}equals(t){return t.type==="system"}get isValid(){return!0}}let Hd={};function mM(e){return Hd[e]||(Hd[e]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),Hd[e]}const gM={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function vM(e,t){const n=e.format(t).replace(/\u200E/g,""),s=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(n),[,i,a,o,c,d,h,f]=s;return[o,i,a,c,d,h,f]}function _M(e,t){const n=e.formatToParts(t),s=[];for(let i=0;i<n.length;i++){const{type:a,value:o}=n[i],c=gM[a];a==="era"?s[c]=o:Qt(c)||(s[c]=parseInt(o,10))}return s}let Wd={};class Mi extends Pl{static create(t){return Wd[t]||(Wd[t]=new Mi(t)),Wd[t]}static resetCache(){Wd={},Hd={}}static isValidSpecifier(t){return this.isValidZone(t)}static isValidZone(t){if(!t)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:t}).format(),!0}catch{return!1}}constructor(t){super(),this.zoneName=t,this.valid=Mi.isValidZone(t)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(t,{format:n,locale:s}){return Lv(t,n,s,this.name)}formatOffset(t,n){return Fl(this.offset(t),n)}offset(t){const n=new Date(t);if(isNaN(n))return NaN;const s=mM(this.name);let[i,a,o,c,d,h,f]=s.formatToParts?_M(s,n):vM(s,n);c==="BC"&&(i=-Math.abs(i)+1);const v=of({year:i,month:a,day:o,hour:d===24?0:d,minute:h,second:f,millisecond:0});let y=+n;const w=y%1e3;return y-=w>=0?w:1e3+w,(v-y)/(60*1e3)}equals(t){return t.type==="iana"&&t.name===this.name}get isValid(){return this.valid}}let Dv={};function yM(e,t={}){const n=JSON.stringify([e,t]);let s=Dv[n];return s||(s=new Intl.ListFormat(e,t),Dv[n]=s),s}let qh={};function $h(e,t={}){const n=JSON.stringify([e,t]);let s=qh[n];return s||(s=new Intl.DateTimeFormat(e,t),qh[n]=s),s}let tf={};function bM(e,t={}){const n=JSON.stringify([e,t]);let s=tf[n];return s||(s=new Intl.NumberFormat(e,t),tf[n]=s),s}let ef={};function wM(e,t={}){const{base:n,...s}=t,i=JSON.stringify([e,s]);let a=ef[i];return a||(a=new Intl.RelativeTimeFormat(e,t),ef[i]=a),a}let Nl=null;function xM(){return Nl||(Nl=new Intl.DateTimeFormat().resolvedOptions().locale,Nl)}function SM(e){const t=e.indexOf("-x-");t!==-1&&(e=e.substring(0,t));const n=e.indexOf("-u-");if(n===-1)return[e];{let s,i;try{s=$h(e).resolvedOptions(),i=e}catch{const d=e.substring(0,n);s=$h(d).resolvedOptions(),i=d}const{numberingSystem:a,calendar:o}=s;return[i,a,o]}}function kM(e,t,n){return(n||t)&&(e.includes("-u-")||(e+="-u"),n&&(e+=`-ca-${n}`),t&&(e+=`-nu-${t}`)),e}function CM(e){const t=[];for(let n=1;n<=12;n++){const s=St.utc(2016,n,1);t.push(e(s))}return t}function OM(e){const t=[];for(let n=1;n<=7;n++){const s=St.utc(2016,11,13+n);t.push(e(s))}return t}function jd(e,t,n,s,i){const a=e.listingMode(n);return a==="error"?null:a==="en"?s(t):i(t)}function MM(e){return e.numberingSystem&&e.numberingSystem!=="latn"?!1:e.numberingSystem==="latn"||!e.locale||e.locale.startsWith("en")||new Intl.DateTimeFormat(e.intl).resolvedOptions().numberingSystem==="latn"}class DM{constructor(t,n,s){this.padTo=s.padTo||0,this.floor=s.floor||!1;const{padTo:i,floor:a,...o}=s;if(!n||Object.keys(o).length>0){const c={useGrouping:!1,...s};s.padTo>0&&(c.minimumIntegerDigits=s.padTo),this.inf=bM(t,c)}}format(t){if(this.inf){const n=this.floor?Math.floor(t):t;return this.inf.format(n)}else{const n=this.floor?Math.floor(t):af(t,3);return Ye(n,this.padTo)}}}class EM{constructor(t,n,s){this.opts=s;let i;if(t.zone.isUniversal){const o=-1*(t.offset/60),c=o>=0?`Etc/GMT+${o}`:`Etc/GMT${o}`;t.offset!==0&&Mi.create(c).valid?(i=c,this.dt=t):(i="UTC",s.timeZoneName?this.dt=t:this.dt=t.offset===0?t:St.fromMillis(t.ts+t.offset*60*1e3))}else t.zone.type==="system"?this.dt=t:(this.dt=t,i=t.zone.name);const a={...this.opts};a.timeZone=a.timeZone||i,this.dtf=$h(n,a)}format(){return this.dtf.format(this.dt.toJSDate())}formatToParts(){return this.dtf.formatToParts(this.dt.toJSDate())}resolvedOptions(){return this.dtf.resolvedOptions()}}class TM{constructor(t,n,s){this.opts={style:"long",...s},!n&&Nv()&&(this.rtf=wM(t,s))}format(t,n){return this.rtf?this.rtf.format(t,n):KM(n,t,this.opts.numeric,this.opts.style!=="long")}formatToParts(t,n){return this.rtf?this.rtf.formatToParts(t,n):[]}}class Ce{static fromOpts(t){return Ce.create(t.locale,t.numberingSystem,t.outputCalendar,t.defaultToEN)}static create(t,n,s,i=!1){const a=t||je.defaultLocale,o=a||(i?"en-US":xM()),c=n||je.defaultNumberingSystem,d=s||je.defaultOutputCalendar;return new Ce(o,c,d,a)}static resetCache(){Nl=null,qh={},tf={},ef={}}static fromObject({locale:t,numberingSystem:n,outputCalendar:s}={}){return Ce.create(t,n,s)}constructor(t,n,s,i){const[a,o,c]=SM(t);this.locale=a,this.numberingSystem=n||o||null,this.outputCalendar=s||c||null,this.intl=kM(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=i,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=MM(this)),this.fastNumbersCached}listingMode(){const t=this.isEnglish(),n=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return t&&n?"en":"intl"}clone(t){return!t||Object.getOwnPropertyNames(t).length===0?this:Ce.create(t.locale||this.specifiedLocale,t.numberingSystem||this.numberingSystem,t.outputCalendar||this.outputCalendar,t.defaultToEN||!1)}redefaultToEN(t={}){return this.clone({...t,defaultToEN:!0})}redefaultToSystem(t={}){return this.clone({...t,defaultToEN:!1})}months(t,n=!1,s=!0){return jd(this,t,s,Hv,()=>{const i=n?{month:t,day:"numeric"}:{month:t},a=n?"format":"standalone";return this.monthsCache[a][t]||(this.monthsCache[a][t]=CM(o=>this.extract(o,i,"month"))),this.monthsCache[a][t]})}weekdays(t,n=!1,s=!0){return jd(this,t,s,Yv,()=>{const i=n?{weekday:t,year:"numeric",month:"long",day:"numeric"}:{weekday:t},a=n?"format":"standalone";return this.weekdaysCache[a][t]||(this.weekdaysCache[a][t]=OM(o=>this.extract(o,i,"weekday"))),this.weekdaysCache[a][t]})}meridiems(t=!0){return jd(this,void 0,t,()=>Uv,()=>{if(!this.meridiemCache){const n={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[St.utc(2016,11,13,9),St.utc(2016,11,13,19)].map(s=>this.extract(s,n,"dayperiod"))}return this.meridiemCache})}eras(t,n=!0){return jd(this,t,n,Gv,()=>{const s={era:t};return this.eraCache[t]||(this.eraCache[t]=[St.utc(-40,1,1),St.utc(2017,1,1)].map(i=>this.extract(i,s,"era"))),this.eraCache[t]})}extract(t,n,s){const i=this.dtFormatter(t,n),a=i.formatToParts(),o=a.find(c=>c.type.toLowerCase()===s);return o?o.value:null}numberFormatter(t={}){return new DM(this.intl,t.forceSimple||this.fastNumbers,t)}dtFormatter(t,n={}){return new EM(t,this.intl,n)}relFormatter(t={}){return new TM(this.intl,this.isEnglish(),t)}listFormatter(t={}){return yM(this.intl,t)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}equals(t){return this.locale===t.locale&&this.numberingSystem===t.numberingSystem&&this.outputCalendar===t.outputCalendar}}let nf=null;class xn extends Pl{static get utcInstance(){return nf===null&&(nf=new xn(0)),nf}static instance(t){return t===0?xn.utcInstance:new xn(t)}static parseSpecifier(t){if(t){const n=t.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(n)return new xn(Kd(n[1],n[2]))}return null}constructor(t){super(),this.fixed=t}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${Fl(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${Fl(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(t,n){return Fl(this.fixed,n)}get isUniversal(){return!0}offset(){return this.fixed}equals(t){return t.type==="fixed"&&t.fixed===this.fixed}get isValid(){return!0}}class IM extends Pl{constructor(t){super(),this.zoneName=t}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function la(e,t){if(Qt(e)||e===null)return t;if(e instanceof Pl)return e;if(AM(e)){const n=e.toLowerCase();return n==="default"?t:n==="local"||n==="system"?Rd.instance:n==="utc"||n==="gmt"?xn.utcInstance:xn.parseSpecifier(n)||Mi.create(e)}else return Qa(e)?xn.instance(e):typeof e=="object"&&e.offset&&typeof e.offset=="number"?e:new IM(e)}let Ev=()=>Date.now(),Tv="system",Iv=null,Av=null,Vv=null,Bv=60,Pv;class je{static get now(){return Ev}static set now(t){Ev=t}static set defaultZone(t){Tv=t}static get defaultZone(){return la(Tv,Rd.instance)}static get defaultLocale(){return Iv}static set defaultLocale(t){Iv=t}static get defaultNumberingSystem(){return Av}static set defaultNumberingSystem(t){Av=t}static get defaultOutputCalendar(){return Vv}static set defaultOutputCalendar(t){Vv=t}static get twoDigitCutoffYear(){return Bv}static set twoDigitCutoffYear(t){Bv=t%100}static get throwOnInvalid(){return Pv}static set throwOnInvalid(t){Pv=t}static resetCaches(){Ce.resetCache(),Mi.resetCache()}}function Qt(e){return typeof e>"u"}function Qa(e){return typeof e=="number"}function Yd(e){return typeof e=="number"&&e%1===0}function AM(e){return typeof e=="string"}function VM(e){return Object.prototype.toString.call(e)==="[object Date]"}function Nv(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function BM(e){return Array.isArray(e)?e:[e]}function zv(e,t,n){if(e.length!==0)return e.reduce((s,i)=>{const a=[t(i),i];return s&&n(s[0],a[0])===s[0]?s:a},null)[1]}function PM(e,t){return t.reduce((n,s)=>(n[s]=e[s],n),{})}function Uo(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Di(e,t,n){return Yd(e)&&e>=t&&e<=n}function NM(e,t){return e-t*Math.floor(e/t)}function Ye(e,t=2){const n=e<0;let s;return n?s="-"+(""+-e).padStart(t,"0"):s=(""+e).padStart(t,"0"),s}function ca(e){if(!(Qt(e)||e===null||e===""))return parseInt(e,10)}function qa(e){if(!(Qt(e)||e===null||e===""))return parseFloat(e)}function sf(e){if(!(Qt(e)||e===null||e==="")){const t=parseFloat("0."+e)*1e3;return Math.floor(t)}}function af(e,t,n=!1){const s=10**t;return(n?Math.trunc:Math.round)(e*s)/s}function zl(e){return e%4===0&&(e%100!==0||e%400===0)}function Ll(e){return zl(e)?366:365}function Ud(e,t){const n=NM(t-1,12)+1,s=e+(t-n)/12;return n===2?zl(s)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][n-1]}function of(e){let t=Date.UTC(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond);return e.year<100&&e.year>=0&&(t=new Date(t),t.setUTCFullYear(t.getUTCFullYear()-1900)),+t}function Gd(e){const t=(e+Math.floor(e/4)-Math.floor(e/100)+Math.floor(e/400))%7,n=e-1,s=(n+Math.floor(n/4)-Math.floor(n/100)+Math.floor(n/400))%7;return t===4||s===3?53:52}function rf(e){return e>99?e:e>je.twoDigitCutoffYear?1900+e:2e3+e}function Lv(e,t,n,s=null){const i=new Date(e),a={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};s&&(a.timeZone=s);const o={timeZoneName:t,...a},c=new Intl.DateTimeFormat(n,o).formatToParts(i).find(d=>d.type.toLowerCase()==="timezonename");return c?c.value:null}function Kd(e,t){let n=parseInt(e,10);Number.isNaN(n)&&(n=0);const s=parseInt(t,10)||0,i=n<0||Object.is(n,-0)?-s:s;return n*60+i}function Fv(e){const t=Number(e);if(typeof e=="boolean"||e===""||Number.isNaN(t))throw new ps(`Invalid unit value ${e}`);return t}function Zd(e,t){const n={};for(const s in e)if(Uo(e,s)){const i=e[s];if(i==null)continue;n[t(s)]=Fv(i)}return n}function Fl(e,t){const n=Math.trunc(Math.abs(e/60)),s=Math.trunc(Math.abs(e%60)),i=e>=0?"+":"-";switch(t){case"short":return`${i}${Ye(n,2)}:${Ye(s,2)}`;case"narrow":return`${i}${n}${s>0?`:${s}`:""}`;case"techie":return`${i}${Ye(n,2)}${Ye(s,2)}`;default:throw new RangeError(`Value format ${t} is out of range for property format`)}}function Xd(e){return PM(e,["hour","minute","second","millisecond"])}const zM=["January","February","March","April","May","June","July","August","September","October","November","December"],Rv=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],LM=["J","F","M","A","M","J","J","A","S","O","N","D"];function Hv(e){switch(e){case"narrow":return[...LM];case"short":return[...Rv];case"long":return[...zM];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const Wv=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],jv=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],FM=["M","T","W","T","F","S","S"];function Yv(e){switch(e){case"narrow":return[...FM];case"short":return[...jv];case"long":return[...Wv];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const Uv=["AM","PM"],RM=["Before Christ","Anno Domini"],HM=["BC","AD"],WM=["B","A"];function Gv(e){switch(e){case"narrow":return[...WM];case"short":return[...HM];case"long":return[...RM];default:return null}}function jM(e){return Uv[e.hour<12?0:1]}function YM(e,t){return Yv(t)[e.weekday-1]}function UM(e,t){return Hv(t)[e.month-1]}function GM(e,t){return Gv(t)[e.year<0?0:1]}function KM(e,t,n="always",s=!1){const i={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},a=["hours","minutes","seconds"].indexOf(e)===-1;if(n==="auto"&&a){const m=e==="days";switch(t){case 1:return m?"tomorrow":`next ${i[e][0]}`;case-1:return m?"yesterday":`last ${i[e][0]}`;case 0:return m?"today":`this ${i[e][0]}`}}const o=Object.is(t,-0)||t<0,c=Math.abs(t),d=c===1,h=i[e],f=s?d?h[1]:h[2]||h[1]:d?i[e][0]:e;return o?`${c} ${f} ago`:`in ${c} ${f}`}function Kv(e,t){let n="";for(const s of e)s.literal?n+=s.val:n+=t(s.val);return n}const ZM={D:Fd,DD:cv,DDD:dv,DDDD:uv,t:hv,tt:fv,ttt:pv,tttt:mv,T:gv,TT:vv,TTT:_v,TTTT:yv,f:bv,ff:xv,fff:kv,ffff:Ov,F:wv,FF:Sv,FFF:Cv,FFFF:Mv};class gn{static create(t,n={}){return new gn(t,n)}static parseFormat(t){let n=null,s="",i=!1;const a=[];for(let o=0;o<t.length;o++){const c=t.charAt(o);c==="'"?(s.length>0&&a.push({literal:i,val:s}),n=null,s="",i=!i):i||c===n?s+=c:(s.length>0&&a.push({literal:!1,val:s}),s=c,n=c)}return s.length>0&&a.push({literal:i,val:s}),a}static macroTokenToFormatOpts(t){return ZM[t]}constructor(t,n){this.opts=n,this.loc=t,this.systemLoc=null}formatWithSystemDefault(t,n){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(t,{...this.opts,...n}).format()}formatDateTime(t,n={}){return this.loc.dtFormatter(t,{...this.opts,...n}).format()}formatDateTimeParts(t,n={}){return this.loc.dtFormatter(t,{...this.opts,...n}).formatToParts()}formatInterval(t,n={}){return this.loc.dtFormatter(t.start,{...this.opts,...n}).dtf.formatRange(t.start.toJSDate(),t.end.toJSDate())}resolvedOptions(t,n={}){return this.loc.dtFormatter(t,{...this.opts,...n}).resolvedOptions()}num(t,n=0){if(this.opts.forceSimple)return Ye(t,n);const s={...this.opts};return n>0&&(s.padTo=n),this.loc.numberFormatter(s).format(t)}formatDateTimeFromString(t,n){const s=this.loc.listingMode()==="en",i=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",a=(y,w)=>this.loc.extract(t,y,w),o=y=>t.isOffsetFixed&&t.offset===0&&y.allowZ?"Z":t.isValid?t.zone.formatOffset(t.ts,y.format):"",c=()=>s?jM(t):a({hour:"numeric",hourCycle:"h12"},"dayperiod"),d=(y,w)=>s?UM(t,y):a(w?{month:y}:{month:y,day:"numeric"},"month"),h=(y,w)=>s?YM(t,y):a(w?{weekday:y}:{weekday:y,month:"long",day:"numeric"},"weekday"),f=y=>{const w=gn.macroTokenToFormatOpts(y);return w?this.formatWithSystemDefault(t,w):y},m=y=>s?GM(t,y):a({era:y},"era"),v=y=>{switch(y){case"S":return this.num(t.millisecond);case"u":case"SSS":return this.num(t.millisecond,3);case"s":return this.num(t.second);case"ss":return this.num(t.second,2);case"uu":return this.num(Math.floor(t.millisecond/10),2);case"uuu":return this.num(Math.floor(t.millisecond/100));case"m":return this.num(t.minute);case"mm":return this.num(t.minute,2);case"h":return this.num(t.hour%12===0?12:t.hour%12);case"hh":return this.num(t.hour%12===0?12:t.hour%12,2);case"H":return this.num(t.hour);case"HH":return this.num(t.hour,2);case"Z":return o({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return o({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return o({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return t.zone.offsetName(t.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return t.zone.offsetName(t.ts,{format:"long",locale:this.loc.locale});case"z":return t.zoneName;case"a":return c();case"d":return i?a({day:"numeric"},"day"):this.num(t.day);case"dd":return i?a({day:"2-digit"},"day"):this.num(t.day,2);case"c":return this.num(t.weekday);case"ccc":return h("short",!0);case"cccc":return h("long",!0);case"ccccc":return h("narrow",!0);case"E":return this.num(t.weekday);case"EEE":return h("short",!1);case"EEEE":return h("long",!1);case"EEEEE":return h("narrow",!1);case"L":return i?a({month:"numeric",day:"numeric"},"month"):this.num(t.month);case"LL":return i?a({month:"2-digit",day:"numeric"},"month"):this.num(t.month,2);case"LLL":return d("short",!0);case"LLLL":return d("long",!0);case"LLLLL":return d("narrow",!0);case"M":return i?a({month:"numeric"},"month"):this.num(t.month);case"MM":return i?a({month:"2-digit"},"month"):this.num(t.month,2);case"MMM":return d("short",!1);case"MMMM":return d("long",!1);case"MMMMM":return d("narrow",!1);case"y":return i?a({year:"numeric"},"year"):this.num(t.year);case"yy":return i?a({year:"2-digit"},"year"):this.num(t.year.toString().slice(-2),2);case"yyyy":return i?a({year:"numeric"},"year"):this.num(t.year,4);case"yyyyyy":return i?a({year:"numeric"},"year"):this.num(t.year,6);case"G":return m("short");case"GG":return m("long");case"GGGGG":return m("narrow");case"kk":return this.num(t.weekYear.toString().slice(-2),2);case"kkkk":return this.num(t.weekYear,4);case"W":return this.num(t.weekNumber);case"WW":return this.num(t.weekNumber,2);case"o":return this.num(t.ordinal);case"ooo":return this.num(t.ordinal,3);case"q":return this.num(t.quarter);case"qq":return this.num(t.quarter,2);case"X":return this.num(Math.floor(t.ts/1e3));case"x":return this.num(t.ts);default:return f(y)}};return Kv(gn.parseFormat(n),v)}formatDurationFromString(t,n){const s=d=>{switch(d[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},i=d=>h=>{const f=s(h);return f?this.num(d.get(f),h.length):h},a=gn.parseFormat(n),o=a.reduce((d,{literal:h,val:f})=>h?d:d.concat(f),[]),c=t.shiftTo(...o.map(s).filter(d=>d));return Kv(a,i(c))}}class js{constructor(t,n){this.reason=t,this.explanation=n}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const Zv=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Go(...e){const t=e.reduce((n,s)=>n+s.source,"");return RegExp(`^${t}$`)}function Ko(...e){return t=>e.reduce(([n,s,i],a)=>{const[o,c,d]=a(t,i);return[{...n,...o},c||s,d]},[{},null,1]).slice(0,2)}function Zo(e,...t){if(e==null)return[null,null];for(const[n,s]of t){const i=n.exec(e);if(i)return s(i)}return[null,null]}function Xv(...e){return(t,n)=>{const s={};let i;for(i=0;i<e.length;i++)s[e[i]]=ca(t[n+i]);return[s,null,n+i]}}const Jv=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,XM=`(?:${Jv.source}?(?:\\[(${Zv.source})\\])?)?`,lf=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Qv=RegExp(`${lf.source}${XM}`),cf=RegExp(`(?:T${Qv.source})?`),JM=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,QM=/(\d{4})-?W(\d\d)(?:-?(\d))?/,qM=/(\d{4})-?(\d{3})/,$M=Xv("weekYear","weekNumber","weekDay"),tD=Xv("year","ordinal"),eD=/(\d{4})-(\d\d)-(\d\d)/,qv=RegExp(`${lf.source} ?(?:${Jv.source}|(${Zv.source}))?`),nD=RegExp(`(?: ${qv.source})?`);function Xo(e,t,n){const s=e[t];return Qt(s)?n:ca(s)}function sD(e,t){return[{year:Xo(e,t),month:Xo(e,t+1,1),day:Xo(e,t+2,1)},null,t+3]}function Jo(e,t){return[{hours:Xo(e,t,0),minutes:Xo(e,t+1,0),seconds:Xo(e,t+2,0),milliseconds:sf(e[t+3])},null,t+4]}function Rl(e,t){const n=!e[t]&&!e[t+1],s=Kd(e[t+1],e[t+2]),i=n?null:xn.instance(s);return[{},i,t+3]}function Hl(e,t){const n=e[t]?Mi.create(e[t]):null;return[{},n,t+1]}const iD=RegExp(`^T?${lf.source}$`),aD=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function oD(e){const[t,n,s,i,a,o,c,d,h]=e,f=t[0]==="-",m=d&&d[0]==="-",v=(y,w=!1)=>y!==void 0&&(w||y&&f)?-y:y;return[{years:v(qa(n)),months:v(qa(s)),weeks:v(qa(i)),days:v(qa(a)),hours:v(qa(o)),minutes:v(qa(c)),seconds:v(qa(d),d==="-0"),milliseconds:v(sf(h),m)}]}const rD={GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function df(e,t,n,s,i,a,o){const c={year:t.length===2?rf(ca(t)):ca(t),month:Rv.indexOf(n)+1,day:ca(s),hour:ca(i),minute:ca(a)};return o&&(c.second=ca(o)),e&&(c.weekday=e.length>3?Wv.indexOf(e)+1:jv.indexOf(e)+1),c}const lD=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function cD(e){const[,t,n,s,i,a,o,c,d,h,f,m]=e,v=df(t,i,s,n,a,o,c);let y;return d?y=rD[d]:h?y=0:y=Kd(f,m),[v,new xn(y)]}function dD(e){return e.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const uD=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,hD=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,fD=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function $v(e){const[,t,n,s,i,a,o,c]=e;return[df(t,i,s,n,a,o,c),xn.utcInstance]}function pD(e){const[,t,n,s,i,a,o,c]=e;return[df(t,c,n,s,i,a,o),xn.utcInstance]}const mD=Go(JM,cf),gD=Go(QM,cf),vD=Go(qM,cf),_D=Go(Qv),t3=Ko(sD,Jo,Rl,Hl),yD=Ko($M,Jo,Rl,Hl),bD=Ko(tD,Jo,Rl,Hl),wD=Ko(Jo,Rl,Hl);function xD(e){return Zo(e,[mD,t3],[gD,yD],[vD,bD],[_D,wD])}function SD(e){return Zo(dD(e),[lD,cD])}function kD(e){return Zo(e,[uD,$v],[hD,$v],[fD,pD])}function CD(e){return Zo(e,[aD,oD])}const OD=Ko(Jo);function MD(e){return Zo(e,[iD,OD])}const DD=Go(eD,nD),ED=Go(qv),TD=Ko(Jo,Rl,Hl);function ID(e){return Zo(e,[DD,t3],[ED,TD])}const AD="Invalid Duration",e3={weeks:{days:7,hours:7*24,minutes:7*24*60,seconds:7*24*60*60,milliseconds:7*24*60*60*1e3},days:{hours:24,minutes:24*60,seconds:24*60*60,milliseconds:24*60*60*1e3},hours:{minutes:60,seconds:60*60,milliseconds:60*60*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},VD={years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:91*24,minutes:91*24*60,seconds:91*24*60*60,milliseconds:91*24*60*60*1e3},months:{weeks:4,days:30,hours:30*24,minutes:30*24*60,seconds:30*24*60*60,milliseconds:30*24*60*60*1e3},...e3},ms=146097/400,Qo=146097/4800,BD={years:{quarters:4,months:12,weeks:ms/7,days:ms,hours:ms*24,minutes:ms*24*60,seconds:ms*24*60*60,milliseconds:ms*24*60*60*1e3},quarters:{months:3,weeks:ms/28,days:ms/4,hours:ms*24/4,minutes:ms*24*60/4,seconds:ms*24*60*60/4,milliseconds:ms*24*60*60*1e3/4},months:{weeks:Qo/7,days:Qo,hours:Qo*24,minutes:Qo*24*60,seconds:Qo*24*60*60,milliseconds:Qo*24*60*60*1e3},...e3},$a=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],PD=$a.slice(0).reverse();function da(e,t,n=!1){const s={values:n?t.values:{...e.values,...t.values||{}},loc:e.loc.clone(t.loc),conversionAccuracy:t.conversionAccuracy||e.conversionAccuracy,matrix:t.matrix||e.matrix};return new ne(s)}function ND(e){return e<0?Math.floor(e):Math.ceil(e)}function n3(e,t,n,s,i){const a=e[i][n],o=t[n]/a,c=Math.sign(o)===Math.sign(s[i]),d=!c&&s[i]!==0&&Math.abs(o)<=1?ND(o):Math.trunc(o);s[i]+=d,t[n]-=d*a}function zD(e,t){PD.reduce((n,s)=>Qt(t[s])?n:(n&&n3(e,t,n,t,s),s),null)}function LD(e){const t={};for(const[n,s]of Object.entries(e))s!==0&&(t[n]=s);return t}class ne{constructor(t){const n=t.conversionAccuracy==="longterm"||!1;let s=n?BD:VD;t.matrix&&(s=t.matrix),this.values=t.values,this.loc=t.loc||Ce.create(),this.conversionAccuracy=n?"longterm":"casual",this.invalid=t.invalid||null,this.matrix=s,this.isLuxonDuration=!0}static fromMillis(t,n){return ne.fromObject({milliseconds:t},n)}static fromObject(t,n={}){if(t==null||typeof t!="object")throw new ps(`Duration.fromObject: argument expected to be an object, got ${t===null?"null":typeof t}`);return new ne({values:Zd(t,ne.normalizeUnit),loc:Ce.fromObject(n),conversionAccuracy:n.conversionAccuracy,matrix:n.matrix})}static fromDurationLike(t){if(Qa(t))return ne.fromMillis(t);if(ne.isDuration(t))return t;if(typeof t=="object")return ne.fromObject(t);throw new ps(`Unknown duration argument ${t} of type ${typeof t}`)}static fromISO(t,n){const[s]=CD(t);return s?ne.fromObject(s,n):ne.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static fromISOTime(t,n){const[s]=MD(t);return s?ne.fromObject(s,n):ne.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static invalid(t,n=null){if(!t)throw new ps("need to specify a reason the Duration is invalid");const s=t instanceof js?t:new js(t,n);if(je.throwOnInvalid)throw new hM(s);return new ne({invalid:s})}static normalizeUnit(t){const n={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[t&&t.toLowerCase()];if(!n)throw new lv(t);return n}static isDuration(t){return t&&t.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(t,n={}){const s={...n,floor:n.round!==!1&&n.floor!==!1};return this.isValid?gn.create(this.loc,s).formatDurationFromString(this,t):AD}toHuman(t={}){const n=$a.map(s=>{const i=this.values[s];return Qt(i)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...t,unit:s.slice(0,-1)}).format(i)}).filter(s=>s);return this.loc.listFormatter({type:"conjunction",style:t.listStyle||"narrow",...t}).format(n)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let t="P";return this.years!==0&&(t+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(t+=this.months+this.quarters*3+"M"),this.weeks!==0&&(t+=this.weeks+"W"),this.days!==0&&(t+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(t+="T"),this.hours!==0&&(t+=this.hours+"H"),this.minutes!==0&&(t+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(t+=af(this.seconds+this.milliseconds/1e3,3)+"S"),t==="P"&&(t+="T0S"),t}toISOTime(t={}){if(!this.isValid)return null;const n=this.toMillis();if(n<0||n>=864e5)return null;t={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...t};const s=this.shiftTo("hours","minutes","seconds","milliseconds");let i=t.format==="basic"?"hhmm":"hh:mm";(!t.suppressSeconds||s.seconds!==0||s.milliseconds!==0)&&(i+=t.format==="basic"?"ss":":ss",(!t.suppressMilliseconds||s.milliseconds!==0)&&(i+=".SSS"));let a=s.toFormat(i);return t.includePrefix&&(a="T"+a),a}toJSON(){return this.toISO()}toString(){return this.toISO()}toMillis(){return this.as("milliseconds")}valueOf(){return this.toMillis()}plus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t),s={};for(const i of $a)(Uo(n.values,i)||Uo(this.values,i))&&(s[i]=n.get(i)+this.get(i));return da(this,{values:s},!0)}minus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t);return this.plus(n.negate())}mapUnits(t){if(!this.isValid)return this;const n={};for(const s of Object.keys(this.values))n[s]=Fv(t(this.values[s],s));return da(this,{values:n},!0)}get(t){return this[ne.normalizeUnit(t)]}set(t){if(!this.isValid)return this;const n={...this.values,...Zd(t,ne.normalizeUnit)};return da(this,{values:n})}reconfigure({locale:t,numberingSystem:n,conversionAccuracy:s,matrix:i}={}){const o={loc:this.loc.clone({locale:t,numberingSystem:n}),matrix:i,conversionAccuracy:s};return da(this,o)}as(t){return this.isValid?this.shiftTo(t).get(t):NaN}normalize(){if(!this.isValid)return this;const t=this.toObject();return zD(this.matrix,t),da(this,{values:t},!0)}rescale(){if(!this.isValid)return this;const t=LD(this.normalize().shiftToAll().toObject());return da(this,{values:t},!0)}shiftTo(...t){if(!this.isValid)return this;if(t.length===0)return this;t=t.map(o=>ne.normalizeUnit(o));const n={},s={},i=this.toObject();let a;for(const o of $a)if(t.indexOf(o)>=0){a=o;let c=0;for(const h in s)c+=this.matrix[h][o]*s[h],s[h]=0;Qa(i[o])&&(c+=i[o]);const d=Math.trunc(c);n[o]=d,s[o]=(c*1e3-d*1e3)/1e3;for(const h in i)$a.indexOf(h)>$a.indexOf(o)&&n3(this.matrix,i,h,n,o)}else Qa(i[o])&&(s[o]=i[o]);for(const o in s)s[o]!==0&&(n[a]+=o===a?s[o]:s[o]/this.matrix[a][o]);return da(this,{values:n},!0).normalize()}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;const t={};for(const n of Object.keys(this.values))t[n]=this.values[n]===0?0:-this.values[n];return da(this,{values:t},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(t){if(!this.isValid||!t.isValid||!this.loc.equals(t.loc))return!1;function n(s,i){return s===void 0||s===0?i===void 0||i===0:s===i}for(const s of $a)if(!n(this.values[s],t.values[s]))return!1;return!0}}const qo="Invalid Interval";function FD(e,t){return!e||!e.isValid?Ae.invalid("missing or invalid start"):!t||!t.isValid?Ae.invalid("missing or invalid end"):t<e?Ae.invalid("end before start",`The end of an interval must be after its start, but you had start=${e.toISO()} and end=${t.toISO()}`):null}class Ae{constructor(t){this.s=t.start,this.e=t.end,this.invalid=t.invalid||null,this.isLuxonInterval=!0}static invalid(t,n=null){if(!t)throw new ps("need to specify a reason the Interval is invalid");const s=t instanceof js?t:new js(t,n);if(je.throwOnInvalid)throw new uM(s);return new Ae({invalid:s})}static fromDateTimes(t,n){const s=Yl(t),i=Yl(n),a=FD(s,i);return a??new Ae({start:s,end:i})}static after(t,n){const s=ne.fromDurationLike(n),i=Yl(t);return Ae.fromDateTimes(i,i.plus(s))}static before(t,n){const s=ne.fromDurationLike(n),i=Yl(t);return Ae.fromDateTimes(i.minus(s),i)}static fromISO(t,n){const[s,i]=(t||"").split("/",2);if(s&&i){let a,o;try{a=St.fromISO(s,n),o=a.isValid}catch{o=!1}let c,d;try{c=St.fromISO(i,n),d=c.isValid}catch{d=!1}if(o&&d)return Ae.fromDateTimes(a,c);if(o){const h=ne.fromISO(i,n);if(h.isValid)return Ae.after(a,h)}else if(d){const h=ne.fromISO(s,n);if(h.isValid)return Ae.before(c,h)}}return Ae.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static isInterval(t){return t&&t.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return this.invalidReason===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(t="milliseconds"){return this.isValid?this.toDuration(t).get(t):NaN}count(t="milliseconds"){if(!this.isValid)return NaN;const n=this.start.startOf(t),s=this.end.startOf(t);return Math.floor(s.diff(n,t).get(t))+1}hasSame(t){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,t):!1}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(t){return this.isValid?this.s>t:!1}isBefore(t){return this.isValid?this.e<=t:!1}contains(t){return this.isValid?this.s<=t&&this.e>t:!1}set({start:t,end:n}={}){return this.isValid?Ae.fromDateTimes(t||this.s,n||this.e):this}splitAt(...t){if(!this.isValid)return[];const n=t.map(Yl).filter(o=>this.contains(o)).sort(),s=[];let{s:i}=this,a=0;for(;i<this.e;){const o=n[a]||this.e,c=+o>+this.e?this.e:o;s.push(Ae.fromDateTimes(i,c)),i=c,a+=1}return s}splitBy(t){const n=ne.fromDurationLike(t);if(!this.isValid||!n.isValid||n.as("milliseconds")===0)return[];let{s}=this,i=1,a;const o=[];for(;s<this.e;){const c=this.start.plus(n.mapUnits(d=>d*i));a=+c>+this.e?this.e:c,o.push(Ae.fromDateTimes(s,a)),s=a,i+=1}return o}divideEqually(t){return this.isValid?this.splitBy(this.length()/t).slice(0,t):[]}overlaps(t){return this.e>t.s&&this.s<t.e}abutsStart(t){return this.isValid?+this.e==+t.s:!1}abutsEnd(t){return this.isValid?+t.e==+this.s:!1}engulfs(t){return this.isValid?this.s<=t.s&&this.e>=t.e:!1}equals(t){return!this.isValid||!t.isValid?!1:this.s.equals(t.s)&&this.e.equals(t.e)}intersection(t){if(!this.isValid)return this;const n=this.s>t.s?this.s:t.s,s=this.e<t.e?this.e:t.e;return n>=s?null:Ae.fromDateTimes(n,s)}union(t){if(!this.isValid)return this;const n=this.s<t.s?this.s:t.s,s=this.e>t.e?this.e:t.e;return Ae.fromDateTimes(n,s)}static merge(t){const[n,s]=t.sort((i,a)=>i.s-a.s).reduce(([i,a],o)=>a?a.overlaps(o)||a.abutsStart(o)?[i,a.union(o)]:[i.concat([a]),o]:[i,o],[[],null]);return s&&n.push(s),n}static xor(t){let n=null,s=0;const i=[],a=t.map(d=>[{time:d.s,type:"s"},{time:d.e,type:"e"}]),o=Array.prototype.concat(...a),c=o.sort((d,h)=>d.time-h.time);for(const d of c)s+=d.type==="s"?1:-1,s===1?n=d.time:(n&&+n!=+d.time&&i.push(Ae.fromDateTimes(n,d.time)),n=null);return Ae.merge(i)}difference(...t){return Ae.xor([this].concat(t)).map(n=>this.intersection(n)).filter(n=>n&&!n.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:qo}toLocaleString(t=Fd,n={}){return this.isValid?gn.create(this.s.loc.clone(n),t).formatInterval(this):qo}toISO(t){return this.isValid?`${this.s.toISO(t)}/${this.e.toISO(t)}`:qo}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:qo}toISOTime(t){return this.isValid?`${this.s.toISOTime(t)}/${this.e.toISOTime(t)}`:qo}toFormat(t,{separator:n=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(t)}${n}${this.e.toFormat(t)}`:qo}toDuration(t,n){return this.isValid?this.e.diff(this.s,t,n):ne.invalid(this.invalidReason)}mapEndpoints(t){return Ae.fromDateTimes(t(this.s),t(this.e))}}class Jd{static hasDST(t=je.defaultZone){const n=St.now().setZone(t).set({month:12});return!t.isUniversal&&n.offset!==n.set({month:6}).offset}static isValidIANAZone(t){return Mi.isValidZone(t)}static normalizeZone(t){return la(t,je.defaultZone)}static months(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null,outputCalendar:a="gregory"}={}){return(i||Ce.create(n,s,a)).months(t)}static monthsFormat(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null,outputCalendar:a="gregory"}={}){return(i||Ce.create(n,s,a)).months(t,!0)}static weekdays(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null}={}){return(i||Ce.create(n,s,null)).weekdays(t)}static weekdaysFormat(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null}={}){return(i||Ce.create(n,s,null)).weekdays(t,!0)}static meridiems({locale:t=null}={}){return Ce.create(t).meridiems()}static eras(t="short",{locale:n=null}={}){return Ce.create(n,null,"gregory").eras(t)}static features(){return{relative:Nv()}}}function s3(e,t){const n=i=>i.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),s=n(t)-n(e);return Math.floor(ne.fromMillis(s).as("days"))}function RD(e,t,n){const s=[["years",(d,h)=>h.year-d.year],["quarters",(d,h)=>h.quarter-d.quarter+(h.year-d.year)*4],["months",(d,h)=>h.month-d.month+(h.year-d.year)*12],["weeks",(d,h)=>{const f=s3(d,h);return(f-f%7)/7}],["days",s3]],i={},a=e;let o,c;for(const[d,h]of s)n.indexOf(d)>=0&&(o=d,i[d]=h(e,t),c=a.plus(i),c>t?(i[d]--,e=a.plus(i)):e=c);return[e,i,c,o]}function HD(e,t,n,s){let[i,a,o,c]=RD(e,t,n);const d=t-i,h=n.filter(m=>["hours","minutes","seconds","milliseconds"].indexOf(m)>=0);h.length===0&&(o<t&&(o=i.plus({[c]:1})),o!==i&&(a[c]=(a[c]||0)+d/(o-i)));const f=ne.fromObject(a,s);return h.length>0?ne.fromMillis(d,s).shiftTo(...h).plus(f):f}const uf={arab:"[\u0660-\u0669]",arabext:"[\u06F0-\u06F9]",bali:"[\u1B50-\u1B59]",beng:"[\u09E6-\u09EF]",deva:"[\u0966-\u096F]",fullwide:"[\uFF10-\uFF19]",gujr:"[\u0AE6-\u0AEF]",hanidec:"[\u3007|\u4E00|\u4E8C|\u4E09|\u56DB|\u4E94|\u516D|\u4E03|\u516B|\u4E5D]",khmr:"[\u17E0-\u17E9]",knda:"[\u0CE6-\u0CEF]",laoo:"[\u0ED0-\u0ED9]",limb:"[\u1946-\u194F]",mlym:"[\u0D66-\u0D6F]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0B66-\u0B6F]",tamldec:"[\u0BE6-\u0BEF]",telu:"[\u0C66-\u0C6F]",thai:"[\u0E50-\u0E59]",tibt:"[\u0F20-\u0F29]",latn:"\\d"},i3={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},WD=uf.hanidec.replace(/[\[|\]]/g,"").split("");function jD(e){let t=parseInt(e,10);if(isNaN(t)){t="";for(let n=0;n<e.length;n++){const s=e.charCodeAt(n);if(e[n].search(uf.hanidec)!==-1)t+=WD.indexOf(e[n]);else for(const i in i3){const[a,o]=i3[i];s>=a&&s<=o&&(t+=s-a)}}return parseInt(t,10)}else return t}function Ys({numberingSystem:e},t=""){return new RegExp(`${uf[e||"latn"]}${t}`)}const YD="missing Intl.DateTimeFormat.formatToParts support";function ie(e,t=n=>n){return{regex:e,deser:([n])=>t(jD(n))}}const a3=`[ ${String.fromCharCode(160)}]`,o3=new RegExp(a3,"g");function UD(e){return e.replace(/\./g,"\\.?").replace(o3,a3)}function r3(e){return e.replace(/\./g,"").replace(o3," ").toLowerCase()}function Us(e,t){return e===null?null:{regex:RegExp(e.map(UD).join("|")),deser:([n])=>e.findIndex(s=>r3(n)===r3(s))+t}}function l3(e,t){return{regex:e,deser:([,n,s])=>Kd(n,s),groups:t}}function hf(e){return{regex:e,deser:([t])=>t}}function GD(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function KD(e,t){const n=Ys(t),s=Ys(t,"{2}"),i=Ys(t,"{3}"),a=Ys(t,"{4}"),o=Ys(t,"{6}"),c=Ys(t,"{1,2}"),d=Ys(t,"{1,3}"),h=Ys(t,"{1,6}"),f=Ys(t,"{1,9}"),m=Ys(t,"{2,4}"),v=Ys(t,"{4,6}"),y=k=>({regex:RegExp(GD(k.val)),deser:([D])=>D,literal:!0}),x=(k=>{if(e.literal)return y(k);switch(k.val){case"G":return Us(t.eras("short",!1),0);case"GG":return Us(t.eras("long",!1),0);case"y":return ie(h);case"yy":return ie(m,rf);case"yyyy":return ie(a);case"yyyyy":return ie(v);case"yyyyyy":return ie(o);case"M":return ie(c);case"MM":return ie(s);case"MMM":return Us(t.months("short",!0,!1),1);case"MMMM":return Us(t.months("long",!0,!1),1);case"L":return ie(c);case"LL":return ie(s);case"LLL":return Us(t.months("short",!1,!1),1);case"LLLL":return Us(t.months("long",!1,!1),1);case"d":return ie(c);case"dd":return ie(s);case"o":return ie(d);case"ooo":return ie(i);case"HH":return ie(s);case"H":return ie(c);case"hh":return ie(s);case"h":return ie(c);case"mm":return ie(s);case"m":return ie(c);case"q":return ie(c);case"qq":return ie(s);case"s":return ie(c);case"ss":return ie(s);case"S":return ie(d);case"SSS":return ie(i);case"u":return hf(f);case"uu":return hf(c);case"uuu":return ie(n);case"a":return Us(t.meridiems(),0);case"kkkk":return ie(a);case"kk":return ie(m,rf);case"W":return ie(c);case"WW":return ie(s);case"E":case"c":return ie(n);case"EEE":return Us(t.weekdays("short",!1,!1),1);case"EEEE":return Us(t.weekdays("long",!1,!1),1);case"ccc":return Us(t.weekdays("short",!0,!1),1);case"cccc":return Us(t.weekdays("long",!0,!1),1);case"Z":case"ZZ":return l3(new RegExp(`([+-]${c.source})(?::(${s.source}))?`),2);case"ZZZ":return l3(new RegExp(`([+-]${c.source})(${s.source})?`),2);case"z":return hf(/[a-z_+-/]{1,256}?/i);default:return y(k)}})(e)||{invalidReason:YD};return x.token=e,x}const ZD={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};function XD(e,t){const{type:n,value:s}=e;if(n==="literal")return{literal:!0,val:s};const i=t[n];let a=ZD[n];if(typeof a=="object"&&(a=a[i]),a)return{literal:!1,val:a}}function JD(e){return[`^${e.map(n=>n.regex).reduce((n,s)=>`${n}(${s.source})`,"")}$`,e]}function QD(e,t,n){const s=e.match(t);if(s){const i={};let a=1;for(const o in n)if(Uo(n,o)){const c=n[o],d=c.groups?c.groups+1:1;!c.literal&&c.token&&(i[c.token.val[0]]=c.deser(s.slice(a,a+d))),a+=d}return[s,i]}else return[s,{}]}function qD(e){const t=a=>{switch(a){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}};let n=null,s;return Qt(e.z)||(n=Mi.create(e.z)),Qt(e.Z)||(n||(n=new xn(e.Z)),s=e.Z),Qt(e.q)||(e.M=(e.q-1)*3+1),Qt(e.h)||(e.h<12&&e.a===1?e.h+=12:e.h===12&&e.a===0&&(e.h=0)),e.G===0&&e.y&&(e.y=-e.y),Qt(e.u)||(e.S=sf(e.u)),[Object.keys(e).reduce((a,o)=>{const c=t(o);return c&&(a[c]=e[o]),a},{}),n,s]}let ff=null;function $D(){return ff||(ff=St.fromMillis(1555555555555)),ff}function tE(e,t){if(e.literal)return e;const n=gn.macroTokenToFormatOpts(e.val),s=u3(n,t);return s==null||s.includes(void 0)?e:s}function c3(e,t){return Array.prototype.concat(...e.map(n=>tE(n,t)))}function d3(e,t,n){const s=c3(gn.parseFormat(n),e),i=s.map(o=>KD(o,e)),a=i.find(o=>o.invalidReason);if(a)return{input:t,tokens:s,invalidReason:a.invalidReason};{const[o,c]=JD(i),d=RegExp(o,"i"),[h,f]=QD(t,d,c),[m,v,y]=f?qD(f):[null,null,void 0];if(Uo(f,"a")&&Uo(f,"H"))throw new Bl("Can't include meridiem when specifying 24-hour format");return{input:t,tokens:s,regex:d,rawMatches:h,matches:f,result:m,zone:v,specificOffset:y}}}function eE(e,t,n){const{result:s,zone:i,specificOffset:a,invalidReason:o}=d3(e,t,n);return[s,i,a,o]}function u3(e,t){return e?gn.create(t,e).formatDateTimeParts($D()).map(i=>XD(i,e)):null}const h3=[0,31,59,90,120,151,181,212,243,273,304,334],f3=[0,31,60,91,121,152,182,213,244,274,305,335];function gs(e,t){return new js("unit out of range",`you specified ${t} (of type ${typeof t}) as a ${e}, which is invalid`)}function p3(e,t,n){const s=new Date(Date.UTC(e,t-1,n));e<100&&e>=0&&s.setUTCFullYear(s.getUTCFullYear()-1900);const i=s.getUTCDay();return i===0?7:i}function m3(e,t,n){return n+(zl(e)?f3:h3)[t-1]}function g3(e,t){const n=zl(e)?f3:h3,s=n.findIndex(a=>a<t),i=t-n[s];return{month:s+1,day:i}}function pf(e){const{year:t,month:n,day:s}=e,i=m3(t,n,s),a=p3(t,n,s);let o=Math.floor((i-a+10)/7),c;return o<1?(c=t-1,o=Gd(c)):o>Gd(t)?(c=t+1,o=1):c=t,{weekYear:c,weekNumber:o,weekday:a,...Xd(e)}}function v3(e){const{weekYear:t,weekNumber:n,weekday:s}=e,i=p3(t,1,4),a=Ll(t);let o=n*7+s-i-3,c;o<1?(c=t-1,o+=Ll(c)):o>a?(c=t+1,o-=Ll(t)):c=t;const{month:d,day:h}=g3(c,o);return{year:c,month:d,day:h,...Xd(e)}}function mf(e){const{year:t,month:n,day:s}=e,i=m3(t,n,s);return{year:t,ordinal:i,...Xd(e)}}function _3(e){const{year:t,ordinal:n}=e,{month:s,day:i}=g3(t,n);return{year:t,month:s,day:i,...Xd(e)}}function nE(e){const t=Yd(e.weekYear),n=Di(e.weekNumber,1,Gd(e.weekYear)),s=Di(e.weekday,1,7);return t?n?s?!1:gs("weekday",e.weekday):gs("week",e.week):gs("weekYear",e.weekYear)}function sE(e){const t=Yd(e.year),n=Di(e.ordinal,1,Ll(e.year));return t?n?!1:gs("ordinal",e.ordinal):gs("year",e.year)}function y3(e){const t=Yd(e.year),n=Di(e.month,1,12),s=Di(e.day,1,Ud(e.year,e.month));return t?n?s?!1:gs("day",e.day):gs("month",e.month):gs("year",e.year)}function b3(e){const{hour:t,minute:n,second:s,millisecond:i}=e,a=Di(t,0,23)||t===24&&n===0&&s===0&&i===0,o=Di(n,0,59),c=Di(s,0,59),d=Di(i,0,999);return a?o?c?d?!1:gs("millisecond",i):gs("second",s):gs("minute",n):gs("hour",t)}const gf="Invalid DateTime",w3=864e13;function Qd(e){return new js("unsupported zone",`the zone "${e.name}" is not supported`)}function vf(e){return e.weekData===null&&(e.weekData=pf(e.c)),e.weekData}function Wl(e,t){const n={ts:e.ts,zone:e.zone,c:e.c,o:e.o,loc:e.loc,invalid:e.invalid};return new St({...n,...t,old:n})}function x3(e,t,n){let s=e-t*60*1e3;const i=n.offset(s);if(t===i)return[s,t];s-=(i-t)*60*1e3;const a=n.offset(s);return i===a?[s,i]:[e-Math.min(i,a)*60*1e3,Math.max(i,a)]}function S3(e,t){e+=t*60*1e3;const n=new Date(e);return{year:n.getUTCFullYear(),month:n.getUTCMonth()+1,day:n.getUTCDate(),hour:n.getUTCHours(),minute:n.getUTCMinutes(),second:n.getUTCSeconds(),millisecond:n.getUTCMilliseconds()}}function qd(e,t,n){return x3(of(e),t,n)}function k3(e,t){const n=e.o,s=e.c.year+Math.trunc(t.years),i=e.c.month+Math.trunc(t.months)+Math.trunc(t.quarters)*3,a={...e.c,year:s,month:i,day:Math.min(e.c.day,Ud(s,i))+Math.trunc(t.days)+Math.trunc(t.weeks)*7},o=ne.fromObject({years:t.years-Math.trunc(t.years),quarters:t.quarters-Math.trunc(t.quarters),months:t.months-Math.trunc(t.months),weeks:t.weeks-Math.trunc(t.weeks),days:t.days-Math.trunc(t.days),hours:t.hours,minutes:t.minutes,seconds:t.seconds,milliseconds:t.milliseconds}).as("milliseconds"),c=of(a);let[d,h]=x3(c,n,e.zone);return o!==0&&(d+=o,h=e.zone.offset(d)),{ts:d,o:h}}function jl(e,t,n,s,i,a){const{setZone:o,zone:c}=n;if(e&&Object.keys(e).length!==0){const d=t||c,h=St.fromObject(e,{...n,zone:d,specificOffset:a});return o?h:h.setZone(c)}else return St.invalid(new js("unparsable",`the input "${i}" can't be parsed as ${s}`))}function $d(e,t,n=!0){return e.isValid?gn.create(Ce.create("en-US"),{allowZ:n,forceSimple:!0}).formatDateTimeFromString(e,t):null}function _f(e,t){const n=e.c.year>9999||e.c.year<0;let s="";return n&&e.c.year>=0&&(s+="+"),s+=Ye(e.c.year,n?6:4),t?(s+="-",s+=Ye(e.c.month),s+="-",s+=Ye(e.c.day)):(s+=Ye(e.c.month),s+=Ye(e.c.day)),s}function C3(e,t,n,s,i,a){let o=Ye(e.c.hour);return t?(o+=":",o+=Ye(e.c.minute),(e.c.second!==0||!n)&&(o+=":")):o+=Ye(e.c.minute),(e.c.second!==0||!n)&&(o+=Ye(e.c.second),(e.c.millisecond!==0||!s)&&(o+=".",o+=Ye(e.c.millisecond,3))),i&&(e.isOffsetFixed&&e.offset===0&&!a?o+="Z":e.o<0?(o+="-",o+=Ye(Math.trunc(-e.o/60)),o+=":",o+=Ye(Math.trunc(-e.o%60))):(o+="+",o+=Ye(Math.trunc(e.o/60)),o+=":",o+=Ye(Math.trunc(e.o%60)))),a&&(o+="["+e.zone.ianaName+"]"),o}const O3={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},iE={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},aE={ordinal:1,hour:0,minute:0,second:0,millisecond:0},M3=["year","month","day","hour","minute","second","millisecond"],oE=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],rE=["year","ordinal","hour","minute","second","millisecond"];function D3(e){const t={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[e.toLowerCase()];if(!t)throw new lv(e);return t}function E3(e,t){const n=la(t.zone,je.defaultZone),s=Ce.fromObject(t),i=je.now();let a,o;if(Qt(e.year))a=i;else{for(const h of M3)Qt(e[h])&&(e[h]=O3[h]);const c=y3(e)||b3(e);if(c)return St.invalid(c);const d=n.offset(i);[a,o]=qd(e,d,n)}return new St({ts:a,zone:n,loc:s,o})}function T3(e,t,n){const s=Qt(n.round)?!0:n.round,i=(o,c)=>(o=af(o,s||n.calendary?0:2,!0),t.loc.clone(n).relFormatter(n).format(o,c)),a=o=>n.calendary?t.hasSame(e,o)?0:t.startOf(o).diff(e.startOf(o),o).get(o):t.diff(e,o).get(o);if(n.unit)return i(a(n.unit),n.unit);for(const o of n.units){const c=a(o);if(Math.abs(c)>=1)return i(c,o)}return i(e>t?-0:0,n.units[n.units.length-1])}function I3(e){let t={},n;return e.length>0&&typeof e[e.length-1]=="object"?(t=e[e.length-1],n=Array.from(e).slice(0,e.length-1)):n=Array.from(e),[t,n]}class St{constructor(t){const n=t.zone||je.defaultZone;let s=t.invalid||(Number.isNaN(t.ts)?new js("invalid input"):null)||(n.isValid?null:Qd(n));this.ts=Qt(t.ts)?je.now():t.ts;let i=null,a=null;if(!s)if(t.old&&t.old.ts===this.ts&&t.old.zone.equals(n))[i,a]=[t.old.c,t.old.o];else{const c=n.offset(this.ts);i=S3(this.ts,c),s=Number.isNaN(i.year)?new js("invalid input"):null,i=s?null:i,a=s?null:c}this._zone=n,this.loc=t.loc||Ce.create(),this.invalid=s,this.weekData=null,this.c=i,this.o=a,this.isLuxonDateTime=!0}static now(){return new St({})}static local(){const[t,n]=I3(arguments),[s,i,a,o,c,d,h]=n;return E3({year:s,month:i,day:a,hour:o,minute:c,second:d,millisecond:h},t)}static utc(){const[t,n]=I3(arguments),[s,i,a,o,c,d,h]=n;return t.zone=xn.utcInstance,E3({year:s,month:i,day:a,hour:o,minute:c,second:d,millisecond:h},t)}static fromJSDate(t,n={}){const s=VM(t)?t.valueOf():NaN;if(Number.isNaN(s))return St.invalid("invalid input");const i=la(n.zone,je.defaultZone);return i.isValid?new St({ts:s,zone:i,loc:Ce.fromObject(n)}):St.invalid(Qd(i))}static fromMillis(t,n={}){if(Qa(t))return t<-w3||t>w3?St.invalid("Timestamp out of range"):new St({ts:t,zone:la(n.zone,je.defaultZone),loc:Ce.fromObject(n)});throw new ps(`fromMillis requires a numerical input, but received a ${typeof t} with value ${t}`)}static fromSeconds(t,n={}){if(Qa(t))return new St({ts:t*1e3,zone:la(n.zone,je.defaultZone),loc:Ce.fromObject(n)});throw new ps("fromSeconds requires a numerical input")}static fromObject(t,n={}){t=t||{};const s=la(n.zone,je.defaultZone);if(!s.isValid)return St.invalid(Qd(s));const i=je.now(),a=Qt(n.specificOffset)?s.offset(i):n.specificOffset,o=Zd(t,D3),c=!Qt(o.ordinal),d=!Qt(o.year),h=!Qt(o.month)||!Qt(o.day),f=d||h,m=o.weekYear||o.weekNumber,v=Ce.fromObject(n);if((f||c)&&m)throw new Bl("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(h&&c)throw new Bl("Can't mix ordinal dates with month/day");const y=m||o.weekday&&!f;let w,x,k=S3(i,a);y?(w=oE,x=iE,k=pf(k)):c?(w=rE,x=aE,k=mf(k)):(w=M3,x=O3);let D=!1;for(const L of w){const W=o[L];Qt(W)?D?o[L]=x[L]:o[L]=k[L]:D=!0}const E=y?nE(o):c?sE(o):y3(o),B=E||b3(o);if(B)return St.invalid(B);const S=y?v3(o):c?_3(o):o,[A,I]=qd(S,a,s),F=new St({ts:A,zone:s,o:I,loc:v});return o.weekday&&f&&t.weekday!==F.weekday?St.invalid("mismatched weekday",`you can't specify both a weekday of ${o.weekday} and a date of ${F.toISO()}`):F}static fromISO(t,n={}){const[s,i]=xD(t);return jl(s,i,n,"ISO 8601",t)}static fromRFC2822(t,n={}){const[s,i]=SD(t);return jl(s,i,n,"RFC 2822",t)}static fromHTTP(t,n={}){const[s,i]=kD(t);return jl(s,i,n,"HTTP",n)}static fromFormat(t,n,s={}){if(Qt(t)||Qt(n))throw new ps("fromFormat requires an input string and a format");const{locale:i=null,numberingSystem:a=null}=s,o=Ce.fromOpts({locale:i,numberingSystem:a,defaultToEN:!0}),[c,d,h,f]=eE(o,t,n);return f?St.invalid(f):jl(c,d,s,`format ${n}`,t,h)}static fromString(t,n,s={}){return St.fromFormat(t,n,s)}static fromSQL(t,n={}){const[s,i]=ID(t);return jl(s,i,n,"SQL",t)}static invalid(t,n=null){if(!t)throw new ps("need to specify a reason the DateTime is invalid");const s=t instanceof js?t:new js(t,n);if(je.throwOnInvalid)throw new dM(s);return new St({invalid:s})}static isDateTime(t){return t&&t.isLuxonDateTime||!1}static parseFormatForOpts(t,n={}){const s=u3(t,Ce.fromObject(n));return s?s.map(i=>i?i.val:null).join(""):null}static expandFormat(t,n={}){return c3(gn.parseFormat(t),Ce.fromObject(n)).map(i=>i.val).join("")}get(t){return this[t]}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?vf(this).weekYear:NaN}get weekNumber(){return this.isValid?vf(this).weekNumber:NaN}get weekday(){return this.isValid?vf(this).weekday:NaN}get ordinal(){return this.isValid?mf(this.c).ordinal:NaN}get monthShort(){return this.isValid?Jd.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?Jd.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?Jd.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?Jd.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return this.isOffsetFixed?!1:this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset}get isInLeapYear(){return zl(this.year)}get daysInMonth(){return Ud(this.year,this.month)}get daysInYear(){return this.isValid?Ll(this.year):NaN}get weeksInWeekYear(){return this.isValid?Gd(this.weekYear):NaN}resolvedLocaleOptions(t={}){const{locale:n,numberingSystem:s,calendar:i}=gn.create(this.loc.clone(t),t).resolvedOptions(this);return{locale:n,numberingSystem:s,outputCalendar:i}}toUTC(t=0,n={}){return this.setZone(xn.instance(t),n)}toLocal(){return this.setZone(je.defaultZone)}setZone(t,{keepLocalTime:n=!1,keepCalendarTime:s=!1}={}){if(t=la(t,je.defaultZone),t.equals(this.zone))return this;if(t.isValid){let i=this.ts;if(n||s){const a=t.offset(this.ts),o=this.toObject();[i]=qd(o,a,t)}return Wl(this,{ts:i,zone:t})}else return St.invalid(Qd(t))}reconfigure({locale:t,numberingSystem:n,outputCalendar:s}={}){const i=this.loc.clone({locale:t,numberingSystem:n,outputCalendar:s});return Wl(this,{loc:i})}setLocale(t){return this.reconfigure({locale:t})}set(t){if(!this.isValid)return this;const n=Zd(t,D3),s=!Qt(n.weekYear)||!Qt(n.weekNumber)||!Qt(n.weekday),i=!Qt(n.ordinal),a=!Qt(n.year),o=!Qt(n.month)||!Qt(n.day),c=a||o,d=n.weekYear||n.weekNumber;if((c||i)&&d)throw new Bl("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(o&&i)throw new Bl("Can't mix ordinal dates with month/day");let h;s?h=v3({...pf(this.c),...n}):Qt(n.ordinal)?(h={...this.toObject(),...n},Qt(n.day)&&(h.day=Math.min(Ud(h.year,h.month),h.day))):h=_3({...mf(this.c),...n});const[f,m]=qd(h,this.o,this.zone);return Wl(this,{ts:f,o:m})}plus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t);return Wl(this,k3(this,n))}minus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t).negate();return Wl(this,k3(this,n))}startOf(t){if(!this.isValid)return this;const n={},s=ne.normalizeUnit(t);switch(s){case"years":n.month=1;case"quarters":case"months":n.day=1;case"weeks":case"days":n.hour=0;case"hours":n.minute=0;case"minutes":n.second=0;case"seconds":n.millisecond=0;break}if(s==="weeks"&&(n.weekday=1),s==="quarters"){const i=Math.ceil(this.month/3);n.month=(i-1)*3+1}return this.set(n)}endOf(t){return this.isValid?this.plus({[t]:1}).startOf(t).minus(1):this}toFormat(t,n={}){return this.isValid?gn.create(this.loc.redefaultToEN(n)).formatDateTimeFromString(this,t):gf}toLocaleString(t=Fd,n={}){return this.isValid?gn.create(this.loc.clone(n),t).formatDateTime(this):gf}toLocaleParts(t={}){return this.isValid?gn.create(this.loc.clone(t),t).formatDateTimeParts(this):[]}toISO({format:t="extended",suppressSeconds:n=!1,suppressMilliseconds:s=!1,includeOffset:i=!0,extendedZone:a=!1}={}){if(!this.isValid)return null;const o=t==="extended";let c=_f(this,o);return c+="T",c+=C3(this,o,n,s,i,a),c}toISODate({format:t="extended"}={}){return this.isValid?_f(this,t==="extended"):null}toISOWeekDate(){return $d(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:t=!1,suppressSeconds:n=!1,includeOffset:s=!0,includePrefix:i=!1,extendedZone:a=!1,format:o="extended"}={}){return this.isValid?(i?"T":"")+C3(this,o==="extended",n,t,s,a):null}toRFC2822(){return $d(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return $d(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?_f(this,!0):null}toSQLTime({includeOffset:t=!0,includeZone:n=!1,includeOffsetSpace:s=!0}={}){let i="HH:mm:ss.SSS";return(n||t)&&(s&&(i+=" "),n?i+="z":t&&(i+="ZZ")),$d(this,i,!0)}toSQL(t={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(t)}`:null}toString(){return this.isValid?this.toISO():gf}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(t={}){if(!this.isValid)return{};const n={...this.c};return t.includeConfig&&(n.outputCalendar=this.outputCalendar,n.numberingSystem=this.loc.numberingSystem,n.locale=this.loc.locale),n}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(t,n="milliseconds",s={}){if(!this.isValid||!t.isValid)return ne.invalid("created by diffing an invalid DateTime");const i={locale:this.locale,numberingSystem:this.numberingSystem,...s},a=BM(n).map(ne.normalizeUnit),o=t.valueOf()>this.valueOf(),c=o?this:t,d=o?t:this,h=HD(c,d,a,i);return o?h.negate():h}diffNow(t="milliseconds",n={}){return this.diff(St.now(),t,n)}until(t){return this.isValid?Ae.fromDateTimes(this,t):this}hasSame(t,n){if(!this.isValid)return!1;const s=t.valueOf(),i=this.setZone(t.zone,{keepLocalTime:!0});return i.startOf(n)<=s&&s<=i.endOf(n)}equals(t){return this.isValid&&t.isValid&&this.valueOf()===t.valueOf()&&this.zone.equals(t.zone)&&this.loc.equals(t.loc)}toRelative(t={}){if(!this.isValid)return null;const n=t.base||St.fromObject({},{zone:this.zone}),s=t.padding?this<n?-t.padding:t.padding:0;let i=["years","months","days","hours","minutes","seconds"],a=t.unit;return Array.isArray(t.unit)&&(i=t.unit,a=void 0),T3(n,this.plus(s),{...t,numeric:"always",units:i,unit:a})}toRelativeCalendar(t={}){return this.isValid?T3(t.base||St.fromObject({},{zone:this.zone}),this,{...t,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...t){if(!t.every(St.isDateTime))throw new ps("min requires all arguments be DateTimes");return zv(t,n=>n.valueOf(),Math.min)}static max(...t){if(!t.every(St.isDateTime))throw new ps("max requires all arguments be DateTimes");return zv(t,n=>n.valueOf(),Math.max)}static fromFormatExplain(t,n,s={}){const{locale:i=null,numberingSystem:a=null}=s,o=Ce.fromOpts({locale:i,numberingSystem:a,defaultToEN:!0});return d3(o,t,n)}static fromStringExplain(t,n,s={}){return St.fromFormatExplain(t,n,s)}static get DATE_SHORT(){return Fd}static get DATE_MED(){return cv}static get DATE_MED_WITH_WEEKDAY(){return fM}static get DATE_FULL(){return dv}static get DATE_HUGE(){return uv}static get TIME_SIMPLE(){return hv}static get TIME_WITH_SECONDS(){return fv}static get TIME_WITH_SHORT_OFFSET(){return pv}static get TIME_WITH_LONG_OFFSET(){return mv}static get TIME_24_SIMPLE(){return gv}static get TIME_24_WITH_SECONDS(){return vv}static get TIME_24_WITH_SHORT_OFFSET(){return _v}static get TIME_24_WITH_LONG_OFFSET(){return yv}static get DATETIME_SHORT(){return bv}static get DATETIME_SHORT_WITH_SECONDS(){return wv}static get DATETIME_MED(){return xv}static get DATETIME_MED_WITH_SECONDS(){return Sv}static get DATETIME_MED_WITH_WEEKDAY(){return pM}static get DATETIME_FULL(){return kv}static get DATETIME_FULL_WITH_SECONDS(){return Cv}static get DATETIME_HUGE(){return Ov}static get DATETIME_HUGE_WITH_SECONDS(){return Mv}}function Yl(e){if(St.isDateTime(e))return e;if(e&&e.valueOf&&Qa(e.valueOf()))return St.fromJSDate(e);if(e&&typeof e=="object")return St.fromObject(e);throw new ps(`Unknown datetime argument: ${e}, of type ${typeof e}`)}function Ul(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function vs(e){if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t?t.defaultView:window}return e}function yf(e){var t=vs(e),n=t.pageXOffset,s=t.pageYOffset;return{scrollLeft:n,scrollTop:s}}function Gl(e){var t=vs(e).Element;return e instanceof t||e instanceof Element}function Gs(e){var t=vs(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function lE(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function cE(e){return e===vs(e)||!Gs(e)?yf(e):lE(e)}function Ei(e){return e?(e.nodeName||"").toLowerCase():null}function ua(e){return(Gl(e)?e.ownerDocument:e.document).documentElement}function A3(e){return Ul(ua(e)).left+yf(e).scrollLeft}function to(e){return vs(e).getComputedStyle(e)}function bf(e){var t=to(e),n=t.overflow,s=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+s)}function V3(e,t,n){n===void 0&&(n=!1);var s=ua(t),i=Ul(e),a={scrollLeft:0,scrollTop:0},o={x:0,y:0};return n||((Ei(t)!=="body"||bf(s))&&(a=cE(t)),Gs(t)?(o=Ul(t),o.x+=t.clientLeft,o.y+=t.clientTop):s&&(o.x=A3(s))),{x:i.left+a.scrollLeft-o.x,y:i.top+a.scrollTop-o.y,width:i.width,height:i.height}}function wf(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function B3(e){return Ei(e)==="html"?e:e.assignedSlot||e.parentNode||e.host||ua(e)}function P3(e){return["html","body","#document"].indexOf(Ei(e))>=0?e.ownerDocument.body:Gs(e)&&bf(e)?e:P3(B3(e))}function Kl(e,t){t===void 0&&(t=[]);var n=P3(e),s=Ei(n)==="body",i=vs(n),a=s?[i].concat(i.visualViewport||[],bf(n)?n:[]):n,o=t.concat(a);return s?o:o.concat(Kl(B3(a)))}function dE(e){return["table","td","th"].indexOf(Ei(e))>=0}function N3(e){return!Gs(e)||to(e).position==="fixed"?null:e.offsetParent}function Zl(e){for(var t=vs(e),n=N3(e);n&&dE(n);)n=N3(n);return n&&Ei(n)==="body"&&to(n).position==="static"?t:n||t}var _s="top",Ks="bottom",Zs="right",ys="left",tu="auto",Xl=[_s,Ks,Zs,ys],$o="start",xf="end",uE="clippingParents",z3="viewport",Jl="popper",hE="reference",L3=Xl.reduce(function(e,t){return e.concat([t+"-"+$o,t+"-"+xf])},[]),F3=[].concat(Xl,[tu]).reduce(function(e,t){return e.concat([t,t+"-"+$o,t+"-"+xf])},[]),fE="beforeRead",pE="read",mE="afterRead",gE="beforeMain",vE="main",_E="afterMain",yE="beforeWrite",bE="write",wE="afterWrite",Sf=[fE,pE,mE,gE,vE,_E,yE,bE,wE];function xE(e){var t=new Map,n=new Set,s=[];e.forEach(function(a){t.set(a.name,a)});function i(a){n.add(a.name);var o=[].concat(a.requires||[],a.requiresIfExists||[]);o.forEach(function(c){if(!n.has(c)){var d=t.get(c);d&&i(d)}}),s.push(a)}return e.forEach(function(a){n.has(a.name)||i(a)}),s}function SE(e){var t=xE(e);return Sf.reduce(function(n,s){return n.concat(t.filter(function(i){return i.phase===s}))},[])}function kE(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function ha(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),s=1;s<t;s++)n[s-1]=arguments[s];return[].concat(n).reduce(function(i,a){return i.replace(/%s/,a)},e)}var eo='Popper: modifier "%s" provided an invalid %s property, expected %s but got %s',CE='Popper: modifier "%s" requires "%s", but "%s" modifier is not available',OE=["name","enabled","phase","fn","effect","requires","options"];function ME(e){e.forEach(function(t){Object.keys(t).forEach(function(n){switch(n){case"name":typeof t.name!="string"&&console.error(ha(eo,String(t.name),'"name"','"string"','"'+String(t.name)+'"'));break;case"enabled":typeof t.enabled!="boolean"&&console.error(ha(eo,t.name,'"enabled"','"boolean"','"'+String(t.enabled)+'"'));case"phase":Sf.indexOf(t.phase)<0&&console.error(ha(eo,t.name,'"phase"',"either "+Sf.join(", "),'"'+String(t.phase)+'"'));break;case"fn":typeof t.fn!="function"&&console.error(ha(eo,t.name,'"fn"','"function"','"'+String(t.fn)+'"'));break;case"effect":typeof t.effect!="function"&&console.error(ha(eo,t.name,'"effect"','"function"','"'+String(t.fn)+'"'));break;case"requires":Array.isArray(t.requires)||console.error(ha(eo,t.name,'"requires"','"array"','"'+String(t.requires)+'"'));break;case"requiresIfExists":Array.isArray(t.requiresIfExists)||console.error(ha(eo,t.name,'"requiresIfExists"','"array"','"'+String(t.requiresIfExists)+'"'));break;case"options":case"data":break;default:console.error('PopperJS: an invalid property has been provided to the "'+t.name+'" modifier, valid properties are '+OE.map(function(s){return'"'+s+'"'}).join(", ")+'; but "'+n+'" was provided.')}t.requires&&t.requires.forEach(function(s){e.find(function(i){return i.name===s})==null&&console.error(ha(CE,String(t.name),s,s))})})})}function DE(e,t){var n=new Set;return e.filter(function(s){var i=t(s);if(!n.has(i))return n.add(i),!0})}function Xs(e){return e.split("-")[0]}function EE(e){var t=e.reduce(function(n,s){var i=n[s.name];return n[s.name]=i?Object.assign({},i,{},s,{options:Object.assign({},i.options,{},s.options),data:Object.assign({},i.data,{},s.data)}):s,n},{});return Object.keys(t).map(function(n){return t[n]})}var R3="Popper: Invalid reference or popper argument provided. They must be either a DOM element or virtual element.",TE="Popper: An infinite loop in the modifiers cycle has been detected! The cycle has been interrupted to prevent a browser crash.",H3={placement:"bottom",modifiers:[],strategy:"absolute"};function W3(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(s){return!(s&&typeof s.getBoundingClientRect=="function")})}function IE(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,s=n===void 0?[]:n,i=t.defaultOptions,a=i===void 0?H3:i;return function(c,d,h){h===void 0&&(h=a);var f={placement:"bottom",orderedModifiers:[],options:Object.assign({},H3,{},a),modifiersData:{},elements:{reference:c,popper:d},attributes:{},styles:{}},m=[],v=!1,y={state:f,setOptions:function(D){x(),f.options=Object.assign({},a,{},f.options,{},D),f.scrollParents={reference:Gl(c)?Kl(c):c.contextElement?Kl(c.contextElement):[],popper:Kl(d)};var E=SE(EE([].concat(s,f.options.modifiers)));if(f.orderedModifiers=E.filter(function(X){return X.enabled}),process.env.NODE_ENV!=="production"){var B=DE([].concat(E,f.options.modifiers),function(X){var Z=X.name;return Z});if(ME(B),Xs(f.options.placement)===tu){var S=f.orderedModifiers.find(function(X){var Z=X.name;return Z==="flip"});S||console.error(['Popper: "auto" placements require the "flip" modifier be',"present and enabled to work."].join(" "))}var A=to(d),I=A.marginTop,F=A.marginRight,L=A.marginBottom,W=A.marginLeft;[I,F,L,W].some(function(X){return parseFloat(X)})&&console.warn(['Popper: CSS "margin" styles cannot be used to apply padding',"between the popper and its reference element or boundary.","To replicate margin, use the `offset` modifier, as well as","the `padding` option in the `preventOverflow` and `flip`","modifiers."].join(" "))}return w(),y.update()},forceUpdate:function(){if(!v){var D=f.elements,E=D.reference,B=D.popper;if(!W3(E,B)){process.env.NODE_ENV!=="production"&&console.error(R3);return}f.rects={reference:V3(E,Zl(B),f.options.strategy==="fixed"),popper:wf(B)},f.reset=!1,f.placement=f.options.placement,f.orderedModifiers.forEach(function(Z){return f.modifiersData[Z.name]=Object.assign({},Z.data)});for(var S=0,A=0;A<f.orderedModifiers.length;A++){if(process.env.NODE_ENV!=="production"&&(S+=1,S>100)){console.error(TE);break}if(f.reset===!0){f.reset=!1,A=-1;continue}var I=f.orderedModifiers[A],F=I.fn,L=I.options,W=L===void 0?{}:L,X=I.name;typeof F=="function"&&(f=F({state:f,options:W,name:X,instance:y})||f)}}},update:kE(function(){return new Promise(function(k){y.forceUpdate(),k(f)})}),destroy:function(){x(),v=!0}};if(!W3(c,d))return process.env.NODE_ENV!=="production"&&console.error(R3),y;y.setOptions(h).then(function(k){!v&&h.onFirstUpdate&&h.onFirstUpdate(k)});function w(){f.orderedModifiers.forEach(function(k){var D=k.name,E=k.options,B=E===void 0?{}:E,S=k.effect;if(typeof S=="function"){var A=S({state:f,name:D,instance:y,options:B}),I=function(){};m.push(A||I)}})}function x(){m.forEach(function(k){return k()}),m=[]}return y}}var eu={passive:!0};function AE(e){var t=e.state,n=e.instance,s=e.options,i=s.scroll,a=i===void 0?!0:i,o=s.resize,c=o===void 0?!0:o,d=vs(t.elements.popper),h=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&h.forEach(function(f){f.addEventListener("scroll",n.update,eu)}),c&&d.addEventListener("resize",n.update,eu),function(){a&&h.forEach(function(f){f.removeEventListener("scroll",n.update,eu)}),c&&d.removeEventListener("resize",n.update,eu)}}const VE={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:AE,data:{}};function Ql(e){return e.split("-")[1]}function kf(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function j3(e){var t=e.reference,n=e.element,s=e.placement,i=s?Xs(s):null,a=s?Ql(s):null,o=t.x+t.width/2-n.width/2,c=t.y+t.height/2-n.height/2,d;switch(i){case _s:d={x:o,y:t.y-n.height};break;case Ks:d={x:o,y:t.y+t.height};break;case Zs:d={x:t.x+t.width,y:c};break;case ys:d={x:t.x-n.width,y:c};break;default:d={x:t.x,y:t.y}}var h=i?kf(i):null;if(h!=null){var f=h==="y"?"height":"width";switch(a){case $o:d[h]=Math.floor(d[h])-Math.floor(t[f]/2-n[f]/2);break;case xf:d[h]=Math.floor(d[h])+Math.ceil(t[f]/2-n[f]/2);break}}return d}function BE(e){var t=e.state,n=e.name;t.modifiersData[n]=j3({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const PE={name:"popperOffsets",enabled:!0,phase:"read",fn:BE,data:{}};var NE={top:"auto",right:"auto",bottom:"auto",left:"auto"};function zE(e){var t=e.x,n=e.y,s=window,i=s.devicePixelRatio||1;return{x:Math.round(t*i)/i||0,y:Math.round(n*i)/i||0}}function Y3(e){var t,n=e.popper,s=e.popperRect,i=e.placement,a=e.offsets,o=e.position,c=e.gpuAcceleration,d=e.adaptive,h=zE(a),f=h.x,m=h.y,v=a.hasOwnProperty("x"),y=a.hasOwnProperty("y"),w=ys,x=_s,k=window;if(d){var D=Zl(n);D===vs(n)&&(D=ua(n)),i===_s&&(x=Ks,m-=D.clientHeight-s.height,m*=c?1:-1),i===ys&&(w=Zs,f-=D.clientWidth-s.width,f*=c?1:-1)}var E=Object.assign({position:o},d&&NE);if(c){var B;return Object.assign({},E,(B={},B[x]=y?"0":"",B[w]=v?"0":"",B.transform=(k.devicePixelRatio||1)<2?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",B))}return Object.assign({},E,(t={},t[x]=y?m+"px":"",t[w]=v?f+"px":"",t.transform="",t))}function LE(e){var t=e.state,n=e.options,s=n.gpuAcceleration,i=s===void 0?!0:s,a=n.adaptive,o=a===void 0?!0:a;if(process.env.NODE_ENV!=="production"){var c=to(t.elements.popper).transitionProperty||"";o&&["transform","top","right","bottom","left"].some(function(h){return c.indexOf(h)>=0})&&console.warn(["Popper: Detected CSS transitions on at least one of the following",'CSS properties: "transform", "top", "right", "bottom", "left".',`
|
|
42
|
+
`):e}function Ek(e,t){const{element:n,datasetIndex:s,index:i}=t,a=e.getDatasetMeta(s).controller,{label:o,value:c}=a.getLabelAndValue(i);return{chart:e,label:o,parsed:a.getParsed(i),raw:e.data.datasets[s].data[i],formattedValue:c,dataset:a.getDataset(),dataIndex:i,datasetIndex:s,element:n}}function E2(e,t){const n=e.chart.ctx,{body:s,footer:i,title:a}=e,{boxWidth:o,boxHeight:c}=t,d=$e(t.bodyFont),h=$e(t.titleFont),f=$e(t.footerFont),m=a.length,v=i.length,y=s.length,w=pn(t.padding);let x=w.height,k=0,D=s.reduce((S,A)=>S+A.before.length+A.lines.length+A.after.length,0);if(D+=e.beforeBody.length+e.afterBody.length,m&&(x+=m*h.lineHeight+(m-1)*t.titleSpacing+t.titleMarginBottom),D){const S=t.displayColors?Math.max(c,d.lineHeight):d.lineHeight;x+=y*S+(D-y)*d.lineHeight+(D-1)*t.bodySpacing}v&&(x+=t.footerMarginTop+v*f.lineHeight+(v-1)*t.footerSpacing);let E=0;const B=function(S){k=Math.max(k,n.measureText(S).width+E)};return n.save(),n.font=h.string,ue(e.title,B),n.font=d.string,ue(e.beforeBody.concat(e.afterBody),B),E=t.displayColors?o+2+t.boxPadding:0,ue(s,S=>{ue(S.before,B),ue(S.lines,B),ue(S.after,B)}),E=0,n.font=f.string,ue(e.footer,B),n.restore(),k+=w.width,{width:k,height:x}}function Tk(e,t){const{y:n,height:s}=t;return n<s/2?"top":n>e.height-s/2?"bottom":"center"}function Ik(e,t,n,s){const{x:i,width:a}=s,o=n.caretSize+n.caretPadding;if(e==="left"&&i+a+o>t.width||e==="right"&&i-a-o<0)return!0}function Ak(e,t,n,s){const{x:i,width:a}=n,{width:o,chartArea:{left:c,right:d}}=e;let h="center";return s==="center"?h=i<=(c+d)/2?"left":"right":i<=a/2?h="left":i>=o-a/2&&(h="right"),Ik(h,e,t,n)&&(h="center"),h}function T2(e,t,n){const s=n.yAlign||t.yAlign||Tk(e,n);return{xAlign:n.xAlign||t.xAlign||Ak(e,t,n,s),yAlign:s}}function Vk(e,t){let{x:n,width:s}=e;return t==="right"?n-=s:t==="center"&&(n-=s/2),n}function Bk(e,t,n){let{y:s,height:i}=e;return t==="top"?s+=n:t==="bottom"?s-=i+n:s-=i/2,s}function I2(e,t,n,s){const{caretSize:i,caretPadding:a,cornerRadius:o}=e,{xAlign:c,yAlign:d}=n,h=i+a,{topLeft:f,topRight:m,bottomLeft:v,bottomRight:y}=Wa(o);let w=Vk(t,c);const x=Bk(t,d,h);return d==="center"?c==="left"?w+=h:c==="right"&&(w-=h):c==="left"?w-=Math.max(f,v)+i:c==="right"&&(w+=Math.max(m,y)+i),{x:an(w,0,s.width-t.width),y:an(x,0,s.height-t.height)}}function Vd(e,t,n){const s=pn(n.padding);return t==="center"?e.x+e.width/2:t==="right"?e.x+e.width-s.right:e.x+s.left}function A2(e){return li([],Oi(e))}function Pk(e,t,n){return sa(e,{tooltip:t,tooltipItems:n,type:"tooltip"})}function V2(e,t){const n=t&&t.dataset&&t.dataset.tooltip&&t.dataset.tooltip.callbacks;return n?e.override(n):e}const B2={beforeTitle:wi,title(e){if(e.length>0){const t=e[0],n=t.chart.data.labels,s=n?n.length:0;if(this&&this.options&&this.options.mode==="dataset")return t.dataset.label||"";if(t.label)return t.label;if(s>0&&t.dataIndex<s)return n[t.dataIndex]}return""},afterTitle:wi,beforeBody:wi,beforeLabel:wi,label(e){if(this&&this.options&&this.options.mode==="dataset")return e.label+": "+e.formattedValue||e.formattedValue;let t=e.dataset.label||"";t&&(t+=": ");const n=e.formattedValue;return ee(n)||(t+=n),t},labelColor(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{borderColor:n.borderColor,backgroundColor:n.backgroundColor,borderWidth:n.borderWidth,borderDash:n.borderDash,borderDashOffset:n.borderDashOffset,borderRadius:0}},labelTextColor(){return this.options.bodyColor},labelPointStyle(e){const n=e.chart.getDatasetMeta(e.datasetIndex).controller.getStyle(e.dataIndex);return{pointStyle:n.pointStyle,rotation:n.rotation}},afterLabel:wi,afterBody:wi,beforeFooter:wi,footer:wi,afterFooter:wi};function Bn(e,t,n,s){const i=e[t].call(n,s);return typeof i>"u"?B2[t].call(n,s):i}class Bh extends Hs{constructor(t){super(),this.opacity=0,this._active=[],this._eventPosition=void 0,this._size=void 0,this._cachedAnimations=void 0,this._tooltipItems=[],this.$animations=void 0,this.$context=void 0,this.chart=t.chart,this.options=t.options,this.dataPoints=void 0,this.title=void 0,this.beforeBody=void 0,this.body=void 0,this.afterBody=void 0,this.footer=void 0,this.xAlign=void 0,this.yAlign=void 0,this.x=void 0,this.y=void 0,this.height=void 0,this.width=void 0,this.caretX=void 0,this.caretY=void 0,this.labelColors=void 0,this.labelPointStyles=void 0,this.labelTextColors=void 0}initialize(t){this.options=t,this._cachedAnimations=void 0,this.$context=void 0}_resolveAnimations(){const t=this._cachedAnimations;if(t)return t;const n=this.chart,s=this.options.setContext(this.getContext()),i=s.enabled&&n.options.animation&&s.animations,a=new Sg(this.chart,i);return i._cacheable&&(this._cachedAnimations=Object.freeze(a)),a}getContext(){return this.$context||(this.$context=Pk(this.chart.getContext(),this,this._tooltipItems))}getTitle(t,n){const{callbacks:s}=n,i=Bn(s,"beforeTitle",this,t),a=Bn(s,"title",this,t),o=Bn(s,"afterTitle",this,t);let c=[];return c=li(c,Oi(i)),c=li(c,Oi(a)),c=li(c,Oi(o)),c}getBeforeBody(t,n){return A2(Bn(n.callbacks,"beforeBody",this,t))}getBody(t,n){const{callbacks:s}=n,i=[];return ue(t,a=>{const o={before:[],lines:[],after:[]},c=V2(s,a);li(o.before,Oi(Bn(c,"beforeLabel",this,a))),li(o.lines,Bn(c,"label",this,a)),li(o.after,Oi(Bn(c,"afterLabel",this,a))),i.push(o)}),i}getAfterBody(t,n){return A2(Bn(n.callbacks,"afterBody",this,t))}getFooter(t,n){const{callbacks:s}=n,i=Bn(s,"beforeFooter",this,t),a=Bn(s,"footer",this,t),o=Bn(s,"afterFooter",this,t);let c=[];return c=li(c,Oi(i)),c=li(c,Oi(a)),c=li(c,Oi(o)),c}_createItems(t){const n=this._active,s=this.chart.data,i=[],a=[],o=[];let c=[],d,h;for(d=0,h=n.length;d<h;++d)c.push(Ek(this.chart,n[d]));return t.filter&&(c=c.filter((f,m,v)=>t.filter(f,m,v,s))),t.itemSort&&(c=c.sort((f,m)=>t.itemSort(f,m,s))),ue(c,f=>{const m=V2(t.callbacks,f);i.push(Bn(m,"labelColor",this,f)),a.push(Bn(m,"labelPointStyle",this,f)),o.push(Bn(m,"labelTextColor",this,f))}),this.labelColors=i,this.labelPointStyles=a,this.labelTextColors=o,this.dataPoints=c,c}update(t,n){const s=this.options.setContext(this.getContext()),i=this._active;let a,o=[];if(!i.length)this.opacity!==0&&(a={opacity:0});else{const c=El[s.position].call(this,i,this._eventPosition);o=this._createItems(s),this.title=this.getTitle(o,s),this.beforeBody=this.getBeforeBody(o,s),this.body=this.getBody(o,s),this.afterBody=this.getAfterBody(o,s),this.footer=this.getFooter(o,s);const d=this._size=E2(this,s),h=Object.assign({},c,d),f=T2(this.chart,s,h),m=I2(s,h,f,this.chart);this.xAlign=f.xAlign,this.yAlign=f.yAlign,a={opacity:1,x:m.x,y:m.y,width:d.width,height:d.height,caretX:c.x,caretY:c.y}}this._tooltipItems=o,this.$context=void 0,a&&this._resolveAnimations().update(this,a),t&&s.external&&s.external.call(this,{chart:this.chart,tooltip:this,replay:n})}drawCaret(t,n,s,i){const a=this.getCaretPosition(t,s,i);n.lineTo(a.x1,a.y1),n.lineTo(a.x2,a.y2),n.lineTo(a.x3,a.y3)}getCaretPosition(t,n,s){const{xAlign:i,yAlign:a}=this,{caretSize:o,cornerRadius:c}=s,{topLeft:d,topRight:h,bottomLeft:f,bottomRight:m}=Wa(c),{x:v,y}=t,{width:w,height:x}=n;let k,D,E,B,S,A;return a==="center"?(S=y+x/2,i==="left"?(k=v,D=k-o,B=S+o,A=S-o):(k=v+w,D=k+o,B=S-o,A=S+o),E=k):(i==="left"?D=v+Math.max(d,f)+o:i==="right"?D=v+w-Math.max(h,m)-o:D=this.caretX,a==="top"?(B=y,S=B-o,k=D-o,E=D+o):(B=y+x,S=B+o,k=D+o,E=D-o),A=B),{x1:k,x2:D,x3:E,y1:B,y2:S,y3:A}}drawTitle(t,n,s){const i=this.title,a=i.length;let o,c,d;if(a){const h=Ro(s.rtl,this.x,this.width);for(t.x=Vd(this,s.titleAlign,s),n.textAlign=h.textAlign(s.titleAlign),n.textBaseline="middle",o=$e(s.titleFont),c=s.titleSpacing,n.fillStyle=s.titleColor,n.font=o.string,d=0;d<a;++d)n.fillText(i[d],h.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+c,d+1===a&&(t.y+=s.titleMarginBottom-c)}}_drawColorBox(t,n,s,i,a){const o=this.labelColors[s],c=this.labelPointStyles[s],{boxHeight:d,boxWidth:h}=a,f=$e(a.bodyFont),m=Vd(this,"left",a),v=i.x(m),y=d<f.lineHeight?(f.lineHeight-d)/2:0,w=n.y+y;if(a.usePointStyle){const x={radius:Math.min(h,d)/2,pointStyle:c.pointStyle,rotation:c.rotation,borderWidth:1},k=i.leftForLtr(v,h)+h/2,D=w+d/2;t.strokeStyle=a.multiKeyBackground,t.fillStyle=a.multiKeyBackground,uh(t,x,k,D),t.strokeStyle=o.borderColor,t.fillStyle=o.backgroundColor,uh(t,x,k,D)}else{t.lineWidth=Kt(o.borderWidth)?Math.max(...Object.values(o.borderWidth)):o.borderWidth||1,t.strokeStyle=o.borderColor,t.setLineDash(o.borderDash||[]),t.lineDashOffset=o.borderDashOffset||0;const x=i.leftForLtr(v,h),k=i.leftForLtr(i.xPlus(v,1),h-2),D=Wa(o.borderRadius);Object.values(D).some(E=>E!==0)?(t.beginPath(),t.fillStyle=a.multiKeyBackground,gl(t,{x,y:w,w:h,h:d,radius:D}),t.fill(),t.stroke(),t.fillStyle=o.backgroundColor,t.beginPath(),gl(t,{x:k,y:w+1,w:h-2,h:d-2,radius:D}),t.fill()):(t.fillStyle=a.multiKeyBackground,t.fillRect(x,w,h,d),t.strokeRect(x,w,h,d),t.fillStyle=o.backgroundColor,t.fillRect(k,w+1,h-2,d-2))}t.fillStyle=this.labelTextColors[s]}drawBody(t,n,s){const{body:i}=this,{bodySpacing:a,bodyAlign:o,displayColors:c,boxHeight:d,boxWidth:h,boxPadding:f}=s,m=$e(s.bodyFont);let v=m.lineHeight,y=0;const w=Ro(s.rtl,this.x,this.width),x=function(L){n.fillText(L,w.x(t.x+y),t.y+v/2),t.y+=v+a},k=w.textAlign(o);let D,E,B,S,A,I,F;for(n.textAlign=o,n.textBaseline="middle",n.font=m.string,t.x=Vd(this,k,s),n.fillStyle=s.bodyColor,ue(this.beforeBody,x),y=c&&k!=="right"?o==="center"?h/2+f:h+2+f:0,S=0,I=i.length;S<I;++S){for(D=i[S],E=this.labelTextColors[S],n.fillStyle=E,ue(D.before,x),B=D.lines,c&&B.length&&(this._drawColorBox(n,t,S,w,s),v=Math.max(m.lineHeight,d)),A=0,F=B.length;A<F;++A)x(B[A]),v=m.lineHeight;ue(D.after,x)}y=0,v=m.lineHeight,ue(this.afterBody,x),t.y-=a}drawFooter(t,n,s){const i=this.footer,a=i.length;let o,c;if(a){const d=Ro(s.rtl,this.x,this.width);for(t.x=Vd(this,s.footerAlign,s),t.y+=s.footerMarginTop,n.textAlign=d.textAlign(s.footerAlign),n.textBaseline="middle",o=$e(s.footerFont),n.fillStyle=s.footerColor,n.font=o.string,c=0;c<a;++c)n.fillText(i[c],d.x(t.x),t.y+o.lineHeight/2),t.y+=o.lineHeight+s.footerSpacing}}drawBackground(t,n,s,i){const{xAlign:a,yAlign:o}=this,{x:c,y:d}=t,{width:h,height:f}=s,{topLeft:m,topRight:v,bottomLeft:y,bottomRight:w}=Wa(i.cornerRadius);n.fillStyle=i.backgroundColor,n.strokeStyle=i.borderColor,n.lineWidth=i.borderWidth,n.beginPath(),n.moveTo(c+m,d),o==="top"&&this.drawCaret(t,n,s,i),n.lineTo(c+h-v,d),n.quadraticCurveTo(c+h,d,c+h,d+v),o==="center"&&a==="right"&&this.drawCaret(t,n,s,i),n.lineTo(c+h,d+f-w),n.quadraticCurveTo(c+h,d+f,c+h-w,d+f),o==="bottom"&&this.drawCaret(t,n,s,i),n.lineTo(c+y,d+f),n.quadraticCurveTo(c,d+f,c,d+f-y),o==="center"&&a==="left"&&this.drawCaret(t,n,s,i),n.lineTo(c,d+m),n.quadraticCurveTo(c,d,c+m,d),n.closePath(),n.fill(),i.borderWidth>0&&n.stroke()}_updateAnimationTarget(t){const n=this.chart,s=this.$animations,i=s&&s.x,a=s&&s.y;if(i||a){const o=El[t.position].call(this,this._active,this._eventPosition);if(!o)return;const c=this._size=E2(this,t),d=Object.assign({},o,this._size),h=T2(n,t,d),f=I2(t,d,h,n);(i._to!==f.x||a._to!==f.y)&&(this.xAlign=h.xAlign,this.yAlign=h.yAlign,this.width=c.width,this.height=c.height,this.caretX=o.x,this.caretY=o.y,this._resolveAnimations().update(this,f))}}_willRender(){return!!this.opacity}draw(t){const n=this.options.setContext(this.getContext());let s=this.opacity;if(!s)return;this._updateAnimationTarget(n);const i={width:this.width,height:this.height},a={x:this.x,y:this.y};s=Math.abs(s)<.001?0:s;const o=pn(n.padding),c=this.title.length||this.beforeBody.length||this.body.length||this.afterBody.length||this.footer.length;n.enabled&&c&&(t.save(),t.globalAlpha=s,this.drawBackground(a,t,i,n),pg(t,n.textDirection),a.y+=o.top,this.drawTitle(a,t,n),this.drawBody(a,t,n),this.drawFooter(a,t,n),mg(t,n.textDirection),t.restore())}getActiveElements(){return this._active||[]}setActiveElements(t,n){const s=this._active,i=t.map(({datasetIndex:c,index:d})=>{const h=this.chart.getDatasetMeta(c);if(!h)throw new Error("Cannot find a dataset at index "+c);return{datasetIndex:c,element:h.data[d],index:d}}),a=!od(s,i),o=this._positionChanged(i,n);(a||o)&&(this._active=i,this._eventPosition=n,this._ignoreReplayEvents=!0,this.update(!0))}handleEvent(t,n,s=!0){if(n&&this._ignoreReplayEvents)return!1;this._ignoreReplayEvents=!1;const i=this.options,a=this._active||[],o=this._getActiveElements(t,a,n,s),c=this._positionChanged(o,t),d=n||!od(o,a)||c;return d&&(this._active=o,(i.enabled||i.external)&&(this._eventPosition={x:t.x,y:t.y},this.update(!0,n))),d}_getActiveElements(t,n,s,i){const a=this.options;if(t.type==="mouseout")return[];if(!i)return n;const o=this.chart.getElementsAtEventForMode(t,a.mode,a,s);return a.reverse&&o.reverse(),o}_positionChanged(t,n){const{caretX:s,caretY:i,options:a}=this,o=El[a.position].call(this,t,n);return o!==!1&&(s!==o.x||i!==o.y)}}nt(Bh,"positioners",El);var Nk={id:"tooltip",_element:Bh,positioners:El,afterInit(e,t,n){n&&(e.tooltip=new Bh({chart:e,options:n}))},beforeUpdate(e,t,n){e.tooltip&&e.tooltip.initialize(n)},reset(e,t,n){e.tooltip&&e.tooltip.initialize(n)},afterDraw(e){const t=e.tooltip;if(t&&t._willRender()){const n={tooltip:t};if(e.notifyPlugins("beforeTooltipDraw",{...n,cancelable:!0})===!1)return;t.draw(e.ctx),e.notifyPlugins("afterTooltipDraw",n)}},afterEvent(e,t){if(e.tooltip){const n=t.replay;e.tooltip.handleEvent(t.event,n,t.inChartArea)&&(t.changed=!0)}},defaults:{enabled:!0,external:null,position:"average",backgroundColor:"rgba(0,0,0,0.8)",titleColor:"#fff",titleFont:{weight:"bold"},titleSpacing:2,titleMarginBottom:6,titleAlign:"left",bodyColor:"#fff",bodySpacing:2,bodyFont:{},bodyAlign:"left",footerColor:"#fff",footerSpacing:2,footerMarginTop:6,footerFont:{weight:"bold"},footerAlign:"left",padding:6,caretPadding:2,caretSize:5,cornerRadius:6,boxHeight:(e,t)=>t.bodyFont.size,boxWidth:(e,t)=>t.bodyFont.size,multiKeyBackground:"#fff",displayColors:!0,boxPadding:0,borderColor:"rgba(0,0,0,0)",borderWidth:0,animation:{duration:400,easing:"easeOutQuart"},animations:{numbers:{type:"number",properties:["x","y","width","height","caretX","caretY"]},opacity:{easing:"linear",duration:200}},callbacks:B2},defaultRoutes:{bodyFont:"font",footerFont:"font",titleFont:"font"},descriptors:{_scriptable:e=>e!=="filter"&&e!=="itemSort"&&e!=="external",_indexable:!1,callbacks:{_scriptable:!1,_indexable:!1},animation:{_fallback:!1},animations:{_fallback:"animation"}},additionalOptionScopes:["interaction"]},zk=Object.freeze({__proto__:null,Colors:XS,Decimation:$S,Filler:yk,Legend:Ck,SubTitle:Dk,Title:Mk,Tooltip:Nk});const Lk=(e,t,n,s)=>(typeof t=="string"?(n=e.push(t)-1,s.unshift({index:n,label:t})):isNaN(t)&&(n=null),n);function Fk(e,t,n,s){const i=e.indexOf(t);if(i===-1)return Lk(e,t,n,s);const a=e.lastIndexOf(t);return i!==a?n:i}const Rk=(e,t)=>e===null?null:an(Math.round(e),0,t);function P2(e){const t=this.getLabels();return e>=0&&e<t.length?t[e]:e}class Ph extends Za{constructor(t){super(t),this._startValue=void 0,this._valueRange=0,this._addedLabels=[]}init(t){const n=this._addedLabels;if(n.length){const s=this.getLabels();for(const{index:i,label:a}of n)s[i]===a&&s.splice(i,1);this._addedLabels=[]}super.init(t)}parse(t,n){if(ee(t))return null;const s=this.getLabels();return n=isFinite(n)&&s[n]===t?n:Fk(s,t,Vt(n,t),this._addedLabels),Rk(n,s.length-1)}determineDataLimits(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let{min:s,max:i}=this.getMinMax(!0);this.options.bounds==="ticks"&&(t||(s=0),n||(i=this.getLabels().length-1)),this.min=s,this.max=i}buildTicks(){const t=this.min,n=this.max,s=this.options.offset,i=[];let a=this.getLabels();a=t===0&&n===a.length-1?a:a.slice(t,n+1),this._valueRange=Math.max(a.length-(s?0:1),1),this._startValue=this.min-(s?.5:0);for(let o=t;o<=n;o++)i.push({value:o});return i}getLabelForValue(t){return P2.call(this,t)}configure(){super.configure(),this.isHorizontal()||(this._reversePixels=!this._reversePixels)}getPixelForValue(t){return typeof t!="number"&&(t=this.parse(t)),t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getPixelForTick(t){const n=this.ticks;return t<0||t>n.length-1?null:this.getPixelForValue(n[t].value)}getValueForPixel(t){return Math.round(this._startValue+this.getDecimalForPixel(t)*this._valueRange)}getBasePixel(){return this.bottom}}nt(Ph,"id","category"),nt(Ph,"defaults",{ticks:{callback:P2}});function Hk(e,t){const n=[],{bounds:i,step:a,min:o,max:c,precision:d,count:h,maxTicks:f,maxDigits:m,includeBounds:v}=e,y=a||1,w=f-1,{min:x,max:k}=t,D=!ee(o),E=!ee(c),B=!ee(h),S=(k-x)/(m+1);let A=Lm((k-x)/w/y)*y,I,F,L,W;if(A<1e-14&&!D&&!E)return[{value:x},{value:k}];W=Math.ceil(k/A)-Math.floor(x/A),W>w&&(A=Lm(W*A/w/y)*y),ee(d)||(I=Math.pow(10,d),A=Math.ceil(A*I)/I),i==="ticks"?(F=Math.floor(x/A)*A,L=Math.ceil(k/A)*A):(F=x,L=k),D&&E&&a&&Pw((c-o)/a,A/1e3)?(W=Math.round(Math.min((c-o)/A,f)),A=(c-o)/W,F=o,L=c):B?(F=D?o:F,L=E?c:L,W=h-1,A=(L-F)/W):(W=(L-F)/A,ul(W,Math.round(W),A/1e3)?W=Math.round(W):W=Math.ceil(W));const X=Math.max(Rm(A),Rm(F));I=Math.pow(10,ee(d)?X:d),F=Math.round(F*I)/I,L=Math.round(L*I)/I;let Z=0;for(D&&(v&&F!==o?(n.push({value:o}),F<o&&Z++,ul(Math.round((F+Z*A)*I)/I,o,N2(o,S,e))&&Z++):F<o&&Z++);Z<W;++Z){const Q=Math.round((F+Z*A)*I)/I;if(E&&Q>c)break;n.push({value:Q})}return E&&v&&L!==c?n.length&&ul(n[n.length-1].value,c,N2(c,S,e))?n[n.length-1].value=c:n.push({value:c}):(!E||L===c)&&n.push({value:L}),n}function N2(e,t,{horizontal:n,minRotation:s}){const i=Fs(s),a=(n?Math.sin(i):Math.cos(i))||.001,o=.75*t*(""+e).length;return Math.min(t/a,o)}class Bd extends Za{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._endValue=void 0,this._valueRange=0}parse(t,n){return ee(t)||(typeof t=="number"||t instanceof Number)&&!isFinite(+t)?null:+t}handleTickRangeOptions(){const{beginAtZero:t}=this.options,{minDefined:n,maxDefined:s}=this.getUserBounds();let{min:i,max:a}=this;const o=d=>i=n?i:d,c=d=>a=s?a:d;if(t){const d=oi(i),h=oi(a);d<0&&h<0?c(0):d>0&&h>0&&o(0)}if(i===a){let d=a===0?1:Math.abs(a*.05);c(a+d),t||o(i-d)}this.min=i,this.max=a}getTickLimit(){const t=this.options.ticks;let{maxTicksLimit:n,stepSize:s}=t,i;return s?(i=Math.ceil(this.max/s)-Math.floor(this.min/s)+1,i>1e3&&(console.warn(`scales.${this.id}.ticks.stepSize: ${s} would result generating up to ${i} ticks. Limiting to 1000.`),i=1e3)):(i=this.computeTickLimit(),n=n||11),n&&(i=Math.min(n,i)),i}computeTickLimit(){return Number.POSITIVE_INFINITY}buildTicks(){const t=this.options,n=t.ticks;let s=this.getTickLimit();s=Math.max(2,s);const i={maxTicks:s,bounds:t.bounds,min:t.min,max:t.max,precision:n.precision,step:n.stepSize,count:n.count,maxDigits:this._maxDigits(),horizontal:this.isHorizontal(),minRotation:n.minRotation||0,includeBounds:n.includeBounds!==!1},a=this._range||this,o=Hk(i,a);return t.bounds==="ticks"&&Fm(o,this,"value"),t.reverse?(o.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),o}configure(){const t=this.ticks;let n=this.min,s=this.max;if(super.configure(),this.options.offset&&t.length){const i=(s-n)/Math.max(t.length-1,1)/2;n-=i,s+=i}this._startValue=n,this._endValue=s,this._valueRange=s-n}getLabelForValue(t){return pl(t,this.chart.options.locale,this.options.ticks.format)}}class Nh extends Bd{determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Pe(t)?t:0,this.max=Pe(n)?n:1,this.handleTickRangeOptions()}computeTickLimit(){const t=this.isHorizontal(),n=t?this.width:this.height,s=Fs(this.options.ticks.minRotation),i=(t?Math.sin(s):Math.cos(s))||.001,a=this._resolveTickFontOptions(0);return Math.ceil(n/Math.min(40,a.lineHeight/i))}getPixelForValue(t){return t===null?NaN:this.getPixelForDecimal((t-this._startValue)/this._valueRange)}getValueForPixel(t){return this._startValue+this.getDecimalForPixel(t)*this._valueRange}}nt(Nh,"id","linear"),nt(Nh,"defaults",{ticks:{callback:dd.formatters.numeric}});const Tl=e=>Math.floor(na(e)),Xa=(e,t)=>Math.pow(10,Tl(e)+t);function z2(e){return e/Math.pow(10,Tl(e))===1}function L2(e,t,n){const s=Math.pow(10,n),i=Math.floor(e/s);return Math.ceil(t/s)-i}function Wk(e,t){const n=t-e;let s=Tl(n);for(;L2(e,t,s)>10;)s++;for(;L2(e,t,s)<10;)s--;return Math.min(s,Tl(e))}function jk(e,{min:t,max:n}){t=Gn(e.min,t);const s=[],i=Tl(t);let a=Wk(t,n),o=a<0?Math.pow(10,Math.abs(a)):1;const c=Math.pow(10,a),d=i>a?Math.pow(10,i):0,h=Math.round((t-d)*o)/o,f=Math.floor((t-d)/c/10)*c*10;let m=Math.floor((h-f)/Math.pow(10,a)),v=Gn(e.min,Math.round((d+f+m*Math.pow(10,a))*o)/o);for(;v<n;)s.push({value:v,major:z2(v),significand:m}),m>=10?m=m<15?15:20:m++,m>=20&&(a++,m=2,o=a>=0?1:o),v=Math.round((d+f+m*Math.pow(10,a))*o)/o;const y=Gn(e.max,v);return s.push({value:y,major:z2(y),significand:m}),s}class zh extends Za{constructor(t){super(t),this.start=void 0,this.end=void 0,this._startValue=void 0,this._valueRange=0}parse(t,n){const s=Bd.prototype.parse.apply(this,[t,n]);if(s===0){this._zero=!0;return}return Pe(s)&&s>0?s:null}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!0);this.min=Pe(t)?Math.max(0,t):null,this.max=Pe(n)?Math.max(0,n):null,this.options.beginAtZero&&(this._zero=!0),this._zero&&this.min!==this._suggestedMin&&!Pe(this._userMin)&&(this.min=t===Xa(this.min,0)?Xa(this.min,-1):Xa(this.min,0)),this.handleTickRangeOptions()}handleTickRangeOptions(){const{minDefined:t,maxDefined:n}=this.getUserBounds();let s=this.min,i=this.max;const a=c=>s=t?s:c,o=c=>i=n?i:c;s===i&&(s<=0?(a(1),o(10)):(a(Xa(s,-1)),o(Xa(i,1)))),s<=0&&a(Xa(i,-1)),i<=0&&o(Xa(s,1)),this.min=s,this.max=i}buildTicks(){const t=this.options,n={min:this._userMin,max:this._userMax},s=jk(n,this);return t.bounds==="ticks"&&Fm(s,this,"value"),t.reverse?(s.reverse(),this.start=this.max,this.end=this.min):(this.start=this.min,this.end=this.max),s}getLabelForValue(t){return t===void 0?"0":pl(t,this.chart.options.locale,this.options.ticks.format)}configure(){const t=this.min;super.configure(),this._startValue=na(t),this._valueRange=na(this.max)-na(t)}getPixelForValue(t){return(t===void 0||t===0)&&(t=this.min),t===null||isNaN(t)?NaN:this.getPixelForDecimal(t===this.min?0:(na(t)-this._startValue)/this._valueRange)}getValueForPixel(t){const n=this.getDecimalForPixel(t);return Math.pow(10,this._startValue+n*this._valueRange)}}nt(zh,"id","logarithmic"),nt(zh,"defaults",{ticks:{callback:dd.formatters.logarithmic,major:{enabled:!0}}});function Lh(e){const t=e.ticks;if(t.display&&e.display){const n=pn(t.backdropPadding);return Vt(t.font&&t.font.size,ze.font.size)+n.height}return 0}function Yk(e,t,n){return n=Se(n)?n:[n],{w:qw(e,t.string,n),h:n.length*t.lineHeight}}function F2(e,t,n,s,i){return e===s||e===i?{start:t-n/2,end:t+n/2}:e<s||e>i?{start:t-n,end:t}:{start:t,end:t+n}}function Uk(e){const t={l:e.left+e._padding.left,r:e.right-e._padding.right,t:e.top+e._padding.top,b:e.bottom-e._padding.bottom},n=Object.assign({},t),s=[],i=[],a=e._pointLabels.length,o=e.options.pointLabels,c=o.centerPointLabels?De/a:0;for(let d=0;d<a;d++){const h=o.setContext(e.getPointLabelContext(d));i[d]=h.padding;const f=e.getPointPosition(d,e.drawingArea+i[d],c),m=$e(h.font),v=Yk(e.ctx,m,e._pointLabels[d]);s[d]=v;const y=Kn(e.getIndexAngle(d)+c),w=Math.round(sh(y)),x=F2(w,f.x,v.w,0,180),k=F2(w,f.y,v.h,90,270);Gk(n,t,y,x,k)}e.setCenterPoint(t.l-n.l,n.r-t.r,t.t-n.t,n.b-t.b),e._pointLabelItems=Xk(e,s,i)}function Gk(e,t,n,s,i){const a=Math.abs(Math.sin(n)),o=Math.abs(Math.cos(n));let c=0,d=0;s.start<t.l?(c=(t.l-s.start)/a,e.l=Math.min(e.l,t.l-c)):s.end>t.r&&(c=(s.end-t.r)/a,e.r=Math.max(e.r,t.r+c)),i.start<t.t?(d=(t.t-i.start)/o,e.t=Math.min(e.t,t.t-d)):i.end>t.b&&(d=(i.end-t.b)/o,e.b=Math.max(e.b,t.b+d))}function Kk(e,t,n){const s=e.drawingArea,{extra:i,additionalAngle:a,padding:o,size:c}=n,d=e.getPointPosition(t,s+i+o,a),h=Math.round(sh(Kn(d.angle+Ne))),f=qk(d.y,c.h,h),m=Jk(h),v=Qk(d.x,c.w,m);return{visible:!0,x:d.x,y:f,textAlign:m,left:v,top:f,right:v+c.w,bottom:f+c.h}}function Zk(e,t){if(!t)return!0;const{left:n,top:s,right:i,bottom:a}=e;return!(ki({x:n,y:s},t)||ki({x:n,y:a},t)||ki({x:i,y:s},t)||ki({x:i,y:a},t))}function Xk(e,t,n){const s=[],i=e._pointLabels.length,a=e.options,{centerPointLabels:o,display:c}=a.pointLabels,d={extra:Lh(a)/2,additionalAngle:o?De/i:0};let h;for(let f=0;f<i;f++){d.padding=n[f],d.size=t[f];const m=Kk(e,f,d);s.push(m),c==="auto"&&(m.visible=Zk(m,h),m.visible&&(h=m))}return s}function Jk(e){return e===0||e===180?"center":e<180?"left":"right"}function Qk(e,t,n){return n==="right"?e-=t:n==="center"&&(e-=t/2),e}function qk(e,t,n){return n===90||n===270?e-=t/2:(n>270||n<90)&&(e-=t),e}function $k(e,t,n){const{left:s,top:i,right:a,bottom:o}=n,{backdropColor:c}=t;if(!ee(c)){const d=Wa(t.borderRadius),h=pn(t.backdropPadding);e.fillStyle=c;const f=s-h.left,m=i-h.top,v=a-s+h.width,y=o-i+h.height;Object.values(d).some(w=>w!==0)?(e.beginPath(),gl(e,{x:f,y:m,w:v,h:y,radius:d}),e.fill()):e.fillRect(f,m,v,y)}}function tC(e,t){const{ctx:n,options:{pointLabels:s}}=e;for(let i=t-1;i>=0;i--){const a=e._pointLabelItems[i];if(!a.visible)continue;const o=s.setContext(e.getPointLabelContext(i));$k(n,o,a);const c=$e(o.font),{x:d,y:h,textAlign:f}=a;Ha(n,e._pointLabels[i],d,h+c.lineHeight/2,c,{color:o.color,textAlign:f,textBaseline:"middle"})}}function R2(e,t,n,s){const{ctx:i}=e;if(n)i.arc(e.xCenter,e.yCenter,t,0,ke);else{let a=e.getPointPosition(0,t);i.moveTo(a.x,a.y);for(let o=1;o<s;o++)a=e.getPointPosition(o,t),i.lineTo(a.x,a.y)}}function eC(e,t,n,s,i){const a=e.ctx,o=t.circular,{color:c,lineWidth:d}=t;!o&&!s||!c||!d||n<0||(a.save(),a.strokeStyle=c,a.lineWidth=d,a.setLineDash(i.dash),a.lineDashOffset=i.dashOffset,a.beginPath(),R2(e,n,o,s),a.closePath(),a.stroke(),a.restore())}function nC(e,t,n){return sa(e,{label:n,index:t,type:"pointLabel"})}class Il extends Bd{constructor(t){super(t),this.xCenter=void 0,this.yCenter=void 0,this.drawingArea=void 0,this._pointLabels=[],this._pointLabelItems=[]}setDimensions(){const t=this._padding=pn(Lh(this.options)/2),n=this.width=this.maxWidth-t.width,s=this.height=this.maxHeight-t.height;this.xCenter=Math.floor(this.left+n/2+t.left),this.yCenter=Math.floor(this.top+s/2+t.top),this.drawingArea=Math.floor(Math.min(n,s)/2)}determineDataLimits(){const{min:t,max:n}=this.getMinMax(!1);this.min=Pe(t)&&!isNaN(t)?t:0,this.max=Pe(n)&&!isNaN(n)?n:0,this.handleTickRangeOptions()}computeTickLimit(){return Math.ceil(this.drawingArea/Lh(this.options))}generateTickLabels(t){Bd.prototype.generateTickLabels.call(this,t),this._pointLabels=this.getLabels().map((n,s)=>{const i=we(this.options.pointLabels.callback,[n,s],this);return i||i===0?i:""}).filter((n,s)=>this.chart.getDataVisibility(s))}fit(){const t=this.options;t.display&&t.pointLabels.display?Uk(this):this.setCenterPoint(0,0,0,0)}setCenterPoint(t,n,s,i){this.xCenter+=Math.floor((t-n)/2),this.yCenter+=Math.floor((s-i)/2),this.drawingArea-=Math.min(this.drawingArea/2,Math.max(t,n,s,i))}getIndexAngle(t){const n=ke/(this._pointLabels.length||1),s=this.options.startAngle||0;return Kn(t*n+Fs(s))}getDistanceFromCenterForValue(t){if(ee(t))return NaN;const n=this.drawingArea/(this.max-this.min);return this.options.reverse?(this.max-t)*n:(t-this.min)*n}getValueForDistanceFromCenter(t){if(ee(t))return NaN;const n=t/(this.drawingArea/(this.max-this.min));return this.options.reverse?this.max-n:this.min+n}getPointLabelContext(t){const n=this._pointLabels||[];if(t>=0&&t<n.length){const s=n[t];return nC(this.getContext(),t,s)}}getPointPosition(t,n,s=0){const i=this.getIndexAngle(t)-Ne+s;return{x:Math.cos(i)*n+this.xCenter,y:Math.sin(i)*n+this.yCenter,angle:i}}getPointPositionForValue(t,n){return this.getPointPosition(t,this.getDistanceFromCenterForValue(n))}getBasePosition(t){return this.getPointPositionForValue(t||0,this.getBaseValue())}getPointLabelPosition(t){const{left:n,top:s,right:i,bottom:a}=this._pointLabelItems[t];return{left:n,top:s,right:i,bottom:a}}drawBackground(){const{backgroundColor:t,grid:{circular:n}}=this.options;if(t){const s=this.ctx;s.save(),s.beginPath(),R2(this,this.getDistanceFromCenterForValue(this._endValue),n,this._pointLabels.length),s.closePath(),s.fillStyle=t,s.fill(),s.restore()}}drawGrid(){const t=this.ctx,n=this.options,{angleLines:s,grid:i,border:a}=n,o=this._pointLabels.length;let c,d,h;if(n.pointLabels.display&&tC(this,o),i.display&&this.ticks.forEach((f,m)=>{if(m!==0){d=this.getDistanceFromCenterForValue(f.value);const v=this.getContext(m),y=i.setContext(v),w=a.setContext(v);eC(this,y,d,o,w)}}),s.display){for(t.save(),c=o-1;c>=0;c--){const f=s.setContext(this.getPointLabelContext(c)),{color:m,lineWidth:v}=f;!v||!m||(t.lineWidth=v,t.strokeStyle=m,t.setLineDash(f.borderDash),t.lineDashOffset=f.borderDashOffset,d=this.getDistanceFromCenterForValue(n.ticks.reverse?this.min:this.max),h=this.getPointPosition(c,d),t.beginPath(),t.moveTo(this.xCenter,this.yCenter),t.lineTo(h.x,h.y),t.stroke())}t.restore()}}drawBorder(){}drawLabels(){const t=this.ctx,n=this.options,s=n.ticks;if(!s.display)return;const i=this.getIndexAngle(0);let a,o;t.save(),t.translate(this.xCenter,this.yCenter),t.rotate(i),t.textAlign="center",t.textBaseline="middle",this.ticks.forEach((c,d)=>{if(d===0&&!n.reverse)return;const h=s.setContext(this.getContext(d)),f=$e(h.font);if(a=this.getDistanceFromCenterForValue(this.ticks[d].value),h.showLabelBackdrop){t.font=f.string,o=t.measureText(c.label).width,t.fillStyle=h.backdropColor;const m=pn(h.backdropPadding);t.fillRect(-o/2-m.left,-a-f.size/2-m.top,o+m.width,f.size+m.height)}Ha(t,c.label,0,-a,f,{color:h.color})}),t.restore()}drawTitle(){}}nt(Il,"id","radialLinear"),nt(Il,"defaults",{display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,lineWidth:1,borderDash:[],borderDashOffset:0},grid:{circular:!1},startAngle:0,ticks:{showLabelBackdrop:!0,callback:dd.formatters.numeric},pointLabels:{backdropColor:void 0,backdropPadding:2,display:!0,font:{size:10},callback(t){return t},padding:5,centerPointLabels:!1}}),nt(Il,"defaultRoutes",{"angleLines.color":"borderColor","pointLabels.color":"color","ticks.color":"color"}),nt(Il,"descriptors",{angleLines:{_fallback:"grid"}});const Pd={millisecond:{common:!0,size:1,steps:1e3},second:{common:!0,size:1e3,steps:60},minute:{common:!0,size:6e4,steps:60},hour:{common:!0,size:36e5,steps:24},day:{common:!0,size:864e5,steps:30},week:{common:!1,size:6048e5,steps:4},month:{common:!0,size:2628e6,steps:12},quarter:{common:!1,size:7884e6,steps:4},year:{common:!0,size:3154e7}},Pn=Object.keys(Pd);function sC(e,t){return e-t}function H2(e,t){if(ee(t))return null;const n=e._adapter,{parser:s,round:i,isoWeekday:a}=e._parseOpts;let o=t;return typeof s=="function"&&(o=s(o)),Pe(o)||(o=typeof s=="string"?n.parse(o,s):n.parse(o)),o===null?null:(i&&(o=i==="week"&&(zo(a)||a===!0)?n.startOf(o,"isoWeek",a):n.startOf(o,i)),+o)}function W2(e,t,n,s){const i=Pn.length;for(let a=Pn.indexOf(e);a<i-1;++a){const o=Pd[Pn[a]],c=o.steps?o.steps:Number.MAX_SAFE_INTEGER;if(o.common&&Math.ceil((n-t)/(c*o.size))<=s)return Pn[a]}return Pn[i-1]}function iC(e,t,n,s,i){for(let a=Pn.length-1;a>=Pn.indexOf(n);a--){const o=Pn[a];if(Pd[o].common&&e._adapter.diff(i,s,o)>=t-1)return o}return Pn[n?Pn.indexOf(n):0]}function aC(e){for(let t=Pn.indexOf(e)+1,n=Pn.length;t<n;++t)if(Pd[Pn[t]].common)return Pn[t]}function j2(e,t,n){if(!n)e[t]=!0;else if(n.length){const{lo:s,hi:i}=ah(n,t),a=n[s]>=t?n[s]:n[i];e[a]=!0}}function oC(e,t,n,s){const i=e._adapter,a=+i.startOf(t[0].value,s),o=t[t.length-1].value;let c,d;for(c=a;c<=o;c=+i.add(c,1,s))d=n[c],d>=0&&(t[d].major=!0);return t}function Y2(e,t,n){const s=[],i={},a=t.length;let o,c;for(o=0;o<a;++o)c=t[o],i[c]=o,s.push({value:c,major:!1});return a===0||!n?s:oC(e,s,i,n)}class Al extends Za{constructor(t){super(t),this._cache={data:[],labels:[],all:[]},this._unit="day",this._majorUnit=void 0,this._offsets={},this._normalized=!1,this._parseOpts=void 0}init(t,n={}){const s=t.time||(t.time={}),i=this._adapter=new px._date(t.adapters.date);i.init(n),cl(s.displayFormats,i.formats()),this._parseOpts={parser:s.parser,round:s.round,isoWeekday:s.isoWeekday},super.init(t),this._normalized=n.normalized}parse(t,n){return t===void 0?null:H2(this,t)}beforeLayout(){super.beforeLayout(),this._cache={data:[],labels:[],all:[]}}determineDataLimits(){const t=this.options,n=this._adapter,s=t.time.unit||"day";let{min:i,max:a,minDefined:o,maxDefined:c}=this.getUserBounds();function d(h){!o&&!isNaN(h.min)&&(i=Math.min(i,h.min)),!c&&!isNaN(h.max)&&(a=Math.max(a,h.max))}(!o||!c)&&(d(this._getLabelBounds()),(t.bounds!=="ticks"||t.ticks.source!=="labels")&&d(this.getMinMax(!1))),i=Pe(i)&&!isNaN(i)?i:+n.startOf(Date.now(),s),a=Pe(a)&&!isNaN(a)?a:+n.endOf(Date.now(),s)+1,this.min=Math.min(i,a-1),this.max=Math.max(i+1,a)}_getLabelBounds(){const t=this.getLabelTimestamps();let n=Number.POSITIVE_INFINITY,s=Number.NEGATIVE_INFINITY;return t.length&&(n=t[0],s=t[t.length-1]),{min:n,max:s}}buildTicks(){const t=this.options,n=t.time,s=t.ticks,i=s.source==="labels"?this.getLabelTimestamps():this._generate();t.bounds==="ticks"&&i.length&&(this.min=this._userMin||i[0],this.max=this._userMax||i[i.length-1]);const a=this.min,o=this.max,c=Fw(i,a,o);return this._unit=n.unit||(s.autoSkip?W2(n.minUnit,this.min,this.max,this._getLabelCapacity(a)):iC(this,c.length,n.minUnit,this.min,this.max)),this._majorUnit=!s.major.enabled||this._unit==="year"?void 0:aC(this._unit),this.initOffsets(i),t.reverse&&c.reverse(),Y2(this,c,this._majorUnit)}afterAutoSkip(){this.options.offsetAfterAutoskip&&this.initOffsets(this.ticks.map(t=>+t.value))}initOffsets(t=[]){let n=0,s=0,i,a;this.options.offset&&t.length&&(i=this.getDecimalForValue(t[0]),t.length===1?n=1-i:n=(this.getDecimalForValue(t[1])-i)/2,a=this.getDecimalForValue(t[t.length-1]),t.length===1?s=a:s=(a-this.getDecimalForValue(t[t.length-2]))/2);const o=t.length<3?.5:.25;n=an(n,0,o),s=an(s,0,o),this._offsets={start:n,end:s,factor:1/(n+1+s)}}_generate(){const t=this._adapter,n=this.min,s=this.max,i=this.options,a=i.time,o=a.unit||W2(a.minUnit,n,s,this._getLabelCapacity(n)),c=Vt(i.ticks.stepSize,1),d=o==="week"?a.isoWeekday:!1,h=zo(d)||d===!0,f={};let m=n,v,y;if(h&&(m=+t.startOf(m,"isoWeek",d)),m=+t.startOf(m,h?"day":o),t.diff(s,n,o)>1e5*c)throw new Error(n+" and "+s+" are too far apart with stepSize of "+c+" "+o);const w=i.ticks.source==="data"&&this.getDataTimestamps();for(v=m,y=0;v<s;v=+t.add(v,c,o),y++)j2(f,v,w);return(v===s||i.bounds==="ticks"||y===1)&&j2(f,v,w),Object.keys(f).sort((x,k)=>x-k).map(x=>+x)}getLabelForValue(t){const n=this._adapter,s=this.options.time;return s.tooltipFormat?n.format(t,s.tooltipFormat):n.format(t,s.displayFormats.datetime)}format(t,n){const i=this.options.time.displayFormats,a=this._unit,o=n||i[a];return this._adapter.format(t,o)}_tickFormatFunction(t,n,s,i){const a=this.options,o=a.ticks.callback;if(o)return we(o,[t,n,s],this);const c=a.time.displayFormats,d=this._unit,h=this._majorUnit,f=d&&c[d],m=h&&c[h],v=s[n],y=h&&m&&v&&v.major;return this._adapter.format(t,i||(y?m:f))}generateTickLabels(t){let n,s,i;for(n=0,s=t.length;n<s;++n)i=t[n],i.label=this._tickFormatFunction(i.value,n,t)}getDecimalForValue(t){return t===null?NaN:(t-this.min)/(this.max-this.min)}getPixelForValue(t){const n=this._offsets,s=this.getDecimalForValue(t);return this.getPixelForDecimal((n.start+s)*n.factor)}getValueForPixel(t){const n=this._offsets,s=this.getDecimalForPixel(t)/n.factor-n.end;return this.min+s*(this.max-this.min)}_getLabelSize(t){const n=this.options.ticks,s=this.ctx.measureText(t).width,i=Fs(this.isHorizontal()?n.maxRotation:n.minRotation),a=Math.cos(i),o=Math.sin(i),c=this._resolveTickFontOptions(0).size;return{w:s*a+c*o,h:s*o+c*a}}_getLabelCapacity(t){const n=this.options.time,s=n.displayFormats,i=s[n.unit]||s.millisecond,a=this._tickFormatFunction(t,0,Y2(this,[t],this._majorUnit),i),o=this._getLabelSize(a),c=Math.floor(this.isHorizontal()?this.width/o.w:this.height/o.h)-1;return c>0?c:1}getDataTimestamps(){let t=this._cache.data||[],n,s;if(t.length)return t;const i=this.getMatchingVisibleMetas();if(this._normalized&&i.length)return this._cache.data=i[0].controller.getAllParsedValues(this);for(n=0,s=i.length;n<s;++n)t=t.concat(i[n].controller.getAllParsedValues(this));return this._cache.data=this.normalize(t)}getLabelTimestamps(){const t=this._cache.labels||[];let n,s;if(t.length)return t;const i=this.getLabels();for(n=0,s=i.length;n<s;++n)t.push(H2(this,i[n]));return this._cache.labels=this._normalized?t:this.normalize(t)}normalize(t){return Ym(t.sort(sC))}}nt(Al,"id","time"),nt(Al,"defaults",{bounds:"data",adapters:{},time:{parser:!1,unit:!1,round:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{}},ticks:{source:"auto",callback:!1,major:{enabled:!1}}});function Nd(e,t,n){let s=0,i=e.length-1,a,o,c,d;n?(t>=e[s].pos&&t<=e[i].pos&&({lo:s,hi:i}=Si(e,"pos",t)),{pos:a,time:c}=e[s],{pos:o,time:d}=e[i]):(t>=e[s].time&&t<=e[i].time&&({lo:s,hi:i}=Si(e,"time",t)),{time:a,pos:c}=e[s],{time:o,pos:d}=e[i]);const h=o-a;return h?c+(d-c)*(t-a)/h:c}class Fh extends Al{constructor(t){super(t),this._table=[],this._minPos=void 0,this._tableRange=void 0}initOffsets(){const t=this._getTimestampsForTable(),n=this._table=this.buildLookupTable(t);this._minPos=Nd(n,this.min),this._tableRange=Nd(n,this.max)-this._minPos,super.initOffsets(t)}buildLookupTable(t){const{min:n,max:s}=this,i=[],a=[];let o,c,d,h,f;for(o=0,c=t.length;o<c;++o)h=t[o],h>=n&&h<=s&&i.push(h);if(i.length<2)return[{time:n,pos:0},{time:s,pos:1}];for(o=0,c=i.length;o<c;++o)f=i[o+1],d=i[o-1],h=i[o],Math.round((f+d)/2)!==h&&a.push({time:h,pos:o/(c-1)});return a}_getTimestampsForTable(){let t=this._cache.all||[];if(t.length)return t;const n=this.getDataTimestamps(),s=this.getLabelTimestamps();return n.length&&s.length?t=this.normalize(n.concat(s)):t=n.length?n:s,t=this._cache.all=t,t}getDecimalForValue(t){return(Nd(this._table,t)-this._minPos)/this._tableRange}getValueForPixel(t){const n=this._offsets,s=this.getDecimalForPixel(t)/n.factor-n.end;return Nd(this._table,s*this._tableRange+this._minPos,!0)}}nt(Fh,"id","timeseries"),nt(Fh,"defaults",Al.defaults);var rC=Object.freeze({__proto__:null,CategoryScale:Ph,LinearScale:Nh,LogarithmicScale:zh,RadialLinearScale:Il,TimeScale:Al,TimeSeriesScale:Fh});const Rh=[fx,jS,zk,rC],U2={data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},datasetIdKey:{type:String,default:"label"},updateMode:{type:String,default:void 0}},lC={type:{type:String,required:!0},...U2},cC=l.version[0]==="2"?(e,t)=>Object.assign(e,{attrs:t}):(e,t)=>Object.assign(e,t);function jo(e){return l.isProxy(e)?l.toRaw(e):e}function dC(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e;return l.isProxy(t)?new Proxy(e,{}):e}function uC(e,t){const n=e.options;n&&t&&Object.assign(n,t)}function G2(e,t){e.labels=t}function K2(e,t,n){const s=[];e.datasets=t.map(i=>{const a=e.datasets.find(o=>o[n]===i[n]);return!a||!i.data||s.includes(a)?{...i}:(s.push(a),Object.assign(a,i),a)})}function hC(e,t){const n={labels:[],datasets:[]};return G2(n,e.labels),K2(n,e.datasets,t),n}const fC=l.defineComponent({props:lC,setup(e,t){let{expose:n}=t;const s=l.ref(null),i=l.shallowRef(null);n({chart:i});const a=()=>{if(!s.value)return;const{type:d,data:h,options:f,plugins:m,datasetIdKey:v}=e,y=hC(h,v),w=dC(y,h);i.value=new fs(s.value,{type:d,data:w,options:{...f},plugins:m})},o=()=>{const d=l.toRaw(i.value);d&&(d.destroy(),i.value=null)},c=d=>{d.update(e.updateMode)};return l.onMounted(a),l.onBeforeUnmount(o),l.watch([()=>e.options,()=>e.data],(d,h)=>{let[f,m]=d,[v,y]=h;const w=l.toRaw(i.value);if(!w)return;let x=!1;if(f){const k=jo(f),D=jo(v);k&&k!==D&&(uC(w,k),x=!0)}if(m){const k=jo(m.labels),D=jo(y.labels),E=jo(m.datasets),B=jo(y.datasets);k!==D&&(G2(w.config.data,k),x=!0),E&&E!==B&&(K2(w.config.data,E,e.datasetIdKey),x=!0)}x&&c(w)},{deep:!0}),()=>l.h("canvas",{ref:s})}});function zd(e,t){return fs.register(t),l.defineComponent({props:U2,setup(n,s){let{expose:i}=s;const a=l.shallowRef(null),o=c=>{a.value=c==null?void 0:c.chart};return i({chart:a}),()=>l.h(fC,cC({ref:o},{type:e,...n}))}})}const Z2=zd("bar",yl),pC=zd("line",bl),mC=zd("pie",yd),gC=zd("polarArea",Ho),oa={gp50:"#f3fcf8",gp100:"#e2f8ef",gp200:"#abedd3",gp300:"#6ddfb1",gp400:"#2db981",gp500:"#239f6d",gp600:"#1c7d56",gp700:"#136746",ta50:"#eefcfa",ta100:"#dcf9f6",ta200:"#a2f1e5",ta300:"#51e6d0",ta400:"#20c5ad",ta500:"#18aa94",ta600:"#138675",ta700:"#0f6b5d",ts50:"#f5fbff",ts100:"#e6f6fe",ts200:"#C2EDFF",ts300:"#7BD0F4",ts400:"#42AAD7",ts500:"#1F86B2",ts600:"#18698B",ts700:"#155875",bn50:"#f6f9fe",bn100:"#e6effe",bn200:"#b4cdf8",bn300:"#729ee9",bn400:"#467bd8",bn500:"#2f64c1",bn600:"#2051a7",bn700:"#19438a",in50:"#f5f6ff",in100:"#ebefff",in200:"#CED6FD",in300:"#9bacf8",in400:"#6a7cd7",in500:"#4b5caf",in600:"#374486",in700:"#2f396f",vr50:"#faf5ff",vr100:"#f7f0ff",vr200:"#E6D2F9",vr300:"#CEABED",vr400:"#a772d5",vr500:"#8955B9",vr600:"#6B3A98",vr700:"#5c3082",pp50:"#fff5fb",pp100:"#ffebf7",pp200:"#F9C8E2",pp300:"#EF8FC0",pp400:"#DA629F",pp500:"#BE377C",pp600:"#A12663",pp700:"#88255a",rc50:"#fef6f7",rc100:"#ffebed",rc200:"#FABDC5",rc300:"#F98B98",rc400:"#F3596C",rc500:"#E03E52",rc600:"#C92C3F",rc700:"#b22435",og50:"#fef7f6",og100:"#ffefeb",og200:"#FFD6CC",og300:"#FDAF9B",og400:"#FF8567",og500:"#F06442",og600:"#D64B29",og700:"#bc4224",al50:"#fefbf6",al100:"#fdf3e2",al200:"#ffe5b8",al300:"#fdd286",al400:"#f6bd5a",al500:"#eda831",al600:"#d89013",al700:"#c08011",n0:"#FFFFFF",n10:"#FAFCFE",n20:"#F4F8FB",n30:"#E7EDF3",n40:"#DFE5EC",n50:"#D6DCE3",n100:"#C3CCD5",n200:"#ACB8C3",n300:"#99A6B2",n400:"#8794A1",n500:"#647382",n600:"#52616F",n700:"#3B4754",n800:"#28333E",n900:"#1D262F",palete:'["Light Neutrals", "Light", #FFFFFF, #FAFCFE, #F4F8FB, #E7EDF3, #DFE5EC, "$n-0", "$n-10", "$n-20", "$n-30", "$n-40"], ["Mid Neutrals", "Gray", #D6DCE3, #C3CCD5, #ACB8C3, #99A6B2, #8794A1, "$n-50", "$n-100", "$n-200", "$n-300", "$n-400"], ["Dark Neutrals", "Dark", #647382, #52616F, #3B4754, #28333E, #1D262F, "$n-500", "$n-600", "$n-700", "$n-800", "$n-900"], ["Piccolo Green", "Green", #f3fcf8, #e2f8ef, #abedd3, #6ddfb1, #2db981, #239f6d, #1c7d56, #136746, "$gp-50", "$gp-100", "$gp-200", "$gp-300", "$gp-400", "$gp-500", "$gp-600", "$gp-700"], ["Aquaman Teal", "Teal", #eefcfa, #dcf9f6, #a2f1e5, #51e6d0, #20c5ad, #18aa94, #138675, #0f6b5d, "$ta-50", "$ta-100", "$ta-200", "$ta-300", "$ta-400", "$ta-500", "$ta-600", "$ta-700"], ["Sulivan Turquoise", "Turquoise", #f5fbff, #e6f6fe, #C2EDFF, #7BD0F4, #42AAD7, #1F86B2, #18698B, #155875, "$ts-50", "$ts-100", "$ts-200", "$ts-300", "$ts-400", "$ts-500", "$ts-600", "$ts-700"], ["Nocturne Blue", "Blue", #f6f9fe, #e6effe, #b4cdf8, #729ee9, #467bd8, #2f64c1, #2051a7, #19438a, "$bn-50", "$bn-100", "$bn-200", "$bn-300", "$bn-400", "$bn-500", "$bn-600", "$bn-700"], ["Nightwing Indigo", "Indigo", #f5f6ff, #ebefff, #CED6FD, #9bacf8, #6a7cd7, #4b5caf, #374486, #2f396f, "$in-50", "$in-100", "$in-200", "$in-300", "$in-400", "$in-500", "$in-600", "$in-700"], ["Raven Violet", "Violet", #faf5ff, #f7f0ff, #E6D2F9, #CEABED, #a772d5, #8955B9, #6B3A98, #5c3082, "$vr-50", "$vr-100", "$vr-200", "$vr-300", "$vr-400", "$vr-500", "$vr-600", "$vr-700"], ["Peppa Pink", "Pink", #fff5fb, #ffebf7, #F9C8E2, #EF8FC0, #DA629F, #BE377C, #A12663, #88255a, "$pp-50", "$pp-100", "$pp-200", "$pp-300", "$pp-400", "$pp-500", "$pp-600", "$pp-700"], ["Carmen Red", "Red", #fef6f7, #ffebed, #FABDC5, #F98B98, #F3596C, #E03E52, #C92C3F, #b22435, "$rc-50", "$rc-100", "$rc-200", "$rc-300", "$rc-400", "$rc-500", "$rc-600", "$rc-700"], ["Goku Orange", "Orange", #fef7f6, #ffefeb, #FFD6CC, #FDAF9B, #FF8567, #F06442, #D64B29, #bc4224, "$og-50", "$og-100", "$og-200", "$og-300", "$og-400", "$og-500", "$og-600", "$og-700"], ["Lisa Amber", "Amber", #fefbf6, #fdf3e2, #ffe5b8, #fdd286, #f6bd5a, #eda831, #d89013, #c08011, "$al-50", "$al-100", "$al-200", "$al-300", "$al-400", "$al-500", "$al-600", "$al-700"]'},Yo=e=>{let t=[],n={};const s=/(\[[^[\]]*\])/g,i=e.match(s);for(let a=0;a<i.length;a++){i[a]=i[a].replace("[",""),i[a]=i[a].replace("]","");let o=i[a].split(",");n.colorName=o[0].trim().replace(/"/g,""),n.variantName=o[1].trim().replace(/"/g,""),n.color400=o[6],n.colorShades=[],n.colorTokens=[],n.colorData=[];let c=!1;for(let d=2,h=2;d<o.length;d++,h++)o[d].includes("#")?(n.colorShades.push(o[d].trim()),n.colorData[h-2]={},n.colorData[h-2].shade=o[d].trim()):o[d].includes("$")&&(n.colorTokens.push(o[d].trim().replace(/"/g,"")),n.colorData[h-2].token=o[d].trim().replace(/"/g,"")),!c&&o[d+1].includes("$")&&(h=1,c=!0);t.push(n),n={}}return t},O1t="";fs.register(...Rh);const vC={components:{Bar:Z2},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},barWidth:{type:Number,default:1}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{responsive:!0,maintainAspectRatio:!1,categoryPercentage:null,plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0},barWidth:{handler(e){e>=.1&&e<=1?this.chartOptions.categoryPercentage=e:this.chartOptions.categoryPercentage=1},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};this.chartOptions.plugins.legend.display=!0,e.forEach(s=>{const i=s.name;let a;e.length===1&&(a=2,n[i]=t[a],this.chartOptions.plugins.legend.display=!1),n[i]||(a=Object.keys(n).length%t.length,n[i]=t[a]),s.backgroundColor=n[i],s.borderRadius=6})}}},_C={class:"responsive-container"};function yC(e,t,n,s,i,a){const o=l.resolveComponent("Bar");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",_C,[l.createVNode(o,{is:"bar",data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const bC=st(vC,[["render",yC],["__scopeId","data-v-1e55dea1"]]),M1t="";fs.register(...Rh);const wC={components:{Line:pC},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},xAxisRange:{type:Array,default:()=>[0,100]},yAxisRange:{type:Array,default:()=>[0,100]},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},showLabelName:{type:Boolean,required:!0,default:!0},fill:{type:Boolean,default:!1},isDashed:{type:Boolean,default:!1},borderDash:{type:Array,default:()=>[]},smoothing:{type:Number,default:.3}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{interaction:{intersect:!1},scales:{x:{suggestedMin:this.xAxisRange[0],suggestedMax:this.xAxisRange[1],display:!0,title:{display:!0}},y:{suggestedMin:this.yAxisRange[0],suggestedMax:this.yAxisRange[1],display:!0,title:{display:!0}}},tension:this.smoothing,responsive:!0,maintainAspectRatio:!1,pieceLabel:{mode:"percentage",precision:1},plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}},fill:this.fill}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0},isDashed:{handler(e){e===!0&&this.checkDashed()},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:this.showLabelName?i.name:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?this.fill?t.colorShades.map(s=>s+"80"):t.colorShades:[]},setColors(e,t){const n={};e.forEach((s,i)=>{const a=s.name;n[a]||(n[a]=t.slice()),s.data.length>0&&(s.backgroundColor=n[a][i%n[a].length],s.borderColor=n[a][i%n[a].length]),s.borderRadius=6})},checkDashed(){this.chartOptions.borderDash=[this.borderDash[0],this.borderDash[1]]}}},xC={class:"responsive-container"};function SC(e,t,n,s,i,a){const o=l.resolveComponent("Line");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",xC,[l.createVNode(o,{data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const kC=st(wC,[["render",SC],["__scopeId","data-v-3a3639cb"]]),D1t="",CC={components:{Pie:mC},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","teal","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},colors:{type:Array,default:()=>[],validator:e=>{const t=["green","teal","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"];return e.every(n=>t.includes(n))}}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{responsive:!0,maintainAspectRatio:!1,pieceLabel:{mode:"percentage",precision:1},plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},computed:{isColorsSet(){return this.colors&&this.colors.length>0},computedBackgroundColors(){return this.colors.map(e=>{const t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));if(t)return t.color400})}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.isColorsSet?this.computedBackgroundColors:this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};e.forEach(s=>{const i=s.name;n[i]||(n[i]=t.slice()),s.backgroundColor=n[i].splice(0,s.data.length),s.borderRadius=6})}}},OC={class:"responsive-container"};function MC(e,t,n,s,i,a){const o=l.resolveComponent("Pie");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",OC,[l.createVNode(o,{data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const DC=st(CC,[["render",MC],["__scopeId","data-v-df415374"]]),E1t="",EC={components:{PolarArea:gC},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},isVisiblePointNames:{type:Boolean,default:!1}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{responsive:!0,scales:{r:{pointLabels:{display:this.isVisiblePointNames,centerPointLabels:!0,font:{size:12}}}},maintainAspectRatio:!1,pieceLabel:{mode:"percentage",precision:1},plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:this.showLabelName?i.name:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};e.forEach(s=>{const i=s.name;n[i]||(n[i]=t.slice()),s.backgroundColor=n[i].splice(0,s.data.length),s.borderRadius=6})}}},TC={class:"responsive-container"};function IC(e,t,n,s,i,a){const o=l.resolveComponent("PolarArea");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",TC,[l.createVNode(o,{data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const AC=st(EC,[["render",IC],["__scopeId","data-v-386a0dc0"]]),T1t="";fs.register(...Rh);const VC={components:{Bar:Z2},props:{data:{type:Object,required:!0,default:()=>({datasets:[{label:"",data:[]}]})},variant:{type:String,required:!0,default:"green",validator:e=>["green","turquoise","blue","indigo","violet","pink","red","orange","amber","gray","dark"].includes(e)},labels:{type:Array,required:!0,default:()=>[]},barWidth:{type:Number,default:1}},data(){return{sassColorVariables:oa,localChartData:{},localLabels:[],palletColors:[],deleteFirstTwoColors:!1,chartOptions:{scales:{x:{stacked:!0},y:{stacked:!0}},responsive:!0,maintainAspectRatio:!1,categoryPercentage:null,plugins:{tooltip:{callbacks:{beforeTitle:function(e){return`${e[0].dataset.name}`}}},legend:{display:!0,labels:{usePointStyle:!0,pointStyle:"rectRounded"}}}}}},watch:{labels:{handler(e){this.localLabels=e},immediate:!0},variant:{handler(e){e==="gray"||e==="dark"?this.deleteFirstTwoColors=!0:this.deleteFirstTwoColors=!1},immediate:!0},data:{handler(e){this.mergeChartDataNoSelect(e)},immediate:!0},barWidth:{handler(e){e>=.1&&e<=1?this.chartOptions.categoryPercentage=e:this.chartOptions.categoryPercentage=1},immediate:!0}},methods:{paleteBuilder:Yo,palete(){this.palletColors=this.paleteBuilder(this.sassColorVariables.palete),this.removeFirstTwoElements()},removeFirstTwoElements(){for(let e=0;e<this.palletColors.length;e++){const t=this.palletColors[e];this.deleteFirstTwoColors===!1&&(t.colorShades.splice(0,2),t.colorTokens.splice(0,2),t.colorData.splice(0,2))}},addDataSetNames(){this.data.forEach(e=>{e.datasets.forEach(t=>{t.name=e.name})})},mergeChartDataNoSelect(e){const t={labels:this.localLabels,datasets:[]};this.addDataSetNames(),e.forEach(s=>{s.datasets.forEach(i=>{const a={label:i.label,data:i.data,name:i.name,borderRadius:6};t.datasets.push(a)})}),this.palete();const n=this.generateBackgroundColor();this.setColors(t.datasets,n),this.localChartData=t},generateBackgroundColor(){const e=this.variant.toLowerCase(),t=this.palletColors.find(n=>n.variantName.toLowerCase().includes(e));return t?t.colorShades:[]},setColors(e,t){const n={};this.chartOptions.plugins.legend.display=!0,e.forEach(s=>{const i=s.name;let a;e.length===1&&(a=2,n[i]=t[a],this.chartOptions.plugins.legend.display=!1),n[i]||(a=Object.keys(n).length%t.length,n[i]=t[a]),s.backgroundColor=n[i],s.borderRadius=6})}}},BC={class:"responsive-container"};function PC(e,t,n,s,i,a){const o=l.resolveComponent("Bar");return l.openBlock(),l.createElementBlock("span",null,[l.createElementVNode("div",BC,[l.createVNode(o,{is:"bar",data:i.localChartData,options:i.chartOptions},null,8,["data","options"])])])}const NC=st(VC,[["render",PC],["__scopeId","data-v-ed4bef4e"]]),I1t="",Hh={props:{padding:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingTop:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingRight:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingBottom:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},paddingLeft:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},margin:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginTop:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginRight:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginBottom:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12},marginLeft:{type:[Number,String],default:0,validator:e=>e>=0&&e<=12}},computed:{paddingTopResolver(){let e=this.paddingTop>12?12:+this.paddingTop;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},paddingRightResolver(){let e=this.paddingRight>12?12:+this.paddingRight;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},paddingBottomResolver(){let e=this.paddingBottom>12?12:+this.paddingBottom;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},paddingLeftResolver(){let e=this.paddingLeft>12?12:+this.paddingLeft;return e=this.padding?this.basePropertyResolver(this.padding):e,`${e*4}px`},marginTopResolver(){let e=this.marginTop>12?12:+this.marginTop;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`},marginRightResolver(){let e=this.marginRight>12?12:+this.marginRight;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`},marginBottomResolver(){let e=this.marginBottom>12?12:+this.marginBottom;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`},marginLeftResolver(){let e=this.marginLeft>12?12:+this.marginLeft;return e=this.margin?this.basePropertyResolver(this.margin):e,`${e*4}px`}},methods:{basePropertyResolver(e){return e>=0&&e<=12?e:e<0?0:12}}},X2=()=>{l.useCssVars(e=>({"6d4c0f4d":e.marginBottomResolver,d6616fae:e.marginLeftResolver,"0baf3274":e.marginRightResolver,"7c666dff":e.marginTopResolver,"561264d4":e.paddingBottomResolver,17295920:e.paddingLeftResolver,e3e47742:e.paddingRightResolver,"9def4450":e.paddingTopResolver}))},J2=Hh.setup;Hh.setup=J2?(e,t)=>(X2(),J2(e,t)):X2;const zC=Hh,LC={class:"spacer"};function FC(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",LC,[l.renderSlot(e.$slots,"default",{},void 0,!0)])}const Ld=st(zC,[["render",FC],["__scopeId","data-v-5aebf225"]]);function Wh(e,t=24){let n=e/8,s=n%4;return`${n>t?t:n-s+4}px`}const A1t="",jh={components:{CdsSpacer:Ld,CdsClickable:Qi},props:{elevated:{type:Boolean,default:!1},fluid:{type:Boolean,default:!1},padding:{type:[Number,String],default:4,validator:e=>e<=12},clickable:{type:Boolean,default:!1},variant:{type:String,default:"gray"}},data(){return{width:0}},computed:{widthResolver(){return this.fluid?"100%":"fit-content"},borderRadiusResolver(){return this.rounder(this.width,12)}},mounted(){this.width=this.$refs["cds-box"].getBoundingClientRect().width},methods:{rounder:Wh,handleClick(){this.clickable&&this.$emit("boxClick",!0)}}},Q2=()=>{l.useCssVars(e=>({"8bf1f4e6":e.widthResolver,"337f1943":e.borderRadiusResolver}))},q2=jh.setup;jh.setup=q2?(e,t)=>(Q2(),q2(e,t)):Q2;const RC=jh;function HC(e,t,n,s,i,a){const o=l.resolveComponent("cds-spacer"),c=l.resolveComponent("cds-clickable");return l.openBlock(),l.createElementBlock("div",{ref:"cds-box",class:l.normalizeClass(n.elevated?"box--elevated":`box--${n.variant}`)},[l.createVNode(c,{class:"box__container",clickable:n.clickable,onClick:a.handleClick},{default:l.withCtx(()=>[l.createVNode(o,{"padding-top":n.padding,"padding-right":n.padding,"padding-bottom":n.padding,"padding-left":n.padding},{default:l.withCtx(()=>[l.renderSlot(e.$slots,"default",{},void 0,!0)]),_:3},8,["padding-top","padding-right","padding-bottom","padding-left"])]),_:3},8,["clickable","onClick"])],2)}const Vl=st(RC,[["render",HC],["__scopeId","data-v-34f9c778"]]);var Yh={exports:{}};(function(e,t){var n=9007199254740991,s="[object Arguments]",i="[object Function]",a="[object GeneratorFunction]",o="[object Map]",c="[object Object]",d="[object Promise]",h="[object Set]",f="[object WeakMap]",m="[object DataView]",v=/[\\^$.*+?()[\]{}|]/g,y=/^\[object .+?Constructor\]$/,w=typeof qe=="object"&&qe&&qe.Object===Object&&qe,x=typeof self=="object"&&self&&self.Object===Object&&self,k=w||x||Function("return this")(),D=t&&!t.nodeType&&t,E=D&&!0&&e&&!e.nodeType&&e,B=E&&E.exports===D;function S(tt,Ht){return tt==null?void 0:tt[Ht]}function A(tt){var Ht=!1;if(tt!=null&&typeof tt.toString!="function")try{Ht=!!(tt+"")}catch{}return Ht}function I(tt,Ht){return function(oe){return tt(Ht(oe))}}var F=Function.prototype,L=Object.prototype,W=k["__core-js_shared__"],X=function(){var tt=/[^.]+$/.exec(W&&W.keys&&W.keys.IE_PROTO||"");return tt?"Symbol(src)_1."+tt:""}(),Z=F.toString,Q=L.hasOwnProperty,et=L.toString,gt=RegExp("^"+Z.call(Q).replace(v,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ot=B?k.Buffer:void 0,ft=L.propertyIsEnumerable,lt=ot?ot.isBuffer:void 0,vt=I(Object.keys,Object),xt=Nt(k,"DataView"),ct=Nt(k,"Map"),R=Nt(k,"Promise"),q=Nt(k,"Set"),rt=Nt(k,"WeakMap"),pt=!ft.call({valueOf:1},"valueOf"),$=$t(xt),_t=$t(ct),Mt=$t(R),ut=$t(q),Bt=$t(rt);function Lt(tt){return et.call(tt)}function Pt(tt){if(!Xe(tt)||le(tt))return!1;var Ht=Ke(tt)||A(tt)?gt:y;return Ht.test($t(tt))}function Nt(tt,Ht){var oe=S(tt,Ht);return Pt(oe)?oe:void 0}var jt=Lt;(xt&&jt(new xt(new ArrayBuffer(1)))!=m||ct&&jt(new ct)!=o||R&&jt(R.resolve())!=d||q&&jt(new q)!=h||rt&&jt(new rt)!=f)&&(jt=function(tt){var Ht=et.call(tt),oe=Ht==c?tt.constructor:void 0,$n=oe?$t(oe):void 0;if($n)switch($n){case $:return m;case _t:return o;case Mt:return d;case ut:return h;case Bt:return f}return Ht});function le(tt){return!!X&&X in tt}function he(tt){var Ht=tt&&tt.constructor,oe=typeof Ht=="function"&&Ht.prototype||L;return tt===oe}function $t(tt){if(tt!=null){try{return Z.call(tt)}catch{}try{return tt+""}catch{}}return""}function Et(tt){return Ee(tt)&&Q.call(tt,"callee")&&(!ft.call(tt,"callee")||et.call(tt)==s)}var ve=Array.isArray;function Ge(tt){return tt!=null&&Ze(tt.length)&&!Ke(tt)}function Ee(tt){return ks(tt)&&Ge(tt)}var _e=lt||Je;function on(tt){if(Ge(tt)&&(ve(tt)||typeof tt=="string"||typeof tt.splice=="function"||_e(tt)||Et(tt)))return!tt.length;var Ht=jt(tt);if(Ht==o||Ht==h)return!tt.size;if(pt||he(tt))return!vt(tt).length;for(var oe in tt)if(Q.call(tt,oe))return!1;return!0}function Ke(tt){var Ht=Xe(tt)?et.call(tt):"";return Ht==i||Ht==a}function Ze(tt){return typeof tt=="number"&&tt>-1&&tt%1==0&&tt<=n}function Xe(tt){var Ht=typeof tt;return!!tt&&(Ht=="object"||Ht=="function")}function ks(tt){return!!tt&&typeof tt=="object"}function Je(){return!1}e.exports=on})(Yh,Yh.exports);const We=Yh.exports,V1t="",WC={components:{CdsIcon:Me,CdsSpacer:Ld,CdsClickable:Qi},props:{items:{type:Array,default:()=>[],required:!0}},methods:{resolveRoute({route:e,path:t}){const n=We(e)?t:e;return n instanceof String?{path:n}:n},routerPushTo(e){return this.resolveRoute(e)?this.resolveRoute(e).path:null}}},jC={class:"breadcrumb"};function YC(e,t,n,s,i,a){const o=l.resolveComponent("cds-icon"),c=l.resolveComponent("cds-spacer"),d=l.resolveComponent("router-link"),h=l.resolveComponent("cds-clickable");return l.openBlock(),l.createElementBlock("nav",null,[l.createElementVNode("ul",jC,[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.items,(f,m)=>(l.openBlock(),l.createElementBlock("li",{key:`${m}-${f.name}-item`,role:"presentation"},[m===0?(l.openBlock(),l.createBlock(h,{key:0,clickable:""},{default:l.withCtx(()=>[l.createVNode(d,{to:a.routerPushTo(f),class:"breadcrumb__link"},{default:l.withCtx(()=>[n.items.length<=2?(l.openBlock(),l.createBlock(o,{key:0,height:"16",width:"16",name:"arrow-left-outline"})):(l.openBlock(),l.createBlock(o,{key:1,height:"15",width:"15",name:"home-outline"})),l.createVNode(c,{"margin-left":"2"},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(f.label),1)]),_:2},1024)]),_:2},1032,["to"])]),_:2},1024)):(l.openBlock(),l.createBlock(c,{key:1,class:"breadcrumb__item","margin-right":"1","margin-left":"1"},{default:l.withCtx(()=>[l.createVNode(o,{height:"16",width:"16",name:"caret-right-outline",class:"breadcrumb__separator"}),l.createVNode(d,{to:a.routerPushTo(f),class:"breadcrumb__link"},{default:l.withCtx(()=>[l.createVNode(h,{clickable:""},{default:l.withCtx(()=>[l.createTextVNode(l.toDisplayString(f.label),1)]),_:2},1024)]),_:2},1032,["to"])]),_:2},1024))]))),128))])])}const UC=st(WC,[["render",YC],["__scopeId","data-v-c2046c1c"]]),B1t="",Uh={props:{src:{type:String,required:!0},fallbackSrc:{type:String,required:!1},width:{type:[Number,String],default:null},height:{type:[Number,String],default:null},alt:{type:String,default:"Imagem"},opacity:{type:[Number,String],default:1},dimmed:{type:Boolean,default:!1},blackAndWhite:{type:Boolean,default:!1},roundedCorners:{type:Boolean,default:!1}},data(){return{innerSrc:this.src}},computed:{heightResolver(){return this.height?`${this.height}px`:"auto"},widthResolver(){return this.width?`${this.width}px`:"auto"},opacityResolver(){return this.width?`${this.width}px`:"auto"},radiusResolver(){return this.roundedCorners?Wh(this.width):"0px"},grayScaleResolver(){return this.blackAndWhite?"grayscale(100%)":this.dimmed?"grayscale(35%)":"grayscale(0%)"}},methods:{rounder:Wh,imageSrcResolver(){this.innerSrc=this.fallbackSrc}}},$2=()=>{l.useCssVars(e=>({"21136de6":e.radiusResolver,e10ed842:e.grayScaleResolver,"31ae2d7b":e.heightResolver,"1e7f7c9d":e.opacity,"775376fe":e.widthResolver}))},tv=Uh.setup;Uh.setup=tv?(e,t)=>($2(),tv(e,t)):$2;const GC=Uh,KC=["src","alt"];function ZC(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("img",l.mergeProps(e.$attrs,{src:i.innerSrc,alt:n.alt,class:"cds__image",onError:t[0]||(t[0]=(...o)=>a.imageSrcResolver&&a.imageSrcResolver(...o))}),null,16,KC)}const ev=st(GC,[["render",ZC],["__scopeId","data-v-79754f28"]]),Gh=(e,t)=>Object.keys(e).some(n=>n===t),P1t="",Kh={components:{CdsBox:Vl,CdsImage:ev},props:{title:{type:String,default:""},content:{type:String,default:""},imageSrc:{type:String,default:""},imageAlt:{type:String,default:"imagem do card"},imageWidth:{type:[String,Number],default:300},imageHeight:{type:[String,Number],default:180},bodyWidth:{type:[String,Number],default:300},horizontal:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1}},computed:{imageWidthResolver(){return this.horizontal?"fit-content":`${this.imageWidth}px`},bodyWidthResolver(){return`${this.bodyWidth}px`}},methods:{hasSlot:Gh,handleClick(){this.clickable&&this.$emit("cardClick",!0)}}},nv=()=>{l.useCssVars(e=>({"8d304056":e.bodyWidthResolver,"4730bd46":e.imageWidthResolver}))},sv=Kh.setup;Kh.setup=sv?(e,t)=>(nv(),sv(e,t)):nv;const XC=Kh,JC={class:"card__extra-container"},QC={class:"card__extra"},qC={key:0},$C={key:1,class:"card__image"},tO={key:2,class:"card__icon"},eO={class:"card__spacer"},nO={key:0,class:"card__header"},sO={key:1},iO={class:"card__header"},aO={key:2,class:"card__body"},oO={key:3},rO={class:"card__body"},lO={key:4,class:"card__footer"};function cO(e,t,n,s,i,a){const o=l.resolveComponent("cds-image"),c=l.resolveComponent("cds-box");return l.openBlock(),l.createBlock(c,{padding:"0",clickable:n.clickable,onBoxClick:a.handleClick},{default:l.withCtx(()=>[l.createElementVNode("div",JC,[l.createElementVNode("div",QC,[l.renderSlot(e.$slots,"extra",{},void 0,!0)])]),l.createElementVNode("div",{class:l.normalizeClass({"card--horizontal":this.horizontal})},[a.hasSlot(e.$slots,"image")?(l.openBlock(),l.createElementBlock("div",qC,[l.renderSlot(e.$slots,"image",{},void 0,!0)])):n.imageSrc?(l.openBlock(),l.createElementBlock("div",$C,[l.createVNode(o,{src:n.imageSrc,width:n.imageWidth,height:n.imageHeight,alt:n.imageAlt},null,8,["src","width","height","alt"])])):a.hasSlot(e.$slots,"icon")?(l.openBlock(),l.createElementBlock("div",tO,[l.renderSlot(e.$slots,"icon",{},void 0,!0)])):l.createCommentVNode("",!0),l.createElementVNode("div",eO,[a.hasSlot(e.$slots,"header")?(l.openBlock(),l.createElementBlock("div",nO,[l.renderSlot(e.$slots,"header",{},void 0,!0)])):(l.openBlock(),l.createElementBlock("div",sO,[l.createElementVNode("p",iO,l.toDisplayString(n.title),1)])),a.hasSlot(e.$slots,"body")?(l.openBlock(),l.createElementBlock("div",aO,[l.renderSlot(e.$slots,"body",{},void 0,!0)])):(l.openBlock(),l.createElementBlock("div",oO,[l.createElementVNode("p",rO,l.toDisplayString(n.content),1)])),a.hasSlot(e.$slots,"footer")?(l.openBlock(),l.createElementBlock("div",lO,[l.renderSlot(e.$slots,"footer",{},void 0,!0)])):l.createCommentVNode("",!0)])],2)]),_:3},8,["clickable","onBoxClick"])}const dO=st(XC,[["render",cO],["__scopeId","data-v-ef799654"]]),N1t="",uO={components:{CdsButton:Po},props:{title:{type:String,default:"T\xEDtulo do AlertCard",required:!0},text:{type:String,default:"Subt\xEDtulo do AlertCard"},image:{type:String,default:"",required:!0},imageDescription:{type:String,default:"Imagem de CalloutCard"},actionButtonVariant:{type:String,default:"green"},actionButtonText:{type:String,default:"Ok"},actionButtonSecondary:{type:Boolean,default:!1},actionButtonDisabled:{type:Boolean,default:!1},compact:{type:Boolean,default:!1}},methods:{resolveClass(e){return this.compact?`${e}--compact`:e}}},hO={id:"callout-card"},fO={class:"image__container"},pO=["src","alt"],mO={class:"content__title"},gO={class:"content__text"};function vO(e,t,n,s,i,a){const o=l.resolveComponent("cds-button");return l.openBlock(),l.createElementBlock("span",hO,[l.createElementVNode("div",{class:l.normalizeClass(a.resolveClass("callout-card__container"))},[l.createElementVNode("div",fO,[l.createElementVNode("img",{class:l.normalizeClass(a.resolveClass("image__content")),src:n.image,alt:n.imageDescription},null,10,pO)]),l.createElementVNode("div",{class:l.normalizeClass(a.resolveClass("content__container"))},[l.createElementVNode("div",{class:l.normalizeClass(a.resolveClass("content"))},[l.createElementVNode("p",mO,l.toDisplayString(n.title),1),l.createElementVNode("span",gO,[l.renderSlot(e.$slots,"text",{},()=>[l.createTextVNode(l.toDisplayString(n.text),1)])])],2),l.createElementVNode("div",null,[l.renderSlot(e.$slots,"action",{},()=>[l.createVNode(o,{id:"content-button",variant:n.actionButtonVariant,text:n.actionButtonText,secondary:n.actionButtonSecondary,disabled:n.actionButtonDisabled,onClick:t[0]||(t[0]=c=>e.$emit("action-button-click",!0))},null,8,["variant","text","secondary","disabled"])])])],2)],2)])}const _O=st(uO,[["render",vO]]),z1t="",yO={props:{propertyName:{type:String,default:"Dados",required:!1},perPage:{type:Number,required:!0},total:{type:Number,required:!0},simple:{type:Boolean,default:!1,required:!1},fluid:{type:Boolean,default:!1,required:!1}},data(){return{currentNumberOfItemsMin:1,currentNumberOfItemsMax:this.perPage}},computed:{numberOfPages(){return Math.ceil(this.total/this.perPage)},disabledForward(){return this.currentNumberOfItemsMax>=this.total||this.simple&&this.currentNumberOfItemsMin>=this.numberOfPages},disabledBack(){return this.currentNumberOfItemsMin===1}},methods:{handleClickBack(){if(!this.disabledBack){if(this.simple&&this.currentNumberOfItemsMin>1){this.currentNumberOfItemsMin-=1,this.$emit("click-back",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1});return}else if(this.simple&&this.currentNumberOfItemsMin===1)return;this.currentNumberOfItemsMin-this.perPage<=0?(this.currentNumberOfItemsMin=1,this.currentNumberOfItemsMax=this.perPage,this.$emit("click-back",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1})):(this.currentNumberOfItemsMax-=this.currentNumberOfItemsMax-this.currentNumberOfItemsMin+1,this.currentNumberOfItemsMin-=this.perPage,this.$emit("click-back",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax}))}},handleClickForward(){if(!this.disabledForward){if(this.simple&&this.currentNumberOfItemsMin<this.numberOfPages){this.currentNumberOfItemsMin+=1,this.$emit("click-forward",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1});return}else if(this.simple&&this.currentNumberOfItemsMin===this.numberOfPages)return;this.currentNumberOfItemsMax+this.perPage>this.total?(this.currentNumberOfItemsMin=this.currentNumberOfItemsMax+1,this.currentNumberOfItemsMax=this.total,this.$emit("click-forward",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1})):(this.currentNumberOfItemsMin=this.currentNumberOfItemsMax+1,this.currentNumberOfItemsMax+=this.perPage,this.$emit("click-forward",{min:this.currentNumberOfItemsMin-1,max:this.currentNumberOfItemsMax+1}))}}}},bO={key:0,class:"carousel-controller__text"},wO={key:1,class:"carousel-controller__text"},xO={class:"carousel-controller__property"};function SO(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",null,[l.createElementVNode("div",{class:l.normalizeClass(["carousel-controller",{"carousel-controller--fluid":n.fluid}])},[l.createElementVNode("span",{class:l.normalizeClass({"carousel-controller__previous-button--disabled":a.disabledBack,"carousel-controller__previous-button":!a.disabledBack}),onClick:t[0]||(t[0]=(...o)=>a.handleClickBack&&a.handleClickBack(...o))},null,2),l.createElementVNode("div",null,[n.simple?(l.openBlock(),l.createElementBlock("span",wO,l.toDisplayString(i.currentNumberOfItemsMin)+" de "+l.toDisplayString(a.numberOfPages),1)):(l.openBlock(),l.createElementBlock("span",bO,l.toDisplayString(i.currentNumberOfItemsMin)+"-"+l.toDisplayString(i.currentNumberOfItemsMax)+" de "+l.toDisplayString(n.total),1)),l.createElementVNode("span",xO,l.toDisplayString(n.propertyName),1)]),l.createElementVNode("span",{class:l.normalizeClass({"carousel-controller__next-button--disabled":a.disabledForward,"carousel-controller__next-button":!a.disabledForward}),onClick:t[1]||(t[1]=(...o)=>a.handleClickForward&&a.handleClickForward(...o))},null,2)],2)])}const kO=st(yO,[["render",SO],["__scopeId","data-v-fcb19a0a"]]);function iv(e,t){return`${e}--${t}`}const L1t="",CO={props:{modelValue:{type:Boolean,default:!1,required:!0},label:{type:String,default:"checkbox content"},variant:{type:String,default:"green"},indeterminate:{type:Boolean,default:!1},prominent:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},data(){return{isChecked:this.modelValue,isIndeterminate:this.indeterminate}},computed:{resolveCheckboxClass(){const e=this.disabled?"cds-checkbox__input--disabled":"",t=iv("cds-checkbox__input",this.variant);let n=this.isChecked?"cds-checkbox__input--checked":"cds-checkbox__input--unchecked";return n=this.isIndeterminate?"cds-checkbox__input--indeterminate":n,`${t} ${n} ${e}`}},watch:{modelValue:{handler(e,t){e!==t&&(this.isChecked=this.modelValue)},immediate:!0},indeterminate:{handler(e,t){e!==t&&(this.isIndeterminate=this.indeterminate)},immediate:!0}},methods:{toggleValue(){this.disabled||(this.isChecked=this.isIndeterminate?!1:!this.isChecked,this.isIndeterminate=!1,this.$emit("update:modelValue",this.isChecked),this.$emit("update:indeterminate",!1))}}},OO={class:"cds-checkbox__container"},MO={class:"cds-checkbox__input"},DO=["id","value","name","disabled"],EO=["for"],TO=["for"];function IO(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",OO,[l.createElementVNode("div",MO,[l.createElementVNode("input",{id:e.$attrs.id||"cds-checkbox-option-input",value:n.modelValue,type:"checkbox",name:e.$attrs.name||"cds-checkbox-option",disabled:n.disabled},null,8,DO),l.createElementVNode("label",{for:e.$attrs.id||"cds-checkbox-option-input",class:l.normalizeClass(a.resolveCheckboxClass),onClick:t[0]||(t[0]=(...o)=>a.toggleValue&&a.toggleValue(...o))},null,10,EO)]),l.createElementVNode("label",{class:l.normalizeClass(["cds-checkbox__label",{"cds-checkbox__label--disabled":n.disabled,"cds-checkbox__label--prominent":n.prominent&&n.modelValue}]),for:e.$attrs.id||"cds-checkbox-option-input",onClick:t[1]||(t[1]=(...o)=>a.toggleValue&&a.toggleValue(...o))},l.toDisplayString(n.label),11,TO)])}const Zh=st(CO,[["render",IO],["__scopeId","data-v-0758b096"]]),F1t="",AO={props:{modelValue:{type:Boolean,default:!1,required:!0},title:{type:String,default:"Visualizar mais"}},data(){return{internalValue:this.modelValue}},watch:{internalValue(e){this.$emit("update:modelValue",e)},modelValue(e){this.internalValue=e}},methods:{triggerExpanded(){this.internalValue=!this.internalValue}}},VO={id:"collapsible-container"},BO={class:"collapsible-container__title"},PO={key:0,class:"collapsible-container__content"};function NO(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("span",VO,[l.createElementVNode("div",{class:"collapsible-container__item",onClick:t[0]||(t[0]=(...o)=>a.triggerExpanded&&a.triggerExpanded(...o))},[l.createElementVNode("span",{class:l.normalizeClass(i.internalValue?"collapsible-container__chevron--opened":"collapsible-container__chevron--closed")},null,2),l.renderSlot(e.$slots,"title",{},()=>[l.createElementVNode("span",BO,l.toDisplayString(n.title),1)])]),i.internalValue?(l.openBlock(),l.createElementBlock("div",PO,[l.renderSlot(e.$slots,"default")])):l.createCommentVNode("",!0)])}const zO=st(AO,[["render",NO]]),Xh=e=>{var t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]:null},LO=.2126,FO=.7152,RO=.0722,HO=2.4,WO={POOR:3,GOOD:4.5,VERYGOOD:7,SUPER:12},jO=(e,t,n="GOOD")=>{let s=Xh(e),i=Xh(t);var a=av(...s),o=av(...i),c=Math.max(a,o),d=Math.min(a,o);return(c+.05)/(d+.05)>=WO[n]};function av(e,t,n){var s=[e,t,n].map(i=>(i/=255,i<=.03928?i/12.92:Math.pow((i+.055)/1.055,HO)));return s[0]*LO+s[1]*FO+s[2]*RO}const R1t="",Jh={components:{CdsPopover:Z1,CdsIcon:Me},props:{modelValue:{type:String,required:!0},label:{type:String,default:"Label"},inline:{type:Boolean,default:!1},popoverHeight:{type:Number,default:190},swatch:{type:Array,default:()=>[]}},data(){return{selectedColor:this.modelValue,sassColorVariables:oa,showPopover:!1}},computed:{iconColorResolver(){return this.ContrastChecker(this.selectedColor,"#FFFFFF","POOR")?"swatch__icon--white":"swatch__icon--black"},palete(){return this.paleteBuilder(this.sassColorVariables.palete)}},watch:{modelValue:{handler(e,t){e!==t&&(this.selectedColor=e)},immediate:!0}},methods:{paleteBuilder:Yo,ContrastChecker:jO,SwatchSelection(e){let t="";this.selectedColor=this.sassColorVariables[e.replace(/-|\$/gi,"")],this.palete.forEach(n=>{n.colorTokens.find(s=>s===e)&&(t=n.variantName.toLowerCase())}),this.$emit("update:modelValue",this.selectedColor),this.$emit("variant-chosen",t)},isCurrentColorSelected(e){return this.selectedColor===this.sassColorVariables[e.replace(/-|\$/gi,"")]}}},ov=()=>{l.useCssVars(e=>({f73e5680:e.selectedColor}))},rv=Jh.setup;Jh.setup=rv?(e,t)=>(ov(),rv(e,t)):ov;const YO=Jh,UO=e=>(l.pushScopeId("data-v-a4ff5e3b"),e=e(),l.popScopeId(),e),GO={key:0},KO={class:"color-picker__label"},ZO=["onClick"],XO={key:1},JO=[UO(()=>l.createElementVNode("div",{class:"color-picker__preview"},null,-1))],QO=["onClick"];function qO(e,t,n,s,i,a){const o=l.resolveComponent("cds-icon"),c=l.resolveComponent("cds-popover");return n.inline?(l.openBlock(),l.createElementBlock("div",GO,[l.createElementVNode("div",KO,l.toDisplayString(n.label),1),(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.swatch,(d,h)=>(l.openBlock(),l.createElementBlock("div",{key:h,class:"color-picker__container"},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(d,(f,m)=>(l.openBlock(),l.createElementBlock("div",{key:m},[l.createElementVNode("div",{class:l.normalizeClass(`color-picker__swatch--${f.replace("$","")}`),onClick:v=>a.SwatchSelection(f)},[a.isCurrentColorSelected(f)?(l.openBlock(),l.createBlock(o,{key:0,height:"22",width:"22",name:"check-outline",class:l.normalizeClass(["swatch__icon",a.iconColorResolver])},null,8,["class"])):l.createCommentVNode("",!0)],10,ZO)]))),128))]))),128))])):(l.openBlock(),l.createElementBlock("div",XO,[l.createElementVNode("div",{id:"color-picker",class:"color-picker__trigger",onClick:t[0]||(t[0]=l.withModifiers(d=>i.showPopover=!i.showPopover,["stop"]))},JO),l.createVNode(c,{modelValue:i.showPopover,"onUpdate:modelValue":t[1]||(t[1]=d=>i.showPopover=d),"right-aligned":!1,"target-id":"color-picker",height:n.popoverHeight,"fit-content-width":""},{default:l.withCtx(()=>[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.swatch,(d,h)=>(l.openBlock(),l.createElementBlock("div",{key:h,class:"popover__container"},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(d,(f,m)=>(l.openBlock(),l.createElementBlock("div",{key:m},[l.createElementVNode("div",{class:l.normalizeClass(`color-picker__swatch--${f.replace("$","")}`),onClick:v=>a.SwatchSelection(f)},[a.isCurrentColorSelected(f)?(l.openBlock(),l.createBlock(o,{key:0,height:"22",width:"22",name:"check-outline",class:l.normalizeClass(["swatch__icon",a.iconColorResolver])},null,8,["class"])):l.createCommentVNode("",!0)],10,QO)]))),128))]))),128))]),_:1},8,["modelValue","height"])]))}const $O=st(YO,[["render",qO],["__scopeId","data-v-a4ff5e3b"]]),W1t="",tM={props:{title:{type:String,default:"",required:!1},description:{type:String,default:"",required:!1},showAction:{type:Boolean,default:!1,required:!1},action:{type:String,default:"Action",required:!1},fluid:{type:Boolean,default:!1}}},eM={class:"dashboard-card"},nM={class:"dashboard-card__header"},sM={key:0,class:"dashboard-card__title"},iM={key:1,class:"dashboard-card__title"},aM={key:0,class:"dashboard-card__description"},oM={key:1,class:"dashboard-card__description"},rM={key:0};function lM(e,t,n,s,i,a){return l.openBlock(),l.createElementBlock("div",eM,[l.createElementVNode("div",null,[l.createElementVNode("div",nM,[n.title.length>0?(l.openBlock(),l.createElementBlock("p",sM,l.toDisplayString(n.title),1)):(l.openBlock(),l.createElementBlock("p",iM,[l.renderSlot(e.$slots,"title-slot",{},void 0,!0)])),l.createElementVNode("div",null,[l.renderSlot(e.$slots,"status-slot",{},void 0,!0)])]),n.description.length>0?(l.openBlock(),l.createElementBlock("p",aM,l.toDisplayString(n.description),1)):(l.openBlock(),l.createElementBlock("p",oM,[l.renderSlot(e.$slots,"description-slot",{},void 0,!0)]))]),l.createElementVNode("div",{class:"dashboard-card__action",onClick:t[0]||(t[0]=o=>e.$emit("action-button-click"))},[l.renderSlot(e.$slots,"action-slot",{},()=>[n.showAction?(l.openBlock(),l.createElementBlock("div",rM,l.toDisplayString(n.action),1)):l.createCommentVNode("",!0)],!0)])])}const cM=st(tM,[["render",lM],["__scopeId","data-v-cd0db219"]]);class Ja extends Error{}class dM extends Ja{constructor(t){super(`Invalid DateTime: ${t.toMessage()}`)}}class uM extends Ja{constructor(t){super(`Invalid Interval: ${t.toMessage()}`)}}class hM extends Ja{constructor(t){super(`Invalid Duration: ${t.toMessage()}`)}}class Bl extends Ja{}class lv extends Ja{constructor(t){super(`Invalid unit ${t}`)}}class ps extends Ja{}class ra extends Ja{constructor(){super("Zone is an abstract class")}}const it="numeric",Ws="short",Zn="long",Fd={year:it,month:it,day:it},cv={year:it,month:Ws,day:it},fM={year:it,month:Ws,day:it,weekday:Ws},dv={year:it,month:Zn,day:it},uv={year:it,month:Zn,day:it,weekday:Zn},hv={hour:it,minute:it},fv={hour:it,minute:it,second:it},pv={hour:it,minute:it,second:it,timeZoneName:Ws},mv={hour:it,minute:it,second:it,timeZoneName:Zn},gv={hour:it,minute:it,hourCycle:"h23"},vv={hour:it,minute:it,second:it,hourCycle:"h23"},_v={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:Ws},yv={hour:it,minute:it,second:it,hourCycle:"h23",timeZoneName:Zn},bv={year:it,month:it,day:it,hour:it,minute:it},wv={year:it,month:it,day:it,hour:it,minute:it,second:it},xv={year:it,month:Ws,day:it,hour:it,minute:it},Sv={year:it,month:Ws,day:it,hour:it,minute:it,second:it},pM={year:it,month:Ws,day:it,weekday:Ws,hour:it,minute:it},kv={year:it,month:Zn,day:it,hour:it,minute:it,timeZoneName:Ws},Cv={year:it,month:Zn,day:it,hour:it,minute:it,second:it,timeZoneName:Ws},Ov={year:it,month:Zn,day:it,weekday:Zn,hour:it,minute:it,timeZoneName:Zn},Mv={year:it,month:Zn,day:it,weekday:Zn,hour:it,minute:it,second:it,timeZoneName:Zn};class Pl{get type(){throw new ra}get name(){throw new ra}get ianaName(){return this.name}get isUniversal(){throw new ra}offsetName(t,n){throw new ra}formatOffset(t,n){throw new ra}offset(t){throw new ra}equals(t){throw new ra}get isValid(){throw new ra}}let Qh=null;class Rd extends Pl{static get instance(){return Qh===null&&(Qh=new Rd),Qh}get type(){return"system"}get name(){return new Intl.DateTimeFormat().resolvedOptions().timeZone}get isUniversal(){return!1}offsetName(t,{format:n,locale:s}){return Lv(t,n,s)}formatOffset(t,n){return Fl(this.offset(t),n)}offset(t){return-new Date(t).getTimezoneOffset()}equals(t){return t.type==="system"}get isValid(){return!0}}let Hd={};function mM(e){return Hd[e]||(Hd[e]=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",era:"short"})),Hd[e]}const gM={year:0,month:1,day:2,era:3,hour:4,minute:5,second:6};function vM(e,t){const n=e.format(t).replace(/\u200E/g,""),s=/(\d+)\/(\d+)\/(\d+) (AD|BC),? (\d+):(\d+):(\d+)/.exec(n),[,i,a,o,c,d,h,f]=s;return[o,i,a,c,d,h,f]}function _M(e,t){const n=e.formatToParts(t),s=[];for(let i=0;i<n.length;i++){const{type:a,value:o}=n[i],c=gM[a];a==="era"?s[c]=o:Qt(c)||(s[c]=parseInt(o,10))}return s}let Wd={};class Mi extends Pl{static create(t){return Wd[t]||(Wd[t]=new Mi(t)),Wd[t]}static resetCache(){Wd={},Hd={}}static isValidSpecifier(t){return this.isValidZone(t)}static isValidZone(t){if(!t)return!1;try{return new Intl.DateTimeFormat("en-US",{timeZone:t}).format(),!0}catch{return!1}}constructor(t){super(),this.zoneName=t,this.valid=Mi.isValidZone(t)}get type(){return"iana"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(t,{format:n,locale:s}){return Lv(t,n,s,this.name)}formatOffset(t,n){return Fl(this.offset(t),n)}offset(t){const n=new Date(t);if(isNaN(n))return NaN;const s=mM(this.name);let[i,a,o,c,d,h,f]=s.formatToParts?_M(s,n):vM(s,n);c==="BC"&&(i=-Math.abs(i)+1);const v=of({year:i,month:a,day:o,hour:d===24?0:d,minute:h,second:f,millisecond:0});let y=+n;const w=y%1e3;return y-=w>=0?w:1e3+w,(v-y)/(60*1e3)}equals(t){return t.type==="iana"&&t.name===this.name}get isValid(){return this.valid}}let Dv={};function yM(e,t={}){const n=JSON.stringify([e,t]);let s=Dv[n];return s||(s=new Intl.ListFormat(e,t),Dv[n]=s),s}let qh={};function $h(e,t={}){const n=JSON.stringify([e,t]);let s=qh[n];return s||(s=new Intl.DateTimeFormat(e,t),qh[n]=s),s}let tf={};function bM(e,t={}){const n=JSON.stringify([e,t]);let s=tf[n];return s||(s=new Intl.NumberFormat(e,t),tf[n]=s),s}let ef={};function wM(e,t={}){const{base:n,...s}=t,i=JSON.stringify([e,s]);let a=ef[i];return a||(a=new Intl.RelativeTimeFormat(e,t),ef[i]=a),a}let Nl=null;function xM(){return Nl||(Nl=new Intl.DateTimeFormat().resolvedOptions().locale,Nl)}function SM(e){const t=e.indexOf("-x-");t!==-1&&(e=e.substring(0,t));const n=e.indexOf("-u-");if(n===-1)return[e];{let s,i;try{s=$h(e).resolvedOptions(),i=e}catch{const d=e.substring(0,n);s=$h(d).resolvedOptions(),i=d}const{numberingSystem:a,calendar:o}=s;return[i,a,o]}}function kM(e,t,n){return(n||t)&&(e.includes("-u-")||(e+="-u"),n&&(e+=`-ca-${n}`),t&&(e+=`-nu-${t}`)),e}function CM(e){const t=[];for(let n=1;n<=12;n++){const s=St.utc(2016,n,1);t.push(e(s))}return t}function OM(e){const t=[];for(let n=1;n<=7;n++){const s=St.utc(2016,11,13+n);t.push(e(s))}return t}function jd(e,t,n,s,i){const a=e.listingMode(n);return a==="error"?null:a==="en"?s(t):i(t)}function MM(e){return e.numberingSystem&&e.numberingSystem!=="latn"?!1:e.numberingSystem==="latn"||!e.locale||e.locale.startsWith("en")||new Intl.DateTimeFormat(e.intl).resolvedOptions().numberingSystem==="latn"}class DM{constructor(t,n,s){this.padTo=s.padTo||0,this.floor=s.floor||!1;const{padTo:i,floor:a,...o}=s;if(!n||Object.keys(o).length>0){const c={useGrouping:!1,...s};s.padTo>0&&(c.minimumIntegerDigits=s.padTo),this.inf=bM(t,c)}}format(t){if(this.inf){const n=this.floor?Math.floor(t):t;return this.inf.format(n)}else{const n=this.floor?Math.floor(t):af(t,3);return Ye(n,this.padTo)}}}class EM{constructor(t,n,s){this.opts=s;let i;if(t.zone.isUniversal){const o=-1*(t.offset/60),c=o>=0?`Etc/GMT+${o}`:`Etc/GMT${o}`;t.offset!==0&&Mi.create(c).valid?(i=c,this.dt=t):(i="UTC",s.timeZoneName?this.dt=t:this.dt=t.offset===0?t:St.fromMillis(t.ts+t.offset*60*1e3))}else t.zone.type==="system"?this.dt=t:(this.dt=t,i=t.zone.name);const a={...this.opts};a.timeZone=a.timeZone||i,this.dtf=$h(n,a)}format(){return this.dtf.format(this.dt.toJSDate())}formatToParts(){return this.dtf.formatToParts(this.dt.toJSDate())}resolvedOptions(){return this.dtf.resolvedOptions()}}class TM{constructor(t,n,s){this.opts={style:"long",...s},!n&&Nv()&&(this.rtf=wM(t,s))}format(t,n){return this.rtf?this.rtf.format(t,n):KM(n,t,this.opts.numeric,this.opts.style!=="long")}formatToParts(t,n){return this.rtf?this.rtf.formatToParts(t,n):[]}}class Ce{static fromOpts(t){return Ce.create(t.locale,t.numberingSystem,t.outputCalendar,t.defaultToEN)}static create(t,n,s,i=!1){const a=t||je.defaultLocale,o=a||(i?"en-US":xM()),c=n||je.defaultNumberingSystem,d=s||je.defaultOutputCalendar;return new Ce(o,c,d,a)}static resetCache(){Nl=null,qh={},tf={},ef={}}static fromObject({locale:t,numberingSystem:n,outputCalendar:s}={}){return Ce.create(t,n,s)}constructor(t,n,s,i){const[a,o,c]=SM(t);this.locale=a,this.numberingSystem=n||o||null,this.outputCalendar=s||c||null,this.intl=kM(this.locale,this.numberingSystem,this.outputCalendar),this.weekdaysCache={format:{},standalone:{}},this.monthsCache={format:{},standalone:{}},this.meridiemCache=null,this.eraCache={},this.specifiedLocale=i,this.fastNumbersCached=null}get fastNumbers(){return this.fastNumbersCached==null&&(this.fastNumbersCached=MM(this)),this.fastNumbersCached}listingMode(){const t=this.isEnglish(),n=(this.numberingSystem===null||this.numberingSystem==="latn")&&(this.outputCalendar===null||this.outputCalendar==="gregory");return t&&n?"en":"intl"}clone(t){return!t||Object.getOwnPropertyNames(t).length===0?this:Ce.create(t.locale||this.specifiedLocale,t.numberingSystem||this.numberingSystem,t.outputCalendar||this.outputCalendar,t.defaultToEN||!1)}redefaultToEN(t={}){return this.clone({...t,defaultToEN:!0})}redefaultToSystem(t={}){return this.clone({...t,defaultToEN:!1})}months(t,n=!1,s=!0){return jd(this,t,s,Hv,()=>{const i=n?{month:t,day:"numeric"}:{month:t},a=n?"format":"standalone";return this.monthsCache[a][t]||(this.monthsCache[a][t]=CM(o=>this.extract(o,i,"month"))),this.monthsCache[a][t]})}weekdays(t,n=!1,s=!0){return jd(this,t,s,Yv,()=>{const i=n?{weekday:t,year:"numeric",month:"long",day:"numeric"}:{weekday:t},a=n?"format":"standalone";return this.weekdaysCache[a][t]||(this.weekdaysCache[a][t]=OM(o=>this.extract(o,i,"weekday"))),this.weekdaysCache[a][t]})}meridiems(t=!0){return jd(this,void 0,t,()=>Uv,()=>{if(!this.meridiemCache){const n={hour:"numeric",hourCycle:"h12"};this.meridiemCache=[St.utc(2016,11,13,9),St.utc(2016,11,13,19)].map(s=>this.extract(s,n,"dayperiod"))}return this.meridiemCache})}eras(t,n=!0){return jd(this,t,n,Gv,()=>{const s={era:t};return this.eraCache[t]||(this.eraCache[t]=[St.utc(-40,1,1),St.utc(2017,1,1)].map(i=>this.extract(i,s,"era"))),this.eraCache[t]})}extract(t,n,s){const i=this.dtFormatter(t,n),a=i.formatToParts(),o=a.find(c=>c.type.toLowerCase()===s);return o?o.value:null}numberFormatter(t={}){return new DM(this.intl,t.forceSimple||this.fastNumbers,t)}dtFormatter(t,n={}){return new EM(t,this.intl,n)}relFormatter(t={}){return new TM(this.intl,this.isEnglish(),t)}listFormatter(t={}){return yM(this.intl,t)}isEnglish(){return this.locale==="en"||this.locale.toLowerCase()==="en-us"||new Intl.DateTimeFormat(this.intl).resolvedOptions().locale.startsWith("en-us")}equals(t){return this.locale===t.locale&&this.numberingSystem===t.numberingSystem&&this.outputCalendar===t.outputCalendar}}let nf=null;class xn extends Pl{static get utcInstance(){return nf===null&&(nf=new xn(0)),nf}static instance(t){return t===0?xn.utcInstance:new xn(t)}static parseSpecifier(t){if(t){const n=t.match(/^utc(?:([+-]\d{1,2})(?::(\d{2}))?)?$/i);if(n)return new xn(Kd(n[1],n[2]))}return null}constructor(t){super(),this.fixed=t}get type(){return"fixed"}get name(){return this.fixed===0?"UTC":`UTC${Fl(this.fixed,"narrow")}`}get ianaName(){return this.fixed===0?"Etc/UTC":`Etc/GMT${Fl(-this.fixed,"narrow")}`}offsetName(){return this.name}formatOffset(t,n){return Fl(this.fixed,n)}get isUniversal(){return!0}offset(){return this.fixed}equals(t){return t.type==="fixed"&&t.fixed===this.fixed}get isValid(){return!0}}class IM extends Pl{constructor(t){super(),this.zoneName=t}get type(){return"invalid"}get name(){return this.zoneName}get isUniversal(){return!1}offsetName(){return null}formatOffset(){return""}offset(){return NaN}equals(){return!1}get isValid(){return!1}}function la(e,t){if(Qt(e)||e===null)return t;if(e instanceof Pl)return e;if(AM(e)){const n=e.toLowerCase();return n==="default"?t:n==="local"||n==="system"?Rd.instance:n==="utc"||n==="gmt"?xn.utcInstance:xn.parseSpecifier(n)||Mi.create(e)}else return Qa(e)?xn.instance(e):typeof e=="object"&&e.offset&&typeof e.offset=="number"?e:new IM(e)}let Ev=()=>Date.now(),Tv="system",Iv=null,Av=null,Vv=null,Bv=60,Pv;class je{static get now(){return Ev}static set now(t){Ev=t}static set defaultZone(t){Tv=t}static get defaultZone(){return la(Tv,Rd.instance)}static get defaultLocale(){return Iv}static set defaultLocale(t){Iv=t}static get defaultNumberingSystem(){return Av}static set defaultNumberingSystem(t){Av=t}static get defaultOutputCalendar(){return Vv}static set defaultOutputCalendar(t){Vv=t}static get twoDigitCutoffYear(){return Bv}static set twoDigitCutoffYear(t){Bv=t%100}static get throwOnInvalid(){return Pv}static set throwOnInvalid(t){Pv=t}static resetCaches(){Ce.resetCache(),Mi.resetCache()}}function Qt(e){return typeof e>"u"}function Qa(e){return typeof e=="number"}function Yd(e){return typeof e=="number"&&e%1===0}function AM(e){return typeof e=="string"}function VM(e){return Object.prototype.toString.call(e)==="[object Date]"}function Nv(){try{return typeof Intl<"u"&&!!Intl.RelativeTimeFormat}catch{return!1}}function BM(e){return Array.isArray(e)?e:[e]}function zv(e,t,n){if(e.length!==0)return e.reduce((s,i)=>{const a=[t(i),i];return s&&n(s[0],a[0])===s[0]?s:a},null)[1]}function PM(e,t){return t.reduce((n,s)=>(n[s]=e[s],n),{})}function Uo(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function Di(e,t,n){return Yd(e)&&e>=t&&e<=n}function NM(e,t){return e-t*Math.floor(e/t)}function Ye(e,t=2){const n=e<0;let s;return n?s="-"+(""+-e).padStart(t,"0"):s=(""+e).padStart(t,"0"),s}function ca(e){if(!(Qt(e)||e===null||e===""))return parseInt(e,10)}function qa(e){if(!(Qt(e)||e===null||e===""))return parseFloat(e)}function sf(e){if(!(Qt(e)||e===null||e==="")){const t=parseFloat("0."+e)*1e3;return Math.floor(t)}}function af(e,t,n=!1){const s=10**t;return(n?Math.trunc:Math.round)(e*s)/s}function zl(e){return e%4===0&&(e%100!==0||e%400===0)}function Ll(e){return zl(e)?366:365}function Ud(e,t){const n=NM(t-1,12)+1,s=e+(t-n)/12;return n===2?zl(s)?29:28:[31,null,31,30,31,30,31,31,30,31,30,31][n-1]}function of(e){let t=Date.UTC(e.year,e.month-1,e.day,e.hour,e.minute,e.second,e.millisecond);return e.year<100&&e.year>=0&&(t=new Date(t),t.setUTCFullYear(t.getUTCFullYear()-1900)),+t}function Gd(e){const t=(e+Math.floor(e/4)-Math.floor(e/100)+Math.floor(e/400))%7,n=e-1,s=(n+Math.floor(n/4)-Math.floor(n/100)+Math.floor(n/400))%7;return t===4||s===3?53:52}function rf(e){return e>99?e:e>je.twoDigitCutoffYear?1900+e:2e3+e}function Lv(e,t,n,s=null){const i=new Date(e),a={hourCycle:"h23",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit"};s&&(a.timeZone=s);const o={timeZoneName:t,...a},c=new Intl.DateTimeFormat(n,o).formatToParts(i).find(d=>d.type.toLowerCase()==="timezonename");return c?c.value:null}function Kd(e,t){let n=parseInt(e,10);Number.isNaN(n)&&(n=0);const s=parseInt(t,10)||0,i=n<0||Object.is(n,-0)?-s:s;return n*60+i}function Fv(e){const t=Number(e);if(typeof e=="boolean"||e===""||Number.isNaN(t))throw new ps(`Invalid unit value ${e}`);return t}function Zd(e,t){const n={};for(const s in e)if(Uo(e,s)){const i=e[s];if(i==null)continue;n[t(s)]=Fv(i)}return n}function Fl(e,t){const n=Math.trunc(Math.abs(e/60)),s=Math.trunc(Math.abs(e%60)),i=e>=0?"+":"-";switch(t){case"short":return`${i}${Ye(n,2)}:${Ye(s,2)}`;case"narrow":return`${i}${n}${s>0?`:${s}`:""}`;case"techie":return`${i}${Ye(n,2)}${Ye(s,2)}`;default:throw new RangeError(`Value format ${t} is out of range for property format`)}}function Xd(e){return PM(e,["hour","minute","second","millisecond"])}const zM=["January","February","March","April","May","June","July","August","September","October","November","December"],Rv=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],LM=["J","F","M","A","M","J","J","A","S","O","N","D"];function Hv(e){switch(e){case"narrow":return[...LM];case"short":return[...Rv];case"long":return[...zM];case"numeric":return["1","2","3","4","5","6","7","8","9","10","11","12"];case"2-digit":return["01","02","03","04","05","06","07","08","09","10","11","12"];default:return null}}const Wv=["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],jv=["Mon","Tue","Wed","Thu","Fri","Sat","Sun"],FM=["M","T","W","T","F","S","S"];function Yv(e){switch(e){case"narrow":return[...FM];case"short":return[...jv];case"long":return[...Wv];case"numeric":return["1","2","3","4","5","6","7"];default:return null}}const Uv=["AM","PM"],RM=["Before Christ","Anno Domini"],HM=["BC","AD"],WM=["B","A"];function Gv(e){switch(e){case"narrow":return[...WM];case"short":return[...HM];case"long":return[...RM];default:return null}}function jM(e){return Uv[e.hour<12?0:1]}function YM(e,t){return Yv(t)[e.weekday-1]}function UM(e,t){return Hv(t)[e.month-1]}function GM(e,t){return Gv(t)[e.year<0?0:1]}function KM(e,t,n="always",s=!1){const i={years:["year","yr."],quarters:["quarter","qtr."],months:["month","mo."],weeks:["week","wk."],days:["day","day","days"],hours:["hour","hr."],minutes:["minute","min."],seconds:["second","sec."]},a=["hours","minutes","seconds"].indexOf(e)===-1;if(n==="auto"&&a){const m=e==="days";switch(t){case 1:return m?"tomorrow":`next ${i[e][0]}`;case-1:return m?"yesterday":`last ${i[e][0]}`;case 0:return m?"today":`this ${i[e][0]}`}}const o=Object.is(t,-0)||t<0,c=Math.abs(t),d=c===1,h=i[e],f=s?d?h[1]:h[2]||h[1]:d?i[e][0]:e;return o?`${c} ${f} ago`:`in ${c} ${f}`}function Kv(e,t){let n="";for(const s of e)s.literal?n+=s.val:n+=t(s.val);return n}const ZM={D:Fd,DD:cv,DDD:dv,DDDD:uv,t:hv,tt:fv,ttt:pv,tttt:mv,T:gv,TT:vv,TTT:_v,TTTT:yv,f:bv,ff:xv,fff:kv,ffff:Ov,F:wv,FF:Sv,FFF:Cv,FFFF:Mv};class gn{static create(t,n={}){return new gn(t,n)}static parseFormat(t){let n=null,s="",i=!1;const a=[];for(let o=0;o<t.length;o++){const c=t.charAt(o);c==="'"?(s.length>0&&a.push({literal:i,val:s}),n=null,s="",i=!i):i||c===n?s+=c:(s.length>0&&a.push({literal:!1,val:s}),s=c,n=c)}return s.length>0&&a.push({literal:i,val:s}),a}static macroTokenToFormatOpts(t){return ZM[t]}constructor(t,n){this.opts=n,this.loc=t,this.systemLoc=null}formatWithSystemDefault(t,n){return this.systemLoc===null&&(this.systemLoc=this.loc.redefaultToSystem()),this.systemLoc.dtFormatter(t,{...this.opts,...n}).format()}formatDateTime(t,n={}){return this.loc.dtFormatter(t,{...this.opts,...n}).format()}formatDateTimeParts(t,n={}){return this.loc.dtFormatter(t,{...this.opts,...n}).formatToParts()}formatInterval(t,n={}){return this.loc.dtFormatter(t.start,{...this.opts,...n}).dtf.formatRange(t.start.toJSDate(),t.end.toJSDate())}resolvedOptions(t,n={}){return this.loc.dtFormatter(t,{...this.opts,...n}).resolvedOptions()}num(t,n=0){if(this.opts.forceSimple)return Ye(t,n);const s={...this.opts};return n>0&&(s.padTo=n),this.loc.numberFormatter(s).format(t)}formatDateTimeFromString(t,n){const s=this.loc.listingMode()==="en",i=this.loc.outputCalendar&&this.loc.outputCalendar!=="gregory",a=(y,w)=>this.loc.extract(t,y,w),o=y=>t.isOffsetFixed&&t.offset===0&&y.allowZ?"Z":t.isValid?t.zone.formatOffset(t.ts,y.format):"",c=()=>s?jM(t):a({hour:"numeric",hourCycle:"h12"},"dayperiod"),d=(y,w)=>s?UM(t,y):a(w?{month:y}:{month:y,day:"numeric"},"month"),h=(y,w)=>s?YM(t,y):a(w?{weekday:y}:{weekday:y,month:"long",day:"numeric"},"weekday"),f=y=>{const w=gn.macroTokenToFormatOpts(y);return w?this.formatWithSystemDefault(t,w):y},m=y=>s?GM(t,y):a({era:y},"era"),v=y=>{switch(y){case"S":return this.num(t.millisecond);case"u":case"SSS":return this.num(t.millisecond,3);case"s":return this.num(t.second);case"ss":return this.num(t.second,2);case"uu":return this.num(Math.floor(t.millisecond/10),2);case"uuu":return this.num(Math.floor(t.millisecond/100));case"m":return this.num(t.minute);case"mm":return this.num(t.minute,2);case"h":return this.num(t.hour%12===0?12:t.hour%12);case"hh":return this.num(t.hour%12===0?12:t.hour%12,2);case"H":return this.num(t.hour);case"HH":return this.num(t.hour,2);case"Z":return o({format:"narrow",allowZ:this.opts.allowZ});case"ZZ":return o({format:"short",allowZ:this.opts.allowZ});case"ZZZ":return o({format:"techie",allowZ:this.opts.allowZ});case"ZZZZ":return t.zone.offsetName(t.ts,{format:"short",locale:this.loc.locale});case"ZZZZZ":return t.zone.offsetName(t.ts,{format:"long",locale:this.loc.locale});case"z":return t.zoneName;case"a":return c();case"d":return i?a({day:"numeric"},"day"):this.num(t.day);case"dd":return i?a({day:"2-digit"},"day"):this.num(t.day,2);case"c":return this.num(t.weekday);case"ccc":return h("short",!0);case"cccc":return h("long",!0);case"ccccc":return h("narrow",!0);case"E":return this.num(t.weekday);case"EEE":return h("short",!1);case"EEEE":return h("long",!1);case"EEEEE":return h("narrow",!1);case"L":return i?a({month:"numeric",day:"numeric"},"month"):this.num(t.month);case"LL":return i?a({month:"2-digit",day:"numeric"},"month"):this.num(t.month,2);case"LLL":return d("short",!0);case"LLLL":return d("long",!0);case"LLLLL":return d("narrow",!0);case"M":return i?a({month:"numeric"},"month"):this.num(t.month);case"MM":return i?a({month:"2-digit"},"month"):this.num(t.month,2);case"MMM":return d("short",!1);case"MMMM":return d("long",!1);case"MMMMM":return d("narrow",!1);case"y":return i?a({year:"numeric"},"year"):this.num(t.year);case"yy":return i?a({year:"2-digit"},"year"):this.num(t.year.toString().slice(-2),2);case"yyyy":return i?a({year:"numeric"},"year"):this.num(t.year,4);case"yyyyyy":return i?a({year:"numeric"},"year"):this.num(t.year,6);case"G":return m("short");case"GG":return m("long");case"GGGGG":return m("narrow");case"kk":return this.num(t.weekYear.toString().slice(-2),2);case"kkkk":return this.num(t.weekYear,4);case"W":return this.num(t.weekNumber);case"WW":return this.num(t.weekNumber,2);case"o":return this.num(t.ordinal);case"ooo":return this.num(t.ordinal,3);case"q":return this.num(t.quarter);case"qq":return this.num(t.quarter,2);case"X":return this.num(Math.floor(t.ts/1e3));case"x":return this.num(t.ts);default:return f(y)}};return Kv(gn.parseFormat(n),v)}formatDurationFromString(t,n){const s=d=>{switch(d[0]){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":return"hour";case"d":return"day";case"w":return"week";case"M":return"month";case"y":return"year";default:return null}},i=d=>h=>{const f=s(h);return f?this.num(d.get(f),h.length):h},a=gn.parseFormat(n),o=a.reduce((d,{literal:h,val:f})=>h?d:d.concat(f),[]),c=t.shiftTo(...o.map(s).filter(d=>d));return Kv(a,i(c))}}class js{constructor(t,n){this.reason=t,this.explanation=n}toMessage(){return this.explanation?`${this.reason}: ${this.explanation}`:this.reason}}const Zv=/[A-Za-z_+-]{1,256}(?::?\/[A-Za-z0-9_+-]{1,256}(?:\/[A-Za-z0-9_+-]{1,256})?)?/;function Go(...e){const t=e.reduce((n,s)=>n+s.source,"");return RegExp(`^${t}$`)}function Ko(...e){return t=>e.reduce(([n,s,i],a)=>{const[o,c,d]=a(t,i);return[{...n,...o},c||s,d]},[{},null,1]).slice(0,2)}function Zo(e,...t){if(e==null)return[null,null];for(const[n,s]of t){const i=n.exec(e);if(i)return s(i)}return[null,null]}function Xv(...e){return(t,n)=>{const s={};let i;for(i=0;i<e.length;i++)s[e[i]]=ca(t[n+i]);return[s,null,n+i]}}const Jv=/(?:(Z)|([+-]\d\d)(?::?(\d\d))?)/,XM=`(?:${Jv.source}?(?:\\[(${Zv.source})\\])?)?`,lf=/(\d\d)(?::?(\d\d)(?::?(\d\d)(?:[.,](\d{1,30}))?)?)?/,Qv=RegExp(`${lf.source}${XM}`),cf=RegExp(`(?:T${Qv.source})?`),JM=/([+-]\d{6}|\d{4})(?:-?(\d\d)(?:-?(\d\d))?)?/,QM=/(\d{4})-?W(\d\d)(?:-?(\d))?/,qM=/(\d{4})-?(\d{3})/,$M=Xv("weekYear","weekNumber","weekDay"),tD=Xv("year","ordinal"),eD=/(\d{4})-(\d\d)-(\d\d)/,qv=RegExp(`${lf.source} ?(?:${Jv.source}|(${Zv.source}))?`),nD=RegExp(`(?: ${qv.source})?`);function Xo(e,t,n){const s=e[t];return Qt(s)?n:ca(s)}function sD(e,t){return[{year:Xo(e,t),month:Xo(e,t+1,1),day:Xo(e,t+2,1)},null,t+3]}function Jo(e,t){return[{hours:Xo(e,t,0),minutes:Xo(e,t+1,0),seconds:Xo(e,t+2,0),milliseconds:sf(e[t+3])},null,t+4]}function Rl(e,t){const n=!e[t]&&!e[t+1],s=Kd(e[t+1],e[t+2]),i=n?null:xn.instance(s);return[{},i,t+3]}function Hl(e,t){const n=e[t]?Mi.create(e[t]):null;return[{},n,t+1]}const iD=RegExp(`^T?${lf.source}$`),aD=/^-?P(?:(?:(-?\d{1,20}(?:\.\d{1,20})?)Y)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20}(?:\.\d{1,20})?)W)?(?:(-?\d{1,20}(?:\.\d{1,20})?)D)?(?:T(?:(-?\d{1,20}(?:\.\d{1,20})?)H)?(?:(-?\d{1,20}(?:\.\d{1,20})?)M)?(?:(-?\d{1,20})(?:[.,](-?\d{1,20}))?S)?)?)$/;function oD(e){const[t,n,s,i,a,o,c,d,h]=e,f=t[0]==="-",m=d&&d[0]==="-",v=(y,w=!1)=>y!==void 0&&(w||y&&f)?-y:y;return[{years:v(qa(n)),months:v(qa(s)),weeks:v(qa(i)),days:v(qa(a)),hours:v(qa(o)),minutes:v(qa(c)),seconds:v(qa(d),d==="-0"),milliseconds:v(sf(h),m)}]}const rD={GMT:0,EDT:-4*60,EST:-5*60,CDT:-5*60,CST:-6*60,MDT:-6*60,MST:-7*60,PDT:-7*60,PST:-8*60};function df(e,t,n,s,i,a,o){const c={year:t.length===2?rf(ca(t)):ca(t),month:Rv.indexOf(n)+1,day:ca(s),hour:ca(i),minute:ca(a)};return o&&(c.second=ca(o)),e&&(c.weekday=e.length>3?Wv.indexOf(e)+1:jv.indexOf(e)+1),c}const lD=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|(?:([+-]\d\d)(\d\d)))$/;function cD(e){const[,t,n,s,i,a,o,c,d,h,f,m]=e,v=df(t,i,s,n,a,o,c);let y;return d?y=rD[d]:h?y=0:y=Kd(f,m),[v,new xn(y)]}function dD(e){return e.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").trim()}const uD=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun), (\d\d) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) (\d{4}) (\d\d):(\d\d):(\d\d) GMT$/,hD=/^(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday), (\d\d)-(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)-(\d\d) (\d\d):(\d\d):(\d\d) GMT$/,fD=/^(Mon|Tue|Wed|Thu|Fri|Sat|Sun) (Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec) ( \d|\d\d) (\d\d):(\d\d):(\d\d) (\d{4})$/;function $v(e){const[,t,n,s,i,a,o,c]=e;return[df(t,i,s,n,a,o,c),xn.utcInstance]}function pD(e){const[,t,n,s,i,a,o,c]=e;return[df(t,c,n,s,i,a,o),xn.utcInstance]}const mD=Go(JM,cf),gD=Go(QM,cf),vD=Go(qM,cf),_D=Go(Qv),t3=Ko(sD,Jo,Rl,Hl),yD=Ko($M,Jo,Rl,Hl),bD=Ko(tD,Jo,Rl,Hl),wD=Ko(Jo,Rl,Hl);function xD(e){return Zo(e,[mD,t3],[gD,yD],[vD,bD],[_D,wD])}function SD(e){return Zo(dD(e),[lD,cD])}function kD(e){return Zo(e,[uD,$v],[hD,$v],[fD,pD])}function CD(e){return Zo(e,[aD,oD])}const OD=Ko(Jo);function MD(e){return Zo(e,[iD,OD])}const DD=Go(eD,nD),ED=Go(qv),TD=Ko(Jo,Rl,Hl);function ID(e){return Zo(e,[DD,t3],[ED,TD])}const AD="Invalid Duration",e3={weeks:{days:7,hours:7*24,minutes:7*24*60,seconds:7*24*60*60,milliseconds:7*24*60*60*1e3},days:{hours:24,minutes:24*60,seconds:24*60*60,milliseconds:24*60*60*1e3},hours:{minutes:60,seconds:60*60,milliseconds:60*60*1e3},minutes:{seconds:60,milliseconds:60*1e3},seconds:{milliseconds:1e3}},VD={years:{quarters:4,months:12,weeks:52,days:365,hours:365*24,minutes:365*24*60,seconds:365*24*60*60,milliseconds:365*24*60*60*1e3},quarters:{months:3,weeks:13,days:91,hours:91*24,minutes:91*24*60,seconds:91*24*60*60,milliseconds:91*24*60*60*1e3},months:{weeks:4,days:30,hours:30*24,minutes:30*24*60,seconds:30*24*60*60,milliseconds:30*24*60*60*1e3},...e3},ms=146097/400,Qo=146097/4800,BD={years:{quarters:4,months:12,weeks:ms/7,days:ms,hours:ms*24,minutes:ms*24*60,seconds:ms*24*60*60,milliseconds:ms*24*60*60*1e3},quarters:{months:3,weeks:ms/28,days:ms/4,hours:ms*24/4,minutes:ms*24*60/4,seconds:ms*24*60*60/4,milliseconds:ms*24*60*60*1e3/4},months:{weeks:Qo/7,days:Qo,hours:Qo*24,minutes:Qo*24*60,seconds:Qo*24*60*60,milliseconds:Qo*24*60*60*1e3},...e3},$a=["years","quarters","months","weeks","days","hours","minutes","seconds","milliseconds"],PD=$a.slice(0).reverse();function da(e,t,n=!1){const s={values:n?t.values:{...e.values,...t.values||{}},loc:e.loc.clone(t.loc),conversionAccuracy:t.conversionAccuracy||e.conversionAccuracy,matrix:t.matrix||e.matrix};return new ne(s)}function ND(e){return e<0?Math.floor(e):Math.ceil(e)}function n3(e,t,n,s,i){const a=e[i][n],o=t[n]/a,c=Math.sign(o)===Math.sign(s[i]),d=!c&&s[i]!==0&&Math.abs(o)<=1?ND(o):Math.trunc(o);s[i]+=d,t[n]-=d*a}function zD(e,t){PD.reduce((n,s)=>Qt(t[s])?n:(n&&n3(e,t,n,t,s),s),null)}function LD(e){const t={};for(const[n,s]of Object.entries(e))s!==0&&(t[n]=s);return t}class ne{constructor(t){const n=t.conversionAccuracy==="longterm"||!1;let s=n?BD:VD;t.matrix&&(s=t.matrix),this.values=t.values,this.loc=t.loc||Ce.create(),this.conversionAccuracy=n?"longterm":"casual",this.invalid=t.invalid||null,this.matrix=s,this.isLuxonDuration=!0}static fromMillis(t,n){return ne.fromObject({milliseconds:t},n)}static fromObject(t,n={}){if(t==null||typeof t!="object")throw new ps(`Duration.fromObject: argument expected to be an object, got ${t===null?"null":typeof t}`);return new ne({values:Zd(t,ne.normalizeUnit),loc:Ce.fromObject(n),conversionAccuracy:n.conversionAccuracy,matrix:n.matrix})}static fromDurationLike(t){if(Qa(t))return ne.fromMillis(t);if(ne.isDuration(t))return t;if(typeof t=="object")return ne.fromObject(t);throw new ps(`Unknown duration argument ${t} of type ${typeof t}`)}static fromISO(t,n){const[s]=CD(t);return s?ne.fromObject(s,n):ne.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static fromISOTime(t,n){const[s]=MD(t);return s?ne.fromObject(s,n):ne.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static invalid(t,n=null){if(!t)throw new ps("need to specify a reason the Duration is invalid");const s=t instanceof js?t:new js(t,n);if(je.throwOnInvalid)throw new hM(s);return new ne({invalid:s})}static normalizeUnit(t){const n={year:"years",years:"years",quarter:"quarters",quarters:"quarters",month:"months",months:"months",week:"weeks",weeks:"weeks",day:"days",days:"days",hour:"hours",hours:"hours",minute:"minutes",minutes:"minutes",second:"seconds",seconds:"seconds",millisecond:"milliseconds",milliseconds:"milliseconds"}[t&&t.toLowerCase()];if(!n)throw new lv(t);return n}static isDuration(t){return t&&t.isLuxonDuration||!1}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}toFormat(t,n={}){const s={...n,floor:n.round!==!1&&n.floor!==!1};return this.isValid?gn.create(this.loc,s).formatDurationFromString(this,t):AD}toHuman(t={}){const n=$a.map(s=>{const i=this.values[s];return Qt(i)?null:this.loc.numberFormatter({style:"unit",unitDisplay:"long",...t,unit:s.slice(0,-1)}).format(i)}).filter(s=>s);return this.loc.listFormatter({type:"conjunction",style:t.listStyle||"narrow",...t}).format(n)}toObject(){return this.isValid?{...this.values}:{}}toISO(){if(!this.isValid)return null;let t="P";return this.years!==0&&(t+=this.years+"Y"),(this.months!==0||this.quarters!==0)&&(t+=this.months+this.quarters*3+"M"),this.weeks!==0&&(t+=this.weeks+"W"),this.days!==0&&(t+=this.days+"D"),(this.hours!==0||this.minutes!==0||this.seconds!==0||this.milliseconds!==0)&&(t+="T"),this.hours!==0&&(t+=this.hours+"H"),this.minutes!==0&&(t+=this.minutes+"M"),(this.seconds!==0||this.milliseconds!==0)&&(t+=af(this.seconds+this.milliseconds/1e3,3)+"S"),t==="P"&&(t+="T0S"),t}toISOTime(t={}){if(!this.isValid)return null;const n=this.toMillis();if(n<0||n>=864e5)return null;t={suppressMilliseconds:!1,suppressSeconds:!1,includePrefix:!1,format:"extended",...t};const s=this.shiftTo("hours","minutes","seconds","milliseconds");let i=t.format==="basic"?"hhmm":"hh:mm";(!t.suppressSeconds||s.seconds!==0||s.milliseconds!==0)&&(i+=t.format==="basic"?"ss":":ss",(!t.suppressMilliseconds||s.milliseconds!==0)&&(i+=".SSS"));let a=s.toFormat(i);return t.includePrefix&&(a="T"+a),a}toJSON(){return this.toISO()}toString(){return this.toISO()}toMillis(){return this.as("milliseconds")}valueOf(){return this.toMillis()}plus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t),s={};for(const i of $a)(Uo(n.values,i)||Uo(this.values,i))&&(s[i]=n.get(i)+this.get(i));return da(this,{values:s},!0)}minus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t);return this.plus(n.negate())}mapUnits(t){if(!this.isValid)return this;const n={};for(const s of Object.keys(this.values))n[s]=Fv(t(this.values[s],s));return da(this,{values:n},!0)}get(t){return this[ne.normalizeUnit(t)]}set(t){if(!this.isValid)return this;const n={...this.values,...Zd(t,ne.normalizeUnit)};return da(this,{values:n})}reconfigure({locale:t,numberingSystem:n,conversionAccuracy:s,matrix:i}={}){const o={loc:this.loc.clone({locale:t,numberingSystem:n}),matrix:i,conversionAccuracy:s};return da(this,o)}as(t){return this.isValid?this.shiftTo(t).get(t):NaN}normalize(){if(!this.isValid)return this;const t=this.toObject();return zD(this.matrix,t),da(this,{values:t},!0)}rescale(){if(!this.isValid)return this;const t=LD(this.normalize().shiftToAll().toObject());return da(this,{values:t},!0)}shiftTo(...t){if(!this.isValid)return this;if(t.length===0)return this;t=t.map(o=>ne.normalizeUnit(o));const n={},s={},i=this.toObject();let a;for(const o of $a)if(t.indexOf(o)>=0){a=o;let c=0;for(const h in s)c+=this.matrix[h][o]*s[h],s[h]=0;Qa(i[o])&&(c+=i[o]);const d=Math.trunc(c);n[o]=d,s[o]=(c*1e3-d*1e3)/1e3;for(const h in i)$a.indexOf(h)>$a.indexOf(o)&&n3(this.matrix,i,h,n,o)}else Qa(i[o])&&(s[o]=i[o]);for(const o in s)s[o]!==0&&(n[a]+=o===a?s[o]:s[o]/this.matrix[a][o]);return da(this,{values:n},!0).normalize()}shiftToAll(){return this.isValid?this.shiftTo("years","months","weeks","days","hours","minutes","seconds","milliseconds"):this}negate(){if(!this.isValid)return this;const t={};for(const n of Object.keys(this.values))t[n]=this.values[n]===0?0:-this.values[n];return da(this,{values:t},!0)}get years(){return this.isValid?this.values.years||0:NaN}get quarters(){return this.isValid?this.values.quarters||0:NaN}get months(){return this.isValid?this.values.months||0:NaN}get weeks(){return this.isValid?this.values.weeks||0:NaN}get days(){return this.isValid?this.values.days||0:NaN}get hours(){return this.isValid?this.values.hours||0:NaN}get minutes(){return this.isValid?this.values.minutes||0:NaN}get seconds(){return this.isValid?this.values.seconds||0:NaN}get milliseconds(){return this.isValid?this.values.milliseconds||0:NaN}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}equals(t){if(!this.isValid||!t.isValid||!this.loc.equals(t.loc))return!1;function n(s,i){return s===void 0||s===0?i===void 0||i===0:s===i}for(const s of $a)if(!n(this.values[s],t.values[s]))return!1;return!0}}const qo="Invalid Interval";function FD(e,t){return!e||!e.isValid?Ae.invalid("missing or invalid start"):!t||!t.isValid?Ae.invalid("missing or invalid end"):t<e?Ae.invalid("end before start",`The end of an interval must be after its start, but you had start=${e.toISO()} and end=${t.toISO()}`):null}class Ae{constructor(t){this.s=t.start,this.e=t.end,this.invalid=t.invalid||null,this.isLuxonInterval=!0}static invalid(t,n=null){if(!t)throw new ps("need to specify a reason the Interval is invalid");const s=t instanceof js?t:new js(t,n);if(je.throwOnInvalid)throw new uM(s);return new Ae({invalid:s})}static fromDateTimes(t,n){const s=Yl(t),i=Yl(n),a=FD(s,i);return a??new Ae({start:s,end:i})}static after(t,n){const s=ne.fromDurationLike(n),i=Yl(t);return Ae.fromDateTimes(i,i.plus(s))}static before(t,n){const s=ne.fromDurationLike(n),i=Yl(t);return Ae.fromDateTimes(i.minus(s),i)}static fromISO(t,n){const[s,i]=(t||"").split("/",2);if(s&&i){let a,o;try{a=St.fromISO(s,n),o=a.isValid}catch{o=!1}let c,d;try{c=St.fromISO(i,n),d=c.isValid}catch{d=!1}if(o&&d)return Ae.fromDateTimes(a,c);if(o){const h=ne.fromISO(i,n);if(h.isValid)return Ae.after(a,h)}else if(d){const h=ne.fromISO(s,n);if(h.isValid)return Ae.before(c,h)}}return Ae.invalid("unparsable",`the input "${t}" can't be parsed as ISO 8601`)}static isInterval(t){return t&&t.isLuxonInterval||!1}get start(){return this.isValid?this.s:null}get end(){return this.isValid?this.e:null}get isValid(){return this.invalidReason===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}length(t="milliseconds"){return this.isValid?this.toDuration(t).get(t):NaN}count(t="milliseconds"){if(!this.isValid)return NaN;const n=this.start.startOf(t),s=this.end.startOf(t);return Math.floor(s.diff(n,t).get(t))+1}hasSame(t){return this.isValid?this.isEmpty()||this.e.minus(1).hasSame(this.s,t):!1}isEmpty(){return this.s.valueOf()===this.e.valueOf()}isAfter(t){return this.isValid?this.s>t:!1}isBefore(t){return this.isValid?this.e<=t:!1}contains(t){return this.isValid?this.s<=t&&this.e>t:!1}set({start:t,end:n}={}){return this.isValid?Ae.fromDateTimes(t||this.s,n||this.e):this}splitAt(...t){if(!this.isValid)return[];const n=t.map(Yl).filter(o=>this.contains(o)).sort(),s=[];let{s:i}=this,a=0;for(;i<this.e;){const o=n[a]||this.e,c=+o>+this.e?this.e:o;s.push(Ae.fromDateTimes(i,c)),i=c,a+=1}return s}splitBy(t){const n=ne.fromDurationLike(t);if(!this.isValid||!n.isValid||n.as("milliseconds")===0)return[];let{s}=this,i=1,a;const o=[];for(;s<this.e;){const c=this.start.plus(n.mapUnits(d=>d*i));a=+c>+this.e?this.e:c,o.push(Ae.fromDateTimes(s,a)),s=a,i+=1}return o}divideEqually(t){return this.isValid?this.splitBy(this.length()/t).slice(0,t):[]}overlaps(t){return this.e>t.s&&this.s<t.e}abutsStart(t){return this.isValid?+this.e==+t.s:!1}abutsEnd(t){return this.isValid?+t.e==+this.s:!1}engulfs(t){return this.isValid?this.s<=t.s&&this.e>=t.e:!1}equals(t){return!this.isValid||!t.isValid?!1:this.s.equals(t.s)&&this.e.equals(t.e)}intersection(t){if(!this.isValid)return this;const n=this.s>t.s?this.s:t.s,s=this.e<t.e?this.e:t.e;return n>=s?null:Ae.fromDateTimes(n,s)}union(t){if(!this.isValid)return this;const n=this.s<t.s?this.s:t.s,s=this.e>t.e?this.e:t.e;return Ae.fromDateTimes(n,s)}static merge(t){const[n,s]=t.sort((i,a)=>i.s-a.s).reduce(([i,a],o)=>a?a.overlaps(o)||a.abutsStart(o)?[i,a.union(o)]:[i.concat([a]),o]:[i,o],[[],null]);return s&&n.push(s),n}static xor(t){let n=null,s=0;const i=[],a=t.map(d=>[{time:d.s,type:"s"},{time:d.e,type:"e"}]),o=Array.prototype.concat(...a),c=o.sort((d,h)=>d.time-h.time);for(const d of c)s+=d.type==="s"?1:-1,s===1?n=d.time:(n&&+n!=+d.time&&i.push(Ae.fromDateTimes(n,d.time)),n=null);return Ae.merge(i)}difference(...t){return Ae.xor([this].concat(t)).map(n=>this.intersection(n)).filter(n=>n&&!n.isEmpty())}toString(){return this.isValid?`[${this.s.toISO()} \u2013 ${this.e.toISO()})`:qo}toLocaleString(t=Fd,n={}){return this.isValid?gn.create(this.s.loc.clone(n),t).formatInterval(this):qo}toISO(t){return this.isValid?`${this.s.toISO(t)}/${this.e.toISO(t)}`:qo}toISODate(){return this.isValid?`${this.s.toISODate()}/${this.e.toISODate()}`:qo}toISOTime(t){return this.isValid?`${this.s.toISOTime(t)}/${this.e.toISOTime(t)}`:qo}toFormat(t,{separator:n=" \u2013 "}={}){return this.isValid?`${this.s.toFormat(t)}${n}${this.e.toFormat(t)}`:qo}toDuration(t,n){return this.isValid?this.e.diff(this.s,t,n):ne.invalid(this.invalidReason)}mapEndpoints(t){return Ae.fromDateTimes(t(this.s),t(this.e))}}class Jd{static hasDST(t=je.defaultZone){const n=St.now().setZone(t).set({month:12});return!t.isUniversal&&n.offset!==n.set({month:6}).offset}static isValidIANAZone(t){return Mi.isValidZone(t)}static normalizeZone(t){return la(t,je.defaultZone)}static months(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null,outputCalendar:a="gregory"}={}){return(i||Ce.create(n,s,a)).months(t)}static monthsFormat(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null,outputCalendar:a="gregory"}={}){return(i||Ce.create(n,s,a)).months(t,!0)}static weekdays(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null}={}){return(i||Ce.create(n,s,null)).weekdays(t)}static weekdaysFormat(t="long",{locale:n=null,numberingSystem:s=null,locObj:i=null}={}){return(i||Ce.create(n,s,null)).weekdays(t,!0)}static meridiems({locale:t=null}={}){return Ce.create(t).meridiems()}static eras(t="short",{locale:n=null}={}){return Ce.create(n,null,"gregory").eras(t)}static features(){return{relative:Nv()}}}function s3(e,t){const n=i=>i.toUTC(0,{keepLocalTime:!0}).startOf("day").valueOf(),s=n(t)-n(e);return Math.floor(ne.fromMillis(s).as("days"))}function RD(e,t,n){const s=[["years",(d,h)=>h.year-d.year],["quarters",(d,h)=>h.quarter-d.quarter+(h.year-d.year)*4],["months",(d,h)=>h.month-d.month+(h.year-d.year)*12],["weeks",(d,h)=>{const f=s3(d,h);return(f-f%7)/7}],["days",s3]],i={},a=e;let o,c;for(const[d,h]of s)n.indexOf(d)>=0&&(o=d,i[d]=h(e,t),c=a.plus(i),c>t?(i[d]--,e=a.plus(i)):e=c);return[e,i,c,o]}function HD(e,t,n,s){let[i,a,o,c]=RD(e,t,n);const d=t-i,h=n.filter(m=>["hours","minutes","seconds","milliseconds"].indexOf(m)>=0);h.length===0&&(o<t&&(o=i.plus({[c]:1})),o!==i&&(a[c]=(a[c]||0)+d/(o-i)));const f=ne.fromObject(a,s);return h.length>0?ne.fromMillis(d,s).shiftTo(...h).plus(f):f}const uf={arab:"[\u0660-\u0669]",arabext:"[\u06F0-\u06F9]",bali:"[\u1B50-\u1B59]",beng:"[\u09E6-\u09EF]",deva:"[\u0966-\u096F]",fullwide:"[\uFF10-\uFF19]",gujr:"[\u0AE6-\u0AEF]",hanidec:"[\u3007|\u4E00|\u4E8C|\u4E09|\u56DB|\u4E94|\u516D|\u4E03|\u516B|\u4E5D]",khmr:"[\u17E0-\u17E9]",knda:"[\u0CE6-\u0CEF]",laoo:"[\u0ED0-\u0ED9]",limb:"[\u1946-\u194F]",mlym:"[\u0D66-\u0D6F]",mong:"[\u1810-\u1819]",mymr:"[\u1040-\u1049]",orya:"[\u0B66-\u0B6F]",tamldec:"[\u0BE6-\u0BEF]",telu:"[\u0C66-\u0C6F]",thai:"[\u0E50-\u0E59]",tibt:"[\u0F20-\u0F29]",latn:"\\d"},i3={arab:[1632,1641],arabext:[1776,1785],bali:[6992,7001],beng:[2534,2543],deva:[2406,2415],fullwide:[65296,65303],gujr:[2790,2799],khmr:[6112,6121],knda:[3302,3311],laoo:[3792,3801],limb:[6470,6479],mlym:[3430,3439],mong:[6160,6169],mymr:[4160,4169],orya:[2918,2927],tamldec:[3046,3055],telu:[3174,3183],thai:[3664,3673],tibt:[3872,3881]},WD=uf.hanidec.replace(/[\[|\]]/g,"").split("");function jD(e){let t=parseInt(e,10);if(isNaN(t)){t="";for(let n=0;n<e.length;n++){const s=e.charCodeAt(n);if(e[n].search(uf.hanidec)!==-1)t+=WD.indexOf(e[n]);else for(const i in i3){const[a,o]=i3[i];s>=a&&s<=o&&(t+=s-a)}}return parseInt(t,10)}else return t}function Ys({numberingSystem:e},t=""){return new RegExp(`${uf[e||"latn"]}${t}`)}const YD="missing Intl.DateTimeFormat.formatToParts support";function ie(e,t=n=>n){return{regex:e,deser:([n])=>t(jD(n))}}const a3=`[ ${String.fromCharCode(160)}]`,o3=new RegExp(a3,"g");function UD(e){return e.replace(/\./g,"\\.?").replace(o3,a3)}function r3(e){return e.replace(/\./g,"").replace(o3," ").toLowerCase()}function Us(e,t){return e===null?null:{regex:RegExp(e.map(UD).join("|")),deser:([n])=>e.findIndex(s=>r3(n)===r3(s))+t}}function l3(e,t){return{regex:e,deser:([,n,s])=>Kd(n,s),groups:t}}function hf(e){return{regex:e,deser:([t])=>t}}function GD(e){return e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")}function KD(e,t){const n=Ys(t),s=Ys(t,"{2}"),i=Ys(t,"{3}"),a=Ys(t,"{4}"),o=Ys(t,"{6}"),c=Ys(t,"{1,2}"),d=Ys(t,"{1,3}"),h=Ys(t,"{1,6}"),f=Ys(t,"{1,9}"),m=Ys(t,"{2,4}"),v=Ys(t,"{4,6}"),y=k=>({regex:RegExp(GD(k.val)),deser:([D])=>D,literal:!0}),x=(k=>{if(e.literal)return y(k);switch(k.val){case"G":return Us(t.eras("short",!1),0);case"GG":return Us(t.eras("long",!1),0);case"y":return ie(h);case"yy":return ie(m,rf);case"yyyy":return ie(a);case"yyyyy":return ie(v);case"yyyyyy":return ie(o);case"M":return ie(c);case"MM":return ie(s);case"MMM":return Us(t.months("short",!0,!1),1);case"MMMM":return Us(t.months("long",!0,!1),1);case"L":return ie(c);case"LL":return ie(s);case"LLL":return Us(t.months("short",!1,!1),1);case"LLLL":return Us(t.months("long",!1,!1),1);case"d":return ie(c);case"dd":return ie(s);case"o":return ie(d);case"ooo":return ie(i);case"HH":return ie(s);case"H":return ie(c);case"hh":return ie(s);case"h":return ie(c);case"mm":return ie(s);case"m":return ie(c);case"q":return ie(c);case"qq":return ie(s);case"s":return ie(c);case"ss":return ie(s);case"S":return ie(d);case"SSS":return ie(i);case"u":return hf(f);case"uu":return hf(c);case"uuu":return ie(n);case"a":return Us(t.meridiems(),0);case"kkkk":return ie(a);case"kk":return ie(m,rf);case"W":return ie(c);case"WW":return ie(s);case"E":case"c":return ie(n);case"EEE":return Us(t.weekdays("short",!1,!1),1);case"EEEE":return Us(t.weekdays("long",!1,!1),1);case"ccc":return Us(t.weekdays("short",!0,!1),1);case"cccc":return Us(t.weekdays("long",!0,!1),1);case"Z":case"ZZ":return l3(new RegExp(`([+-]${c.source})(?::(${s.source}))?`),2);case"ZZZ":return l3(new RegExp(`([+-]${c.source})(${s.source})?`),2);case"z":return hf(/[a-z_+-/]{1,256}?/i);default:return y(k)}})(e)||{invalidReason:YD};return x.token=e,x}const ZD={year:{"2-digit":"yy",numeric:"yyyyy"},month:{numeric:"M","2-digit":"MM",short:"MMM",long:"MMMM"},day:{numeric:"d","2-digit":"dd"},weekday:{short:"EEE",long:"EEEE"},dayperiod:"a",dayPeriod:"a",hour:{numeric:"h","2-digit":"hh"},minute:{numeric:"m","2-digit":"mm"},second:{numeric:"s","2-digit":"ss"},timeZoneName:{long:"ZZZZZ",short:"ZZZ"}};function XD(e,t){const{type:n,value:s}=e;if(n==="literal")return{literal:!0,val:s};const i=t[n];let a=ZD[n];if(typeof a=="object"&&(a=a[i]),a)return{literal:!1,val:a}}function JD(e){return[`^${e.map(n=>n.regex).reduce((n,s)=>`${n}(${s.source})`,"")}$`,e]}function QD(e,t,n){const s=e.match(t);if(s){const i={};let a=1;for(const o in n)if(Uo(n,o)){const c=n[o],d=c.groups?c.groups+1:1;!c.literal&&c.token&&(i[c.token.val[0]]=c.deser(s.slice(a,a+d))),a+=d}return[s,i]}else return[s,{}]}function qD(e){const t=a=>{switch(a){case"S":return"millisecond";case"s":return"second";case"m":return"minute";case"h":case"H":return"hour";case"d":return"day";case"o":return"ordinal";case"L":case"M":return"month";case"y":return"year";case"E":case"c":return"weekday";case"W":return"weekNumber";case"k":return"weekYear";case"q":return"quarter";default:return null}};let n=null,s;return Qt(e.z)||(n=Mi.create(e.z)),Qt(e.Z)||(n||(n=new xn(e.Z)),s=e.Z),Qt(e.q)||(e.M=(e.q-1)*3+1),Qt(e.h)||(e.h<12&&e.a===1?e.h+=12:e.h===12&&e.a===0&&(e.h=0)),e.G===0&&e.y&&(e.y=-e.y),Qt(e.u)||(e.S=sf(e.u)),[Object.keys(e).reduce((a,o)=>{const c=t(o);return c&&(a[c]=e[o]),a},{}),n,s]}let ff=null;function $D(){return ff||(ff=St.fromMillis(1555555555555)),ff}function tE(e,t){if(e.literal)return e;const n=gn.macroTokenToFormatOpts(e.val),s=u3(n,t);return s==null||s.includes(void 0)?e:s}function c3(e,t){return Array.prototype.concat(...e.map(n=>tE(n,t)))}function d3(e,t,n){const s=c3(gn.parseFormat(n),e),i=s.map(o=>KD(o,e)),a=i.find(o=>o.invalidReason);if(a)return{input:t,tokens:s,invalidReason:a.invalidReason};{const[o,c]=JD(i),d=RegExp(o,"i"),[h,f]=QD(t,d,c),[m,v,y]=f?qD(f):[null,null,void 0];if(Uo(f,"a")&&Uo(f,"H"))throw new Bl("Can't include meridiem when specifying 24-hour format");return{input:t,tokens:s,regex:d,rawMatches:h,matches:f,result:m,zone:v,specificOffset:y}}}function eE(e,t,n){const{result:s,zone:i,specificOffset:a,invalidReason:o}=d3(e,t,n);return[s,i,a,o]}function u3(e,t){return e?gn.create(t,e).formatDateTimeParts($D()).map(i=>XD(i,e)):null}const h3=[0,31,59,90,120,151,181,212,243,273,304,334],f3=[0,31,60,91,121,152,182,213,244,274,305,335];function gs(e,t){return new js("unit out of range",`you specified ${t} (of type ${typeof t}) as a ${e}, which is invalid`)}function p3(e,t,n){const s=new Date(Date.UTC(e,t-1,n));e<100&&e>=0&&s.setUTCFullYear(s.getUTCFullYear()-1900);const i=s.getUTCDay();return i===0?7:i}function m3(e,t,n){return n+(zl(e)?f3:h3)[t-1]}function g3(e,t){const n=zl(e)?f3:h3,s=n.findIndex(a=>a<t),i=t-n[s];return{month:s+1,day:i}}function pf(e){const{year:t,month:n,day:s}=e,i=m3(t,n,s),a=p3(t,n,s);let o=Math.floor((i-a+10)/7),c;return o<1?(c=t-1,o=Gd(c)):o>Gd(t)?(c=t+1,o=1):c=t,{weekYear:c,weekNumber:o,weekday:a,...Xd(e)}}function v3(e){const{weekYear:t,weekNumber:n,weekday:s}=e,i=p3(t,1,4),a=Ll(t);let o=n*7+s-i-3,c;o<1?(c=t-1,o+=Ll(c)):o>a?(c=t+1,o-=Ll(t)):c=t;const{month:d,day:h}=g3(c,o);return{year:c,month:d,day:h,...Xd(e)}}function mf(e){const{year:t,month:n,day:s}=e,i=m3(t,n,s);return{year:t,ordinal:i,...Xd(e)}}function _3(e){const{year:t,ordinal:n}=e,{month:s,day:i}=g3(t,n);return{year:t,month:s,day:i,...Xd(e)}}function nE(e){const t=Yd(e.weekYear),n=Di(e.weekNumber,1,Gd(e.weekYear)),s=Di(e.weekday,1,7);return t?n?s?!1:gs("weekday",e.weekday):gs("week",e.week):gs("weekYear",e.weekYear)}function sE(e){const t=Yd(e.year),n=Di(e.ordinal,1,Ll(e.year));return t?n?!1:gs("ordinal",e.ordinal):gs("year",e.year)}function y3(e){const t=Yd(e.year),n=Di(e.month,1,12),s=Di(e.day,1,Ud(e.year,e.month));return t?n?s?!1:gs("day",e.day):gs("month",e.month):gs("year",e.year)}function b3(e){const{hour:t,minute:n,second:s,millisecond:i}=e,a=Di(t,0,23)||t===24&&n===0&&s===0&&i===0,o=Di(n,0,59),c=Di(s,0,59),d=Di(i,0,999);return a?o?c?d?!1:gs("millisecond",i):gs("second",s):gs("minute",n):gs("hour",t)}const gf="Invalid DateTime",w3=864e13;function Qd(e){return new js("unsupported zone",`the zone "${e.name}" is not supported`)}function vf(e){return e.weekData===null&&(e.weekData=pf(e.c)),e.weekData}function Wl(e,t){const n={ts:e.ts,zone:e.zone,c:e.c,o:e.o,loc:e.loc,invalid:e.invalid};return new St({...n,...t,old:n})}function x3(e,t,n){let s=e-t*60*1e3;const i=n.offset(s);if(t===i)return[s,t];s-=(i-t)*60*1e3;const a=n.offset(s);return i===a?[s,i]:[e-Math.min(i,a)*60*1e3,Math.max(i,a)]}function S3(e,t){e+=t*60*1e3;const n=new Date(e);return{year:n.getUTCFullYear(),month:n.getUTCMonth()+1,day:n.getUTCDate(),hour:n.getUTCHours(),minute:n.getUTCMinutes(),second:n.getUTCSeconds(),millisecond:n.getUTCMilliseconds()}}function qd(e,t,n){return x3(of(e),t,n)}function k3(e,t){const n=e.o,s=e.c.year+Math.trunc(t.years),i=e.c.month+Math.trunc(t.months)+Math.trunc(t.quarters)*3,a={...e.c,year:s,month:i,day:Math.min(e.c.day,Ud(s,i))+Math.trunc(t.days)+Math.trunc(t.weeks)*7},o=ne.fromObject({years:t.years-Math.trunc(t.years),quarters:t.quarters-Math.trunc(t.quarters),months:t.months-Math.trunc(t.months),weeks:t.weeks-Math.trunc(t.weeks),days:t.days-Math.trunc(t.days),hours:t.hours,minutes:t.minutes,seconds:t.seconds,milliseconds:t.milliseconds}).as("milliseconds"),c=of(a);let[d,h]=x3(c,n,e.zone);return o!==0&&(d+=o,h=e.zone.offset(d)),{ts:d,o:h}}function jl(e,t,n,s,i,a){const{setZone:o,zone:c}=n;if(e&&Object.keys(e).length!==0){const d=t||c,h=St.fromObject(e,{...n,zone:d,specificOffset:a});return o?h:h.setZone(c)}else return St.invalid(new js("unparsable",`the input "${i}" can't be parsed as ${s}`))}function $d(e,t,n=!0){return e.isValid?gn.create(Ce.create("en-US"),{allowZ:n,forceSimple:!0}).formatDateTimeFromString(e,t):null}function _f(e,t){const n=e.c.year>9999||e.c.year<0;let s="";return n&&e.c.year>=0&&(s+="+"),s+=Ye(e.c.year,n?6:4),t?(s+="-",s+=Ye(e.c.month),s+="-",s+=Ye(e.c.day)):(s+=Ye(e.c.month),s+=Ye(e.c.day)),s}function C3(e,t,n,s,i,a){let o=Ye(e.c.hour);return t?(o+=":",o+=Ye(e.c.minute),(e.c.second!==0||!n)&&(o+=":")):o+=Ye(e.c.minute),(e.c.second!==0||!n)&&(o+=Ye(e.c.second),(e.c.millisecond!==0||!s)&&(o+=".",o+=Ye(e.c.millisecond,3))),i&&(e.isOffsetFixed&&e.offset===0&&!a?o+="Z":e.o<0?(o+="-",o+=Ye(Math.trunc(-e.o/60)),o+=":",o+=Ye(Math.trunc(-e.o%60))):(o+="+",o+=Ye(Math.trunc(e.o/60)),o+=":",o+=Ye(Math.trunc(e.o%60)))),a&&(o+="["+e.zone.ianaName+"]"),o}const O3={month:1,day:1,hour:0,minute:0,second:0,millisecond:0},iE={weekNumber:1,weekday:1,hour:0,minute:0,second:0,millisecond:0},aE={ordinal:1,hour:0,minute:0,second:0,millisecond:0},M3=["year","month","day","hour","minute","second","millisecond"],oE=["weekYear","weekNumber","weekday","hour","minute","second","millisecond"],rE=["year","ordinal","hour","minute","second","millisecond"];function D3(e){const t={year:"year",years:"year",month:"month",months:"month",day:"day",days:"day",hour:"hour",hours:"hour",minute:"minute",minutes:"minute",quarter:"quarter",quarters:"quarter",second:"second",seconds:"second",millisecond:"millisecond",milliseconds:"millisecond",weekday:"weekday",weekdays:"weekday",weeknumber:"weekNumber",weeksnumber:"weekNumber",weeknumbers:"weekNumber",weekyear:"weekYear",weekyears:"weekYear",ordinal:"ordinal"}[e.toLowerCase()];if(!t)throw new lv(e);return t}function E3(e,t){const n=la(t.zone,je.defaultZone),s=Ce.fromObject(t),i=je.now();let a,o;if(Qt(e.year))a=i;else{for(const h of M3)Qt(e[h])&&(e[h]=O3[h]);const c=y3(e)||b3(e);if(c)return St.invalid(c);const d=n.offset(i);[a,o]=qd(e,d,n)}return new St({ts:a,zone:n,loc:s,o})}function T3(e,t,n){const s=Qt(n.round)?!0:n.round,i=(o,c)=>(o=af(o,s||n.calendary?0:2,!0),t.loc.clone(n).relFormatter(n).format(o,c)),a=o=>n.calendary?t.hasSame(e,o)?0:t.startOf(o).diff(e.startOf(o),o).get(o):t.diff(e,o).get(o);if(n.unit)return i(a(n.unit),n.unit);for(const o of n.units){const c=a(o);if(Math.abs(c)>=1)return i(c,o)}return i(e>t?-0:0,n.units[n.units.length-1])}function I3(e){let t={},n;return e.length>0&&typeof e[e.length-1]=="object"?(t=e[e.length-1],n=Array.from(e).slice(0,e.length-1)):n=Array.from(e),[t,n]}class St{constructor(t){const n=t.zone||je.defaultZone;let s=t.invalid||(Number.isNaN(t.ts)?new js("invalid input"):null)||(n.isValid?null:Qd(n));this.ts=Qt(t.ts)?je.now():t.ts;let i=null,a=null;if(!s)if(t.old&&t.old.ts===this.ts&&t.old.zone.equals(n))[i,a]=[t.old.c,t.old.o];else{const c=n.offset(this.ts);i=S3(this.ts,c),s=Number.isNaN(i.year)?new js("invalid input"):null,i=s?null:i,a=s?null:c}this._zone=n,this.loc=t.loc||Ce.create(),this.invalid=s,this.weekData=null,this.c=i,this.o=a,this.isLuxonDateTime=!0}static now(){return new St({})}static local(){const[t,n]=I3(arguments),[s,i,a,o,c,d,h]=n;return E3({year:s,month:i,day:a,hour:o,minute:c,second:d,millisecond:h},t)}static utc(){const[t,n]=I3(arguments),[s,i,a,o,c,d,h]=n;return t.zone=xn.utcInstance,E3({year:s,month:i,day:a,hour:o,minute:c,second:d,millisecond:h},t)}static fromJSDate(t,n={}){const s=VM(t)?t.valueOf():NaN;if(Number.isNaN(s))return St.invalid("invalid input");const i=la(n.zone,je.defaultZone);return i.isValid?new St({ts:s,zone:i,loc:Ce.fromObject(n)}):St.invalid(Qd(i))}static fromMillis(t,n={}){if(Qa(t))return t<-w3||t>w3?St.invalid("Timestamp out of range"):new St({ts:t,zone:la(n.zone,je.defaultZone),loc:Ce.fromObject(n)});throw new ps(`fromMillis requires a numerical input, but received a ${typeof t} with value ${t}`)}static fromSeconds(t,n={}){if(Qa(t))return new St({ts:t*1e3,zone:la(n.zone,je.defaultZone),loc:Ce.fromObject(n)});throw new ps("fromSeconds requires a numerical input")}static fromObject(t,n={}){t=t||{};const s=la(n.zone,je.defaultZone);if(!s.isValid)return St.invalid(Qd(s));const i=je.now(),a=Qt(n.specificOffset)?s.offset(i):n.specificOffset,o=Zd(t,D3),c=!Qt(o.ordinal),d=!Qt(o.year),h=!Qt(o.month)||!Qt(o.day),f=d||h,m=o.weekYear||o.weekNumber,v=Ce.fromObject(n);if((f||c)&&m)throw new Bl("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(h&&c)throw new Bl("Can't mix ordinal dates with month/day");const y=m||o.weekday&&!f;let w,x,k=S3(i,a);y?(w=oE,x=iE,k=pf(k)):c?(w=rE,x=aE,k=mf(k)):(w=M3,x=O3);let D=!1;for(const L of w){const W=o[L];Qt(W)?D?o[L]=x[L]:o[L]=k[L]:D=!0}const E=y?nE(o):c?sE(o):y3(o),B=E||b3(o);if(B)return St.invalid(B);const S=y?v3(o):c?_3(o):o,[A,I]=qd(S,a,s),F=new St({ts:A,zone:s,o:I,loc:v});return o.weekday&&f&&t.weekday!==F.weekday?St.invalid("mismatched weekday",`you can't specify both a weekday of ${o.weekday} and a date of ${F.toISO()}`):F}static fromISO(t,n={}){const[s,i]=xD(t);return jl(s,i,n,"ISO 8601",t)}static fromRFC2822(t,n={}){const[s,i]=SD(t);return jl(s,i,n,"RFC 2822",t)}static fromHTTP(t,n={}){const[s,i]=kD(t);return jl(s,i,n,"HTTP",n)}static fromFormat(t,n,s={}){if(Qt(t)||Qt(n))throw new ps("fromFormat requires an input string and a format");const{locale:i=null,numberingSystem:a=null}=s,o=Ce.fromOpts({locale:i,numberingSystem:a,defaultToEN:!0}),[c,d,h,f]=eE(o,t,n);return f?St.invalid(f):jl(c,d,s,`format ${n}`,t,h)}static fromString(t,n,s={}){return St.fromFormat(t,n,s)}static fromSQL(t,n={}){const[s,i]=ID(t);return jl(s,i,n,"SQL",t)}static invalid(t,n=null){if(!t)throw new ps("need to specify a reason the DateTime is invalid");const s=t instanceof js?t:new js(t,n);if(je.throwOnInvalid)throw new dM(s);return new St({invalid:s})}static isDateTime(t){return t&&t.isLuxonDateTime||!1}static parseFormatForOpts(t,n={}){const s=u3(t,Ce.fromObject(n));return s?s.map(i=>i?i.val:null).join(""):null}static expandFormat(t,n={}){return c3(gn.parseFormat(t),Ce.fromObject(n)).map(i=>i.val).join("")}get(t){return this[t]}get isValid(){return this.invalid===null}get invalidReason(){return this.invalid?this.invalid.reason:null}get invalidExplanation(){return this.invalid?this.invalid.explanation:null}get locale(){return this.isValid?this.loc.locale:null}get numberingSystem(){return this.isValid?this.loc.numberingSystem:null}get outputCalendar(){return this.isValid?this.loc.outputCalendar:null}get zone(){return this._zone}get zoneName(){return this.isValid?this.zone.name:null}get year(){return this.isValid?this.c.year:NaN}get quarter(){return this.isValid?Math.ceil(this.c.month/3):NaN}get month(){return this.isValid?this.c.month:NaN}get day(){return this.isValid?this.c.day:NaN}get hour(){return this.isValid?this.c.hour:NaN}get minute(){return this.isValid?this.c.minute:NaN}get second(){return this.isValid?this.c.second:NaN}get millisecond(){return this.isValid?this.c.millisecond:NaN}get weekYear(){return this.isValid?vf(this).weekYear:NaN}get weekNumber(){return this.isValid?vf(this).weekNumber:NaN}get weekday(){return this.isValid?vf(this).weekday:NaN}get ordinal(){return this.isValid?mf(this.c).ordinal:NaN}get monthShort(){return this.isValid?Jd.months("short",{locObj:this.loc})[this.month-1]:null}get monthLong(){return this.isValid?Jd.months("long",{locObj:this.loc})[this.month-1]:null}get weekdayShort(){return this.isValid?Jd.weekdays("short",{locObj:this.loc})[this.weekday-1]:null}get weekdayLong(){return this.isValid?Jd.weekdays("long",{locObj:this.loc})[this.weekday-1]:null}get offset(){return this.isValid?+this.o:NaN}get offsetNameShort(){return this.isValid?this.zone.offsetName(this.ts,{format:"short",locale:this.locale}):null}get offsetNameLong(){return this.isValid?this.zone.offsetName(this.ts,{format:"long",locale:this.locale}):null}get isOffsetFixed(){return this.isValid?this.zone.isUniversal:null}get isInDST(){return this.isOffsetFixed?!1:this.offset>this.set({month:1,day:1}).offset||this.offset>this.set({month:5}).offset}get isInLeapYear(){return zl(this.year)}get daysInMonth(){return Ud(this.year,this.month)}get daysInYear(){return this.isValid?Ll(this.year):NaN}get weeksInWeekYear(){return this.isValid?Gd(this.weekYear):NaN}resolvedLocaleOptions(t={}){const{locale:n,numberingSystem:s,calendar:i}=gn.create(this.loc.clone(t),t).resolvedOptions(this);return{locale:n,numberingSystem:s,outputCalendar:i}}toUTC(t=0,n={}){return this.setZone(xn.instance(t),n)}toLocal(){return this.setZone(je.defaultZone)}setZone(t,{keepLocalTime:n=!1,keepCalendarTime:s=!1}={}){if(t=la(t,je.defaultZone),t.equals(this.zone))return this;if(t.isValid){let i=this.ts;if(n||s){const a=t.offset(this.ts),o=this.toObject();[i]=qd(o,a,t)}return Wl(this,{ts:i,zone:t})}else return St.invalid(Qd(t))}reconfigure({locale:t,numberingSystem:n,outputCalendar:s}={}){const i=this.loc.clone({locale:t,numberingSystem:n,outputCalendar:s});return Wl(this,{loc:i})}setLocale(t){return this.reconfigure({locale:t})}set(t){if(!this.isValid)return this;const n=Zd(t,D3),s=!Qt(n.weekYear)||!Qt(n.weekNumber)||!Qt(n.weekday),i=!Qt(n.ordinal),a=!Qt(n.year),o=!Qt(n.month)||!Qt(n.day),c=a||o,d=n.weekYear||n.weekNumber;if((c||i)&&d)throw new Bl("Can't mix weekYear/weekNumber units with year/month/day or ordinals");if(o&&i)throw new Bl("Can't mix ordinal dates with month/day");let h;s?h=v3({...pf(this.c),...n}):Qt(n.ordinal)?(h={...this.toObject(),...n},Qt(n.day)&&(h.day=Math.min(Ud(h.year,h.month),h.day))):h=_3({...mf(this.c),...n});const[f,m]=qd(h,this.o,this.zone);return Wl(this,{ts:f,o:m})}plus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t);return Wl(this,k3(this,n))}minus(t){if(!this.isValid)return this;const n=ne.fromDurationLike(t).negate();return Wl(this,k3(this,n))}startOf(t){if(!this.isValid)return this;const n={},s=ne.normalizeUnit(t);switch(s){case"years":n.month=1;case"quarters":case"months":n.day=1;case"weeks":case"days":n.hour=0;case"hours":n.minute=0;case"minutes":n.second=0;case"seconds":n.millisecond=0;break}if(s==="weeks"&&(n.weekday=1),s==="quarters"){const i=Math.ceil(this.month/3);n.month=(i-1)*3+1}return this.set(n)}endOf(t){return this.isValid?this.plus({[t]:1}).startOf(t).minus(1):this}toFormat(t,n={}){return this.isValid?gn.create(this.loc.redefaultToEN(n)).formatDateTimeFromString(this,t):gf}toLocaleString(t=Fd,n={}){return this.isValid?gn.create(this.loc.clone(n),t).formatDateTime(this):gf}toLocaleParts(t={}){return this.isValid?gn.create(this.loc.clone(t),t).formatDateTimeParts(this):[]}toISO({format:t="extended",suppressSeconds:n=!1,suppressMilliseconds:s=!1,includeOffset:i=!0,extendedZone:a=!1}={}){if(!this.isValid)return null;const o=t==="extended";let c=_f(this,o);return c+="T",c+=C3(this,o,n,s,i,a),c}toISODate({format:t="extended"}={}){return this.isValid?_f(this,t==="extended"):null}toISOWeekDate(){return $d(this,"kkkk-'W'WW-c")}toISOTime({suppressMilliseconds:t=!1,suppressSeconds:n=!1,includeOffset:s=!0,includePrefix:i=!1,extendedZone:a=!1,format:o="extended"}={}){return this.isValid?(i?"T":"")+C3(this,o==="extended",n,t,s,a):null}toRFC2822(){return $d(this,"EEE, dd LLL yyyy HH:mm:ss ZZZ",!1)}toHTTP(){return $d(this.toUTC(),"EEE, dd LLL yyyy HH:mm:ss 'GMT'")}toSQLDate(){return this.isValid?_f(this,!0):null}toSQLTime({includeOffset:t=!0,includeZone:n=!1,includeOffsetSpace:s=!0}={}){let i="HH:mm:ss.SSS";return(n||t)&&(s&&(i+=" "),n?i+="z":t&&(i+="ZZ")),$d(this,i,!0)}toSQL(t={}){return this.isValid?`${this.toSQLDate()} ${this.toSQLTime(t)}`:null}toString(){return this.isValid?this.toISO():gf}valueOf(){return this.toMillis()}toMillis(){return this.isValid?this.ts:NaN}toSeconds(){return this.isValid?this.ts/1e3:NaN}toUnixInteger(){return this.isValid?Math.floor(this.ts/1e3):NaN}toJSON(){return this.toISO()}toBSON(){return this.toJSDate()}toObject(t={}){if(!this.isValid)return{};const n={...this.c};return t.includeConfig&&(n.outputCalendar=this.outputCalendar,n.numberingSystem=this.loc.numberingSystem,n.locale=this.loc.locale),n}toJSDate(){return new Date(this.isValid?this.ts:NaN)}diff(t,n="milliseconds",s={}){if(!this.isValid||!t.isValid)return ne.invalid("created by diffing an invalid DateTime");const i={locale:this.locale,numberingSystem:this.numberingSystem,...s},a=BM(n).map(ne.normalizeUnit),o=t.valueOf()>this.valueOf(),c=o?this:t,d=o?t:this,h=HD(c,d,a,i);return o?h.negate():h}diffNow(t="milliseconds",n={}){return this.diff(St.now(),t,n)}until(t){return this.isValid?Ae.fromDateTimes(this,t):this}hasSame(t,n){if(!this.isValid)return!1;const s=t.valueOf(),i=this.setZone(t.zone,{keepLocalTime:!0});return i.startOf(n)<=s&&s<=i.endOf(n)}equals(t){return this.isValid&&t.isValid&&this.valueOf()===t.valueOf()&&this.zone.equals(t.zone)&&this.loc.equals(t.loc)}toRelative(t={}){if(!this.isValid)return null;const n=t.base||St.fromObject({},{zone:this.zone}),s=t.padding?this<n?-t.padding:t.padding:0;let i=["years","months","days","hours","minutes","seconds"],a=t.unit;return Array.isArray(t.unit)&&(i=t.unit,a=void 0),T3(n,this.plus(s),{...t,numeric:"always",units:i,unit:a})}toRelativeCalendar(t={}){return this.isValid?T3(t.base||St.fromObject({},{zone:this.zone}),this,{...t,numeric:"auto",units:["years","months","days"],calendary:!0}):null}static min(...t){if(!t.every(St.isDateTime))throw new ps("min requires all arguments be DateTimes");return zv(t,n=>n.valueOf(),Math.min)}static max(...t){if(!t.every(St.isDateTime))throw new ps("max requires all arguments be DateTimes");return zv(t,n=>n.valueOf(),Math.max)}static fromFormatExplain(t,n,s={}){const{locale:i=null,numberingSystem:a=null}=s,o=Ce.fromOpts({locale:i,numberingSystem:a,defaultToEN:!0});return d3(o,t,n)}static fromStringExplain(t,n,s={}){return St.fromFormatExplain(t,n,s)}static get DATE_SHORT(){return Fd}static get DATE_MED(){return cv}static get DATE_MED_WITH_WEEKDAY(){return fM}static get DATE_FULL(){return dv}static get DATE_HUGE(){return uv}static get TIME_SIMPLE(){return hv}static get TIME_WITH_SECONDS(){return fv}static get TIME_WITH_SHORT_OFFSET(){return pv}static get TIME_WITH_LONG_OFFSET(){return mv}static get TIME_24_SIMPLE(){return gv}static get TIME_24_WITH_SECONDS(){return vv}static get TIME_24_WITH_SHORT_OFFSET(){return _v}static get TIME_24_WITH_LONG_OFFSET(){return yv}static get DATETIME_SHORT(){return bv}static get DATETIME_SHORT_WITH_SECONDS(){return wv}static get DATETIME_MED(){return xv}static get DATETIME_MED_WITH_SECONDS(){return Sv}static get DATETIME_MED_WITH_WEEKDAY(){return pM}static get DATETIME_FULL(){return kv}static get DATETIME_FULL_WITH_SECONDS(){return Cv}static get DATETIME_HUGE(){return Ov}static get DATETIME_HUGE_WITH_SECONDS(){return Mv}}function Yl(e){if(St.isDateTime(e))return e;if(e&&e.valueOf&&Qa(e.valueOf()))return St.fromJSDate(e);if(e&&typeof e=="object")return St.fromObject(e);throw new ps(`Unknown datetime argument: ${e}, of type ${typeof e}`)}function Ul(e){var t=e.getBoundingClientRect();return{width:t.width,height:t.height,top:t.top,right:t.right,bottom:t.bottom,left:t.left,x:t.left,y:t.top}}function vs(e){if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t?t.defaultView:window}return e}function yf(e){var t=vs(e),n=t.pageXOffset,s=t.pageYOffset;return{scrollLeft:n,scrollTop:s}}function Gl(e){var t=vs(e).Element;return e instanceof t||e instanceof Element}function Gs(e){var t=vs(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function lE(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function cE(e){return e===vs(e)||!Gs(e)?yf(e):lE(e)}function Ei(e){return e?(e.nodeName||"").toLowerCase():null}function ua(e){return(Gl(e)?e.ownerDocument:e.document).documentElement}function A3(e){return Ul(ua(e)).left+yf(e).scrollLeft}function to(e){return vs(e).getComputedStyle(e)}function bf(e){var t=to(e),n=t.overflow,s=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+i+s)}function V3(e,t,n){n===void 0&&(n=!1);var s=ua(t),i=Ul(e),a={scrollLeft:0,scrollTop:0},o={x:0,y:0};return n||((Ei(t)!=="body"||bf(s))&&(a=cE(t)),Gs(t)?(o=Ul(t),o.x+=t.clientLeft,o.y+=t.clientTop):s&&(o.x=A3(s))),{x:i.left+a.scrollLeft-o.x,y:i.top+a.scrollTop-o.y,width:i.width,height:i.height}}function wf(e){return{x:e.offsetLeft,y:e.offsetTop,width:e.offsetWidth,height:e.offsetHeight}}function B3(e){return Ei(e)==="html"?e:e.assignedSlot||e.parentNode||e.host||ua(e)}function P3(e){return["html","body","#document"].indexOf(Ei(e))>=0?e.ownerDocument.body:Gs(e)&&bf(e)?e:P3(B3(e))}function Kl(e,t){t===void 0&&(t=[]);var n=P3(e),s=Ei(n)==="body",i=vs(n),a=s?[i].concat(i.visualViewport||[],bf(n)?n:[]):n,o=t.concat(a);return s?o:o.concat(Kl(B3(a)))}function dE(e){return["table","td","th"].indexOf(Ei(e))>=0}function N3(e){return!Gs(e)||to(e).position==="fixed"?null:e.offsetParent}function Zl(e){for(var t=vs(e),n=N3(e);n&&dE(n);)n=N3(n);return n&&Ei(n)==="body"&&to(n).position==="static"?t:n||t}var _s="top",Ks="bottom",Zs="right",ys="left",tu="auto",Xl=[_s,Ks,Zs,ys],$o="start",xf="end",uE="clippingParents",z3="viewport",Jl="popper",hE="reference",L3=Xl.reduce(function(e,t){return e.concat([t+"-"+$o,t+"-"+xf])},[]),F3=[].concat(Xl,[tu]).reduce(function(e,t){return e.concat([t,t+"-"+$o,t+"-"+xf])},[]),fE="beforeRead",pE="read",mE="afterRead",gE="beforeMain",vE="main",_E="afterMain",yE="beforeWrite",bE="write",wE="afterWrite",Sf=[fE,pE,mE,gE,vE,_E,yE,bE,wE];function xE(e){var t=new Map,n=new Set,s=[];e.forEach(function(a){t.set(a.name,a)});function i(a){n.add(a.name);var o=[].concat(a.requires||[],a.requiresIfExists||[]);o.forEach(function(c){if(!n.has(c)){var d=t.get(c);d&&i(d)}}),s.push(a)}return e.forEach(function(a){n.has(a.name)||i(a)}),s}function SE(e){var t=xE(e);return Sf.reduce(function(n,s){return n.concat(t.filter(function(i){return i.phase===s}))},[])}function kE(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function ha(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),s=1;s<t;s++)n[s-1]=arguments[s];return[].concat(n).reduce(function(i,a){return i.replace(/%s/,a)},e)}var eo='Popper: modifier "%s" provided an invalid %s property, expected %s but got %s',CE='Popper: modifier "%s" requires "%s", but "%s" modifier is not available',OE=["name","enabled","phase","fn","effect","requires","options"];function ME(e){e.forEach(function(t){Object.keys(t).forEach(function(n){switch(n){case"name":typeof t.name!="string"&&console.error(ha(eo,String(t.name),'"name"','"string"','"'+String(t.name)+'"'));break;case"enabled":typeof t.enabled!="boolean"&&console.error(ha(eo,t.name,'"enabled"','"boolean"','"'+String(t.enabled)+'"'));case"phase":Sf.indexOf(t.phase)<0&&console.error(ha(eo,t.name,'"phase"',"either "+Sf.join(", "),'"'+String(t.phase)+'"'));break;case"fn":typeof t.fn!="function"&&console.error(ha(eo,t.name,'"fn"','"function"','"'+String(t.fn)+'"'));break;case"effect":typeof t.effect!="function"&&console.error(ha(eo,t.name,'"effect"','"function"','"'+String(t.fn)+'"'));break;case"requires":Array.isArray(t.requires)||console.error(ha(eo,t.name,'"requires"','"array"','"'+String(t.requires)+'"'));break;case"requiresIfExists":Array.isArray(t.requiresIfExists)||console.error(ha(eo,t.name,'"requiresIfExists"','"array"','"'+String(t.requiresIfExists)+'"'));break;case"options":case"data":break;default:console.error('PopperJS: an invalid property has been provided to the "'+t.name+'" modifier, valid properties are '+OE.map(function(s){return'"'+s+'"'}).join(", ")+'; but "'+n+'" was provided.')}t.requires&&t.requires.forEach(function(s){e.find(function(i){return i.name===s})==null&&console.error(ha(CE,String(t.name),s,s))})})})}function DE(e,t){var n=new Set;return e.filter(function(s){var i=t(s);if(!n.has(i))return n.add(i),!0})}function Xs(e){return e.split("-")[0]}function EE(e){var t=e.reduce(function(n,s){var i=n[s.name];return n[s.name]=i?Object.assign({},i,{},s,{options:Object.assign({},i.options,{},s.options),data:Object.assign({},i.data,{},s.data)}):s,n},{});return Object.keys(t).map(function(n){return t[n]})}var R3="Popper: Invalid reference or popper argument provided. They must be either a DOM element or virtual element.",TE="Popper: An infinite loop in the modifiers cycle has been detected! The cycle has been interrupted to prevent a browser crash.",H3={placement:"bottom",modifiers:[],strategy:"absolute"};function W3(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return!t.some(function(s){return!(s&&typeof s.getBoundingClientRect=="function")})}function IE(e){e===void 0&&(e={});var t=e,n=t.defaultModifiers,s=n===void 0?[]:n,i=t.defaultOptions,a=i===void 0?H3:i;return function(c,d,h){h===void 0&&(h=a);var f={placement:"bottom",orderedModifiers:[],options:Object.assign({},H3,{},a),modifiersData:{},elements:{reference:c,popper:d},attributes:{},styles:{}},m=[],v=!1,y={state:f,setOptions:function(D){x(),f.options=Object.assign({},a,{},f.options,{},D),f.scrollParents={reference:Gl(c)?Kl(c):c.contextElement?Kl(c.contextElement):[],popper:Kl(d)};var E=SE(EE([].concat(s,f.options.modifiers)));if(f.orderedModifiers=E.filter(function(X){return X.enabled}),process.env.NODE_ENV!=="production"){var B=DE([].concat(E,f.options.modifiers),function(X){var Z=X.name;return Z});if(ME(B),Xs(f.options.placement)===tu){var S=f.orderedModifiers.find(function(X){var Z=X.name;return Z==="flip"});S||console.error(['Popper: "auto" placements require the "flip" modifier be',"present and enabled to work."].join(" "))}var A=to(d),I=A.marginTop,F=A.marginRight,L=A.marginBottom,W=A.marginLeft;[I,F,L,W].some(function(X){return parseFloat(X)})&&console.warn(['Popper: CSS "margin" styles cannot be used to apply padding',"between the popper and its reference element or boundary.","To replicate margin, use the `offset` modifier, as well as","the `padding` option in the `preventOverflow` and `flip`","modifiers."].join(" "))}return w(),y.update()},forceUpdate:function(){if(!v){var D=f.elements,E=D.reference,B=D.popper;if(!W3(E,B)){process.env.NODE_ENV!=="production"&&console.error(R3);return}f.rects={reference:V3(E,Zl(B),f.options.strategy==="fixed"),popper:wf(B)},f.reset=!1,f.placement=f.options.placement,f.orderedModifiers.forEach(function(Z){return f.modifiersData[Z.name]=Object.assign({},Z.data)});for(var S=0,A=0;A<f.orderedModifiers.length;A++){if(process.env.NODE_ENV!=="production"&&(S+=1,S>100)){console.error(TE);break}if(f.reset===!0){f.reset=!1,A=-1;continue}var I=f.orderedModifiers[A],F=I.fn,L=I.options,W=L===void 0?{}:L,X=I.name;typeof F=="function"&&(f=F({state:f,options:W,name:X,instance:y})||f)}}},update:kE(function(){return new Promise(function(k){y.forceUpdate(),k(f)})}),destroy:function(){x(),v=!0}};if(!W3(c,d))return process.env.NODE_ENV!=="production"&&console.error(R3),y;y.setOptions(h).then(function(k){!v&&h.onFirstUpdate&&h.onFirstUpdate(k)});function w(){f.orderedModifiers.forEach(function(k){var D=k.name,E=k.options,B=E===void 0?{}:E,S=k.effect;if(typeof S=="function"){var A=S({state:f,name:D,instance:y,options:B}),I=function(){};m.push(A||I)}})}function x(){m.forEach(function(k){return k()}),m=[]}return y}}var eu={passive:!0};function AE(e){var t=e.state,n=e.instance,s=e.options,i=s.scroll,a=i===void 0?!0:i,o=s.resize,c=o===void 0?!0:o,d=vs(t.elements.popper),h=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&h.forEach(function(f){f.addEventListener("scroll",n.update,eu)}),c&&d.addEventListener("resize",n.update,eu),function(){a&&h.forEach(function(f){f.removeEventListener("scroll",n.update,eu)}),c&&d.removeEventListener("resize",n.update,eu)}}const VE={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:AE,data:{}};function Ql(e){return e.split("-")[1]}function kf(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function j3(e){var t=e.reference,n=e.element,s=e.placement,i=s?Xs(s):null,a=s?Ql(s):null,o=t.x+t.width/2-n.width/2,c=t.y+t.height/2-n.height/2,d;switch(i){case _s:d={x:o,y:t.y-n.height};break;case Ks:d={x:o,y:t.y+t.height};break;case Zs:d={x:t.x+t.width,y:c};break;case ys:d={x:t.x-n.width,y:c};break;default:d={x:t.x,y:t.y}}var h=i?kf(i):null;if(h!=null){var f=h==="y"?"height":"width";switch(a){case $o:d[h]=Math.floor(d[h])-Math.floor(t[f]/2-n[f]/2);break;case xf:d[h]=Math.floor(d[h])+Math.ceil(t[f]/2-n[f]/2);break}}return d}function BE(e){var t=e.state,n=e.name;t.modifiersData[n]=j3({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const PE={name:"popperOffsets",enabled:!0,phase:"read",fn:BE,data:{}};var NE={top:"auto",right:"auto",bottom:"auto",left:"auto"};function zE(e){var t=e.x,n=e.y,s=window,i=s.devicePixelRatio||1;return{x:Math.round(t*i)/i||0,y:Math.round(n*i)/i||0}}function Y3(e){var t,n=e.popper,s=e.popperRect,i=e.placement,a=e.offsets,o=e.position,c=e.gpuAcceleration,d=e.adaptive,h=zE(a),f=h.x,m=h.y,v=a.hasOwnProperty("x"),y=a.hasOwnProperty("y"),w=ys,x=_s,k=window;if(d){var D=Zl(n);D===vs(n)&&(D=ua(n)),i===_s&&(x=Ks,m-=D.clientHeight-s.height,m*=c?1:-1),i===ys&&(w=Zs,f-=D.clientWidth-s.width,f*=c?1:-1)}var E=Object.assign({position:o},d&&NE);if(c){var B;return Object.assign({},E,(B={},B[x]=y?"0":"",B[w]=v?"0":"",B.transform=(k.devicePixelRatio||1)<2?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",B))}return Object.assign({},E,(t={},t[x]=y?m+"px":"",t[w]=v?f+"px":"",t.transform="",t))}function LE(e){var t=e.state,n=e.options,s=n.gpuAcceleration,i=s===void 0?!0:s,a=n.adaptive,o=a===void 0?!0:a;if(process.env.NODE_ENV!=="production"){var c=to(t.elements.popper).transitionProperty||"";o&&["transform","top","right","bottom","left"].some(function(h){return c.indexOf(h)>=0})&&console.warn(["Popper: Detected CSS transitions on at least one of the following",'CSS properties: "transform", "top", "right", "bottom", "left".',`
|
|
43
43
|
|
|
44
44
|
`,'Disable the "computeStyles" modifier\'s `adaptive` option to allow',"for smooth transitions, or remove these properties from the CSS","transition declaration on the popper element if only transitioning","opacity or background-color for example.",`
|
|
45
45
|
|