UNPKG

cal-heatmap

Version:

Cal-Heatmap is a javascript module to create calendar heatmap to visualize time series data

2 lines 155 kB
import{select as t}from"d3-selection";import{hcl as e}from"d3-color";import{ascending as n,timeSecond as r,timeMinute as i,timeHour as o,timeDay as a,timeWeek as u,timeMonth as s,timeYear as c,timeMonday as l,timeTuesday as f,timeWednesday as h,timeThursday as d,timeFriday as p,timeSaturday as v,timeSunday as y,utcSecond as m,utcMinute as g,utcHour as w,utcDay as b,utcWeek as x,utcMonth as O,utcYear as k,utcMonday as S,utcTuesday as j,utcWednesday as _,utcThursday as M,utcFriday as D,utcSaturday as $,utcSunday as E,descending as P,range as L,symbolAsterisk as A,symbolCircle as C,symbolCross as T,symbolDiamond as R,symbolDiamond2 as I,symbolPlus as N,symbolSquare as W,symbolSquare2 as F,symbolStar as z,symbolTimes as H,symbolTriangle as Y,symbolTriangle2 as U,symbolWye as B,schemeAccent as G,schemeCategory10 as V,schemeDark2 as q,schemePaired as K,schemePastel1 as Z,schemePastel2 as J,schemeSet1 as Q,schemeSet2 as X,schemeSet3 as tt,schemeTableau10 as et,quantize as nt,interpolateBrBG as rt,interpolatePRGn as it,interpolatePiYG as ot,interpolatePuOr as at,interpolateRdBu as ut,interpolateRdGy as st,interpolateRdYlBu as ct,interpolateRdYlGn as lt,interpolateSpectral as ft,interpolateBlues as ht,interpolateGreens as dt,interpolateGreys as pt,interpolatePurples as vt,interpolateReds as yt,interpolateOranges as mt,interpolateTurbo as gt,interpolateViridis as wt,interpolateMagma as bt,interpolateInferno as xt,interpolatePlasma as Ot,interpolateCividis as kt,interpolateCubehelixDefault as St,interpolateWarm as jt,interpolateCool as _t,interpolateBuGn as Mt,interpolateBuPu as Dt,interpolateGnBu as $t,interpolateOrRd as Et,interpolatePuBuGn as Pt,interpolatePuBu as Lt,interpolatePuRd as At,interpolateRdPu as Ct,interpolateYlGnBu as Tt,interpolateYlGn as Rt,interpolateYlOrBr as It,interpolateYlOrRd as Nt,interpolateRainbow as Wt,interpolateSinebow as Ft,schemeBrBG as zt,schemePRGn as Ht,schemePiYG as Yt,schemePuOr as Ut,schemeRdBu as Bt,schemeRdGy as Gt,schemeRdYlBu as Vt,schemeRdYlGn as qt,schemeSpectral as Kt,schemeBlues as Zt,schemeGreens as Jt,schemeGreys as Qt,schemeOranges as Xt,schemePurples as te,schemeReds as ee,schemeBuGn as ne,schemeBuPu as re,schemeGnBu as ie,schemeOrRd as oe,schemePuBu as ae,schemePuBuGn as ue,schemePuRd as se,schemeRdPu as ce,schemeYlGn as le,schemeYlGnBu as fe,schemeYlOrBr as he,schemeYlOrRd as de,scaleLinear as pe,scalePow as ve,scaleLog as ye,scaleSymlog as me,scaleQuantile as ge,extent as we,ticks as be,interpolateNumber as xe,reverse as Oe,scaleThreshold as ke,scaleIdentity as Se,max as je,interpolateRgb as _e,interpolateRound as Me,min as De,quantile as $e,median as Ee,interpolateHsl as Pe,interpolateHcl as Le,interpolateLab as Ae,scaleDiverging as Ce,scaleDivergingPow as Te,scaleDivergingLog as Re,scaleDivergingSymlog as Ie,piecewise as Ne,scaleTime as We,scaleUtc as Fe,scaleImplicit as ze,scaleOrdinal as He,scalePoint as Ye,scaleBand as Ue,InternSet as Be,sort as Ge,symbolsStroke as Ve,symbolsFill as qe}from"d3";import{text as Ke,dsv as Ze,csv as Je,json as Qe}from"d3-fetch";function Xe(){Xe=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,r=Object.defineProperty||function(t,e,n){t[e]=n.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,n){return Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,n){return t[e]=n}}function c(t,e,n,i){var o=e&&e.prototype instanceof h?e:h,a=Object.create(o.prototype),u=new j(i||[]);return r(a,"_invoke",{value:x(t,n,u)}),a}function l(t,e,n){try{return{type:"normal",arg:t.call(e,n)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var f={};function h(){}function d(){}function p(){}var v={};s(v,o,(function(){return this}));var y=Object.getPrototypeOf,m=y&&y(y(_([])));m&&m!==e&&n.call(m,o)&&(v=m);var g=p.prototype=h.prototype=Object.create(v);function w(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function b(t,e){function i(r,o,a,u){var s=l(t[r],t,o);if("throw"!==s.type){var c=s.arg,f=c.value;return f&&"object"==typeof f&&n.call(f,"__await")?e.resolve(f.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(f).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;r(this,"_invoke",{value:function(t,n){function r(){return new e((function(e,r){i(t,n,e,r)}))}return o=o?o.then(r,r):r()}})}function x(t,e,n){var r="suspendedStart";return function(i,o){if("executing"===r)throw new Error("Generator is already running");if("completed"===r){if("throw"===i)throw o;return M()}for(n.method=i,n.arg=o;;){var a=n.delegate;if(a){var u=O(a,n);if(u){if(u===f)continue;return u}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if("suspendedStart"===r)throw r="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";var s=l(t,e,n);if("normal"===s.type){if(r=n.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r="completed",n.method="throw",n.arg=s.arg)}}}function O(t,e){var n=e.method,r=t.iterator[n];if(void 0===r)return e.delegate=null,"throw"===n&&t.iterator.return&&(e.method="return",e.arg=void 0,O(t,e),"throw"===e.method)||"return"!==n&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var i=l(r,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,f;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function k(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function S(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function j(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(k,this),this.reset(!0)}function _(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,i=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:M}}function M(){return{value:void 0,done:!0}}return d.prototype=p,r(g,"constructor",{value:p,configurable:!0}),r(p,"constructor",{value:d,configurable:!0}),d.displayName=s(p,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===d||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},w(b.prototype),s(b.prototype,a,(function(){return this})),t.AsyncIterator=b,t.async=function(e,n,r,i,o){void 0===o&&(o=Promise);var a=new b(c(e,n,r,i),o);return t.isGeneratorFunction(n)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(g),s(g,u,"Generator"),s(g,o,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),n=[];for(var r in e)n.push(r);return n.reverse(),function t(){for(;n.length;){var r=n.pop();if(r in e)return t.value=r,t.done=!1,t}return t.done=!0,t}},t.values=_,j.prototype={constructor:j,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(n,r){return a.type="throw",a.arg=t,e.next=n,r&&(e.method="next",e.arg=void 0),!!r}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(o.tryLoc<=this.prev){var u=n.call(o,"catchLoc"),s=n.call(o,"finallyLoc");if(u&&s){if(this.prev<o.catchLoc)return r(o.catchLoc,!0);if(this.prev<o.finallyLoc)return r(o.finallyLoc)}else if(u){if(this.prev<o.catchLoc)return r(o.catchLoc,!0)}else{if(!s)throw new Error("try statement without catch or finally");if(this.prev<o.finallyLoc)return r(o.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(i.tryLoc<=this.prev&&n.call(i,"finallyLoc")&&this.prev<i.finallyLoc){var o=i;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=e&&e<=o.finallyLoc&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this.complete(n.completion,n.afterLoc),S(n),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc===t){var r=n.completion;if("throw"===r.type){var i=r.arg;S(n)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:_(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=void 0),f}},t}function tn(t){return tn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},tn(t)}function en(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function nn(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,cn(r.key),r)}}function rn(t,e,n){return e&&nn(t.prototype,e),n&&nn(t,n),Object.defineProperty(t,"prototype",{writable:!1}),t}function on(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,o,a,u=[],s=!0,c=!1;try{if(o=(n=n.call(t)).next,0===e){if(Object(n)!==n)return;s=!1}else for(;!(s=(r=o.call(n)).done)&&(u.push(r.value),u.length!==e);s=!0);}catch(t){c=!0,i=t}finally{try{if(!s&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(c)throw i}}return u}}(t,e)||un(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function an(t){return function(t){if(Array.isArray(t))return sn(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||un(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function un(t,e){if(t){if("string"==typeof t)return sn(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?sn(t,e):void 0}}function sn(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function cn(t){var e=function(t,e){if("object"!=typeof t||null===t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,e||"default");if("object"!=typeof r)return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}(t,"string");return"symbol"==typeof e?e:String(e)}var ln="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function fn(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var hn=function(t){return t&&t.Math===Math&&t},dn=hn("object"==typeof globalThis&&globalThis)||hn("object"==typeof window&&window)||hn("object"==typeof self&&self)||hn("object"==typeof ln&&ln)||hn("object"==typeof ln&&ln)||function(){return this}()||Function("return this")(),pn={exports:{}},vn=dn,yn=Object.defineProperty,mn=function(t,e){try{yn(vn,t,{value:e,configurable:!0,writable:!0})}catch(n){vn[t]=e}return e},gn=mn,wn="__core-js_shared__",bn=dn[wn]||gn(wn,{}),xn=bn;(pn.exports=function(t,e){return xn[t]||(xn[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.34.0",mode:"global",copyright:"© 2014-2023 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.34.0/LICENSE",source:"https://github.com/zloirock/core-js"});var On,kn,Sn=pn.exports,jn=function(t){try{return!!t()}catch(t){return!0}},_n=!jn((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})),Mn=_n,Dn=Function.prototype,$n=Dn.call,En=Mn&&Dn.bind.bind($n,$n),Pn=Mn?En:function(t){return function(){return $n.apply(t,arguments)}},Ln=function(t){return null==t},An=Ln,Cn=TypeError,Tn=function(t){if(An(t))throw new Cn("Can't call method on "+t);return t},Rn=Tn,In=Object,Nn=function(t){return In(Rn(t))},Wn=Nn,Fn=Pn({}.hasOwnProperty),zn=Object.hasOwn||function(t,e){return Fn(Wn(t),e)},Hn=Pn,Yn=0,Un=Math.random(),Bn=Hn(1..toString),Gn=function(t){return"Symbol("+(void 0===t?"":t)+")_"+Bn(++Yn+Un,36)},Vn="undefined"!=typeof navigator&&String(navigator.userAgent)||"",qn=dn,Kn=Vn,Zn=qn.process,Jn=qn.Deno,Qn=Zn&&Zn.versions||Jn&&Jn.version,Xn=Qn&&Qn.v8;Xn&&(kn=(On=Xn.split("."))[0]>0&&On[0]<4?1:+(On[0]+On[1])),!kn&&Kn&&(!(On=Kn.match(/Edge\/(\d+)/))||On[1]>=74)&&(On=Kn.match(/Chrome\/(\d+)/))&&(kn=+On[1]);var tr=kn,er=tr,nr=jn,rr=dn.String,ir=!!Object.getOwnPropertySymbols&&!nr((function(){var t=Symbol("symbol detection");return!rr(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&er&&er<41})),or=ir&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,ar=Sn,ur=zn,sr=Gn,cr=ir,lr=or,fr=dn.Symbol,hr=ar("wks"),dr=lr?fr.for||fr:fr&&fr.withoutSetter||sr,pr=function(t){return ur(hr,t)||(hr[t]=cr&&ur(fr,t)?fr[t]:dr("Symbol."+t)),hr[t]},vr={};vr[pr("toStringTag")]="z";var yr="[object z]"===String(vr),mr="object"==typeof document&&document.all,gr={all:mr,IS_HTMLDDA:void 0===mr&&void 0!==mr},wr=gr.all,br=gr.IS_HTMLDDA?function(t){return"function"==typeof t||t===wr}:function(t){return"function"==typeof t},xr={},Or=!jn((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})),kr=br,Sr=gr.all,jr=gr.IS_HTMLDDA?function(t){return"object"==typeof t?null!==t:kr(t)||t===Sr}:function(t){return"object"==typeof t?null!==t:kr(t)},_r=jr,Mr=dn.document,Dr=_r(Mr)&&_r(Mr.createElement),$r=function(t){return Dr?Mr.createElement(t):{}},Er=$r,Pr=!Or&&!jn((function(){return 7!==Object.defineProperty(Er("div"),"a",{get:function(){return 7}}).a})),Lr=Or&&jn((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),Ar=jr,Cr=String,Tr=TypeError,Rr=function(t){if(Ar(t))return t;throw new Tr(Cr(t)+" is not an object")},Ir=_n,Nr=Function.prototype.call,Wr=Ir?Nr.bind(Nr):function(){return Nr.apply(Nr,arguments)},Fr=dn,zr=br,Hr=function(t,e){return arguments.length<2?(n=Fr[t],zr(n)?n:void 0):Fr[t]&&Fr[t][e];var n},Yr=Pn({}.isPrototypeOf),Ur=Hr,Br=br,Gr=Yr,Vr=Object,qr=or?function(t){return"symbol"==typeof t}:function(t){var e=Ur("Symbol");return Br(e)&&Gr(e.prototype,Vr(t))},Kr=String,Zr=function(t){try{return Kr(t)}catch(t){return"Object"}},Jr=br,Qr=Zr,Xr=TypeError,ti=function(t){if(Jr(t))return t;throw new Xr(Qr(t)+" is not a function")},ei=ti,ni=Ln,ri=function(t,e){var n=t[e];return ni(n)?void 0:ei(n)},ii=Wr,oi=br,ai=jr,ui=TypeError,si=Wr,ci=jr,li=qr,fi=ri,hi=function(t,e){var n,r;if("string"===e&&oi(n=t.toString)&&!ai(r=ii(n,t)))return r;if(oi(n=t.valueOf)&&!ai(r=ii(n,t)))return r;if("string"!==e&&oi(n=t.toString)&&!ai(r=ii(n,t)))return r;throw new ui("Can't convert object to primitive value")},di=TypeError,pi=pr("toPrimitive"),vi=function(t,e){if(!ci(t)||li(t))return t;var n,r=fi(t,pi);if(r){if(void 0===e&&(e="default"),n=si(r,t,e),!ci(n)||li(n))return n;throw new di("Can't convert object to primitive value")}return void 0===e&&(e="number"),hi(t,e)},yi=qr,mi=function(t){var e=vi(t,"string");return yi(e)?e:e+""},gi=Or,wi=Pr,bi=Lr,xi=Rr,Oi=mi,ki=TypeError,Si=Object.defineProperty,ji=Object.getOwnPropertyDescriptor,_i="enumerable",Mi="configurable",Di="writable";xr.f=gi?bi?function(t,e,n){if(xi(t),e=Oi(e),xi(n),"function"==typeof t&&"prototype"===e&&"value"in n&&Di in n&&!n[Di]){var r=ji(t,e);r&&r[Di]&&(t[e]=n.value,n={configurable:Mi in n?n[Mi]:r[Mi],enumerable:_i in n?n[_i]:r[_i],writable:!1})}return Si(t,e,n)}:Si:function(t,e,n){if(xi(t),e=Oi(e),xi(n),wi)try{return Si(t,e,n)}catch(t){}if("get"in n||"set"in n)throw new ki("Accessors not supported");return"value"in n&&(t[e]=n.value),t};var $i={exports:{}},Ei=Or,Pi=zn,Li=Function.prototype,Ai=Ei&&Object.getOwnPropertyDescriptor,Ci=Pi(Li,"name"),Ti={EXISTS:Ci,PROPER:Ci&&"something"===function(){}.name,CONFIGURABLE:Ci&&(!Ei||Ei&&Ai(Li,"name").configurable)},Ri=br,Ii=bn,Ni=Pn(Function.toString);Ri(Ii.inspectSource)||(Ii.inspectSource=function(t){return Ni(t)});var Wi,Fi,zi,Hi=Ii.inspectSource,Yi=br,Ui=dn.WeakMap,Bi=Yi(Ui)&&/native code/.test(String(Ui)),Gi=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},Vi=xr,qi=Gi,Ki=Or?function(t,e,n){return Vi.f(t,e,qi(1,n))}:function(t,e,n){return t[e]=n,t},Zi=Gn,Ji=Sn("keys"),Qi=function(t){return Ji[t]||(Ji[t]=Zi(t))},Xi={},to=Bi,eo=dn,no=jr,ro=Ki,io=zn,oo=bn,ao=Qi,uo=Xi,so="Object already initialized",co=eo.TypeError,lo=eo.WeakMap;if(to||oo.state){var fo=oo.state||(oo.state=new lo);fo.get=fo.get,fo.has=fo.has,fo.set=fo.set,Wi=function(t,e){if(fo.has(t))throw new co(so);return e.facade=t,fo.set(t,e),e},Fi=function(t){return fo.get(t)||{}},zi=function(t){return fo.has(t)}}else{var ho=ao("state");uo[ho]=!0,Wi=function(t,e){if(io(t,ho))throw new co(so);return e.facade=t,ro(t,ho,e),e},Fi=function(t){return io(t,ho)?t[ho]:{}},zi=function(t){return io(t,ho)}}var po={set:Wi,get:Fi,has:zi,enforce:function(t){return zi(t)?Fi(t):Wi(t,{})},getterFor:function(t){return function(e){var n;if(!no(e)||(n=Fi(e)).type!==t)throw new co("Incompatible receiver, "+t+" required");return n}}},vo=Pn,yo=jn,mo=br,go=zn,wo=Or,bo=Ti.CONFIGURABLE,xo=Hi,Oo=po.enforce,ko=po.get,So=String,jo=Object.defineProperty,_o=vo("".slice),Mo=vo("".replace),Do=vo([].join),$o=wo&&!yo((function(){return 8!==jo((function(){}),"length",{value:8}).length})),Eo=String(String).split("String"),Po=$i.exports=function(t,e,n){"Symbol("===_o(So(e),0,7)&&(e="["+Mo(So(e),/^Symbol\(([^)]*)\)/,"$1")+"]"),n&&n.getter&&(e="get "+e),n&&n.setter&&(e="set "+e),(!go(t,"name")||bo&&t.name!==e)&&(wo?jo(t,"name",{value:e,configurable:!0}):t.name=e),$o&&n&&go(n,"arity")&&t.length!==n.arity&&jo(t,"length",{value:n.arity});try{n&&go(n,"constructor")&&n.constructor?wo&&jo(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(t){}var r=Oo(t);return go(r,"source")||(r.source=Do(Eo,"string"==typeof e?e:"")),t};Function.prototype.toString=Po((function(){return mo(this)&&ko(this).source||xo(this)}),"toString");var Lo=$i.exports,Ao=br,Co=xr,To=Lo,Ro=mn,Io=function(t,e,n,r){r||(r={});var i=r.enumerable,o=void 0!==r.name?r.name:e;if(Ao(n)&&To(n,o,r),r.global)i?t[e]=n:Ro(e,n);else{try{r.unsafe?t[e]&&(i=!0):delete t[e]}catch(t){}i?t[e]=n:Co.f(t,e,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return t},No=Pn,Wo=No({}.toString),Fo=No("".slice),zo=function(t){return Fo(Wo(t),8,-1)},Ho=yr,Yo=br,Uo=zo,Bo=pr("toStringTag"),Go=Object,Vo="Arguments"===Uo(function(){return arguments}()),qo=Ho?Uo:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=Go(t),Bo))?n:Vo?Uo(e):"Object"===(r=Uo(e))&&Yo(e.callee)?"Arguments":r},Ko=qo,Zo=yr?{}.toString:function(){return"[object "+Ko(this)+"]"};yr||Io(Object.prototype,"toString",Zo,{unsafe:!0});var Jo={},Qo={},Xo={}.propertyIsEnumerable,ta=Object.getOwnPropertyDescriptor,ea=ta&&!Xo.call({1:2},1);Qo.f=ea?function(t){var e=ta(this,t);return!!e&&e.enumerable}:Xo;var na=jn,ra=zo,ia=Object,oa=Pn("".split),aa=na((function(){return!ia("z").propertyIsEnumerable(0)}))?function(t){return"String"===ra(t)?oa(t,""):ia(t)}:ia,ua=aa,sa=Tn,ca=function(t){return ua(sa(t))},la=Or,fa=Wr,ha=Qo,da=Gi,pa=ca,va=mi,ya=zn,ma=Pr,ga=Object.getOwnPropertyDescriptor;Jo.f=la?ga:function(t,e){if(t=pa(t),e=va(e),ma)try{return ga(t,e)}catch(t){}if(ya(t,e))return da(!fa(ha.f,t,e),t[e])};var wa={},ba=Math.ceil,xa=Math.floor,Oa=Math.trunc||function(t){var e=+t;return(e>0?xa:ba)(e)},ka=function(t){var e=+t;return e!=e||0===e?0:Oa(e)},Sa=ka,ja=Math.max,_a=Math.min,Ma=function(t,e){var n=Sa(t);return n<0?ja(n+e,0):_a(n,e)},Da=ka,$a=Math.min,Ea=function(t){return t>0?$a(Da(t),9007199254740991):0},Pa=Ea,La=function(t){return Pa(t.length)},Aa=ca,Ca=Ma,Ta=La,Ra=function(t){return function(e,n,r){var i,o=Aa(e),a=Ta(o),u=Ca(r,a);if(t&&n!=n){for(;a>u;)if((i=o[u++])!=i)return!0}else for(;a>u;u++)if((t||u in o)&&o[u]===n)return t||u||0;return!t&&-1}},Ia={includes:Ra(!0),indexOf:Ra(!1)},Na=zn,Wa=ca,Fa=Ia.indexOf,za=Xi,Ha=Pn([].push),Ya=function(t,e){var n,r=Wa(t),i=0,o=[];for(n in r)!Na(za,n)&&Na(r,n)&&Ha(o,n);for(;e.length>i;)Na(r,n=e[i++])&&(~Fa(o,n)||Ha(o,n));return o},Ua=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],Ba=Ya,Ga=Ua.concat("length","prototype");wa.f=Object.getOwnPropertyNames||function(t){return Ba(t,Ga)};var Va={};Va.f=Object.getOwnPropertySymbols;var qa=Hr,Ka=wa,Za=Va,Ja=Rr,Qa=Pn([].concat),Xa=qa("Reflect","ownKeys")||function(t){var e=Ka.f(Ja(t)),n=Za.f;return n?Qa(e,n(t)):e},tu=zn,eu=Xa,nu=Jo,ru=xr,iu=jn,ou=br,au=/#|\.prototype\./,uu=function(t,e){var n=cu[su(t)];return n===fu||n!==lu&&(ou(e)?iu(e):!!e)},su=uu.normalize=function(t){return String(t).replace(au,".").toLowerCase()},cu=uu.data={},lu=uu.NATIVE="N",fu=uu.POLYFILL="P",hu=uu,du=dn,pu=Jo.f,vu=Ki,yu=Io,mu=mn,gu=function(t,e,n){for(var r=eu(e),i=ru.f,o=nu.f,a=0;a<r.length;a++){var u=r[a];tu(t,u)||n&&tu(n,u)||i(t,u,o(e,u))}},wu=hu,bu=function(t,e){var n,r,i,o,a,u=t.target,s=t.global,c=t.stat;if(n=s?du:c?du[u]||mu(u,{}):(du[u]||{}).prototype)for(r in e){if(o=e[r],i=t.dontCallGetSet?(a=pu(n,r))&&a.value:n[r],!wu(s?r:u+(c?".":"#")+r,t.forced)&&void 0!==i){if(typeof o==typeof i)continue;gu(o,i)}(t.sham||i&&i.sham)&&vu(o,"sham",!0),yu(n,r,o,t)}},xu="process"===zo(dn.process),Ou=Pn,ku=ti,Su=br,ju=String,_u=TypeError,Mu=function(t,e,n){try{return Ou(ku(Object.getOwnPropertyDescriptor(t,e)[n]))}catch(t){}},Du=Rr,$u=function(t){if("object"==typeof t||Su(t))return t;throw new _u("Can't set "+ju(t)+" as a prototype")},Eu=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=Mu(Object.prototype,"__proto__","set"))(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return Du(n),$u(r),e?t(n,r):n.__proto__=r,n}}():void 0),Pu=xr.f,Lu=zn,Au=pr("toStringTag"),Cu=function(t,e,n){t&&!n&&(t=t.prototype),t&&!Lu(t,Au)&&Pu(t,Au,{configurable:!0,value:e})},Tu=Lo,Ru=xr,Iu=function(t,e,n){return n.get&&Tu(n.get,e,{getter:!0}),n.set&&Tu(n.set,e,{setter:!0}),Ru.f(t,e,n)},Nu=Hr,Wu=Iu,Fu=Or,zu=pr("species"),Hu=function(t){var e=Nu(t);Fu&&e&&!e[zu]&&Wu(e,zu,{configurable:!0,get:function(){return this}})},Yu=Yr,Uu=TypeError,Bu=function(t,e){if(Yu(e,t))return t;throw new Uu("Incorrect invocation")},Gu=Pn,Vu=jn,qu=br,Ku=qo,Zu=Hi,Ju=function(){},Qu=[],Xu=Hr("Reflect","construct"),ts=/^\s*(?:class|function)\b/,es=Gu(ts.exec),ns=!ts.test(Ju),rs=function(t){if(!qu(t))return!1;try{return Xu(Ju,Qu,t),!0}catch(t){return!1}},is=function(t){if(!qu(t))return!1;switch(Ku(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return ns||!!es(ts,Zu(t))}catch(t){return!0}};is.sham=!0;var os,as,us,ss,cs=!Xu||Vu((function(){var t;return rs(rs.call)||!rs(Object)||!rs((function(){t=!0}))||t}))?is:rs,ls=cs,fs=Zr,hs=TypeError,ds=Rr,ps=function(t){if(ls(t))return t;throw new hs(fs(t)+" is not a constructor")},vs=Ln,ys=pr("species"),ms=_n,gs=Function.prototype,ws=gs.apply,bs=gs.call,xs="object"==typeof Reflect&&Reflect.apply||(ms?bs.bind(ws):function(){return bs.apply(ws,arguments)}),Os=zo,ks=Pn,Ss=function(t){if("Function"===Os(t))return ks(t)},js=ti,_s=_n,Ms=Ss(Ss.bind),Ds=function(t,e){return js(t),void 0===e?t:_s?Ms(t,e):function(){return t.apply(e,arguments)}},$s=Hr("document","documentElement"),Es=Pn([].slice),Ps=TypeError,Ls=/(?:ipad|iphone|ipod).*applewebkit/i.test(Vn),As=dn,Cs=xs,Ts=Ds,Rs=br,Is=zn,Ns=jn,Ws=$s,Fs=Es,zs=$r,Hs=function(t,e){if(t<e)throw new Ps("Not enough arguments");return t},Ys=Ls,Us=xu,Bs=As.setImmediate,Gs=As.clearImmediate,Vs=As.process,qs=As.Dispatch,Ks=As.Function,Zs=As.MessageChannel,Js=As.String,Qs=0,Xs={},tc="onreadystatechange";Ns((function(){os=As.location}));var ec=function(t){if(Is(Xs,t)){var e=Xs[t];delete Xs[t],e()}},nc=function(t){return function(){ec(t)}},rc=function(t){ec(t.data)},ic=function(t){As.postMessage(Js(t),os.protocol+"//"+os.host)};Bs&&Gs||(Bs=function(t){Hs(arguments.length,1);var e=Rs(t)?t:Ks(t),n=Fs(arguments,1);return Xs[++Qs]=function(){Cs(e,void 0,n)},as(Qs),Qs},Gs=function(t){delete Xs[t]},Us?as=function(t){Vs.nextTick(nc(t))}:qs&&qs.now?as=function(t){qs.now(nc(t))}:Zs&&!Ys?(ss=(us=new Zs).port2,us.port1.onmessage=rc,as=Ts(ss.postMessage,ss)):As.addEventListener&&Rs(As.postMessage)&&!As.importScripts&&os&&"file:"!==os.protocol&&!Ns(ic)?(as=ic,As.addEventListener("message",rc,!1)):as=tc in zs("script")?function(t){Ws.appendChild(zs("script"))[tc]=function(){Ws.removeChild(this),ec(t)}}:function(t){setTimeout(nc(t),0)});var oc={set:Bs,clear:Gs},ac=function(){this.head=null,this.tail=null};ac.prototype={add:function(t){var e={item:t,next:null},n=this.tail;n?n.next=e:this.head=e,this.tail=e},get:function(){var t=this.head;if(t)return null===(this.head=t.next)&&(this.tail=null),t.item}};var uc,sc,cc,lc,fc,hc=ac,dc=/ipad|iphone|ipod/i.test(Vn)&&"undefined"!=typeof Pebble,pc=/web0s(?!.*chrome)/i.test(Vn),vc=dn,yc=Ds,mc=Jo.f,gc=oc.set,wc=hc,bc=Ls,xc=dc,Oc=pc,kc=xu,Sc=vc.MutationObserver||vc.WebKitMutationObserver,jc=vc.document,_c=vc.process,Mc=vc.Promise,Dc=mc(vc,"queueMicrotask"),$c=Dc&&Dc.value;if(!$c){var Ec=new wc,Pc=function(){var t,e;for(kc&&(t=_c.domain)&&t.exit();e=Ec.get();)try{e()}catch(t){throw Ec.head&&uc(),t}t&&t.enter()};bc||kc||Oc||!Sc||!jc?!xc&&Mc&&Mc.resolve?((lc=Mc.resolve(void 0)).constructor=Mc,fc=yc(lc.then,lc),uc=function(){fc(Pc)}):kc?uc=function(){_c.nextTick(Pc)}:(gc=yc(gc,vc),uc=function(){gc(Pc)}):(sc=!0,cc=jc.createTextNode(""),new Sc(Pc).observe(cc,{characterData:!0}),uc=function(){cc.data=sc=!sc}),$c=function(t){Ec.head||uc(),Ec.add(t)}}var Lc=$c,Ac=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}},Cc=dn.Promise,Tc="object"==typeof Deno&&Deno&&"object"==typeof Deno.version,Rc=!Tc&&!xu&&"object"==typeof window&&"object"==typeof document,Ic=dn,Nc=Cc,Wc=br,Fc=hu,zc=Hi,Hc=pr,Yc=Rc,Uc=Tc,Bc=tr;Nc&&Nc.prototype;var Gc=Hc("species"),Vc=!1,qc=Wc(Ic.PromiseRejectionEvent),Kc=Fc("Promise",(function(){var t=zc(Nc),e=t!==String(Nc);if(!e&&66===Bc)return!0;if(!Bc||Bc<51||!/native code/.test(t)){var n=new Nc((function(t){t(1)})),r=function(t){t((function(){}),(function(){}))};if((n.constructor={})[Gc]=r,!(Vc=n.then((function(){}))instanceof r))return!0}return!e&&(Yc||Uc)&&!qc})),Zc={CONSTRUCTOR:Kc,REJECTION_EVENT:qc,SUBCLASSING:Vc},Jc={},Qc=ti,Xc=TypeError,tl=function(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw new Xc("Bad Promise constructor");e=t,n=r})),this.resolve=Qc(e),this.reject=Qc(n)};Jc.f=function(t){return new tl(t)};var el,nl,rl,il=bu,ol=xu,al=dn,ul=Wr,sl=Io,cl=Eu,ll=Cu,fl=Hu,hl=ti,dl=br,pl=jr,vl=Bu,yl=function(t,e){var n,r=ds(t).constructor;return void 0===r||vs(n=ds(r)[ys])?e:ps(n)},ml=oc.set,gl=Lc,wl=function(t,e){try{1===arguments.length?console.error(t):console.error(t,e)}catch(t){}},bl=Ac,xl=hc,Ol=po,kl=Cc,Sl=Jc,jl="Promise",_l=Zc.CONSTRUCTOR,Ml=Zc.REJECTION_EVENT,Dl=Zc.SUBCLASSING,$l=Ol.getterFor(jl),El=Ol.set,Pl=kl&&kl.prototype,Ll=kl,Al=Pl,Cl=al.TypeError,Tl=al.document,Rl=al.process,Il=Sl.f,Nl=Il,Wl=!!(Tl&&Tl.createEvent&&al.dispatchEvent),Fl="unhandledrejection",zl=function(t){var e;return!(!pl(t)||!dl(e=t.then))&&e},Hl=function(t,e){var n,r,i,o=e.value,a=1===e.state,u=a?t.ok:t.fail,s=t.resolve,c=t.reject,l=t.domain;try{u?(a||(2===e.rejection&&Vl(e),e.rejection=1),!0===u?n=o:(l&&l.enter(),n=u(o),l&&(l.exit(),i=!0)),n===t.promise?c(new Cl("Promise-chain cycle")):(r=zl(n))?ul(r,n,s,c):s(n)):c(o)}catch(t){l&&!i&&l.exit(),c(t)}},Yl=function(t,e){t.notified||(t.notified=!0,gl((function(){for(var n,r=t.reactions;n=r.get();)Hl(n,t);t.notified=!1,e&&!t.rejection&&Bl(t)})))},Ul=function(t,e,n){var r,i;Wl?((r=Tl.createEvent("Event")).promise=e,r.reason=n,r.initEvent(t,!1,!0),al.dispatchEvent(r)):r={promise:e,reason:n},!Ml&&(i=al["on"+t])?i(r):t===Fl&&wl("Unhandled promise rejection",n)},Bl=function(t){ul(ml,al,(function(){var e,n=t.facade,r=t.value;if(Gl(t)&&(e=bl((function(){ol?Rl.emit("unhandledRejection",r,n):Ul(Fl,n,r)})),t.rejection=ol||Gl(t)?2:1,e.error))throw e.value}))},Gl=function(t){return 1!==t.rejection&&!t.parent},Vl=function(t){ul(ml,al,(function(){var e=t.facade;ol?Rl.emit("rejectionHandled",e):Ul("rejectionhandled",e,t.value)}))},ql=function(t,e,n){return function(r){t(e,r,n)}},Kl=function(t,e,n){t.done||(t.done=!0,n&&(t=n),t.value=e,t.state=2,Yl(t,!0))},Zl=function(t,e,n){if(!t.done){t.done=!0,n&&(t=n);try{if(t.facade===e)throw new Cl("Promise can't be resolved itself");var r=zl(e);r?gl((function(){var n={done:!1};try{ul(r,e,ql(Zl,n,t),ql(Kl,n,t))}catch(e){Kl(n,e,t)}})):(t.value=e,t.state=1,Yl(t,!1))}catch(e){Kl({done:!1},e,t)}}};if(_l&&(Al=(Ll=function(t){vl(this,Al),hl(t),ul(el,this);var e=$l(this);try{t(ql(Zl,e),ql(Kl,e))}catch(t){Kl(e,t)}}).prototype,(el=function(t){El(this,{type:jl,done:!1,notified:!1,parent:!1,reactions:new xl,rejection:!1,state:0,value:void 0})}).prototype=sl(Al,"then",(function(t,e){var n=$l(this),r=Il(yl(this,Ll));return n.parent=!0,r.ok=!dl(t)||t,r.fail=dl(e)&&e,r.domain=ol?Rl.domain:void 0,0===n.state?n.reactions.add(r):gl((function(){Hl(r,n)})),r.promise})),nl=function(){var t=new el,e=$l(t);this.promise=t,this.resolve=ql(Zl,e),this.reject=ql(Kl,e)},Sl.f=Il=function(t){return t===Ll||undefined===t?new nl(t):Nl(t)},dl(kl)&&Pl!==Object.prototype)){rl=Pl.then,Dl||sl(Pl,"then",(function(t,e){var n=this;return new Ll((function(t,e){ul(rl,n,t,e)})).then(t,e)}),{unsafe:!0});try{delete Pl.constructor}catch(t){}cl&&cl(Pl,Al)}il({global:!0,constructor:!0,wrap:!0,forced:_l},{Promise:Ll}),ll(Ll,jl,!1),fl(jl);var Jl={},Ql=Jl,Xl=pr("iterator"),tf=Array.prototype,ef=function(t){return void 0!==t&&(Ql.Array===t||tf[Xl]===t)},nf=qo,rf=ri,of=Ln,af=Jl,uf=pr("iterator"),sf=function(t){if(!of(t))return rf(t,uf)||rf(t,"@@iterator")||af[nf(t)]},cf=Wr,lf=ti,ff=Rr,hf=Zr,df=sf,pf=TypeError,vf=function(t,e){var n=arguments.length<2?df(t):e;if(lf(n))return ff(cf(n,t));throw new pf(hf(t)+" is not iterable")},yf=Wr,mf=Rr,gf=ri,wf=function(t,e,n){var r,i;mf(t);try{if(!(r=gf(t,"return"))){if("throw"===e)throw n;return n}r=yf(r,t)}catch(t){i=!0,r=t}if("throw"===e)throw n;if(i)throw r;return mf(r),n},bf=Ds,xf=Wr,Of=Rr,kf=Zr,Sf=ef,jf=La,_f=Yr,Mf=vf,Df=sf,$f=wf,Ef=TypeError,Pf=function(t,e){this.stopped=t,this.result=e},Lf=Pf.prototype,Af=function(t,e,n){var r,i,o,a,u,s,c,l=n&&n.that,f=!(!n||!n.AS_ENTRIES),h=!(!n||!n.IS_RECORD),d=!(!n||!n.IS_ITERATOR),p=!(!n||!n.INTERRUPTED),v=bf(e,l),y=function(t){return r&&$f(r,"normal",t),new Pf(!0,t)},m=function(t){return f?(Of(t),p?v(t[0],t[1],y):v(t[0],t[1])):p?v(t,y):v(t)};if(h)r=t.iterator;else if(d)r=t;else{if(!(i=Df(t)))throw new Ef(kf(t)+" is not iterable");if(Sf(i)){for(o=0,a=jf(t);a>o;o++)if((u=m(t[o]))&&_f(Lf,u))return u;return new Pf(!1)}r=Mf(t,i)}for(s=h?t.next:r.next;!(c=xf(s,r)).done;){try{u=m(c.value)}catch(t){$f(r,"throw",t)}if("object"==typeof u&&u&&_f(Lf,u))return u}return new Pf(!1)},Cf=pr("iterator"),Tf=!1;try{var Rf=0,If={next:function(){return{done:!!Rf++}},return:function(){Tf=!0}};If[Cf]=function(){return this},Array.from(If,(function(){throw 2}))}catch(t){}var Nf=function(t,e){try{if(!e&&!Tf)return!1}catch(t){return!1}var n=!1;try{var r={};r[Cf]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(t){}return n},Wf=Cc,Ff=Zc.CONSTRUCTOR||!Nf((function(t){Wf.all(t).then(void 0,(function(){}))})),zf=Wr,Hf=ti,Yf=Jc,Uf=Ac,Bf=Af;bu({target:"Promise",stat:!0,forced:Ff},{all:function(t){var e=this,n=Yf.f(e),r=n.resolve,i=n.reject,o=Uf((function(){var n=Hf(e.resolve),o=[],a=0,u=1;Bf(t,(function(t){var s=a++,c=!1;u++,zf(n,e,t).then((function(t){c||(c=!0,o[s]=t,--u||r(o))}),i)})),--u||r(o)}));return o.error&&i(o.value),n.promise}});var Gf=bu,Vf=Zc.CONSTRUCTOR,qf=Cc,Kf=Hr,Zf=br,Jf=Io,Qf=qf&&qf.prototype;if(Gf({target:"Promise",proto:!0,forced:Vf,real:!0},{catch:function(t){return this.then(void 0,t)}}),Zf(qf)){var Xf=Kf("Promise").prototype.catch;Qf.catch!==Xf&&Jf(Qf,"catch",Xf,{unsafe:!0})}var th=Wr,eh=ti,nh=Jc,rh=Ac,ih=Af;bu({target:"Promise",stat:!0,forced:Ff},{race:function(t){var e=this,n=nh.f(e),r=n.reject,i=rh((function(){var i=eh(e.resolve);ih(t,(function(t){th(i,e,t).then(n.resolve,r)}))}));return i.error&&r(i.value),n.promise}});var oh=Wr,ah=Jc;bu({target:"Promise",stat:!0,forced:Zc.CONSTRUCTOR},{reject:function(t){var e=ah.f(this);return oh(e.reject,void 0,t),e.promise}});var uh=Rr,sh=jr,ch=Jc,lh=bu,fh=Zc.CONSTRUCTOR,hh=function(t,e){if(uh(t),sh(e)&&e.constructor===t)return e;var n=ch.f(t);return(0,n.resolve)(e),n.promise};Hr("Promise"),lh({target:"Promise",stat:!0,forced:fh},{resolve:function(t){return hh(this,t)}});var dh={},ph=Ya,vh=Ua,yh=Object.keys||function(t){return ph(t,vh)},mh=Or,gh=Lr,wh=xr,bh=Rr,xh=ca,Oh=yh;dh.f=mh&&!gh?Object.defineProperties:function(t,e){bh(t);for(var n,r=xh(e),i=Oh(e),o=i.length,a=0;o>a;)wh.f(t,n=i[a++],r[n]);return t};var kh,Sh=Rr,jh=dh,_h=Ua,Mh=Xi,Dh=$s,$h=$r,Eh="prototype",Ph="script",Lh=Qi("IE_PROTO"),Ah=function(){},Ch=function(t){return"<"+Ph+">"+t+"</"+Ph+">"},Th=function(t){t.write(Ch("")),t.close();var e=t.parentWindow.Object;return t=null,e},Rh=function(){try{kh=new ActiveXObject("htmlfile")}catch(t){}var t,e,n;Rh="undefined"!=typeof document?document.domain&&kh?Th(kh):(e=$h("iframe"),n="java"+Ph+":",e.style.display="none",Dh.appendChild(e),e.src=String(n),(t=e.contentWindow.document).open(),t.write(Ch("document.F=Object")),t.close(),t.F):Th(kh);for(var r=_h.length;r--;)delete Rh[Eh][_h[r]];return Rh()};Mh[Lh]=!0;var Ih=Object.create||function(t,e){var n;return null!==t?(Ah[Eh]=Sh(t),n=new Ah,Ah[Eh]=null,n[Lh]=t):n=Rh(),void 0===e?n:jh.f(n,e)},Nh=pr,Wh=Ih,Fh=xr.f,zh=Nh("unscopables"),Hh=Array.prototype;void 0===Hh[zh]&&Fh(Hh,zh,{configurable:!0,value:Wh(null)});var Yh,Uh,Bh,Gh=function(t){Hh[zh][t]=!0},Vh=!jn((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),qh=zn,Kh=br,Zh=Nn,Jh=Vh,Qh=Qi("IE_PROTO"),Xh=Object,td=Xh.prototype,ed=Jh?Xh.getPrototypeOf:function(t){var e=Zh(t);if(qh(e,Qh))return e[Qh];var n=e.constructor;return Kh(n)&&e instanceof n?n.prototype:e instanceof Xh?td:null},nd=jn,rd=br,id=jr,od=ed,ad=Io,ud=pr("iterator"),sd=!1;[].keys&&("next"in(Bh=[].keys())?(Uh=od(od(Bh)))!==Object.prototype&&(Yh=Uh):sd=!0);var cd=!id(Yh)||nd((function(){var t={};return Yh[ud].call(t)!==t}));cd&&(Yh={}),rd(Yh[ud])||ad(Yh,ud,(function(){return this}));var ld={IteratorPrototype:Yh,BUGGY_SAFARI_ITERATORS:sd},fd=ld.IteratorPrototype,hd=Ih,dd=Gi,pd=Cu,vd=Jl,yd=function(){return this},md=bu,gd=Wr,wd=br,bd=function(t,e,n,r){var i=e+" Iterator";return t.prototype=hd(fd,{next:dd(+!r,n)}),pd(t,i,!1),vd[i]=yd,t},xd=ed,Od=Eu,kd=Cu,Sd=Ki,jd=Io,_d=Jl,Md=Ti.PROPER,Dd=Ti.CONFIGURABLE,$d=ld.IteratorPrototype,Ed=ld.BUGGY_SAFARI_ITERATORS,Pd=pr("iterator"),Ld="keys",Ad="values",Cd="entries",Td=function(){return this},Rd=function(t,e,n,r,i,o,a){bd(n,e,r);var u,s,c,l=function(t){if(t===i&&v)return v;if(!Ed&&t&&t in d)return d[t];switch(t){case Ld:case Ad:case Cd:return function(){return new n(this,t)}}return function(){return new n(this)}},f=e+" Iterator",h=!1,d=t.prototype,p=d[Pd]||d["@@iterator"]||i&&d[i],v=!Ed&&p||l(i),y="Array"===e&&d.entries||p;if(y&&(u=xd(y.call(new t)))!==Object.prototype&&u.next&&(xd(u)!==$d&&(Od?Od(u,$d):wd(u[Pd])||jd(u,Pd,Td)),kd(u,f,!0)),Md&&i===Ad&&p&&p.name!==Ad&&(Dd?Sd(d,"name",Ad):(h=!0,v=function(){return gd(p,this)})),i)if(s={values:l(Ad),keys:o?v:l(Ld),entries:l(Cd)},a)for(c in s)(Ed||h||!(c in d))&&jd(d,c,s[c]);else md({target:e,proto:!0,forced:Ed||h},s);return d[Pd]!==v&&jd(d,Pd,v,{name:i}),_d[e]=v,s},Id=function(t,e){return{value:t,done:e}},Nd=ca,Wd=Gh,Fd=Jl,zd=po,Hd=xr.f,Yd=Rd,Ud=Id,Bd=Or,Gd="Array Iterator",Vd=zd.set,qd=zd.getterFor(Gd),Kd=Yd(Array,"Array",(function(t,e){Vd(this,{type:Gd,target:Nd(t),index:0,kind:e})}),(function(){var t=qd(this),e=t.target,n=t.index++;if(!e||n>=e.length)return t.target=void 0,Ud(void 0,!0);switch(t.kind){case"keys":return Ud(n,!1);case"values":return Ud(e[n],!1)}return Ud([n,e[n]],!1)}),"values"),Zd=Fd.Arguments=Fd.Array;if(Wd("keys"),Wd("values"),Wd("entries"),Bd&&"values"!==Zd.name)try{Hd(Zd,"name",{value:"values"})}catch(t){}var Jd=Wr,Qd=ti,Xd=Jc,tp=Ac,ep=Af;bu({target:"Promise",stat:!0,forced:Ff},{allSettled:function(t){var e=this,n=Xd.f(e),r=n.resolve,i=n.reject,o=tp((function(){var n=Qd(e.resolve),i=[],o=0,a=1;ep(t,(function(t){var u=o++,s=!1;a++,Jd(n,e,t).then((function(t){s||(s=!0,i[u]={status:"fulfilled",value:t},--a||r(i))}),(function(t){s||(s=!0,i[u]={status:"rejected",reason:t},--a||r(i))}))})),--a||r(i)}));return o.error&&i(o.value),n.promise}});var np=qo,rp=String,ip=function(t){if("Symbol"===np(t))throw new TypeError("Cannot convert a Symbol value to a string");return rp(t)},op=Pn,ap=ka,up=ip,sp=Tn,cp=op("".charAt),lp=op("".charCodeAt),fp=op("".slice),hp=function(t){return function(e,n){var r,i,o=up(sp(e)),a=ap(n),u=o.length;return a<0||a>=u?t?"":void 0:(r=lp(o,a))<55296||r>56319||a+1===u||(i=lp(o,a+1))<56320||i>57343?t?cp(o,a):r:t?fp(o,a,a+2):i-56320+(r-55296<<10)+65536}},dp={codeAt:hp(!1),charAt:hp(!0)},pp=dp.charAt,vp=ip,yp=po,mp=Rd,gp=Id,wp="String Iterator",bp=yp.set,xp=yp.getterFor(wp);mp(String,"String",(function(t){bp(this,{type:wp,string:vp(t),index:0})}),(function(){var t,e=xp(this),n=e.string,r=e.index;return r>=n.length?gp(void 0,!0):(t=pp(n,r),e.index+=t.length,gp(t,!1))}));var Op={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},kp=$r("span").classList,Sp=kp&&kp.constructor&&kp.constructor.prototype,jp=Sp===Object.prototype?void 0:Sp,_p=dn,Mp=Op,Dp=jp,$p=Kd,Ep=Ki,Pp=Cu,Lp=pr("iterator"),Ap=$p.values,Cp=function(t,e){if(t){if(t[Lp]!==Ap)try{Ep(t,Lp,Ap)}catch(e){t[Lp]=Ap}if(Pp(t,e,!0),Mp[e])for(var n in $p)if(t[n]!==$p[n])try{Ep(t,n,$p[n])}catch(e){t[n]=$p[n]}}};for(var Tp in Mp)Cp(_p[Tp]&&_p[Tp].prototype,Tp);Cp(Dp,"DOMTokenList");var Rp=Nn,Ip=Ma,Np=La,Wp=function(t){for(var e=Rp(this),n=Np(e),r=arguments.length,i=Ip(r>1?arguments[1]:void 0,n),o=r>2?arguments[2]:void 0,a=void 0===o?n:Ip(o,n);a>i;)e[i++]=t;return e},Fp=Gh;bu({target:"Array",proto:!0},{fill:Wp}),Fp("fill");var zp=zo,Hp=Array.isArray||function(t){return"Array"===zp(t)},Yp=mi,Up=xr,Bp=Gi,Gp=function(t,e,n){var r=Yp(e);r in t?Up.f(t,r,Bp(0,n)):t[r]=n},Vp=jn,qp=tr,Kp=pr("species"),Zp=function(t){return qp>=51||!Vp((function(){var e=[];return(e.constructor={})[Kp]=function(){return{foo:1}},1!==e[t](Boolean).foo}))},Jp=bu,Qp=Hp,Xp=cs,tv=jr,ev=Ma,nv=La,rv=ca,iv=Gp,ov=pr,av=Es,uv=Zp("slice"),sv=ov("species"),cv=Array,lv=Math.max;function fv(t,e,n,r){return new(n||(n=Promise))((function(i,o){function a(t){try{s(r.next(t))}catch(t){o(t)}}function u(t){try{s(r.throw(t))}catch(t){o(t)}}function s(t){var e;t.done?i(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(a,u)}s((r=r.apply(t,e||[])).next())}))}function hv(t,e,n,r){if("a"===n&&!r)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!r:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===n?r:"a"===n?r.call(t):r?r.value:e.get(t)}Jp({target:"Array",proto:!0,forced:!uv},{slice:function(t,e){var n,r,i,o=rv(this),a=nv(o),u=ev(t,a),s=ev(void 0===e?a:e,a);if(Qp(o)&&(n=o.constructor,(Xp(n)&&(n===cv||Qp(n.prototype))||tv(n)&&null===(n=n[sv]))&&(n=void 0),n===cv||void 0===n))return av(o,u,s);for(r=new(void 0===n?cv:n)(lv(s-u,0)),i=0;u<s;u++,i++)u in o&&iv(r,i,o[u]);return r.length=i,r}});var dv={exports:{}};!function(t){var e=Object.prototype.hasOwnProperty,n="~";function r(){}function i(t,e,n){this.fn=t,this.context=e,this.once=n||!1}function o(t,e,r,o,a){if("function"!=typeof r)throw new TypeError("The listener must be a function");var u=new i(r,o||t,a),s=n?n+e:e;return t._events[s]?t._events[s].fn?t._events[s]=[t._events[s],u]:t._events[s].push(u):(t._events[s]=u,t._eventsCount++),t}function a(t,e){0==--t._eventsCount?t._events=new r:delete t._events[e]}function u(){this._events=new r,this._eventsCount=0}Object.create&&(r.prototype=Object.create(null),(new r).__proto__||(n=!1)),u.prototype.eventNames=function(){var t,r,i=[];if(0===this._eventsCount)return i;for(r in t=this._events)e.call(t,r)&&i.push(n?r.slice(1):r);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(t)):i},u.prototype.listeners=function(t){var e=n?n+t:t,r=this._events[e];if(!r)return[];if(r.fn)return[r.fn];for(var i=0,o=r.length,a=new Array(o);i<o;i++)a[i]=r[i].fn;return a},u.prototype.listenerCount=function(t){var e=n?n+t:t,r=this._events[e];return r?r.fn?1:r.length:0},u.prototype.emit=function(t,e,r,i,o,a){var u=n?n+t:t;if(!this._events[u])return!1;var s,c,l=this._events[u],f=arguments.length;if(l.fn){switch(l.once&&this.removeListener(t,l.fn,void 0,!0),f){case 1:return l.fn.call(l.context),!0;case 2:return l.fn.call(l.context,e),!0;case 3:return l.fn.call(l.context,e,r),!0;case 4:return l.fn.call(l.context,e,r,i),!0;case 5:return l.fn.call(l.context,e,r,i,o),!0;case 6:return l.fn.call(l.context,e,r,i,o,a),!0}for(c=1,s=new Array(f-1);c<f;c++)s[c-1]=arguments[c];l.fn.apply(l.context,s)}else{var h,d=l.length;for(c=0;c<d;c++)switch(l[c].once&&this.removeListener(t,l[c].fn,void 0,!0),f){case 1:l[c].fn.call(l[c].context);break;case 2:l[c].fn.call(l[c].context,e);break;case 3:l[c].fn.call(l[c].context,e,r);break;case 4:l[c].fn.call(l[c].context,e,r,i);break;default:if(!s)for(h=1,s=new Array(f-1);h<f;h++)s[h-1]=arguments[h];l[c].fn.apply(l[c].context,s)}}return!0},u.prototype.on=function(t,e,n){return o(this,t,e,n,!1)},u.prototype.once=function(t,e,n){return o(this,t,e,n,!0)},u.prototype.removeListener=function(t,e,r,i){var o=n?n+t:t;if(!this._events[o])return this;if(!e)return a(this,o),this;var u=this._events[o];if(u.fn)u.fn!==e||i&&!u.once||r&&u.context!==r||a(this,o);else{for(var s=0,c=[],l=u.length;s<l;s++)(u[s].fn!==e||i&&!u[s].once||r&&u[s].context!==r)&&c.push(u[s]);c.length?this._events[o]=1===c.length?c[0]:c:a(this,o)}return this},u.prototype.removeAllListeners=function(t){var e;return t?(e=n?n+t:t,this._events[e]&&a(this,e)):(this._events=new r,this._eventsCount=0),this},u.prototype.off=u.prototype.removeListener,u.prototype.addListener=u.prototype.on,u.prefixed=n,u.EventEmitter=u,t.exports=u}(dv);var pv=fn(dv.exports),vv=Array.isArray;function yv(){if(!arguments.length)return[];var t=arguments[0];return vv(t)?t:[t]}var mv=Hp,gv=cs,wv=jr,bv=pr("species"),xv=Array,Ov=function(t){var e;return mv(t)&&(e=t.constructor,(gv(e)&&(e===xv||mv(e.prototype))||wv(e)&&null===(e=e[bv]))&&(e=void 0)),void 0===e?xv:e},kv=function(t,e){return new(Ov(t))(0===e?0:e)},Sv=Ds,jv=aa,_v=Nn,Mv=La,Dv=kv,$v=Pn([].push),Ev=function(t){var e=1===t,n=2===t,r=3===t,i=4===t,o=6===t,a=7===t,u=5===t||o;return function(s,c,l,f){for(var h,d,p=_v(s),v=jv(p),y=Mv(v),m=Sv(c,l),g=0,w=f||Dv,b=e?w(s,y):n||a?w(s,0):void 0;y>g;g++)if((u||g in v)&&(d=m(h=v[g],g,p),t))if(e)b[g]=d;else if(d)switch(t){case 3:return!0;case 5:return h;case 6:return g;case 2:$v(b,h)}else switch(t){case 4:return!1;case 7:$v(b,h)}return o?-1:r||i?i:b}},Pv={forEach:Ev(0),map:Ev(1),filter:Ev(2),some:Ev(3),every:Ev(4),find:Ev(5),findIndex:Ev(6),filterReject:Ev(7)},Lv=Pv.map;bu({target:"Array",proto:!0,forced:!Zp("map")},{map:function(t){return Lv(this,t,arguments.length>1?arguments[1]:void 0)}});var Av=Or,Cv=Pn,Tv=Wr,Rv=jn,Iv=yh,Nv=Va,Wv=Qo,Fv=Nn,zv=aa,Hv=Object.assign,Yv=Object.defineProperty,Uv=Cv([].concat),Bv=!Hv||Rv((function(){if(Av&&1!==Hv({b:1},Hv(Yv({},"a",{enumerable:!0,get:function(){Yv(this,"b",{value:3,enumerable:!1})}}),{b:2})).b)return!0;var t={},e={},n=Symbol("assign detection"),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach((function(t){e[t]=t})),7!==Hv({},t)[n]||Iv(Hv({},e)).join("")!==r}))?function(t,e){for(var n=Fv(t),r=arguments.length,i=1,o=Nv.f,a=Wv.f;r>i;)for(var u,s=zv(arguments[i++]),c=o?Uv(Iv(s),o(s)):Iv(s),l=c.length,f=0;l>f;)u=c[f++],Av&&!Tv(a,s,u)||(n[u]=s[u]);return n}:Hv,Gv=Bv;bu({target:"Object",stat:!0,arity:2,forced:Object.assign!==Gv},{assign:Gv});var Vv={exports:{}},qv={},Kv=Ma,Zv=La,Jv=Gp,Qv=Array,Xv=Math.max,ty=function(t,e,n){for(var r=Zv(t),i=Kv(e,r),o=Kv(void 0===n?r:n,r),a=Qv(Xv(o-i,0)),u=0;i<o;i++,u++)Jv(a,u,t[i]);return a.length=u,a},ey=zo,ny=ca,ry=wa.f,iy=ty,oy="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];qv.f=function(t){return oy&&"Window"===ey(t)?function(t){try{return ry(t)}catch(t){return iy(oy)}}(t):ry(ny(t))};var ay=jn((function(){if("function"==typeof ArrayBuffer){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}})),uy=jn,sy=jr,cy=zo,ly=ay,fy=Object.isExtensible,hy=uy((function(){fy(1)}))||ly?function(t){return!!sy(t)&&((!ly||"ArrayBuffer"!==cy(t))&&(!fy||fy(t)))}:fy,dy=!jn((function(){return Object.isExtensible(Object.preventExtensions({}))})),py=bu,vy=Pn,yy=Xi,my=jr,gy=zn,wy=xr.f,by=wa,xy=qv,Oy=hy,ky=dy,Sy=!1,jy=Gn("meta"),_y=0,My=function(t){wy(t,jy,{value:{objectID:"O"+_y++,weakData:{}}})},Dy=Vv.exports={enable:function(){Dy.enable=function(){},Sy=!0;var t=by.f,e=vy([].splice),n={};n[jy]=1,t(n).length&&(by.f=function(n){for(var r=t(n),i=0,o=r.length;i<o;i++)if(r[i]===jy){e(r,i,1);break}return r},py({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:xy.f}))},fastKey:function(t,e){if(!my(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!gy(t,jy)){if(!Oy(t))return"F";if(!e)return"E";My(t)}return t[jy].objectID},getWeakData:function(t,e){if(!gy(t,jy)){if(!Oy(t))return!0;if(!e)return!1;My(t)}return t[jy].weakData},onFreeze:function(t){return ky&&Sy&&Oy(t)&&!gy(t,jy)&&My(t),t}};yy[jy]=!0;var $y=Vv.exports,Ey=br,Py=jr,Ly=Eu,Ay=bu,Cy=dn,Ty=Pn,Ry=hu,Iy=Io,Ny=$y,Wy=Af,Fy=Bu,zy=br,Hy=Ln,Yy=jr,Uy=jn,By=Nf,Gy=Cu,Vy=function(t,e,n){var r,i;return Ly&&Ey(r=e.constructor)&&r!==n&&Py(i=r.prototype)&&i!==n.prototype&&Ly(t,i),t},qy=function(t,e,n){var r=-1!==t.indexOf("Map"),i=-1!==t.indexOf("Weak"),o=r?"set":"add",a=Cy[t],u=a&&a.prototype,s=a,c={},l=function(t){var e=Ty(u[t]);Iy(u,t,"add"===t?function(t){return e(this,0===t?0:t),this}:"delete"===t?function(t){return!(i&&!Yy(t))&&e(this,0===t?0:t)}:"get"===t?function(t){return i&&!Yy(t)?void 0:e(this,0===t?0:t)}:"has"===t?function(t){return!(i&&!Yy(t))&&e(this,0===t?0:t)}:function(t,n){return e(this,0===t?0:t,n),this})};if(Ry(t,!zy(a)||!(i||u.forEach&&!Uy((function(){(new a).entries().next()})))))s=n.getConstructor(e,t,r,o),Ny.enable();else if(Ry(t,!0)){var f=new s,h=f[o](i?{}:-0,1)!==f,d=Uy((function(){f.has(1)})),p=By((function(t){new a(t)})),v=!i&&Uy((function(){for(var t=new a,e=5;e--;)t[o](e,e);return!t.has(-0)}));p||((s=e((function(t,e){Fy(t,u);var n=Vy(new a,t,s);return Hy(e)||Wy(e,n[o],{that:n,AS_ENTRIES:r}),n}))).prototype=u,u.constructor=s),(d||v)&&(l("delete"),l("has"),r&&l("get")),(v||h)&&l(o),i&&u.clear&&delete u.clear}return c[t]=s,Ay({global:!0,constructor:!0,forced:s!==a},c),Gy(s,t),i||n.setStrong(s,t,r),s},Ky=Io,Zy=function(t,e,n){for(var r in e)Ky(t,r,e[r],n);return t},Jy=Pn,Qy=Zy,Xy=$y.getWeakData,tm=Bu,em=Rr,nm=Ln,rm=jr,im=Af,om=zn,am=po.set,um=po.getterFor,sm=Pv.find,cm=Pv.findIndex,lm=Jy([].splice),fm=0,hm=function(t){return t.frozen||(t.frozen=new dm)},dm=function(){this.entries=[]},pm=function(t,e){return sm(t.entries,(function(t){return t[0]===e}))};dm.prototype={get:function(t){var e=pm(this,t);if(e)return e[1]},has:function(t){return!!pm(this,t)},set:function(t,e){var n=pm(this,t);n?n[1]=e:this.entries.push([t,e])},delete:function(t){var e=cm(this.entries,(function(e){return e[0]===t}));return~e&&lm(this.entries,e,1),!!~e}};var vm,ym,mm={getConstructor:function(t,e,n,r){var i=t((function(t,i){tm(t,o),am(t,{type:e,id:fm++,frozen:void 0}),nm(i)||im(i,t[r],{that:t,AS_ENTRIES:n})})),o=i.prototype,a=um(e),u=function(t,e,n){var r=a(t),i=Xy(em(e),!0);return!0===i?hm(r).set(e,n):i[r.id]=n,t};return Qy(o,{delete:function(t){var e=a(this);if(!rm(t))return!1;var n=Xy(t);return!0===n?hm(e).delete(t):n&&om(n,e.id)&&delete n[e.id]},has:function(t){var e=a(this);if(!rm(t))return!1;var n=Xy(t);return!0===n?hm(e).has(t):n&&om(n,e.id)}}),Qy(o,n?{get:function(t){var e=a(this);if(rm(t)){var n=Xy(t);return!0===n?hm(e).get(t):n?n[e.id]:void 0}},set:function(t,e){return u(this,t,e)}}:{add:function(t){return u(this,t,!0)}}),i}};qy("WeakSet",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),mm),function(t){t[t.SCROLL_NONE=0]="SCROLL_NONE",t[t.SCROLL_BACKWARD=1]="SCROLL_BACKWARD",t[t.SCROLL_FORWARD=2]="SCROLL_FORWARD"}(vm||(vm={})),function(t){t[t.TOP=0]="TOP",t[t.RIGHT=1]="RIGHT",t[t.BOTTOM=2]="BOTTOM",t[t.LEFT=3]="LEFT"}(ym||(ym={}));var gm,wm,bm,xm="red",Om=[0,100],km=function(){function t(e){en(this,t),gm.add(this),this.calendar=e,this.maxDomainReached=!1,this.minDomainReached=!1}return rn(t,[{key:"loadNewDomains",value:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:vm.SCROLL_NONE,r=this.calendar.options.options,i=this.calendar.templateCollection,o=r.date.min?i.get(r.domain.type).extractUnit(+r.date.min):void 0,a=r.date.max?i.get(r.domain.type).extractUnit(+r.date.max):void 0,u=this.calendar.domainCollection;return hv(this,gm,"m",wm).call(this,t,o,a,n)?vm.SCROLL_NONE:(n!==vm.SCROLL_NONE&&t.clamp(o,a).slice(r.range,n===vm.SCROLL_FORWARD),u.merge(t,r.range,(function(n,o){var a=null;return a=t.at(o+1)?t.at(o+1):e.calendar.dateHelper.intervals(r.domain.type,n,2).pop(),i.get(r.subDomain.type).mapping(n,a).map((function(t){return Object.assign(Object.assign({},t),{v:r.data.defaultValue})}))})),hv(this,gm,"m",bm).call(this,u.min,u.max,o,a),n===vm.SCROLL_BACKWARD?this.calendar.eventEmitter.emit("domainsLoaded",[u.min]):n===vm.SCROLL_FORWARD&&this.calendar.eventEmitter.emit("domainsLoaded",[u.max]),n)}},{key:"jumpTo",value:function(t,e){var n=this.calendar,r=n.domainCollection,i=n.options,o=new Date(r.min),a=new Date(r.max);return t<o?this.loadNewDomains(this.calendar.createDomainCollection(t,o,!1),vm.SCROLL_BACKWARD):e?this.loadNewDomains(this.calendar.createDomainCollection(t,i.options.range),o<t?vm.SCROLL_FORWARD:vm.SCROLL_BACKWARD):t>a?this.loadNewDomains(this.calendar.createDomainCollection(a,t,!1),vm.SCROLL_FORWARD):vm.SCROLL_NONE}}]),t}();gm=new WeakSet,wm=function(t,e,n,r){return!!(n&&t.max>=n&&this.maxDomainReached&&r===vm.SCROLL_FORWARD)||!!(e&&t.min<=e&&this.minDomainReached&&r===vm.SCROLL_BACKWARD)},bm=function(t,e,n,r){if(n){var i=t<=n;this.calendar.eventEmitter.emit(i?"minDateReached":"minDateNotReached"),this.minDomainReached=i}if(r){var o=e>=r;this.calendar.eventEmitter.emit(o?"maxDateReached":"maxDateNotReached"),this.maxDomainReached=o}};var Sm=TypeError,jm=bu,_m=jn,Mm=Hp,Dm=jr,$m=Nn,Em=La,Pm=function(t){if(t>9007199254740991)throw Sm("Maximum allowed index exceeded");return t},Lm=Gp,Am=kv,Cm=Zp,Tm=tr,Rm=pr("isConcatSpreadable"),Im=Tm>=51||!_m((function(){var t=[];return t[Rm]=!1,t.concat()[0]!==t})),Nm=function(t){if(!Dm(t))return!1;var e=t[Rm];return void 0!==e?!!e:Mm(t)};jm({target:"Array",proto:!0,arity:1,forced:!Im||!Cm("concat")},{concat:function(t){var e,n,r,i,o,a=$m(this),u=Am(a,0),s=0;for(e=-1,r=arguments.length;e<r;e++)if(Nm(o=-1===e?a:arguments[e]))for(i=Em(o),Pm(s+i),n=0;n<i;n++,s++)n in o&&Lm(u,s,o[n]);else Pm(s+1),Lm(u,s++,o);return u.length=s,u}});var Wm=jn,Fm=function(t,e){var n=[][t];return!!n&&Wm((function(){n.call(null,e||function(){return 1},1)}))},zm=bu,Hm=aa,Ym=ca,Um=Fm,Bm=Pn([].join);zm({target:"Array",proto:!0,forced:Hm!==Object||!Um("join",",")},{join:function(t){return Bm(Ym(this),void 0===t?",":t)}});var Gm=Ih,Vm=Iu,qm=Zy,Km=Ds,Zm=Bu,Jm=Ln,Qm=Af,Xm=Rd,tg=Id,eg=Hu,ng=Or,rg=$y.fastKey,ig=po.set,og=po.getterFor,ag={getConstructor:function(t,e,n,r){var i=t((function(t,i){Zm(t,o),ig(t,{type:e,index:Gm(null),first:void 0,last:void 0,size:0}),ng||(t.size=0),Jm(i)||Qm(i,t[r],{that:t,AS_ENTRIES:n})})),o=i.prototype,a=og(e),u=function(t,e,n){var r,i,o=a(t),u=s(t,e);return u?u.value=n:(o.last=u={index:i=rg(e,!0),key:e,value:n,previous:r=o.last,next:void 0,removed:!1},o.first||(o.first=u),r&&(r.next=u),ng?o.size++:t.size++,"F"!==i&&(o.index[i]=u)),t},s=function(t,e){var n,r=a(t),i=rg(e);if("F"!==i)return r.index[i];for(n=r.first;n;n=n.next)if(n.key===e)return n};return qm(o,{clear:function(){for(var t=a(this),e=t.index,n=t.first;n;)n.removed=!0,n.previous&&(n.previous=n.previous.next=void 0),delete e[n.index],n=n.next;t.first=t.last=void 0,ng?t.size=0:this.size=0},delete:function(t){var e=this,n=a(e),r=s(e,t);if(r){var i=r.next,o=r.previous;delete n.index[r.index],r.removed=!0,o&&(o.next=i),i&&(i.previous=o),n.first===r&&(n.first=i),n.last===r&&(n.last=o),ng?n.size--:e.size--}return!!r},forEach:function(t){for(var e,n=a(this),r=Km(t,arguments.length>1?arguments[1]:void 0);e=e?e.next:n.first;)for(r(e.value,e.key,this);e&&e.removed;)e=e.previous},has:function(t){return!!s(this,t)}}),qm(o,n?{get:function(t){var e=s(this,t);return e&&e.value},set:function(t,e){return u(this,0===t?0:t,e)}}:{add:function(t){return u(this,t=0===t?0:t,t)}}),ng&&Vm(o,"size",{configurable:!0,get:function(){return a(this).size}}),i},setStrong:function(t,e,n){var r=e+" Iterator",i=og(e),o=og(r);Xm(t,e,(function(t,e){ig(this,{type:r,target:t,state:i(t),kind:e,last:void 0})}),(function(){for(var t=o(this),e=t.kind,n=t.last;n&&n.removed;)n=n.previous;return t.target&&(t.last=n=n?n.next:t.state.first)?tg("keys"===e?n.key:"values"===e?n.value:[n.key,n.value],!1):(t.target=void 0,tg(void 0,!0))}),n?"entries":"values",!n,!0),eg(e)}};qy("Map",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),ag);var ug=Zr,sg=TypeError,cg=ty,lg=Math.floor,fg=function(t,e){var n=t.length,r=lg(n/2);return n<8?hg(t,e):dg(t,fg(cg(t,0,r),e),fg(cg(t,r),e),e)},hg=function(t,e){for(var n,r,i=t.length,o=1;o<i;){for(r=o,n=t[o];r&&e(t[r-1],n)>0;)t[r]=t[--r];r!==o++&&(t[r]=n)}return t},dg=function(t,e,n,r){for(var i=e.length,o=n.length,a=0,u=0;a<i||u<o;)t[a+u]=a<i&&u<o?r(e[a],n[u])<=0?e[a++]:n[u++]:a<i?e[a++]:n[u++];return t},pg=fg,vg=Vn.match(/firefox\/(\d+)/i),yg=!!vg&&+vg[1],mg=/MSIE|Trident/.test(Vn),gg=Vn.match(/AppleWebKit\/(\d+)\./),wg=!!gg&&+gg[1],bg=bu,xg=Pn,Og=ti,kg=Nn,Sg=La,jg=function(t,e){if(!delete t[e])throw new sg("Cannot delete property "+ug(e)+" of "+ug(t))},_g=ip,Mg=jn,Dg=pg,$g=Fm,Eg=yg,Pg=mg,Lg=tr,Ag=wg,Cg=[],Tg=xg(Cg.sort),Rg=xg(Cg.push),Ig=Mg((function(){Cg.sort(void 0)})),Ng=Mg((function(){Cg.sort(null)})),Wg=$g("sort"),Fg=!Mg((function(){if(Lg)return Lg<70;if(!(Eg&&Eg>3)){if(Pg)return!0;if(Ag)return Ag<603;var t,e,n,r,i="";for(t=65;t<76;t++){switch(e=String.fromCharCode(t),t){case 66:case 69:case 70:case 72:n=3;break;case 68:case 71:n=4;break;default:n=2}for(r=0;r<47;r++)Cg.push({k:e+r,v:n})}for(Cg.sort((function(t,e){return e.v-t.v})),r=0;r<Cg.length;r++)e=Cg[r].k.charAt(0),i.charAt(i.length-1)!==e&&(i+=e);return"DGBEFHACIJK"!==i}}));bg({target:"Array",proto:!0,forced:Ig||!Ng||!Wg||!Fg},{sort:function(t){void 0!==t&&Og(t);var e=kg(this);if(Fg)return void 0===t?Tg(e):Tg(e,t);var n,r,i=[],o=Sg(e);for(r=0;r<o;r++)r in e&&Rg(i,e[r]);for(Dg(i,function(t){return function(e,n){return void 0===n?-1:void 0===e?1:void 0!==t?+t(e,n)||0:_g(e)>_g(n)?1:-1}}(t)),n=Sg(i),r=0;r<n;)e[r]=i[r++];for(;r<o;)jg(e,r++);return e}});var zg,Hg,Yg,Ug=Pv.forEach,Bg=dn,Gg=Op,Vg=jp,qg=Fm("forEach")?[].forEach:function(t){return Ug(this,t,arguments.length>1?arguments[1]:void 0)},Kg=Ki,Zg=function(t){if(t&&t.forEach!==qg)try{Kg(t,"forEach",qg)}catch(e){t.forEach=qg}};for(var Jg in Gg)Gg[Jg]&&Zg(Bg[Jg]&&Bg[Jg].prototype);function Qg(t){return"top"===t||"bottom"===t}function Xg(t){return t[ym.LEFT]+t[ym.RIGHT]}function tw(t){return t[ym.TOP]+t[ym.BOTTOM]}Zg(Vg);var ew,nw,rw=function(){function t(e,n){en(this,t),zg.add(this),this.calendar=e,this.domainPainter=n,this.collection=new Map,this.scrollDirection=vm.SCROLL_FORWARD}return rn(t,[{key:"get",value:function(t){return this.collection.get(t)}},{key:"update",value:function(t,e){var n=this,r=this.calendar.options.options,i=r.verticalOrientation,o=r.domain;this.scrollDirection=e;var a={width:0,height:0},u=0,s=e===vm.SCROLL_FORWARD?-1:1,c=t.keys;return"desc"===this.calendar.options.options.domain.sort&&(c.reverse(),s*=-1),t.yankedDomains.forEach((function(t){u+=n.collection.get(t)[i?"height":"width"]})),t.yankedDomains.forEach((function(t){var e=n.collection.get(t);n.collection.set(t,Object.assign(Object.assign({},e),{x:i?e.x:e.x+u*s,y:i?e.y+u*s:e.y}))})),c.forEach((function(t){var e=hv(n,zg,"m",Hg).call(n,t),r=hv(n,zg,"m",Yg).call(n,t);i?(a.height+=r,a.width=Math.max(e,a.width)):(a.width+=e,a.height=Math.max(r,a.height));var c=a.width-e,l=a.height-r;n.collection.set(t,Object.assign(Object.assign({},n.collection.get(t)),{x:i?0:c,y:i?l:0,pre_x:i?c:c-u*s,pre_y:i?l-u*s:l,width:e,height:r,inner_width:e-(i?0:o.gutter),inner_height:r-(i?o.gutter:0)}))})),a}}]),t}();zg=new WeakSet,Hg=function(t){var e=this.calendar.options.options,n=e.domain,r=e.subDomain,i=e.x,o=e.verticalOrientation,a=this.calendar.templateCollection.get(r.type).columnsCount(t),u=(r.width+r.gutter)*a-r.gutter;return Xg(n.padding)+i.domainHorizontalLabelWidth+(o?0:n.gutter)+u},Yg=function(t){var e=this.calendar.options.options,n=e.domain,r=e.subDomain,i=e.x,o=e.verticalOrientation,a=this.calendar.templateCollection.get(r.type).rowsCount(t),u=(r.height+r.gutter)*a-r.gutter;return tw(n.padding)+u+(o?n.gutter:0)+i.domainVerticalLabelHeight};var iw=".ch-domain",ow=function(){function t(e){en(this,t),ew.add(this),this.calendar=e,this.coordinates=new rw(e,this),this.root=null,this.dimensions={width:0,height:0}}return rn(t,[{key:"paint",value:function(t,e){var n=this,r=this.calendar.options.options.animationDuration,i=e.transition().duration(r),o=this.coordinates;this.dimensions=o.update(this.calendar.domainCollection,t);var a=[];return this.root=e.selectAll(iw).data(this.calendar.domainCollection.keys,(function(t){return t})).join((function(t){return t.append("svg").attr("x",(function(t){return o.get(t).pre_x})).attr("y",(function(t){return o.get(t).pre_y})).attr("width",(function(t){return o.get(t).inner_width})).attr("height",(function(t){return o.get(t).inner_height})).attr("class",(function(t){return hv(n,ew,"m",nw).call(n,t)})).call((function(t){return t.append("rect").attr("width",(function(t){return o.get(t).inner_width})).attr("height",(function(t){return o.get(t).inner_height})).attr("class","".concat(iw.slice(1),"-bg"))})).call((function(t){return a.push(t.transition(i).attr("x",(function(t){return o.get(t).x})).attr("y",(function(t){return o.get(t).y})).end())}))}),(function(t){return t.call((function(t){return a.push(t.transition(i).attr("x",(function(t){return o.get(t).x})).attr("y",(function(t){return o.get(t).y})).attr("width",(function(t){return o.get(t).inner_width})).attr("height",(function(t){return o.get(t).inner_height})).end())})).call((function(t){return a.push(t.selectAll("".concat(iw,"-bg")).transition(i).attr("width",(function(t){return o.get(t).inner_width})).attr("height",(function(t){return o.get(t).inner_height})).end())}))}),(function(t){return t.call((function(t){return a.push(t.transition(i).attr("x",(function(t){return o.get(t).x})).attr("y",(function(t){return o.get(t).y})).remove().end())}))})),a}}]),t}();ew=new WeakSet,nw=function(t){var e=iw.slice(1),n=this.calendar.dateHelper.date(t);switch(this.calendar.options.options.domain.type){case"hour":e+=" h_".concat(n.hour());break;case"day":e+=" d_".concat(n.date()," dy_").concat(n.format("d")+1);break;case"week":e+=" w_".concat(n.week());break;case"month":e+=" m_".concat(n.month()+1);break;case"year":e+=" y_".concat(n.year())}return e};var aw=Ia.includes,uw=Gh;bu({target:"Array",proto:!0,forced:jn((function(){return!Array(1).includes()}))},{includes:function(t){return aw(this,t,arguments.length>1?arguments[1]:void 0)}}),uw("includes");var sw=Pv.filter;bu({target:"Array",proto:!0,forced:!Zp("filter")},{filter:function(t){return sw(this,t,arguments.length>1?arguments[1]:void 0)}});var cw,lw,fw,hw,dw=Rr,pw=wf,vw=Ds,yw=Wr,mw=Nn,gw=function(t,e,n,r){try{return r?e(dw(n)[0],n[1]):e(n)}catch(e){pw(t,"throw",e)}},ww=ef,bw=cs,xw=La,Ow=Gp,kw=vf,Sw=sf,jw=Array,_w=function(t){var e=mw(t),n=bw(this),r=arguments.length,i=r>1?arguments[1]:void 0,o=void 0!==i;o&&(i=vw(i,r>2?arguments[2]:void 0));var a,u,s,c,l,f,h=Sw(e),d=0;if(!h||this===jw&&ww(h))for(a=xw(e),u=n?new this(a):jw(a);a>d;d++)f=o?i(e[d],d):e[d],Ow(u,d,f);else for(l=(c=kw(e,h)).next,u=n?new this:[];!(s=yw(l,c)).done;d++)f=o?gw(c,i,[s.value,d],!0):s.value,Ow(u,d,f);return u.length=d,u};bu({target:"Array",stat:!0,forced:!Nf((function(t){Array.from(t)}))},{from:_w});var Mw,Dw,$w,Ew,Pw,Lw,Aw,Cw={year:"YYYY",month:"MMMM",week:"wo [week] YYYY",xDay:"Do MMM",ghDay:"Do MMM",day:"Do MMM",hour:"HH:00",minute:"HH:mm"},Tw=function(){function t(e,n,r,i){var o=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(en(this,t),cw.add(this),this.collection=new Map,this.dateHelper=e,n&&r&&i){var a=this.dateHelper.intervals(n,r,i,o).map((function(t){return yv(t)}));this.collection=new Map(a)}this.min=0,this.max=0,this.keys=[],this.yankedDomains=[],this.collection.size>0&&hv(this,cw,"m",hw).call(this)}return rn(t,[{key:"has",value:function(t){return this.collection.has(t)}},{key:"get",value:function(t){return this.collection.get(t)}},{key:"forEach",value:function(t){return this.collection.forEach(t)}},{key:"at",value:function(t){return this.keys[t]}},{key:"clamp",value:function(t,e){var n=this;return t&&this.min<t&&this.keys.filter((function(e){return e<t})).forEach((function(t){return n.collection.delete(t)})),e&&this.max>e&&this.keys.filter((function(t){return t>e})).forEach((function(t){return n.collection.delete(t)})),hv(this,cw,"m",hw).call(this),this}},{key:"merge",value:function(t,e,n){var r=this;this.yankedDomains=[],t.keys.forEach((function(t,i){if(!r.has(t)){if(r.collection.size>=e){var o=r.max;t>r.max&&(o=r.min),o&&r.collection.delete(o)&&r.yankedDomains.push(o)}r.collection.set(t,n(t,i)),hv(r,cw,"m",hw).call(r)}})),this.yankedDomains=this.yankedDomains.sort((function(t,e){return t-e}))}},{key:"slice",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,n=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];this.keys.length>e&&((n?this.keys.slice(0,-e):this.keys.slice(e)).forEach((function(e){t.collection.delete(e)})),hv(this,cw,"m",hw).call(this));return this}},{key:"fill",value:function(t,e,n){var r=this,i=e.x,o=e.y,a=e.groupY,u=e.defaultValue,s=this.groupRecords(t,i,n);this.keys.forEach((function(t){var e=s.get(t)||{};hv(r,cw,"m",lw).call(r,t,e,o,a,u)}))}},{key:"groupRecords",value:function(t,e,n){var r=this,i=new Map,o=new Map;return this.keys.forEach((function(t){r.get(t).forEach((function(e){o.set(e.t,t)}))})),t.forEach((function(t){var a=r.extractTimestamp(t,e,n);if(o.has(a)){var u=o.get(a),s=i.get(u)||{};s[a]||(s[a]=[]),s[a].push(t),i.set(u,s)}})),i}},{key:"groupValues",value:function(t,e){var n=t.filter((function(t){return null!==t}));if("string"==typeof e){if(n.every((function(t){return"number"==typeof t})))switch(e){case"sum":return n.reduce((function(t,e){return t+e}),0);case"count":return n.length;case"min":return Math.min.apply(Math,an(n))||null;case"max":return Math.max.apply(Math,an(n))||null;case"average":return n.length>0?n.reduce((function(t,e){return t+e}),0)/n.length:null;default:return null}return"count"===e?n.length:null}return"function"==typeof e?e(n):null}},{key:"extractTimestamp",value:function(t,e,n){var r="function"==typeof e?e(t):t[e];return"string"==typeof r&&(r=+new Date(r)),n(r)}}]),t}();cw=new WeakSet,lw=function(t,e,n,r,i){var o=this;this.get(t).forEach((function(a,u){var s=i;e.hasOwnProperty(a.t)&&(s=o.groupValues(hv(o,cw,"m",fw).call(o,e[a.t],n),r)),o.get(t)[u].v=s}))},fw=function(t,e){return t.map((function(t){return"function"==typeof e?e(t):t[e]}))},hw=function(){this.keys=Array.from(this.collection.keys()).map((function(t){return parseInt(t,10)})).sort((function(t,e){return t-e}));var t=this.keys;return this.min=t[0],this.max=t[t.length-1],this.keys};var Rw=".ch-domain-text",Iw=function(){function t(e){en(this,t),Mw.add(this),this.calendar=e}return rn(t,[{key:"paint",value:function(t){var e=this,n=this.calendar.options.options.domain,r=n.label,i=n.type,o=this.calendar.dateHelper,a=r.text;null!==a&&""!==a&&(void 0===a&&(a=Cw[i]),t.selectAll(Rw).data((function(t){return[t]}),(function(t){return t})).join((function(t){return t.append("text").attr("class",Rw.slice(1)).attr("x",(function(t){return hv(e,Mw,"m",$w).call(e,t)})).attr("y",(function(t){return hv(e,Mw,"m",Ew).call(e,t)})).attr("text-anchor",r.textAlign).attr("dominant-baseline",(function(){return hv(e,Mw,"m",Dw).call(e)})).text((function(t,e,n){return o.format(t,a,n[e])})).call((function(t){return hv(e,Mw,"m",Aw).call(e,t)}))}),(function(t){t.attr("x",(function(t){return hv(e,Mw,"m",$w).call(e,t)})).attr("y",(function(t){return hv(e,Mw,"m",Ew).call(e,t)})).attr("text-anchor",r.textAlign).attr("dominant-baseline",(function(){return hv(e,Mw,"m",Dw).call(e)})).text((function(t,e,n){return o.format(t,a,n[e])})).call((function(t){return hv(e,Mw,"m",Aw).call(e,t)}))})))}}]),t}();Mw=new WeakSet,Dw=function(){var t=this.calendar.options.options.domain.label,e=t.position,n=t.rotate;return Qg(e)?"middle":"left"===n&&"left"===e||"right"===n&&"right"===e?"bottom":"hanging"},$w=function(t){var e=this.calendar.options.options.domain,n=e.padding,r=e.label,i=r.position,o=r.textAlign,a=r.offset,u=this.calendar.options.options.x.domainHorizontalLabelWidth,s=n[ym.LEFT];return"right"===i&&(s+=hv(this,Mw,"m",Pw).call(this,t)),"middle"===o&&(["top","bottom"].includes(i)?s+=hv(this,Mw,"m",Pw).call(this,t)/2:s+=u/2),"end"===o&&(Qg(i)?s+=hv(this,Mw,"m",Pw).call(this,t):s+=u),s+a.x},Ew=function(t){var e=this.calendar.options.options,n=e.domain,r=n.label,i=r.position,o=r.offset,a=n.padding,u=e.x,s=a[ym.TOP]+u.domainVerticalLabelHeight/2;return"bottom"===i&&(s+=hv(this,Mw,"m",Lw).call(this,t)),s+o.y},Pw=function(t){var e=this.calendar.options.options,n=e.domain.padding,r=e.x.domainHorizontalLabelWidth;return this.calendar.calendarPainter.domainsContainerPainter.domainPainter.coordinates.get(t).inner_width-r-Xg(n)},Lw=function(t){var e=this.calendar.options.options,n=e.x.domainVerticalLabelHeight,r=e.domain.padding;return this.calendar.calendarPainter.domainsContainerPainter.domainPainter.coordinates.get(t).inner_height-n-tw(r)},Aw=function(t){var e=this,n=this.calendar.options.options,r=n.domain.label,i=r.rotate,o=r.textAlign,a=r.position,u=n.x.domainHorizontalLabelWidth;switch(i){case"right":t.attr("transform",(function(t){var n=hv(e,Mw,"m",Pw).call(e,t),r=hv(e,Mw,"m",Lw).call(e,t),i=["rotate(90, ".concat("right"===a?n:u,", 0)")];switch(a){case"right":"middle"===o?i.push("translate(".concat(r/2-u/2,")")):"end"===o&&i.push("translate(".concat(r-u,")"));break;case"left":"start"===o?i.push("translate(".concat(u,")")):"middle"===o?i.push("translate(".concat(u/2+r/2,")")):"end"===o&&i.push("translate(".concat(r,")"))}return i.join(",")}));break;case"left":t.attr("transform",(function(t){var n=hv(e,Mw,"m",Pw).call(e,t),r=hv(e,Mw,"m",Lw).call(e,t),i=["rotate(270, ".concat("right"===a?n:u,", 0)")];switch(a){case"right":"start"===o?i.push("translate(-".concat(r,")")):"middle"===o?i.push("translate(-".concat(r/2+u/2,")")):"end"===o&&i.push("translate(-".concat(u,")"));break;case"left":"start"===o?i.push("translate(".concat(u-r,")")):"middle"===o&&i.push("translate(".concat(u/2-r/2,")"))}return i.join(",")}))}};var Nw,Ww,Fw,zw,Hw,Yw,Uw,Bw="\t\n\v\f\r                 \u2028\u2029\ufeff",Gw=Tn,Vw=ip,qw=Bw,Kw=Pn("".replace),Zw=RegExp("^["+qw+"]+"),Jw=RegExp("(^|[^"+qw+"])["+qw+"]+$"),Qw=function(t){return function(e){var n=Vw(Gw(e));return 1&t&&(n=Kw(n,Zw,"")),2&t&&(n=Kw(n,Jw,"$1")),n}},Xw={start:Qw(1),end:Qw(2),trim:Qw(3)},tb=Ti.PROPER,eb=jn,nb=Bw,rb=Xw.trim;bu({target:"String",proto:!0,forced:function(t){return eb((function(){return!!nb[t]()||"​…᠎"!=="​…᠎"[t]()||tb&&nb[t].name!==t}))}("trim")},{trim:function(){return rb(this)}});var ib,ob,ab,ub,sb=".ch-subdomain",cb=function(){function t(e){en(this,t),Nw.add(this),this.calendar=e,this.root=null}return rn(t,[{key:"paint",value:function(t){var e=this;this.root=t||this.root;var n="".concat(sb,"-container"),r=this.root.selectAll(n).data((function(t){return[t]}),(function(t){return t})).join((function(t){return t.append("svg").call((function(t){return hv(e,Nw,"m",Ww).call(e,t)})).attr("class",n.slice(1))}),(function(t){return t.call((function(t){return hv(e,Nw,"m",Ww).call(e,t)}))})),i=this.calendar.options.options.subDomain,o=i.radius,a=i.width,u=i.height,s=i.sort,c=this.calendar.eventEmitter;r.selectAll("g").data((function(t){var n=e.calendar.domainCollection.get(t);if("desc"===s){var r=Math.max.apply(Math,an(n.map((function(t){return t.x}))));n.forEach((function(t,e){n[e].x=Math.abs(t.x-r)}))}return n})).join((function(t){return t.append("g").call((function(t){return t.insert("rect").attr("class",(function(t){return hv(e,Nw,"m",Fw).call(e,t.t,"".concat(sb.slice(1),"-bg"))})).attr("width",a).attr("height",u).attr("x",(function(t){return hv(e,Nw,"m",Yw).call(e,t)})).attr("y",(function(t){return hv(e,Nw,"m",Uw).call(e,t)})).on("click",(function(t,e){return c.emit("click",t,e.t,e.v)})).on("mouseover",(function(t,e){return c.emit("mouseover",t,e.t,e.v)})).on("mouseout",(function(t,e){return c.emit("mouseout",t,e.t,e.v)})).attr("rx",o>0?o:null).attr("ry",o>0?o:null)})).call((function(t){return hv(e,Nw,"m",zw).call(e,t)}))}),(function(t){return t.selectAll("rect").attr("class",(function(t){return hv(e,Nw,"m",Fw).call(e,t.t,"".concat(sb.slice(1),"-bg"))})).attr("width",a).attr("height",u).attr("x",(function(t){return hv(e,Nw,"m",Yw).call(e,t)})).attr("y",(function(t){return hv(e,Nw,"m",Uw).call(e,t)})).attr("rx",o).attr("ry",o)}))}}]),t}();Nw=new WeakSet,Ww=function(t){var e=this.calendar.options.options,n=e.domain,r=n.padding,i=n.label.position;t.attr("x",(function(){var t=r[ym.LEFT];return"left"===i&&(t+=e.x.domainHorizontalLabelWidth),t})).attr("y",(function(){var t=r[ym.TOP];return"top"===i&&(t+=e.x.domainVerticalLabelHeight),t}))},Fw=function(t){var e=this,n=this.calendar.options.options,r=n.date.highlight,i=n.subDomain.type,o="";r.length>0&&r.forEach((function(n){var r=e.calendar.templateCollection.get(i).extractUnit;r(+n)===r(t)&&(o="highlight")}));for(var a=arguments.length,u=new Array(a>1?a-1:0),s=1;s<a;s++)u[s-1]=arguments[s];return[o].concat(u).join(" ").trim()},zw=function(t){var e=this,n=this.calendar.options.options.subDomain,r=n.width,i=n.height,o=n.label;return o?t.append("text").attr("class",(function(t){return hv(e,Nw,"m",Fw).call(e,t.t,"".concat(sb.slice(1),"-text"))})).attr("x",(function(t){return hv(e,Nw,"m",Yw).call(e,t)+r/2})).attr("y",(function(t){return hv(e,Nw,"m",Uw).call(e,t)+i/2})).attr("text-anchor","middle").attr("dominant-baseline","central").text((function(t,n,r){return e.calendar.dateHelper.format(t.t,o,t.v,r[n])})):null},Hw=function(t,e){var n=this.calendar.options.options.subDomain;return e[t]*(n["x"===t?"width":"height"]+n.gutter)},Yw=function(t){return hv(this,Nw,"m",Hw).call(this,"x",t)},Uw=function(t){return hv(this,Nw,"m",Hw).call(this,"y",t)};var lb=".ch-domain-container",fb="in-transition",hb=function(){function e(t){en(this,e),ib.add(this),this.calendar=t,this.domainPainter=new ow(t),this.subDomainPainter=new cb(t),this.domainLabelPainter=new Iw(t),this.dimensions={width:0,height:0},this.transitionsQueueCount=0}return rn(e,[{key:"setup",value:function(){this.root=this.calendar.calendarPainter.root.attr("x",0).attr("y",0).append("svg").attr("class",lb.slice(1)).append("svg").attr("class","".concat(lb.slice(1),"-animation-wrapper"))}},{key:"paint",value:function(t){var e=this;hv(this,ib,"m",ob).call(this);var n=this.domainPainter.paint(t,this.root);return this.subDomainPainter.paint(this.domainPainter.root),this.domainLabelPainter.paint(this.domainPainter.root),hv(this,ib,"m",ub).call(this),Promise.allSettled(n).then((function(){hv(e,ib,"m",ab).call(e)})),n}},{key:"updatePosition",value:function(){var e;if(!(null===(e=this.root)||void 0===e?void 0:e.node()))return Promise.resolve();var n=this.calendar.options.options.animationDuration,r=this.calendar.pluginManager.getHeightFromPosition("top"),i=this.calendar.pluginManager.getWidthFromPosition("left");return[t(this.root.node().parentNode).transition().duration(n).call((function(t){t.attr("x",i).attr("y",r)})).end()]}},{key:"width",value:function(){return this.dimensions.width}},{key:"height",value:function(){return this.dimensions.height}},{key:"destroy",value:function(){return hv(this,ib,"m",ob).call(this),Promise.resolve()}}]),e}();ib=new WeakSet,ob=function(){var e;(null===(e=this.root)||void 0===e?void 0:e.node())&&(this.transitionsQueueCount+=1,t(this.root.node().parentNode).classed(fb,!0))},ab=function(){var e;(null===(e=this.root)||void 0===e?void 0:e.node())&&(this.transitionsQueueCount-=1,0===this.transitionsQueueCount&&t(this.root.node().parentNode).classed(fb,!1))},ub=function(){var t=this.calendar.options.options,e=t.animationDuration,n=t.verticalOrientation,r=t.domain.gutter,i=this.domainPainter.dimensions;this.dimensions={width:i.width-(n?0:r),height:i.height-(n?r:0)},this.root.transition().duration(e).attr("width",this.dimensions.width).attr("height",this.dimensions.height)};var db,pb,vb,yb,mb=function(){function t(e){en(this,t),this.calendar=e}return rn(t,[{key:"paint",value:function(){var t=[];return t=(t=t.concat(this.calendar.pluginManager.paintAll())).concat(this.setPluginsPosition())}},{key:"setPluginsPosition",value:function(){var t=this.calendar.pluginManager,e=this.calendar.options.options.animationDuration,n=this.calendar.calendarPainter.domainsContainerPainter,r=t.getFromPosition("top"),i=t.getFromPosition("right"),o=t.getFromPosition("bottom"),a=t.getFromPosition("left"),u=t.getHeightFromPosition("top"),s=t.getWidthFromPosition("left"),c=[],l=0;r.forEach((function(t){c.push(t.root.transition().duration(e).attr("y",l).attr("x",s).end()),l+=t.options.dimensions.height}));var f=0;return a.forEach((function(t){c.push(t.root.transition().duration(e).attr("x",f).attr("y",u).end()),f+=t.options.dimensions.width})),o.forEach((function(t){c.push(t.root.transition().duration(e).attr("x",s).attr("y",u+n.height()).end())})),f+=n.width(),i.forEach((function(t){c.push(t.root.transition().duration(e).attr("x",f).attr("y",u).end()),f+=t.options.dimensions.width})),c}},{key:"insideWidth",value:function(){return this.calendar.pluginManager.getWidthFromPosition("left")+this.calendar.pluginManager.getWidthFromPosition("right")}},{key:"insideHeight",value:function(){return this.calendar.pluginManager.getHeightFromPosition("top")+this.calendar.pluginManager.getHeightFromPosition("bottom")}}]),t}(),gb=function(){function e(t){en(this,e),db.add(this),this.calendar=t,this.dimensions={width:0,height:0},this.root=null,this.domainsContainerPainter=new hb(t),this.pluginPainter=new mb(t)}return rn(e,[{key:"setup",value:function(){var e=this.calendar.options.options,n=e.itemSelector,r=e.theme;return this.root||(this.root=t(n).append("svg").attr("data-theme",r).attr("class",".ch-container".slice(1)),this.domainsContainerPainter.setup()),this.calendar.pluginManager.setupAll(),!0}},{key:"paint",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:vm.SCROLL_NONE,e=this.domainsContainerPainter.paint(t).concat(this.pluginPainter.paint()).concat(this.domainsContainerPainter.updatePosition());return hv(this,db,"m",yb).call(this),Promise.allSettled(e)}},{key:"destroy",value:function(){var t=this.calendar.pluginManager.destroyAll().concat(this.domainsContainerPainter.destroy());return this.root?(t.push(this.root.transition().duration(this.calendar.options.options.animationDuration).attr("width",0).attr("height",0).remove().end()),Promise.allSettled(t)):Promise.allSettled(t)}}]),e}();db=new WeakSet,pb=function(){return this.domainsContainerPainter.height()+this.pluginPainter.insideHeight()},vb=function(){return this.domainsContainerPainter.width()+this.pluginPainter.insideWidth()},yb=function(){var t=this.calendar.options.options,e=hv(this,db,"m",vb).call(this),n=hv(this,db,"m",pb).call(this);this.root.transition().duration(t.animationDuration).attr("width",e).attr("height",n),e===this.dimensions.width&&n===this.dimensions.height||this.calendar.eventEmitter.emit("resize",e,n,this.dimensions.width,this.dimensions.height),this.dimensions={width:e,height:n}};var wb="object"==typeof global&&global&&global.Object===Object&&global,bb="object"==typeof self&&self&&self.Object===Object&&self,xb=wb||bb||Function("return this")(),Ob=xb.Symbol,kb=Object.prototype,Sb=kb.hasOwnProperty,jb=kb.toString,_b=Ob?Ob.toStringTag:void 0;var Mb=Object.prototype.toString;var Db="[object Null]",$b="[object Undefined]",Eb=Ob?Ob.toStringTag:void 0;function Pb(t){return null==t?void 0===t?$b:Db:Eb&&Eb in Object(t)?function(t){var e=Sb.call(t,_b),n=t[_b];try{t[_b]=void 0;var r=!0}catch(t){}var i=jb.call(t);return r&&(e?t[_b]=n:delete t[_b]),i}(t):function(t){return Mb.call(t)}(t)}function Lb(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}var Ab="[object AsyncFunction]",Cb="[object Function]",Tb="[object GeneratorFunction]",Rb="[object Proxy]";function Ib(t){if(!Lb(t))return!1;var e=Pb(t);return e==Cb||e==Tb||e==Ab||e==Rb}var Nb=Nn,Wb=yh;bu({target:"Object",stat:!0,forced:jn((function(){Wb(1)}))},{keys:function(t){return Wb(Nb(t))}});var Fb,zb=jr,Hb=zo,Yb=pr("match"),Ub=function(t){var e;return zb(t)&&(void 0!==(e=t[Yb])?!!e:"RegExp"===Hb(t))},Bb=TypeError,Gb=function(t){if(Ub(t))throw new Bb("The method doesn't accept regular expressions");return t},Vb=pr("match"),qb=function(t){var e=/./;try{"/./"[t](e)}catch(n){try{return e[Vb]=!1,"/./"[t](e)}catch(t){}}return!1},Kb=bu,Zb=Ss,Jb=Jo.f,Qb=Ea,Xb=ip,tx=Gb,ex=Tn,nx=qb,rx=Zb("".startsWith),ix=Zb("".slice),ox=Math.min,ax=nx("startsWith");Kb({target:"String",proto:!0,forced:!!(ax||(Fb=Jb(String.prototype,"startsWith"),!Fb||Fb.writable))&&!ax},{startsWith:function(t){var e=Xb(ex(this));tx(t);var n=Qb(ox(arguments.length>1?arguments[1]:void 0,e.length)),r=Xb(t);return rx?rx(e,r,n):ix(e,n,n+r.length)===r}});var ux=Or,sx=jn,cx=Pn,lx=ed,fx=yh,hx=ca,dx=cx(Qo.f),px=cx([].push),vx=ux&&sx((function(){var t=Object.create(null);return t[2]=2,!dx(t,2)})),yx=function(t){return function(e){for(var n,r=hx(e),i=fx(r),o=vx&&null===lx(r),a=i.length,u=0,s=[];a>u;)n=i[u++],ux&&!(o?n in r:dx(r,n))||px(s,t?[n,r[n]]:r[n]);return s}},mx={entries:yx(!0),values:yx(!1)}.entries;function gx(t){return null!=t&&!Number.isNaN(t)}function wx(t,e){return+gx(e)-+gx(t)||n(t,e)}function bx(t){return isFinite(t)?t:NaN}function xx(t){return t>0&&isFinite(t)?t:NaN}function Ox(t){return t<0&&isFinite(t)?t:NaN}bu({target:"Object",stat:!0},{entries:function(t){return mx(t)}});const kx=/^(?:[-+]\d{2})?\d{4}(?:-\d{2}(?:-\d{2})?)?(?:T\d{2}:\d{2}(?::\d{2}(?:\.\d{3})?)?(?:Z|[-+]\d{2}:?\d{2})?)?$/;function Sx(t,e){return kx.test(t+="")?new Date(t):"function"==typeof e?e(t):e}const jx=new Map([["second",r],["minute",i],["hour",o],["day",a],["week",u],["month",s],["quarter",s.every(3)],["half",s.every(6)],["year",c],["monday",l],["tuesday",f],["wednesday",h],["thursday",d],["friday",p],["saturday",v],["sunday",y]]),_x=new Map([["second",m],["minute",g],["hour",w],["day",b],["week",x],["month",O],["quarter",O.every(3)],["half",O.every(6)],["year",k],["monday",S],["tuesday",j],["wednesday",_],["thursday",M],["friday",D],["saturday",$],["sunday",E]]);function Mx(t){const e=jx.get(`${t}`.toLowerCase());if(!e)throw new Error(`unknown interval: ${t}`);return e}function Dx(t){const e=_x.get(`${t}`.toLowerCase());if(!e)throw new Error(`unknown interval: ${t}`);return e}const $x=Object.getPrototypeOf(Uint8Array),Ex=Object.prototype.toString,Px=t=>()=>t;function Lx(t){return t instanceof $x?t:Ix(t,Ax,Float64Array)}function Ax(t){return null==t?NaN:Number(t)}function Cx(t){return Ix(t,Tx)}function Tx(t){return t instanceof Date&&!isNaN(t)?t:"string"==typeof t?Sx(t):null==t||isNaN(t=+t)?void 0:new Date(t)}function Rx(t){return null==t||t instanceof Array||t instanceof $x?t:Array.from(t)}function Ix(t,e,n=Array){return null==t?t:t instanceof n?t.map(e):n.from(t,e)}function Nx(t,e=Array){return t instanceof e?t.slice():e.from(t)}function Wx(t){return function(t){return t?.toString===Ex}(t)&&(void 0!==t.type||void 0!==t.domain)}function Fx(t,e){if(null!=t){if("number"==typeof t){0<t&&t<1&&Number.isInteger(1/t)&&(t=-1/t);const e=Math.abs(t);return t<0?{floor:t=>Math.floor(t*e)/e,offset:t=>(t*e+1)/e,range:(t,n)=>L(Math.ceil(t*e),n*e).map((t=>t/e))}:{floor:t=>Math.floor(t/e)*e,offset:t=>t+e,range:(t,n)=>L(Math.ceil(t/e),n/e).map((t=>t*e))}}if("string"==typeof t)return("time"===e?Mx:Dx)(t);if("function"!=typeof t.floor)throw new Error("invalid interval; missing floor method");if("function"!=typeof t.offset)throw new Error("invalid interval; missing offset method");return t}}function zx(t,e){if((t=Fx(t,e))&&"function"!=typeof t.range)throw new Error("invalid interval: missing range method");return t}function Hx(t){for(const e of t){if(null==e)continue;const t=typeof e;return"string"===t||"boolean"===t}}function Yx(t){for(const e of t)if(null!=e)return e instanceof Date}function Ux(t){for(const e of t)if(null!=e)return"string"==typeof e&&isNaN(e)&&Sx(e)}function Bx(t){for(const e of t)if(null!=e){if("string"!=typeof e)return!1;if(e.trim())return!isNaN(e)}}function Gx(t){if(null==t)return;const e=t[0],n=t[t.length-1];return P(e,n)}const Vx=Symbol("position"),qx=Symbol("color"),Kx=Symbol("radius"),Zx=Symbol("length"),Jx=Symbol("opacity"),Qx=Symbol("symbol"),Xx=new Map([["x",Vx],["y",Vx],["fx",Vx],["fy",Vx],["r",Kx],["color",qx],["opacity",Jx],["symbol",Qx],["length",Zx]]),tO=2/Math.sqrt(3),eO=new Map([["asterisk",A],["circle",C],["cross",T],["diamond",R],["diamond2",I],["hexagon",{draw(t,e){const n=Math.sqrt(e/Math.PI),r=n*tO,i=r/2;t.moveTo(0,r),t.lineTo(n,i),t.lineTo(n,-i),t.lineTo(0,-r),t.lineTo(-n,-i),t.lineTo(-n,i),t.closePath()}}],["plus",N],["square",W],["square2",F],["star",z],["times",H],["triangle",Y],["triangle2",U],["wye",B]]);function nO(t){if(null==t||function(t){return t&&"function"==typeof t.draw}(t))return t;const e=eO.get(`${t}`.toLowerCase());if(e)return e;throw new Error(`invalid symbol: ${t}`)}function rO(t){console.warn(t)}const iO=new Map([["accent",G],["category10",V],["dark2",q],["paired",K],["pastel1",Z],["pastel2",J],["set1",Q],["set2",X],["set3",tt],["tableau10",et],["brbg",aO(zt,rt)],["prgn",aO(Ht,it)],["piyg",aO(Yt,ot)],["puor",aO(Ut,at)],["rdbu",aO(Bt,ut)],["rdgy",aO(Gt,st)],["rdylbu",aO(Vt,ct)],["rdylgn",aO(qt,lt)],["spectral",aO(Kt,ft)],["burd",uO(Bt,ut)],["buylrd",uO(Vt,ct)],["blues",oO(Zt,ht)],["greens",oO(Jt,dt)],["greys",oO(Qt,pt)],["oranges",oO(Xt,mt)],["purples",oO(te,vt)],["reds",oO(ee,yt)],["turbo",sO(gt)],["viridis",sO(wt)],["magma",sO(bt)],["inferno",sO(xt)],["plasma",sO(Ot)],["cividis",sO(kt)],["cubehelix",sO(St)],["warm",sO(jt)],["cool",sO(_t)],["bugn",oO(ne,Mt)],["bupu",oO(re,Dt)],["gnbu",oO(ie,$t)],["orrd",oO(oe,Et)],["pubu",oO(ae,Lt)],["pubugn",oO(ue,Pt)],["purd",oO(se,At)],["rdpu",oO(ce,Ct)],["ylgn",oO(le,Rt)],["ylgnbu",oO(fe,Tt)],["ylorbr",oO(he,It)],["ylorrd",oO(de,Nt)],["rainbow",cO(Wt)],["sinebow",cO(Ft)]]);function oO(t,e){return({length:n})=>1===n?[t[3][1]]:2===n?[t[3][1],t[3][2]]:(n=Math.max(3,Math.floor(n)))>9?nt(e,n):t[n]}function aO(t,e){return({length:n})=>2===n?[t[3][0],t[3][2]]:(n=Math.max(3,Math.floor(n)))>11?nt(e,n):t[n]}function uO(t,e){return({length:n})=>2===n?[t[3][2],t[3][0]]:(n=Math.max(3,Math.floor(n)))>11?nt((t=>e(1-t)),n):t[n].slice().reverse()}function sO(t){return({length:e})=>nt(t,Math.max(2,Math.floor(e)))}function cO(t){return({length:e})=>nt(t,Math.floor(e)+1).slice(0,-1)}function lO(t){const e=`${t}`.toLowerCase();if(!iO.has(e))throw new Error(`unknown ordinal scheme: ${e}`);return iO.get(e)}function fO(t,e){const n=lO(t),r="function"==typeof n?n({length:e}):n;return r.length!==e?r.slice(0,e):r}const hO=new Map([["brbg",rt],["prgn",it],["piyg",ot],["puor",at],["rdbu",ut],["rdgy",st],["rdylbu",ct],["rdylgn",lt],["spectral",ft],["burd",t=>ut(1-t)],["buylrd",t=>ct(1-t)],["blues",ht],["greens",dt],["greys",pt],["purples",vt],["reds",yt],["oranges",mt],["turbo",gt],["viridis",wt],["magma",bt],["inferno",xt],["plasma",Ot],["cividis",kt],["cubehelix",St],["warm",jt],["cool",_t],["bugn",Mt],["bupu",Dt],["gnbu",$t],["orrd",Et],["pubugn",Pt],["pubu",Lt],["purd",At],["rdpu",Ct],["ylgnbu",Tt],["ylgn",Rt],["ylorbr",It],["ylorrd",Nt],["rainbow",Wt],["sinebow",Ft]]);function dO(t){const e=`${t}`.toLowerCase();if(!hO.has(e))throw new Error(`unknown quantitative scheme: ${e}`);return hO.get(e)}const pO=new Set(["brbg","prgn","piyg","puor","rdbu","rdgy","rdylbu","rdylgn","spectral","burd","buylrd"]);function vO(t){return null!=t&&pO.has(`${t}`.toLowerCase())}const yO=t=>e=>t(1-e),mO=[0,1],gO=new Map([["number",xe],["rgb",_e],["hsl",Pe],["hcl",Le],["lab",Ae]]);function wO(t){const e=`${t}`.toLowerCase();if(!gO.has(e))throw new Error(`unknown interpolator: ${e}`);return gO.get(e)}function bO(t,e,n,{type:r,nice:i,clamp:o,zero:a,domain:u=SO(t,n),unknown:s,round:c,scheme:l,interval:f,range:h=(Xx.get(t)===Kx?_O(n,u):Xx.get(t)===Zx?MO(n,u):Xx.get(t)===Jx?mO:void 0),interpolate:d=(Xx.get(t)===qx?null==l&&void 0!==h?_e:dO(void 0!==l?l:"cyclical"===r?"rainbow":"turbo"):c?Me:xe),reverse:p}){if(f=zx(f,r),"cyclical"!==r&&"sequential"!==r||(r="linear"),p=!!p,"function"!=typeof d&&(d=wO(d)),1===d.length?(p&&(d=yO(d),p=!1),void 0===h&&2===(h=Float64Array.from(u,((t,e)=>e/(u.length-1)))).length&&(h=mO),e.interpolate((h===mO?Px:EO)(d))):e.interpolate(d),a){const[t,e]=we(u);(t>0||e<0)&&(Gx(u=Nx(u))!==Math.sign(t)?u[u.length-1]=0:u[0]=0)}return p&&(u=Oe(u)),e.domain(u).unknown(s),i&&(e.nice(function(t,e){return!0===t?void 0:"number"==typeof t?t:function(t,e){if((t=zx(t,e))&&"function"!=typeof t.ceil)throw new Error("invalid interval: missing ceil method");return t}(t,e)}(i,r)),u=e.domain()),void 0!==h&&e.range(h),o&&e.clamp(o),{type:r,domain:u,range:h,scale:e,interpolate:d,interval:f}}function xO(t,e,{exponent:n=1,...r}){return bO(t,ve().exponent(n),e,{...r,type:"pow"})}function OO(t,e,{domain:n=[0],unknown:r,scheme:i="rdylbu",interpolate:o,range:a=(void 0!==o?nt(o,n.length+1):Xx.get(t)===qx?fO(i,n.length+1):void 0),reverse:u}){const s=Gx(n=Rx(n));if(!isNaN(s)&&!function(t,e){for(let n=1,r=t.length,i=t[0];n<r;++n){const r=P(i,i=t[n]);if(0!==r&&r!==e)return!1}return!0}(n,s))throw new Error(`the ${t} scale has a non-monotonic domain`);return u&&(a=Oe(a)),{type:"threshold",scale:ke(s<0?Oe(n):n,void 0===a?[]:a).unknown(r),domain:n,range:a}}function kO(t,e=bx){return t.length?[De(t,(({value:t})=>void 0===t?t:De(t,e))),je(t,(({value:t})=>void 0===t?t:je(t,e)))]:[0,1]}function SO(t,e){const n=Xx.get(t);return(n===Kx||n===Jx||n===Zx?jO:kO)(e)}function jO(t){return[0,t.length?je(t,(({value:t})=>void 0===t?t:je(t,bx))):1]}function _O(t,e){const n=t.find((({radius:t})=>void 0!==t));if(void 0!==n)return[0,n.radius];const r=$e(t,.5,(({value:t})=>void 0===t?NaN:$e(t,.25,xx))),i=e.map((t=>3*Math.sqrt(t/r))),o=30/je(i);return o<1?i.map((t=>t*o)):i}function MO(t,e){const n=Ee(t,(({value:t})=>void 0===t?NaN:Ee(t,Math.abs))),r=e.map((t=>12*t/n)),i=60/je(r);return i<1?r.map((t=>t*i)):r}function DO(t){for(const{value:e}of t)if(void 0!==e)for(let n of e){if(n>0)return kO(t,xx);if(n<0)return kO(t,Ox)}return[1,10]}function $O(t){const e=[];for(const{value:n}of t)if(void 0!==n)for(const t of n)e.push(t);return e}function EO(t){return(e,n)=>r=>t(e+r*(n-e))}function PO(t,e,n,r,{type:i,nice:o,clamp:a,domain:u=kO(r),unknown:s,pivot:c=0,scheme:l,range:f,symmetric:h=!0,interpolate:d=(Xx.get(t)===qx?null==l&&void 0!==f?_e:dO(void 0!==l?l:"rdbu"):xe),reverse:p}){c=+c;let[v,y]=u;if(P(v,y)<0&&([v,y]=[y,v],p=!p),v=Math.min(v,c),y=Math.max(y,c),"function"!=typeof d&&(d=wO(d)),void 0!==f&&(d=1===d.length?EO(d)(...f):Ne(d,f)),p&&(d=yO(d)),h){const t=n.apply(c),e=t-n.apply(v),r=n.apply(y)-t;e<r?v=n.invert(t-r):e>r&&(y=n.invert(t+e))}return e.domain([v,c,y]).unknown(s).interpolator(d),a&&e.clamp(a),o&&e.nice(o),{type:i,domain:[v,y],pivot:c,interpolate:d,scale:e}}function LO(t,e,{exponent:n=1,...r}){return PO(t,Te().exponent(n=+n),function(t){return.5===t?RO:{apply:e=>Math.sign(e)*Math.pow(Math.abs(e),t),invert:e=>Math.sign(e)*Math.pow(Math.abs(e),1/t)}}(n),e,{...r,type:"diverging-pow"})}function AO(t,e,{constant:n=1,...r}){return PO(t,Ie().constant(n=+n),function(t){return{apply:e=>Math.sign(e)*Math.log1p(Math.abs(e/t)),invert:e=>Math.sign(e)*Math.expm1(Math.abs(e))*t}}(n),e,r)}const CO={apply:t=>t,invert:t=>t},TO={apply:Math.log,invert:Math.exp},RO={apply:t=>Math.sign(t)*Math.sqrt(Math.abs(t)),invert:t=>Math.sign(t)*(t*t)};function IO(t,e,n,r){return bO(t,e,n,r)}const NO=Symbol("ordinal");function WO(t,e,n,{type:r,interval:i,domain:o,range:a,reverse:u,hint:s}){return i=zx(i,r),void 0===o&&(o=HO(n,i,t)),"categorical"!==r&&r!==NO||(r="ordinal"),u&&(o=Oe(o)),e.domain(o),void 0!==a&&("function"==typeof a&&(a=a(o)),e.range(a)),{type:r,domain:o,range:a,scale:e,hint:s,interval:i}}function FO(t,e,{type:n,interval:r,domain:i,range:o,scheme:a,unknown:u,...s}){let c;if(r=zx(r,n),void 0===i&&(i=HO(e,r,t)),Xx.get(t)===Qx)c=function(t){return{fill:YO(t,"fill"),stroke:YO(t,"stroke")}}(e),o=void 0===o?function(t){return e=t.fill,null==e||function(t){return/^\s*none\s*$/i.test(t)}(e)?Ve:qe;var e}(c):Ix(o,nO);else if(Xx.get(t)===qx&&(void 0!==o||"ordinal"!==n&&n!==NO||(o=function(t,e="greys"){const n=new Set,[r,i]=fO(e,2);for(const e of t)if(null!=e)if(!0===e)n.add(i);else{if(!1!==e)return;n.add(r)}return[...n]}(i,a),void 0!==o&&(a=void 0)),void 0===a&&void 0===o&&(a="ordinal"===n?"turbo":"tableau10"),void 0!==a))if(void 0!==o){const t=dO(a),e=o[0],n=o[1]-o[0];o=({length:r})=>nt((r=>t(e+n*r)),r)}else o=lO(a);if(u===ze)throw new Error(`implicit unknown on ${t} scale is not supported`);return WO(t,He().unknown(u),e,{...s,type:n,domain:i,range:o,hint:c})}function zO(t,e,n,r){let{round:i}=n;return void 0!==i&&t.round(i=!!i),(t=WO(r,t,e,n)).round=i,t}function HO(t,e,n){const r=new Be;for(const{value:e,domain:n}of t){if(void 0!==n)return n();if(void 0!==e)for(const t of e)r.add(t)}if(void 0!==e){const[t,n]=we(r).map(e.floor,e);return e.range(t,e.offset(n))}if(r.size>1e4&&Xx.get(n)===Vx)throw new Error(`implicit ordinal domain of ${n} scale has more than 10,000 values`);return Ge(r,wx)}function YO(t,e){let n;for(const{hint:r}of t){const t=r?.[e];if(void 0!==t)if(void 0===n)n=t;else if(n!==t)return}return n}function UO(t,e,n){return function(t,e=[],n={}){const r=function(t,e,{type:n,domain:r,range:i,scheme:o,pivot:a,projection:u}){if("fx"===t||"fy"===t)return"band";"x"!==t&&"y"!==t||null==u||(n=GO);for(const{type:t}of e)if(void 0!==t)if(void 0===n)n=t;else if(n!==t)throw new Error(`scale incompatible with channel: ${n} !== ${t}`);if(n===GO)return;if(void 0!==n)return n;if(void 0===r&&!e.some((({value:t})=>void 0!==t)))return;const s=Xx.get(t);if(s===Kx)return"sqrt";if(s===Jx||s===Zx)return"linear";if(s===Qx)return"ordinal";if((r||i||[]).length>2)return VO(s);if(void 0!==r)return Hx(r)?VO(s):Yx(r)?"utc":s!==qx||null==a&&!vO(o)?"linear":"diverging";const c=e.map((({value:t})=>t)).filter((t=>void 0!==t));return c.some(Hx)?VO(s):c.some(Yx)?"utc":s!==qx||null==a&&!vO(o)?"linear":"diverging"}(t,e,n);if(void 0===n.type&&void 0===n.domain&&void 0===n.range&&null==n.interval&&"fx"!==t&&"fy"!==t&&function({type:t}){return"ordinal"===t||"point"===t||"band"===t||t===NO}({type:r})){const n=e.map((({value:t})=>t)).filter((t=>void 0!==t));n.some(Yx)?rO(`Warning: some data associated with the ${t} scale are dates. Dates are typically associated with a "utc" or "time" scale rather than a "${BO(r)}" scale. If you are using a bar mark, you probably want a rect mark with the interval option instead; if you are using a group transform, you probably want a bin transform instead. If you want to treat this data as ordinal, you can specify the interval of the ${t} scale (e.g., d3.utcDay), or you can suppress this warning by setting the type of the ${t} scale to "${BO(r)}".`):n.some(Ux)?rO(`Warning: some data associated with the ${t} scale are strings that appear to be dates (e.g., YYYY-MM-DD). If these strings represent dates, you should parse them to Date objects. Dates are typically associated with a "utc" or "time" scale rather than a "${BO(r)}" scale. If you are using a bar mark, you probably want a rect mark with the interval option instead; if you are using a group transform, you probably want a bin transform instead. If you want to treat this data as ordinal, you can suppress this warning by setting the type of the ${t} scale to "${BO(r)}".`):n.some(Bx)&&rO(`Warning: some data associated with the ${t} scale are strings that appear to be numbers. If these strings represent numbers, you should parse or coerce them to numbers. Numbers are typically associated with a "linear" scale rather than a "${BO(r)}" scale. If you want to treat this data as ordinal, you can specify the interval of the ${t} scale (e.g., 1 for integers), or you can suppress this warning by setting the type of the ${t} scale to "${BO(r)}".`)}switch(n.type=r,r){case"diverging":case"diverging-sqrt":case"diverging-pow":case"diverging-log":case"diverging-symlog":case"cyclical":case"sequential":case"linear":case"sqrt":case"threshold":case"quantile":case"pow":case"log":case"symlog":n=qO(e,n,Lx);break;case"identity":switch(Xx.get(t)){case Vx:n=qO(e,n,Lx);break;case Qx:n=qO(e,n,KO)}break;case"utc":case"time":n=qO(e,n,Cx)}switch(r){case"diverging":return function(t,e,n){return PO(t,Ce(),CO,e,n)}(t,e,n);case"diverging-sqrt":return function(t,e,n){return LO(t,e,{...n,exponent:.5})}(t,e,n);case"diverging-pow":return LO(t,e,n);case"diverging-log":return function(t,e,{base:n=10,pivot:r=1,domain:i=kO(e,r<0?Ox:xx),...o}){return PO(t,Re().base(n=+n),TO,e,{domain:i,pivot:r,...o})}(t,e,n);case"diverging-symlog":return AO(t,e,n);case"categorical":case"ordinal":case NO:return FO(t,e,n);case"cyclical":case"sequential":case"linear":return function(t,e,n){return bO(t,pe(),e,n)}(t,e,n);case"sqrt":return function(t,e,n){return xO(t,e,{...n,exponent:.5})}(t,e,n);case"threshold":return OO(t,0,n);case"quantile":return function(t,e,{range:n,quantiles:r=(void 0===n?5:(n=[...n]).length),n:i=r,scheme:o="rdylbu",domain:a=$O(e),unknown:u,interpolate:s,reverse:c}){return void 0===n&&(n=void 0!==s?nt(s,i):Xx.get(t)===qx?fO(o,i):void 0),a.length>0&&(a=ge(a,void 0===n?{length:i}:n).quantiles()),OO(t,0,{domain:a,range:n,reverse:c,unknown:u})}(t,e,n);case"quantize":return function(t,e,{range:n,n:r=(void 0===n?5:(n=[...n]).length),scheme:i="rdylbu",domain:o=SO(t,e),unknown:a,interpolate:u,reverse:s}){const[c,l]=we(o);let f;return void 0===n?(f=be(c,l,r),f[0]<=c&&f.splice(0,1),f[f.length-1]>=l&&f.pop(),r=f.length+1,n=void 0!==u?nt(u,r):Xx.get(t)===qx?fO(i,r):void 0):(f=nt(xe(c,l),r+1).slice(1,-1),c instanceof Date&&(f=f.map((t=>new Date(t))))),Gx(Rx(o))<0&&f.reverse(),OO(t,0,{domain:f,range:n,reverse:s,unknown:a})}(t,e,n);case"pow":return xO(t,e,n);case"log":return function(t,e,{base:n=10,domain:r=DO(e),...i}){return bO(t,ye().base(n),e,{...i,domain:r})}(t,e,n);case"symlog":return function(t,e,{constant:n=1,...r}){return bO(t,me().constant(n),e,r)}(t,e,n);case"utc":return function(t,e,n){return IO(t,Fe(),e,n)}(t,e,n);case"time":return function(t,e,n){return IO(t,We(),e,n)}(t,e,n);case"point":return function(t,e,{align:n=.5,padding:r=.5,...i}){return zO(Ye().align(n).padding(r),e,i,t)}(t,e,n);case"band":return function(t,e,{align:n=.5,padding:r=.1,paddingInner:i=r,paddingOuter:o=("fx"===t||"fy"===t?0:r),...a}){return zO(Ue().align(n).paddingInner(i).paddingOuter(o),e,a,t)}(t,e,n);case"identity":return Xx.get(t)===Vx?{type:"identity",scale:Se()}:{type:"identity"};case void 0:return;default:throw new Error(`unknown scale type: ${r}`)}}(t,void 0===n?void 0:[{hint:n}],{...e})}function BO(t){return"symbol"==typeof t?t.description:t}const GO={toString:()=>"projection"};function VO(t){switch(t){case Vx:return"point";case qx:return NO;default:return"ordinal"}}function qO(t,{domain:e,...n},r){for(const e of t)void 0!==e.value&&(e.value=r(e.value));return{domain:void 0===e?e:r(e),...n}}function KO(t){return Ix(t,nO)}function ZO({scale:t,type:e,domain:n,range:r,interpolate:i,interval:o,transform:a,percent:u,pivot:s}){if("identity"===e)return{type:"identity",apply:t=>t,invert:t=>t};const c=t.unknown?t.unknown():void 0;return{type:e,domain:Nx(n),...void 0!==r&&{range:Nx(r)},...void 0!==a&&{transform:a},...u&&{percent:u},...void 0!==c&&{unknown:c},...void 0!==o&&{interval:o},...void 0!==i&&{interpolate:i},...t.clamp&&{clamp:t.clamp()},...void 0!==s&&{pivot:s,symmetric:!1},...t.base&&{base:t.base()},...t.exponent&&{exponent:t.exponent()},...t.constant&&{constant:t.constant()},...t.align&&{align:t.align(),round:t.round()},...t.padding&&(t.paddingInner?{paddingInner:t.paddingInner(),paddingOuter:t.paddingOuter()}:{padding:t.padding()}),...t.bandwidth&&{bandwidth:t.bandwidth(),step:t.step()},apply:e=>t(e),...t.invert&&{invert:e=>t.invert(e)}}}function JO(t){try{var e=Object.keys(t)[0];return function(t={}){let e;for(const n in t)if(Xx.has(n)&&Wx(t[n])){if(void 0!==e)throw new Error("ambiguous scale definition; multiple scales found");e=ZO(UO(n,t[n]))}if(void 0===e)throw new Error("invalid scale definition; no scale found");return e}((n={},r=e,i=Object.assign(Object.assign({},t[e]),{clamp:!0}),(r=cn(r))in n?Object.defineProperty(n,r,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[r]=i,n))}catch(t){return null}var n,r,i}function QO(t,e,n,r){Object.entries(function(t,e){var n={};return e.hasOwnProperty("opacity")?(n.fill=function(){return e.opacity.baseColor||xm},n["fill-opacity"]=function(e){return null==t?void 0:t.apply(e)}):n.fill=function(e){return"string"==typeof e&&(null==e?void 0:e.startsWith("#"))?e:null==t?void 0:t.apply(e)},n}(e,n)).forEach((function(e){var n=on(e,2),i=n[0],o=n[1];return t.style(i,(function(t){return o(r?t[r]:t)}))}))}var XO=function(){function t(e){en(this,t),this.calendar=e}return rn(t,[{key:"populate",value:function(){var t=this.calendar,n=t.options.options,r=n.scale,i=n.subDomain,o=JO(r);t.calendarPainter.root.selectAll(".ch-domain").selectAll("svg").selectAll("g").data((function(e){return t.domainCollection.get(e)||[]})).call((function(t){QO(t.select("rect"),o,r,"v")})).call((function(n){n.select("text").attr("style",(function(t){var n=e(null==o?void 0:o.apply(t.v)).l>60?"#000":"#fff",r=i.color||(t.v?n:null);return Ib(r)&&(r=r(t.t,t.v,null==o?void 0:o.apply(t.v))),r?"fill: ".concat(r,";"):null})).text((function(e,n,r){return t.dateHelper.format(e.t,i.label,e.v,r[n])}))})).call((function(){t.eventEmitter.emit("fill")}))}}]),t}();function tk(t,e){return t===e||t!=t&&e!=e}function ek(t,e){for(var n=t.length;n--;)if(tk(t[n][0],e))return n;return-1}var nk=Array.prototype.splice;function rk(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}rk.prototype.clear=function(){this.__data__=[],this.size=0},rk.prototype.delete=function(t){var e=this.__data__,n=ek(e,t);return!(n<0)&&(n==e.length-1?e.pop():nk.call(e,n,1),--this.size,!0)},rk.prototype.get=function(t){var e=this.__data__,n=ek(e,t);return n<0?void 0:e[n][1]},rk.prototype.has=function(t){return ek(this.__data__,t)>-1},rk.prototype.set=function(t,e){var n=this.__data__,r=ek(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this};var ik=xb["__core-js_shared__"],ok=function(){var t=/[^.]+$/.exec(ik&&ik.keys&&ik.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();var ak=Function.prototype.toString;function uk(t){if(null!=t){try{return ak.call(t)}catch(t){}try{return t+""}catch(t){}}return""}var sk=/^\[object .+?Constructor\]$/,ck=Function.prototype,lk=Object.prototype,fk=ck.toString,hk=lk.hasOwnProperty,dk=RegExp("^"+fk.call(hk).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function pk(t){return!(!Lb(t)||(e=t,ok&&ok in e))&&(Ib(t)?dk:sk).test(uk(t));var e}function vk(t,e){var n=function(t,e){return null==t?void 0:t[e]}(t,e);return pk(n)?n:void 0}var yk=vk(xb,"Map"),mk=vk(Object,"create");var gk=Object.prototype.hasOwnProperty;var wk=Object.prototype.hasOwnProperty;function bk(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}function xk(t,e){var n,r,i=t.__data__;return("string"==(r=typeof(n=e))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof e?"string":"hash"]:i.map}function Ok(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e<n;){var r=t[e];this.set(r[0],r[1])}}bk.prototype.clear=function(){this.__data__=mk?mk(null):{},this.size=0},bk.prototype.delete=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e},bk.prototype.get=function(t){var e=this.__data__;if(mk){var n=e[t];return"__lodash_hash_undefined__"===n?void 0:n}return gk.call(e,t)?e[t]:void 0},bk.prototype.has=function(t){var e=this.__data__;return mk?void 0!==e[t]:wk.call(e,t)},bk.prototype.set=function(t,e){var n=this.__data__;return this.size+=this.has(t)?0:1,n[t]=mk&&void 0===e?"__lodash_hash_undefined__":e,this},Ok.prototype.clear=function(){this.size=0,this.__data__={hash:new bk,map:new(yk||rk),string:new bk}},Ok.prototype.delete=function(t){var e=xk(this,t).delete(t);return this.size-=e?1:0,e},Ok.prototype.get=function(t){return xk(this,t).get(t)},Ok.prototype.has=function(t){return xk(this,t).has(t)},Ok.prototype.set=function(t,e){var n=xk(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this};function kk(t){var e=this.__data__=new rk(t);this.size=e.size}kk.prototype.clear=function(){this.__data__=new rk,this.size=0},kk.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},kk.prototype.get=function(t){return this.__data__.get(t)},kk.prototype.has=function(t){return this.__data__.has(t)},kk.prototype.set=function(t,e){var n=this.__data__;if(n instanceof rk){var r=n.__data__;if(!yk||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Ok(r)}return n.set(t,e),this.size=n.size,this};var Sk=function(){try{var t=vk(Object,"defineProperty");return t({},"",{}),t}catch(t){}}(),jk=Sk;function _k(t,e,n){"__proto__"==e&&jk?jk(t,e,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[e]=n}function Mk(t,e,n){(void 0!==n&&!tk(t[e],n)||void 0===n&&!(e in t))&&_k(t,e,n)}var Dk,$k=function(t,e,n){for(var r=-1,i=Object(t),o=n(t),a=o.length;a--;){var u=o[Dk?a:++r];if(!1===e(i[u],u,i))break}return t},Ek=$k,Pk="object"==typeof exports&&exports&&!exports.nodeType&&exports,Lk=Pk&&"object"==typeof module&&module&&!module.nodeType&&module,Ak=Lk&&Lk.exports===Pk?xb.Buffer:void 0,Ck=Ak?Ak.allocUnsafe:void 0;var Tk=xb.Uint8Array;function Rk(t,e){var n,r,i=e?(n=t.buffer,r=new n.constructor(n.byteLength),new Tk(r).set(new Tk(n)),r):t.buffer;return new t.constructor(i,t.byteOffset,t.length)}var Ik=Object.create,Nk=function(){function t(){}return function(e){if(!Lb(e))return{};if(Ik)return Ik(e);t.prototype=e;var n=new t;return t.prototype=void 0,n}}();function Wk(t,e){return function(n){return t(e(n))}}var Fk=Wk(Object.getPrototypeOf,Object),zk=Object.prototype;function Hk(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||zk)}function Yk(t){return null!=t&&"object"==typeof t}function Uk(t){return Yk(t)&&"[object Arguments]"==Pb(t)}var Bk=Object.prototype,Gk=Bk.hasOwnProperty,Vk=Bk.propertyIsEnumerable,qk=Uk(function(){return arguments}())?Uk:function(t){return Yk(t)&&Gk.call(t,"callee")&&!Vk.call(t,"callee")},Kk=9007199254740991;function Zk(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=Kk}function Jk(t){return null!=t&&Zk(t.length)&&!Ib(t)}var Qk="object"==typeof exports&&exports&&!exports.nodeType&&exports,Xk=Qk&&"object"==typeof module&&module&&!module.nodeType&&module,tS=Xk&&Xk.exports===Qk?xb.Buffer:void 0,eS=(tS?tS.isBuffer:void 0)||function(){return!1},nS="[object Object]",rS=Function.prototype,iS=Object.prototype,oS=rS.toString,aS=iS.hasOwnProperty,uS=oS.call(Object);var sS={};sS["[object Float32Array]"]=sS["[object Float64Array]"]=sS["[object Int8Array]"]=sS["[object Int16Array]"]=sS["[object Int32Array]"]=sS["[object Uint8Array]"]=sS["[object Uint8ClampedArray]"]=sS["[object Uint16Array]"]=sS["[object Uint32Array]"]=!0,sS["[object Arguments]"]=sS["[object Array]"]=sS["[object ArrayBuffer]"]=sS["[object Boolean]"]=sS["[object DataView]"]=sS["[object Date]"]=sS["[object Error]"]=sS["[object Function]"]=sS["[object Map]"]=sS["[object Number]"]=sS["[object Object]"]=sS["[object RegExp]"]=sS["[object Set]"]=sS["[object String]"]=sS["[object WeakMap]"]=!1;var cS,lS="object"==typeof exports&&exports&&!exports.nodeType&&exports,fS=lS&&"object"==typeof module&&module&&!module.nodeType&&module,hS=fS&&fS.exports===lS&&wb.process,dS=function(){try{var t=fS&&fS.require&&fS.require("util").types;return t||hS&&hS.binding&&hS.binding("util")}catch(t){}}(),pS=dS&&dS.isTypedArray,vS=pS?(cS=pS,function(t){return cS(t)}):function(t){return Yk(t)&&Zk(t.length)&&!!sS[Pb(t)]};function yS(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]}var mS=Object.prototype.hasOwnProperty;function gS(t,e,n){var r=t[e];mS.call(t,e)&&tk(r,n)&&(void 0!==n||e in t)||_k(t,e,n)}var wS=9007199254740991,bS=/^(?:0|[1-9]\d*)$/;function xS(t,e){var n=typeof t;return!!(e=null==e?wS:e)&&("number"==n||"symbol"!=n&&bS.test(t))&&t>-1&&t%1==0&&t<e}var OS=Object.prototype.hasOwnProperty;function kS(t,e){var n=vv(t),r=!n&&qk(t),i=!n&&!r&&eS(t),o=!n&&!r&&!i&&vS(t),a=n||r||i||o,u=a?function(t,e){for(var n=-1,r=Array(t);++n<t;)r[n]=e(n);return r}(t.length,String):[],s=u.length;for(var c in t)!e&&!OS.call(t,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||xS(c,s))||u.push(c);return u}var SS=Object.prototype.hasOwnProperty;function jS(t){if(!Lb(t))return function(t){var e=[];if(null!=t)for(var n in Object(t))e.push(n);return e}(t);var e=Hk(t),n=[];for(var r in t)("constructor"!=r||!e&&SS.call(t,r))&&n.push(r);return n}function _S(t){return Jk(t)?kS(t,!0):jS(t)}function MS(t){return function(t,e,n,r){var i=!n;n||(n={});for(var o=-1,a=e.length;++o<a;){var u=e[o],s=r?r(n[u],t[u],u,n,t):void 0;void 0===s&&(s=t[u]),i?_k(n,u,s):gS(n,u,s)}return n}(t,_S(t))}function DS(t,e,n,r,i,o,a){var u=yS(t,n),s=yS(e,n),c=a.get(s);if(c)Mk(t,n,c);else{var l,f=o?o(u,s,n+"",t,e,a):void 0,h=void 0===f;if(h){var d=vv(s),p=!d&&eS(s),v=!d&&!p&&vS(s);f=s,d||p||v?vv(u)?f=u:Yk(l=u)&&Jk(l)?f=function(t,e){var n=-1,r=t.length;for(e||(e=Array(r));++n<r;)e[n]=t[n];return e}(u):p?(h=!1,f=function(t,e){if(e)return t.slice();var n=t.length,r=Ck?Ck(n):new t.constructor(n);return t.copy(r),r}(s,!0)):v?(h=!1,f=Rk(s,!0)):f=[]:function(t){if(!Yk(t)||Pb(t)!=nS)return!1;var e=Fk(t);if(null===e)return!0;var n=aS.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&oS.call(n)==uS}(s)||qk(s)?(f=u,qk(u)?f=MS(u):Lb(u)&&!Ib(u)||(f=function(t){return"function"!=typeof t.constructor||Hk(t)?{}:Nk(Fk(t))}(s))):h=!1}h&&(a.set(s,f),i(f,s,r,o,a),a.delete(s)),Mk(t,n,f)}}function $S(t,e,n,r,i){t!==e&&Ek(e,(function(o,a){if(i||(i=new kk),Lb(o))DS(t,e,a,n,$S,r,i);else{var u=r?r(yS(t,a),o,a+"",t,e,i):void 0;void 0===u&&(u=o),Mk(t,a,u)}}),_S)}function ES(t){return t}var PS=Math.max;var LS=jk?function(t,e){return jk(t,"toString",{configurable:!0,enumerable:!1,value:(n=e,function(){return n}),writable:!0});var n}:ES,AS=LS,CS=Date.now;var TS=function(t){var e=0,n=0;return function(){var r=CS(),i=16-(r-n);if(n=r,i>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(AS),RS=TS;function IS(t,e){return RS(function(t,e,n){return e=PS(void 0===e?t.length-1:e,0),function(){for(var r=arguments,i=-1,o=PS(r.length-e,0),a=Array(o);++i<o;)a[i]=r[e+i];i=-1;for(var u=Array(e+1);++i<e;)u[i]=r[i];return u[e]=n(a),function(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}(t,this,u)}}(t,e,ES),t+"")}var NS,WS=(NS=function(t,e,n,r){$S(t,e,n,r)},IS((function(t,e){var n=-1,r=e.length,i=r>1?e[r-1]:void 0,o=r>2?e[2]:void 0;for(i=NS.length>3&&"function"==typeof i?(r--,i):void 0,o&&function(t,e,n){if(!Lb(n))return!1;var r=typeof e;return!!("number"==r?Jk(n)&&xS(e,n.length):"string"==r&&e in n)&&tk(n[e],t)}(e[0],e[1],o)&&(i=r<3?void 0:i,r=1),t=Object(t);++n<r;){var a=e[n];a&&NS(t,a,n,i)}return t}))),FS=WS;function zS(t){var e=-1,n=null==t?0:t.length;for(this.__data__=new Ok;++e<n;)this.add(t[e])}function HS(t,e){for(var n=-1,r=null==t?0:t.length;++n<r;)if(e(t[n],n,t))return!0;return!1}zS.prototype.add=zS.prototype.push=function(t){return this.__data__.set(t,"__lodash_hash_undefined__"),this},zS.prototype.has=function(t){return this.__data__.has(t)};var YS=1,US=2;function BS(t,e,n,r,i,o){var a=n&YS,u=t.length,s=e.length;if(u!=s&&!(a&&s>u))return!1;var c=o.get(t),l=o.get(e);if(c&&l)return c==e&&l==t;var f=-1,h=!0,d=n&US?new zS:void 0;for(o.set(t,e),o.set(e,t);++f<u;){var p=t[f],v=e[f];if(r)var y=a?r(v,p,f,e,t,o):r(p,v,f,t,e,o);if(void 0!==y){if(y)continue;h=!1;break}if(d){if(!HS(e,(function(t,e){if(a=e,!d.has(a)&&(p===t||i(p,t,n,r,o)))return d.push(e);var a}))){h=!1;break}}else if(p!==v&&!i(p,v,n,r,o)){h=!1;break}}return o.delete(t),o.delete(e),h}function GS(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function VS(t){var e=-1,n=Array(t.size);return t.forEach((function(t){n[++e]=t})),n}var qS=1,KS=2,ZS="[object Boolean]",JS="[object Date]",QS="[object Error]",XS="[object Map]",tj="[object Number]",ej="[object RegExp]",nj="[object Set]",rj="[object String]",ij="[object Symbol]",oj="[object ArrayBuffer]",aj="[object DataView]",uj=Ob?Ob.prototype:void 0,sj=uj?uj.valueOf:void 0;var cj=Object.prototype.propertyIsEnumerable,lj=Object.getOwnPropertySymbols,fj=lj?function(t){return null==t?[]:(t=Object(t),function(t,e){for(var n=-1,r=null==t?0:t.length,i=0,o=[];++n<r;){var a=t[n];e(a,n,t)&&(o[i++]=a)}return o}(lj(t),(function(e){return cj.call(t,e)})))}:function(){return[]},hj=fj,dj=Wk(Object.keys,Object),pj=Object.prototype.hasOwnProperty;function vj(t){return Jk(t)?kS(t):function(t){if(!Hk(t))return dj(t);var e=[];for(var n in Object(t))pj.call(t,n)&&"constructor"!=n&&e.push(n);return e}(t)}function yj(t){return function(t,e,n){var r=e(t);return vv(t)?r:function(t,e){for(var n=-1,r=e.length,i=t.length;++n<r;)t[i+n]=e[n];return t}(r,n(t))}(t,vj,hj)}var mj=1,gj=Object.prototype.hasOwnProperty;var wj=vk(xb,"DataView"),bj=vk(xb,"Promise"),xj=vk(xb,"Set"),Oj=vk(xb,"WeakMap"),kj="[object Map]",Sj="[object Promise]",jj="[object Set]",_j="[object WeakMap]",Mj="[object DataView]",Dj=uk(wj),$j=uk(yk),Ej=uk(bj),Pj=uk(xj),Lj=uk(Oj),Aj=Pb;(wj&&Aj(new wj(new ArrayBuffer(1)))!=Mj||yk&&Aj(new yk)!=kj||bj&&Aj(bj.resolve())!=Sj||xj&&Aj(new xj)!=jj||Oj&&Aj(new Oj)!=_j)&&(Aj=function(t){var e=Pb(t),n="[object Object]"==e?t.constructor:void 0,r=n?uk(n):"";if(r)switch(r){case Dj:return Mj;case $j:return kj;case Ej:return Sj;case Pj:return jj;case Lj:return _j}return e});var Cj=Aj,Tj=1,Rj="[object Arguments]",Ij="[object Array]",Nj="[object Object]",Wj=Object.prototype.hasOwnProperty;function Fj(t,e,n,r,i,o){var a=vv(t),u=vv(e),s=a?Ij:Cj(t),c=u?Ij:Cj(e),l=(s=s==Rj?Nj:s)==Nj,f=(c=c==Rj?Nj:c)==Nj,h=s==c;if(h&&eS(t)){if(!eS(e))return!1;a=!0,l=!1}if(h&&!l)return o||(o=new kk),a||vS(t)?BS(t,e,n,r,i,o):function(t,e,n,r,i,o,a){switch(n){case aj:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case oj:return!(t.byteLength!=e.byteLength||!o(new Tk(t),new Tk(e)));case ZS:case JS:case tj:return tk(+t,+e);case QS:return t.name==e.name&&t.message==e.message;case ej:case rj:return t==e+"";case XS:var u=GS;case nj:var s=r&qS;if(u||(u=VS),t.size!=e.size&&!s)return!1;var c=a.get(t);if(c)return c==e;r|=KS,a.set(t,e);var l=BS(u(t),u(e),r,i,o,a);return a.delete(t),l;case ij:if(sj)return sj.call(t)==sj.call(e)}return!1}(t,e,s,n,r,i,o);if(!(n&Tj)){var d=l&&Wj.call(t,"__wrapped__"),p=f&&Wj.call(e,"__wrapped__");if(d||p){var v=d?t.value():t,y=p?e.value():e;return o||(o=new kk),i(v,y,n,r,o)}}return!!h&&(o||(o=new kk),function(t,e,n,r,i,o){var a=n&mj,u=yj(t),s=u.length;if(s!=yj(e).length&&!a)return!1;for(var c=s;c--;){var l=u[c];if(!(a?l in e:gj.call(e,l)))return!1}var f=o.get(t),h=o.get(e);if(f&&h)return f==e&&h==t;var d=!0;o.set(t,e),o.set(e,t);for(var p=a;++c<s;){var v=t[l=u[c]],y=e[l];if(r)var m=a?r(y,v,l,e,t,o):r(v,y,l,t,e,o);if(!(void 0===m?v===y||i(v,y,n,r,o):m)){d=!1;break}p||(p="constructor"==l)}if(d&&!p){var g=t.constructor,w=e.constructor;g==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof g&&g instanceof g&&"function"==typeof w&&w instanceof w||(d=!1)}return o.delete(t),o.delete(e),d}(t,e,n,r,i,o))}function zj(t,e,n,r,i){return t===e||(null==t||null==e||!Yk(t)&&!Yk(e)?t!=t&&e!=e:Fj(t,e,n,r,zj,i))}function Hj(t,e){return zj(t,e)}var Yj=Object.prototype.hasOwnProperty;function Uj(t,e){return null!=t&&Yj.call(t,e)}var Bj="[object Symbol]";function Gj(t){return"symbol"==typeof t||Yk(t)&&Pb(t)==Bj}var Vj=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,qj=/^\w*$/;var Kj="Expected a function";function Zj(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new TypeError(Kj);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=t.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(Zj.Cache||Ok),n}Zj.Cache=Ok;var Jj=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Qj=/\\(\\)?/g,Xj=function(t){var e=Zj(t,(function(t){return 500===n.size&&n.clear(),t})),n=e.cache;return e}((function(t){var e=[];return 46===t.charCodeAt(0)&&e.push(""),t.replace(Jj,(function(t,n,r,i){e.push(r?i.replace(Qj,"$1"):n||t)})),e})),t_=Xj;var e_=1/0,n_=Ob?Ob.prototype:void 0,r_=n_?n_.toString:void 0;function i_(t){if("string"==typeof t)return t;if(vv(t))return function(t,e){for(var n=-1,r=null==t?0:t.length,i=Array(r);++n<r;)i[n]=e(t[n],n,t);return i}(t,i_)+"";if(Gj(t))return r_?r_.call(t):"";var e=t+"";return"0"==e&&1/t==-e_?"-0":e}function o_(t,e){return vv(t)?t:function(t,e){if(vv(t))return!1;var n=typeof t;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=t&&!Gj(t))||qj.test(t)||!Vj.test(t)||null!=e&&t in Object(e)}(t,e)?[t]:t_(function(t){return null==t?"":i_(t)}(t))}var a_=1/0;function u_(t){if("string"==typeof t||Gj(t))return t;var e=t+"";return"0"==e&&1/t==-a_?"-0":e}function s_(t,e){return null!=t&&function(t,e,n){for(var r=-1,i=(e=o_(e,t)).length,o=!1;++r<i;){var a=u_(e[r]);if(!(o=null!=t&&n(t,a)))break;t=t[a]}return o||++r!=i?o:!!(i=null==t?0:t.length)&&Zk(i)&&xS(a,i)&&(vv(t)||qk(t))}(t,e,Uj)}function c_(t,e,n){var r=null==t?void 0:function(t,e){for(var n=0,r=(e=o_(e,t)).length;null!=t&&n<r;)t=t[u_(e[n++])];return n&&n==r?t:void 0}(t,e);return void 0===r?n:r}function l_(t,e,n){return null==t?t:function(t,e,n,r){if(!Lb(t))return t;for(var i=-1,o=(e=o_(e,t)).length,a=o-1,u=t;null!=u&&++i<o;){var s=u_(e[i]),c=n;if("__proto__"===s||"constructor"===s||"prototype"===s)return t;if(i!=a){var l=u[s];void 0===(c=r?r(l,s,u):void 0)&&(c=Lb(l)?l:xS(e[i+1])?[]:{})}gS(u,s,c),u=u[s]}return t}(t,e,n)}var f_,h_,d_={range:function(t){return Math.max(+t,1)},"date.highlight":function(t){return yv(t)},"subDomain.label":function(t){return function(t){return"string"==typeof t||!vv(t)&&Yk(t)&&"[object String]"==Pb(t)}(t)&&""!==t||Ib(t)?t:null}},p_=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d_;en(this,t),this.preProcessors=e,this.options={itemSelector:"#cal-heatmap",range:12,domain:{type:"hour",gutter:4,padding:[0,0,0,0],dynamicDimension:!0,sort:"asc",label:{text:void 0,position:"bottom",textAlign:"middle",offset:{x:0,y:0},rotate:null,width:100,height:25}},subDomain:{type:"minute",width:10,height:10,gutter:2,radius:0,label:null,color:void 0,sort:"asc"},date:{start:new Date,min:void 0,max:void 0,highlight:[],locale:"en",timezone:void 0},verticalOrientation:!1,data:{source:"",type:"json",requestInit:{},x:"",y:"",groupY:"sum",defaultValue:null},scale:void 0,animationDuration:200,theme:"light",x:{domainHorizontalLabelWidth:0,domainVerticalLabelHeight:0}}}return rn(t,[{key:"set",value:function(t,e){return!(!s_(this.options,t)||Hj(c_(this.options,t),e))&&(l_(this.options,t,s_(this.preProcessors,t)?c_(this.preProcessors,t)(e):e),!0)}},{key:"init",value:function(t){var e=this;this.options=Object.assign({},FS(this.options,t,(function(t,e){return Array.isArray(e)?e:void 0})));var n=this.options;Object.keys(this.preProcessors).forEach((function(t){l_(n,t,c_(e.preProcessors,t)(c_(n,t)))})),void 0===n.scale&&this.initScale(),n.x.domainVerticalLabelHeight=n.domain.label.height,"top"===n.domain.label.position||"bottom"===n.domain.label.position?n.x.domainHorizontalLabelWidth=0:(n.x.domainVerticalLabelHeight=0,n.x.domainHorizontalLabelWidth=n.domain.label.width),null!==n.domain.label.text&&""!==n.domain.label.text||(n.x.domainVerticalLabelHeight=0,n.x.domainHorizontalLabelWidth=0)}},{key:"initScale",value:function(){this.options.scale={color:{scheme:"YlOrBr",type:"quantize",domain:Om}}}}]),t}(),v_=Rr,y_=jn,m_=dn.RegExp,g_=y_((function(){var t=m_("a","y");return t.lastIndex=2,null!==t.exec("abcd")})),w_=g_||y_((function(){return!m_("a","y").sticky})),b_=g_||y_((function(){var t=m_("^r","gy");return t.lastIndex=2,null!==t.exec("str")})),x_={BROKEN_CARET:b_,MISSED_STICKY:w_,UNSUPPORTED_Y:g_},O_=jn,k_=dn.RegExp,S_=O_((function(){var t=k_(".","s");return!(t.dotAll&&t.test("\n")&&"s"===t.flags)})),j_=jn,__=dn.RegExp,M_=j_((function(){var t=__("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})),D_=Wr,$_=Pn,E_=ip,P_=function(){var t=v_(this),e="";return t.hasIndices&&(e+="d"),t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.unicodeSets&&(e+="v"),t.sticky&&(e+="y"),e},L_=x_,A_=Ih,C_=po.get,T_=S_,R_=M_,I_=Sn("native-string-replace",String.prototype.replace),N_=RegExp.prototype.exec,W_=N_,F_=$_("".charAt),z_=$_("".indexOf),H_=$_("".replace),Y_=$_("".slice),U_=(h_=/b*/g,D_(N_,f_=/a/,"a"),D_(N_,h_,"a"),0!==f_.lastIndex||0!==h_.lastIndex),B_=L_.BROKEN_CARET,G_=void 0!==/()??/.exec("")[1];(U_||G_||B_||T_||R_)&&(W_=function(t){var e,n,r,i,o,a,u,s=this,c=C_(s),l=E_(t),f=c.raw;if(f)return f.lastIndex=s.lastIndex,e=D_(W_,f,l),s.lastIndex=f.lastIndex,e;var h=c.groups,d=B_&&s.sticky,p=D_(P_,s),v=s.source,y=0,m=l;if(d&&(p=H_(p,"y",""),-1===z_(p,"g")&&(p+="g"),m=Y_(l,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&"\n"!==F_(l,s.lastIndex-1))&&(v="(?: "+v+")",m=" "+m,y++),n=new RegExp("^(?:"+v+")",p)),G_&&(n=new RegExp("^"+v+"$(?!\\s)",p)),U_&&(r=s.lastIndex),i=D_(N_,d?n:s,m),d?i?(i.input=Y_(i.input,y),i[0]=Y_(i[0],y),i.index=s.lastIndex,s.lastIndex+=i[0].length):s.lastIndex=0:U_&&i&&(s.lastIndex=s.global?i.index+i[0].length:r),G_&&i&&i.length>1&&D_(I_,i[0],n,(function(){for(o=1;o<arguments.length-2;o++)void 0===arguments[o]&&(i[o]=void 0)})),i&&h)for(i.groups=a=A_(null),o=0;o<h.length;o++)a[(u=h[o])[0]]=i[u[1]];return i});var V_=W_;bu({target:"RegExp",proto:!0,forced:/./.exec!==V_},{exec:V_});var q_,K_,Z_=Ss,J_=Io,Q_=V_,X_=jn,tM=pr,eM=Ki,nM=tM("species"),rM=RegExp.prototype,iM=dp.charAt,oM=Pn,aM=Nn,uM=Math.floor,sM=oM("".charAt),cM=oM("".replace),lM=oM("".slice),fM=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,hM=/\$([$&'`]|\d{1,2})/g,dM=Wr,pM=Rr,vM=br,yM=zo,mM=V_,gM=TypeError,wM=xs,bM=Wr,xM=Pn,OM=function(t,e,n,r){var i=tM(t),o=!X_((function(){var e={};return e[i]=function(){return 7},7!==""[t](e)})),a=o&&!X_((function(){var e=!1,n=/a/;return"split"===t&&((n={}).constructor={},n.constructor[nM]=function(){return n},n.flags="",n[i]=/./[i]),n.exec=function(){return e=!0,null},n[i](""),!e}));if(!o||!a||n){var u=Z_(/./[i]),s=e(i,""[t],(function(t,e,n,r,i){var a=Z_(t),s=e.exec;return s===Q_||s===rM.exec?o&&!i?{done:!0,value:u(e,n,r)}:{done:!0,value:a(n,e,r)}:{done:!1}}));J_(String.prototype,t,s[0]),J_(rM,i,s[1])}r&&eM(rM[i],"sham",!0)},kM=jn,SM=Rr,jM=br,_M=Ln,MM=ka,DM=Ea,$M=ip,EM=Tn,PM=function(t,e,n){return e+(n?iM(t,e).length:1)},LM=ri,AM=function(t,e,n,r,i,o){var a=n+t.length,u=r.length,s=hM;return void 0!==i&&(i=aM(i),s=fM),cM(o,s,(function(o,s){var c;switch(sM(s,0)){case"$":return"$";case"&":return t;case"`":return lM(e,0,n);case"'":return lM(e,a);case"<":c=i[lM(s,1,-1)];break;default:var l=+s;if(0===l)return o;if(l>u){var f=uM(l/10);return 0===f?o:f<=u?void 0===r[f-1]?sM(s,1):r[f-1]+sM(s,1):o}c=r[l-1]}return void 0===c?"":c}))},CM=function(t,e){var n=t.exec;if(vM(n)){var r=dM(n,t,e);return null!==r&&pM(r),r}if("RegExp"===yM(t))return dM(mM,t,e);throw new gM("RegExp#exec called on incompatible receiver")},TM=pr("replace"),RM=Math.max,IM=Math.min,NM=xM([].concat),WM=xM([].push),FM=xM("".indexOf),zM=xM("".slice),HM="$0"==="a".replace(/./,"$0"),YM=!!/./[TM]&&""===/./[TM]("a","$0"),UM=!kM((function(){var t=/./;return t.exec=function(){var t=[];return t.groups={a:"7"},t},"7"!=="".replace(t,"$<a>")}));OM("replace",(function(t,e,n){var r=YM?"$":"$0";return[function(t,n){var r=EM(this),i=_M(t)?void 0:LM(t,TM);return i?bM(i,t,r,n):bM(e,$M(r),t,n)},function(t,i){var o=SM(this),a=$M(t);if("string"==typeof i&&-1===FM(i,r)&&-1===FM(i,"$<")){var u=n(e,o,a,i);if(u.done)return u.value}var s=jM(i);s||(i=$M(i));var c,l=o.global;l&&(c=o.unicode,o.lastIndex=0);for(var f,h=[];null!==(f=CM(o,a))&&(WM(h,f),l);){""===$M(f[0])&&(o.lastIndex=PM(a,DM(o.lastIndex),c))}for(var d,p="",v=0,y=0;y<h.length;y++){for(var m,g=$M((f=h[y])[0]),w=RM(IM(MM(f.index),a.length),0),b=[],x=1;x<f.length;x++)WM(b,void 0===(d=f[x])?d:String(d));var O=f.groups;if(s){var k=NM([g],b,w,a);void 0!==O&&WM(k,O),m=$M(wM(i,void 0,k))}else m=AM(g,a,w,b,O,i);w>=v&&(p+=zM(a,v,w)+m,v=w+g.length)}return p+zM(a,v)}]}),!UM||!HM||YM);var BM=function(){function t(e){en(this,t),q_.add(this),this.calendar=e}return rn(t,[{key:"getDatas",value:function(t,e,n){return fv(this,void 0,void 0,Xe().mark((function r(){var i;return Xe().wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(!("string"==typeof t&&t.length>0)){r.next=2;break}return r.abrupt("return",hv(this,q_,"m",K_).call(this,t,e,n));case 2:return i=[],Array.isArray(t)&&(i=t),r.abrupt("return",new Promise((function(t){t(i)})));case 5:case"end":return r.stop()}}),r,this)})))}},{key:"parseURI",value:function(t,e,n){var r=this,i=t.replace(/\{\{start=(.*?)\}\}/g,(function(t,n){return r.calendar.dateHelper.date(e).format(n)}));return i=i.replace(/\{\{end=(.*?)\}\}/g,(function(t,e){return r.calendar.dateHelper.date(n).format(e)}))}}]),t}();q_=new WeakSet,K_=function(t,e,n){var r=this.calendar.options.options.data,i=r.type,o=r.requestInit,a=this.parseURI(t,e,n);switch(i){case"json":return Qe(a,o);case"csv":return Je(a,o);case"tsv":return Ze("\t",a,o);case"txt":return Ke(a,o);default:return new Promise((function(t){t([])}))}};var GM=Or,VM=Ti.EXISTS,qM=Pn,KM=Iu,ZM=Function.prototype,JM=qM(ZM.toString),QM=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,XM=qM(QM.exec);GM&&!VM&&KM(ZM,"name",{configurable:!0,get:function(){try{return XM(QM,JM(this))[1]}catch(t){return""}}});var tD={exports:{}};tD.exports=function(){var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",o="minute",a="hour",u="day",s="week",c="month",l="quarter",f="year",h="date",d="Invalid Date",p=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,v=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,y={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return"["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},m=function(t,e,n){var r=String(t);return!r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},g={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return(e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return-t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,c),o=n-i<0,a=e.clone().add(r+(o?-1:1),c);return+(-(r+(n-i)/(o?i-a:a-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return{M:c,y:f,w:s,d:u,D:h,h:a,m:o,s:i,ms:r,Q:l}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},w="en",b={};b[w]=y;var x="$isDayjsObject",O=function(t){return t instanceof _||!(!t||!t[x])},k=function t(e,n,r){var i;if(!e)return w;if("string"==typeof e){var o=e.toLowerCase();b[o]&&(i=o),n&&(b[o]=n,i=o);var a=e.split("-");if(!i&&a.length>1)return t(a[0])}else{var u=e.name;b[u]=e,i=u}return!r&&i&&(w=i),i||!r&&w},S=function(t,e){if(O(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},j=g;j.l=k,j.i=O,j.w=function(t,e){return S(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function y(t){this.$L=k(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[x]=!0}var m=y.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(j.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match(p);if(r){var i=r[2]-1||0,o=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,o)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,o)}}return new Date(e)}(t),this.init()},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds()},m.$utils=function(){return j},m.isValid=function(){return!(this.$d.toString()===d)},m.isSame=function(t,e){var n=S(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return S(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<S(t)},m.$g=function(t,e,n){return j.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!j.u(e)||e,l=j.p(t),d=function(t,e){var i=j.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(u)},p=function(t,e){return j.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},v=this.$W,y=this.$M,m=this.$D,g="set"+(this.$u?"UTC":"");switch(l){case f:return r?d(1,0):d(31,11);case c:return r?d(1,y):d(0,y+1);case s:var w=this.$locale().weekStart||0,b=(v<w?v+7:v)-w;return d(r?m-b:m+(6-b),y);case u:case h:return p(g+"Hours",0);case a:return p(g+"Minutes",1);case o:return p(g+"Seconds",2);case i:return p(g+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var n,s=j.p(t),l="set"+(this.$u?"UTC":""),d=(n={},n[u]=l+"Date",n[h]=l+"Date",n[c]=l+"Month",n[f]=l+"FullYear",n[a]=l+"Hours",n[o]=l+"Minutes",n[i]=l+"Seconds",n[r]=l+"Milliseconds",n)[s],p=s===u?this.$D+(e-this.$W):e;if(s===c||s===f){var v=this.clone().set(h,1);v.$d[d](p),v.init(),this.$d=v.set(h,Math.min(this.$D,v.daysInMonth())).$d}else d&&this.$d[d](p);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[j.p(t)]()},m.add=function(r,l){var h,d=this;r=Number(r);var p=j.p(l),v=function(t){var e=S(d);return j.w(e.date(e.date()+Math.round(t*r)),d)};if(p===c)return this.set(c,this.$M+r);if(p===f)return this.set(f,this.$y+r);if(p===u)return v(1);if(p===s)return v(7);var y=(h={},h[o]=e,h[a]=n,h[i]=t,h)[p]||1,m=this.$d.getTime()+r*y;return j.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||d;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=j.z(this),o=this.$H,a=this.$m,u=this.$M,s=n.weekdays,c=n.months,l=n.meridiem,f=function(t,n,i,o){return t&&(t[n]||t(e,r))||i[n].slice(0,o)},h=function(t){return j.s(o%12||12,t,"0")},p=l||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(v,(function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return j.s(e.$y,4,"0");case"M":return u+1;case"MM":return j.s(u+1,2,"0");case"MMM":return f(n.monthsShort,u,c,3);case"MMMM":return f(c,u);case"D":return e.$D;case"DD":return j.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return f(n.weekdaysMin,e.$W,s,2);case"ddd":return f(n.weekdaysShort,e.$W,s,3);case"dddd":return s[e.$W];case"H":return String(o);case"HH":return j.s(o,2,"0");case"h":return h(1);case"hh":return h(2);case"a":return p(o,a,!0);case"A":return p(o,a,!1);case"m":return String(a);case"mm":return j.s(a,2,"0");case"s":return String(e.$s);case"ss":return j.s(e.$s,2,"0");case"SSS":return j.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,h,d){var p,v=this,y=j.p(h),m=S(r),g=(m.utcOffset()-this.utcOffset())*e,w=this-m,b=function(){return j.m(v,m)};switch(y){case f:p=b()/12;break;case c:p=b();break;case l:p=b()/3;break;case s:p=(w-g)/6048e5;break;case u:p=(w-g)/864e5;break;case a:p=w/n;break;case o:p=w/e;break;case i:p=w/t;break;default:p=w}return d?p:j.a(p)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return b[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=k(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return j.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},y}(),M=_.prototype;return S.prototype=M,[["$ms",r],["$s",i],["$m",o],["$H",a],["$W",u],["$M",c],["$y",f],["$D",h]].forEach((function(t){M[t[1]]=function(e){return this.$g(e,t[0],t[1])}})),S.extend=function(t,e){return t.$i||(t(e,_,S),t.$i=!0),S},S.locale=k,S.isDayjs=O,S.unix=function(t){return S(1e3*t)},S.en=b[w],S.Ls=b,S.p={},S}();var eD,nD,rD=fn(tD.exports),iD={exports:{}},oD=fn(iD.exports=(eD="week",nD="year",function(t,e,n){var r=e.prototype;r.week=function(t){if(void 0===t&&(t=null),null!==t)return this.add(7*(t-this.week()),"day");var e=this.$locale().yearStart||1;if(11===this.month()&&this.date()>25){var r=n(this).startOf(nD).add(1,nD).date(e),i=n(this).endOf(eD);if(r.isBefore(i))return 1}var o=n(this).startOf(nD).date(e).startOf(eD).subtract(1,"millisecond"),a=this.diff(o,eD,!0);return a<0?n(this).startOf("week").week():Math.ceil(a)},r.weeks=function(t){return void 0===t&&(t=null),this.week(t)}})),aD={exports:{}};aD.exports=function(t,e,n){e.prototype.dayOfYear=function(t){var e=Math.round((n(this).startOf("day")-n(this).startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"day")}};var uD=fn(aD.exports),sD={exports:{}};sD.exports=function(t,e){e.prototype.weekday=function(t){var e=this.$locale().weekStart||0,n=this.$W,r=(n<e?n+7:n)-e;return this.$utils().u(t)?r:this.subtract(r,"day").add(t,"day")}};var cD=fn(sD.exports),lD={exports:{}};lD.exports=function(t,e,n){var r=function(t,e){if(!e||!e.length||1===e.length&&!e[0]||1===e.length&&Array.isArray(e[0])&&!e[0].length)return null;var n;1===e.length&&e[0].length>0&&(e=e[0]),n=(e=e.filter((function(t){return t})))[0];for(var r=1;r<e.length;r+=1)e[r].isValid()&&!e[r][t](n)||(n=e[r]);return n};n.max=function(){var t=[].slice.call(arguments,0);return r("isAfter",t)},n.min=function(){var t=[].slice.call(arguments,0);return r("isBefore",t)}};var fD=fn(lD.exports),hD={exports:{}};hD.exports=function(t,e){e.prototype.isoWeeksInYear=function(){var t=this.isLeapYear(),e=this.endOf("y").day();return 4===e||t&&5===e?53:52}};var dD=fn(hD.exports),pD={exports:{}};pD.exports=function(){var t="day";return function(e,n,r){var i=function(e){return e.add(4-e.isoWeekday(),t)},o=n.prototype;o.isoWeekYear=function(){return i(this).year()},o.isoWeek=function(e){if(!this.$utils().u(e))return this.add(7*(e-this.isoWeek()),t);var n,o,a,u=i(this),s=(n=this.isoWeekYear(),a=4-(o=(this.$u?r.utc:r)().year(n).startOf("year")).isoWeekday(),o.isoWeekday()>4&&(a+=7),o.add(a,t));return u.diff(s,"week")+1},o.isoWeekday=function(t){return this.$utils().u(t)?this.day()||7:this.day(this.day()%7?t:t-7)};var a=o.startOf;o.startOf=function(t,e){var n=this.$utils(),r=!!n.u(e)||e;return"isoweek"===n.p(t)?r?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):a.bind(this)(t,e)}}}();var vD=fn(pD.exports),yD={exports:{}};yD.exports=function(t,e){e.prototype.isLeapYear=function(){return this.$y%4==0&&this.$y%100!=0||this.$y%400==0}};var mD=fn(yD.exports),gD={exports:{}};gD.exports=function(t,e){var n=e.prototype,r=n.format;n.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return r.bind(this)(t);var i=this.$utils(),o=(t||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,(function(t){switch(t){case"Q":return Math.ceil((e.$M+1)/3);case"Do":return n.ordinal(e.$D);case"gggg":return e.weekYear();case"GGGG":return e.isoWeekYear();case"wo":return n.ordinal(e.week(),"W");case"w":case"ww":return i.s(e.week(),"w"===t?1:2,"0");case"W":case"WW":return i.s(e.isoWeek(),"W"===t?1:2,"0");case"k":case"kk":return i.s(String(0===e.$H?24:e.$H),"k"===t?1:2,"0");case"X":return Math.floor(e.$d.getTime()/1e3);case"x":return e.$d.getTime();case"z":return"["+e.offsetName()+"]";case"zzz":return"["+e.offsetName("long")+"]";default:return t}}));return r.bind(this)(o)}};var wD=fn(gD.exports),bD={exports:{}};bD.exports=function(){var t="minute",e=/[+-]\d\d(?::?\d\d)?/g,n=/([+-]|\d\d)/g;return function(r,i,o){var a=i.prototype;o.utc=function(t){return new i({date:t,utc:!0,args:arguments})},a.utc=function(e){var n=o(this.toDate(),{locale:this.$L,utc:!0});return e?n.add(this.utcOffset(),t):n},a.local=function(){return o(this.toDate(),{locale:this.$L,utc:!1})};var u=a.parse;a.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),u.call(this,t)};var s=a.init;a.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds()}else s.call(this)};var c=a.utcOffset;a.utcOffset=function(r,i){var o=this.$utils().u;if(o(r))return this.$u?0:o(this.$offset)?c.call(this):this.$offset;if("string"==typeof r&&(r=function(t){void 0===t&&(t="");var r=t.match(e);if(!r)return null;var i=(""+r[0]).match(n)||["-",0,0],o=i[0],a=60*+i[1]+ +i[2];return 0===a?0:"+"===o?a:-a}(r),null===r))return this;var a=Math.abs(r)<=16?60*r:r,u=this;if(i)return u.$offset=a,u.$u=0===r,u;if(0!==r){var s=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(u=this.local().add(a+s,t)).$offset=a,u.$x.$localOffset=s}else u=this.utc();return u};var l=a.format;a.format=function(t){var e=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return l.call(this,e)},a.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},a.isUTC=function(){return!!this.$u},a.toISOString=function(){return this.toDate().toISOString()},a.toString=function(){return this.toDate().toUTCString()};var f=a.toDate;a.toDate=function(t){return"s"===t&&this.$offset?o(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var h=a.diff;a.diff=function(t,e,n){if(t&&this.$u===t.$u)return h.call(this,t,e,n);var r=this.local(),i=o(t).local();return h.call(r,i,e,n)}}}();var xD=fn(bD.exports),OD={exports:{}};OD.exports=function(){var t={year:0,month:1,day:2,hour:3,minute:4,second:5},e={};return function(n,r,i){var o,a=function(t,n,r){void 0===r&&(r={});var i=new Date(t),o=function(t,n){void 0===n&&(n={});var r=n.timeZoneName||"short",i=t+"|"+r,o=e[i];return o||(o=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:t,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:r}),e[i]=o),o}(n,r);return o.formatToParts(i)},u=function(e,n){for(var r=a(e,n),o=[],u=0;u<r.length;u+=1){var s=r[u],c=s.type,l=s.value,f=t[c];f>=0&&(o[f]=parseInt(l,10))}var h=o[3],d=24===h?0:h,p=o[0]+"-"+o[1]+"-"+o[2]+" "+d+":"+o[4]+":"+o[5]+":000",v=+e;return(i.utc(p).valueOf()-(v-=v%1e3))/6e4},s=r.prototype;s.tz=function(t,e){void 0===t&&(t=o);var n=this.utcOffset(),r=this.toDate(),a=r.toLocaleString("en-US",{timeZone:t}),u=Math.round((r-new Date(a))/1e3/60),s=i(a,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(15*-Math.round(r.getTimezoneOffset()/15)-u,!0);if(e){var c=s.utcOffset();s=s.add(n-c,"minute")}return s.$x.$timezone=t,s},s.offsetName=function(t){var e=this.$x.$timezone||i.tz.guess(),n=a(this.valueOf(),e,{timeZoneName:t}).find((function(t){return"timezonename"===t.type.toLowerCase()}));return n&&n.value};var c=s.startOf;s.startOf=function(t,e){if(!this.$x||!this.$x.$timezone)return c.call(this,t,e);var n=i(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return c.call(n,t,e).tz(this.$x.$timezone,!0)},i.tz=function(t,e,n){var r=n&&e,a=n||e||o,s=u(+i(),a);if("string"!=typeof t)return i(t).tz(a);var c=function(t,e,n){var r=t-60*e*1e3,i=u(r,n);if(e===i)return[r,e];var o=u(r-=60*(i-e)*1e3,n);return i===o?[r,i]:[t-60*Math.min(i,o)*1e3,Math.max(i,o)]}(i.utc(t,r).valueOf(),s,a),l=c[0],f=c[1],h=i(l).utcOffset(f);return h.$x.$timezone=a,h},i.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},i.tz.setDefault=function(t){o=t}}}();var kD=fn(OD.exports),SD={exports:{}};SD.exports=function(t,e,n){var r=e.prototype,i=function(t){return t&&(t.indexOf?t:t.s)},o=function(t,e,n,r,o){var a=t.name?t:t.$locale(),u=i(a[e]),s=i(a[n]),c=u||s.map((function(t){return t.slice(0,r)}));if(!o)return c;var l=a.weekStart;return c.map((function(t,e){return c[(e+(l||0))%7]}))},a=function(){return n.Ls[n.locale()]},u=function(t,e){return t.formats[e]||function(t){return t.replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(t,e,n){return e||n.slice(1)}))}(t.formats[e.toUpperCase()])},s=function(){var t=this;return{months:function(e){return e?e.format("MMMM"):o(t,"months")},monthsShort:function(e){return e?e.format("MMM"):o(t,"monthsShort","months",3)},firstDayOfWeek:function(){return t.$locale().weekStart||0},weekdays:function(e){return e?e.format("dddd"):o(t,"weekdays")},weekdaysMin:function(e){return e?e.format("dd"):o(t,"weekdaysMin","weekdays",2)},weekdaysShort:function(e){return e?e.format("ddd"):o(t,"weekdaysShort","weekdays",3)},longDateFormat:function(e){return u(t.$locale(),e)},meridiem:this.$locale().meridiem,ordinal:this.$locale().ordinal}};r.localeData=function(){return s.bind(this)()},n.localeData=function(){var t=a();return{firstDayOfWeek:function(){return t.weekStart||0},weekdays:function(){return n.weekdays()},weekdaysShort:function(){return n.weekdaysShort()},weekdaysMin:function(){return n.weekdaysMin()},months:function(){return n.months()},monthsShort:function(){return n.monthsShort()},longDateFormat:function(e){return u(t,e)},meridiem:t.meridiem,ordinal:t.ordinal}},n.months=function(){return o(a(),"months")},n.monthsShort=function(){return o(a(),"monthsShort","months",3)},n.weekdays=function(t){return o(a(),"weekdays",null,null,t)},n.weekdaysShort=function(t){return o(a(),"weekdaysShort","weekdays",3,t)},n.weekdaysMin=function(t){return o(a(),"weekdaysMin","weekdays",2,t)}};var jD=fn(SD.exports),_D={exports:{}};_D.exports=function(){var t={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(e,n,r){var i=n.prototype,o=i.format;r.en.formats=t,i.format=function(e){void 0===e&&(e="YYYY-MM-DDTHH:mm:ssZ");var n=this.$locale().formats,r=function(e,n){return e.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(e,r,i){var o=i&&i.toUpperCase();return r||n[i]||t[i]||n[o].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(t,e,n){return e||n.slice(1)}))}))}(e,void 0===n?{}:n);return o.call(this,r)}}}();var MD=fn(_D.exports),DD={exports:{}};DD.exports=function(t,e,n){n.updateLocale=function(t,e){var r=n.Ls[t];if(r)return(e?Object.keys(e):[]).forEach((function(t){r[t]=e[t]})),r}};var $D=fn(DD.exports);rD.extend(oD),rD.extend(dD),rD.extend(vD),rD.extend(mD),rD.extend(uD),rD.extend(cD),rD.extend(fD),rD.extend(wD),rD.extend(xD),rD.extend(kD),rD.extend(jD),rD.extend(MD),rD.extend($D);var ED="en",PD=function(){function t(){var e;en(this,t),this.locale=ED,this.timezone=rD.tz.guess(),"object"===("undefined"==typeof window?"undefined":tn(window))&&((e=window).dayjs||(e.dayjs=rD))}return rn(t,[{key:"setup",value:function(t){var e=t.options;return fv(this,void 0,void 0,Xe().mark((function t(){var n,r;return Xe().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(this.timezone=e.date.timezone||rD.tz.guess(),"string"!=typeof(n=e.date.locale)||n===ED){t.next=17;break}if("object"!==("undefined"==typeof window?"undefined":tn(window))){t.next=12;break}if(t.t0=window["dayjs_locale_".concat(n)],t.t0){t.next=9;break}return t.next=8,this.loadBrowserLocale(n);case 8:t.t0=t.sent;case 9:r=t.t0,t.next=15;break;case 12:return t.next=14,this.loadNodeLocale(n);case 14:r=t.sent;case 15:rD.locale(n),this.locale=r;case 17:"object"===tn(n)&&(n.hasOwnProperty("name")?(rD.locale(n.name,n),this.locale=n):this.locale=rD.updateLocale(ED,n));case 18:case"end":return t.stop()}}),t,this)})))}},{key:"extend",value:function(t){return rD.extend(t)}},{key:"getMonthWeekNumber",value:function(t){var e=this.date(t),n=e.startOf("day"),r=e.startOf("month").endOf("week");return n<=r?1:Math.ceil(n.diff(r,"weeks",!0))+1}},{key:"getWeeksCountInMonth",value:function(t){var e=this.date(t);return this.getLastWeekOfMonth(e).diff(this.getFirstWeekOfMonth(e),"week")+1}},{key:"getFirstWeekOfMonth",value:function(t){var e=this.date(t).startOf("month"),n=e.startOf("week");return e.weekday()>4&&(n=n.add(1,"week")),n}},{key:"getLastWeekOfMonth",value:function(t){var e=this.date(t).endOf("month"),n=e.endOf("week");return e.weekday()<4&&(n=n.subtract(1,"week")),n}},{key:"date",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:new Date;return rD.isDayjs(t)?t:rD(t).tz(this.timezone).utcOffset(0).locale(this.locale)}},{key:"format",value:function(t,e){if("function"==typeof e){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return e.apply(void 0,[t].concat(r))}return"string"==typeof e?this.date(t).format(e):null}},{key:"intervals",value:function(t,e,n){var r,i=!(arguments.length>3&&void 0!==arguments[3])||arguments[3],o=this.date(e);r="number"==typeof n?o.add(n,t):rD.isDayjs(n)?n:this.date(n),o=o.startOf(t),r=r.startOf(t);var a=rD.min(o,r);r=rD.max(o,r);var u=[];i||(r=r.add(1,"second"));do{u.push(+a),a=a.add(1,t)}while(a<r);return u}},{key:"loadBrowserLocale",value:function(t){return new Promise((function(e,n){var r=document.createElement("script");r.type="text/javascript",r.async=!0,r.src="https://cdn.jsdelivr.net/npm/dayjs@1/locale/".concat(t,".js"),r.onerror=function(t){n(t)},r.onload=function(){e(window["dayjs_locale_".concat(t)])},document.head.appendChild(r)}))}},{key:"loadNodeLocale",value:function(t){return import("dayjs/locale/".concat(t,".js"))}}]),t}(),LD=bu,AD=Gb,CD=Tn,TD=ip,RD=qb,ID=Pn("".indexOf);LD({target:"String",proto:!0,forced:!RD("includes")},{includes:function(t){return!!~ID(TD(CD(this)),TD(AD(t)),arguments.length>1?arguments[1]:void 0)}});var ND=["json","csv","tsv","txt"];function WD(t,e){var n=e.domain,r=e.subDomain,i=e.data,o=n.type,a=r.type;if(!t.has(o))throw new Error("'".concat(o,"' is not a valid domain type'"));if(!t.has(a))throw new Error("'".concat(a,"' is not a valid subDomain type'"));if(i.type&&!ND.includes(i.type))throw new Error("The data type '".concat(i.type,"' is not valid data type"));if(!(t.get(a).allowedDomainType||[]).includes(o))throw new Error("The subDomain.type '".concat(a,"' can not be used together ")+"with the domain type ".concat(o));return!0}qy("Set",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),ag);var FD=function(){function t(e){en(this,t),this.calendar=e,this.settings=new Map,this.plugins=new Map,this.pendingPaint=new Set}return rn(t,[{key:"add",value:function(t){var e=this;t.forEach((function(t){var n,r,i=on(t,2),o=i[0],a=i[1],u=function(t,e){return"".concat((new t).name).concat((null==e?void 0:e.key)||"")}(o,a);e.plugins.get(u)&&e.settings.get(u)&&Hj(e.settings.get(u).options,a)||(e.settings.set(u,{options:a,dirty:!0}),e.plugins.has(u)||e.plugins.set(u,(n=o,r=e.calendar,new n(r))),e.pendingPaint.add(e.plugins.get(u)))}))}},{key:"setupAll",value:function(){var t=this;this.plugins.forEach((function(e,n){var r=t.settings.get(n);void 0!==r&&r.dirty&&(e.setup(r.options),r.dirty=!1,t.settings.set(n,r))}))}},{key:"paintAll",value:function(){return Array.from(this.pendingPaint.values()).map((function(t){return t.paint()}))}},{key:"destroyAll",value:function(){return this.allPlugins().map((function(t){return t.destroy()}))}},{key:"getFromPosition",value:function(t){return this.allPlugins().filter((function(e){var n;return(null===(n=e.options)||void 0===n?void 0:n.position)===t}))}},{key:"getHeightFromPosition",value:function(t){return this.getFromPosition(t).map((function(t){return t.options.dimensions.height})).reduce((function(t,e){return t+e}),0)}},{key:"getWidthFromPosition",value:function(t){return this.getFromPosition(t).map((function(t){return t.options.dimensions.width})).reduce((function(t,e){return t+e}),0)}},{key:"allPlugins",value:function(){return Array.from(this.plugins.values())}}]),t}(),zD=[function(t){return{name:"minute",allowedDomainType:["day","hour"],rowsCount:function(){return 10},columnsCount:function(){return 6},mapping:function(e,n){return t.intervals("minute",e,t.date(n)).map((function(t,e){return{t:t,x:Math.floor(e/10),y:e%10}}))},extractUnit:function(e){return t.date(e).startOf("minute").valueOf()}}},function(t,e){var n=e.domain;return{name:"hour",allowedDomainType:["month","week","day"],rowsCount:function(){return 6},columnsCount:function(e){switch(n.type){case"week":return 28;case"month":return 4*(n.dynamicDimension?t.date(e).daysInMonth():31);default:return 4}},mapping:function(e,r){return t.intervals("hour",e,t.date(r)).map((function(e){var r=t.date(e),i=r.hour(),o=r.date(),a=Math.floor(i/6);return"month"===n.type&&(a+=4*(o-1)),"week"===n.type&&(a+=4*+r.format("d")),{t:e,x:a,y:Math.floor(i%6)}}))},extractUnit:function(e){return t.date(e).startOf("hour").valueOf()}}},function(t,e){var n=e.domain,r=e.verticalOrientation;return{name:"day",allowedDomainType:["year","month","week"],rowsCount:function(){return"week"===n.type?1:7},columnsCount:function(e){switch(n.type){case"month":return Math.ceil(n.dynamicDimension&&!r?t.getMonthWeekNumber(t.date(e).endOf("month")):6);case"year":return Math.ceil(n.dynamicDimension?t.date(e).endOf("year").dayOfYear()/7:54);default:return 7}},mapping:function(e,r){var i=0,o=-1;return t.intervals("day",e,t.date(r)).map((function(e){var r=t.date(e);switch(n.type){case"month":o=t.getMonthWeekNumber(e)-1;break;case"year":i!==r.week()&&(i=r.week(),o+=1);break;case"week":o=r.weekday()}return{t:e,x:o,y:"week"===n.type?0:r.weekday()}}))},extractUnit:function(e){return t.date(e).startOf("day").valueOf()}}},function(t,e){var n=e.domain,r=e.verticalOrientation;return{name:"xDay",allowedDomainType:["year","month","week"],rowsCount:function(e){switch(n.type){case"month":return Math.ceil(n.dynamicDimension&&!r?t.getMonthWeekNumber(t.date(e).endOf("month")):6);case"year":return Math.ceil(n.dynamicDimension?t.date(e).endOf("year").dayOfYear()/7:54);default:return 7}},columnsCount:function(){return"week"===n.type?1:7},mapping:function(e,r){return t.intervals("day",e,t.date(r)).map((function(e){var r=t.date(e),i=r.endOf("year").week(),o=0;switch(n.type){case"month":o=t.getMonthWeekNumber(e)-1;break;case"year":1===i&&r.week()===i&&(o=r.subtract(1,"week").week()+1),o=r.week()-1;break;case"week":o=r.weekday()}return{t:e,y:o,x:"week"===n.type?0:r.weekday()}}))},extractUnit:function(e){return t.date(e).startOf("day").valueOf()}}},function(t){return{name:"ghDay",allowedDomainType:["month"],rowsCount:function(){return 7},columnsCount:function(e){return t.getWeeksCountInMonth(e)},mapping:function(e,n){var r=t.getFirstWeekOfMonth(e),i=t.getFirstWeekOfMonth(n),o=-1,a=r.weekday();return t.intervals("day",r,i).map((function(e){var n=t.date(e).weekday();return n===a&&(o+=1),{t:e,x:o,y:n}}))},extractUnit:function(e){return t.date(e).startOf("day").valueOf()}}},function(t,e){var n=e.domain;return{name:"week",allowedDomainType:["year","month"],rowsCount:function(){return 1},columnsCount:function(e){switch(n.type){case"year":return n.dynamicDimension?t.date(e).endOf("year").isoWeeksInYear():53;case"month":return n.dynamicDimension?t.getWeeksCountInMonth(e):5;default:return 1}},mapping:function(e,n){var r=t.getFirstWeekOfMonth(e),i=t.getFirstWeekOfMonth(n);return t.intervals("week",r,i).map((function(t,e){return{t:t,x:e,y:0}}))},extractUnit:function(e){return t.date(e).startOf("week").valueOf()}}},function(t){return{name:"month",allowedDomainType:["year"],rowsCount:function(){return 1},columnsCount:function(){return 12},mapping:function(e,n){return t.intervals("month",e,t.date(n)).map((function(e){return{t:e,x:t.date(e).month(),y:0}}))},extractUnit:function(e){return t.date(e).startOf("month").valueOf()}}},function(t){return{name:"year",allowedDomainType:[],rowsCount:function(){return 1},columnsCount:function(){return 1},mapping:function(e,n){return t.intervals("year",e,t.date(n)).map((function(t,e){return{t:t,x:e,y:0}}))},extractUnit:function(e){return t.date(e).startOf("year").valueOf()}}}],HD=function(){function t(e,n){en(this,t),this.settings=new Map,this.dateHelper=e,this.options=n,this.initiated=!1}return rn(t,[{key:"get",value:function(t){return this.settings.get(t)}},{key:"has",value:function(t){return this.settings.has(t)}},{key:"init",value:function(){this.initiated||(this.initiated=!0,this.add(zD))}},{key:"add",value:function(t){var e=this;this.init();var n=[];yv(t).forEach((function(t){var r=t(e.dateHelper,e.options.options);e.settings.set(r.name,r),r.hasOwnProperty("parent")&&n.push(r.name)})),n.forEach((function(t){var n=e.settings.get(e.settings.get(t).parent);n&&e.settings.set(t,Object.assign(Object.assign({},n),e.settings.get(t)))}))}}]),t}(),YD=function(){function t(){en(this,t),this.options=new p_,this.dateHelper=new PD,this.templateCollection=new HD(this.dateHelper,this.options),this.dataFetcher=new BM(this),this.navigator=new km(this),this.populator=new XO(this),this.calendarPainter=new gb(this),this.eventEmitter=new pv,this.pluginManager=new FD(this)}return rn(t,[{key:"createDomainCollection",value:function(t,e){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];return new Tw(this.dateHelper,this.options.options.domain.type,t,e,n)}},{key:"paint",value:function(t,e){return fv(this,void 0,void 0,Xe().mark((function n(){return Xe().wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return this.options.init(t),n.next=3,this.dateHelper.setup(this.options);case 3:this.templateCollection.init(),n.prev=4,WD(this.templateCollection,this.options.options),n.next=11;break;case 8:return n.prev=8,n.t0=n.catch(4),n.abrupt("return",Promise.reject(n.t0));case 11:return e&&this.pluginManager.add(yv(e)),this.calendarPainter.setup(),this.domainCollection=new Tw(this.dateHelper),this.navigator.loadNewDomains(this.createDomainCollection(this.options.options.date.start,this.options.options.range)),n.abrupt("return",Promise.allSettled([this.calendarPainter.paint(),this.fill()]));case 16:case"end":return n.stop()}}),n,this,[[4,8]])})))}},{key:"addTemplates",value:function(t){this.templateCollection.add(t)}},{key:"next",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=this.navigator.loadNewDomains(this.createDomainCollection(this.domainCollection.max,t+1).slice(t),vm.SCROLL_FORWARD);return Promise.allSettled([this.calendarPainter.paint(e),this.fill()])}},{key:"previous",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1,e=this.navigator.loadNewDomains(this.createDomainCollection(this.domainCollection.min,-t),vm.SCROLL_BACKWARD);return Promise.allSettled([this.calendarPainter.paint(e),this.fill()])}},{key:"jumpTo",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return Promise.allSettled([this.calendarPainter.paint(this.navigator.jumpTo(t,e)),this.fill()])}},{key:"fill",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.options.options.data.source,n=this.options.options,r=this.templateCollection,i=this.dateHelper.intervals(n.domain.type,this.domainCollection.max,2)[1],o=this.dataFetcher.getDatas(e,this.domainCollection.min,i);return new Promise((function(e,i){o.then((function(i){t.domainCollection.fill(i,n.data,r.get(n.subDomain.type).extractUnit),t.populator.populate(),e(null)}),(function(t){i(t)}))}))}},{key:"on",value:function(t,e){this.eventEmitter.on(t,e)}},{key:"dimensions",value:function(){return this.calendarPainter.dimensions}},{key:"destroy",value:function(){return this.calendarPainter.destroy()}},{key:"extendDayjs",value:function(t){return this.dateHelper.extend(t)}}]),t}();YD.VERSION="4.2.4";export{YD as default};//# sourceMappingURL=cal-heatmap.min.esm.js.map