|
*/var It=function(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t};function At(t,e){return t(e={exports:{}},e.exports),e.exports}var Nt=At((function(t){function e(t){return(e="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})(t)}function i(n){return"function"==typeof Symbol&&"symbol"===e(Symbol.iterator)?t.exports=i=function(t){return e(t)}:t.exports=i=function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":e(t)},i(n)}t.exports=i}));var Rt=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")};function jt(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}var Ft=function(t,e,i){return e&&jt(t.prototype,e),i&&jt(t,i),t};var Ht=function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t};var Gt=function(t,e){return!e||"object"!==Nt(e)&&"function"!=typeof e?Ht(t):e},Wt=At((function(t){function e(i){return t.exports=e=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)},e(i)}t.exports=e})),zt=At((function(t){function e(i,n){return t.exports=e=Object.setPrototypeOf||function(t,e){return t.__proto__=e,t},e(i,n)}t.exports=e}));for(var Ut=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&zt(t,e)},Vt=[],Bt=0;Bt<256;Bt++)Vt[Bt]=(Bt+256).toString(16).substr(1);for(var Xt=function(){if("undefined"!=typeof crypto&&crypto.getRandomValues){var t=new Uint8Array(16);return function(){return crypto.getRandomValues(t),t}}var e=new Array(16);return function(){for(var t,i=0;i<16;i++)0==(3&i)&&(t=4294967296*Math.random()),e[i]=t>>>((3&i)<<3)&255;return e}}(),qt=[],Zt=0;Zt<256;Zt++)qt[Zt]=(Zt+256).toString(16).substr(1);var $t=Xt();$t[0],$t[1],$t[2],$t[3],$t[4],$t[5],$t[6],$t[7];function Jt(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1?arguments[1]:void 0,i=arguments.length>2?arguments[2]:void 0,n=e&&i||0;"string"==typeof t&&(e="binary"===t?new Array(16):void 0,t={});var s=t.random||(t.rng||Xt)();if(s[6]=15&s[6]|64,s[8]=63&s[8]|128,e)for(var r=0;r<16;r++)e[n+r]=s[r];return e||function(t,e){var i=e||0,n=Vt;return n[t[i++]]+n[t[i++]]+n[t[i++]]+n[t[i++]]+"-"+n[t[i++]]+n[t[i++]]+"-"+n[t[i++]]+n[t[i++]]+"-"+n[t[i++]]+n[t[i++]]+"-"+n[t[i++]]+n[t[i++]]+n[t[i++]]+n[t[i++]]+n[t[i++]]+n[t[i++]]}(s)}function Kt(t){return(Kt="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})(t)}"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function Qt(){throw new Error("Dynamic requires are not currently supported by rollup-plugin-commonjs")}for(var te=function(t,e){return t(e={exports:{}},e.exports),e.exports}((function(t,e){t.exports=function(){var e,i;function n(){return e.apply(null,arguments)}function s(t){return t instanceof Array||"[object Array]"===Object.prototype.toString.call(t)}function r(t){return null!=t&&"[object Object]"===Object.prototype.toString.call(t)}function o(t){return void 0===t}function a(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)}function l(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function h(t,e){var i,n=[];for(i=0;i<t.length;++i)n.push(e(t[i],i));return n}function u(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function d(t,e){for(var i in e)u(e,i)&&(t[i]=e[i]);return u(e,"toString")&&(t.toString=e.toString),u(e,"valueOf")&&(t.valueOf=e.valueOf),t}function c(t,e,i,n){return Le(t,e,i,n,!0).utc()}function f(t){return null==t._pf&&(t._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}),t._pf}function m(t){if(null==t._isValid){var e=f(t),n=i.call(e.parsedDateParts,(function(t){return null!=t})),s=!isNaN(t._d.getTime())&&e.overflow<0&&!e.empty&&!e.invalidMonth&&!e.invalidWeekday&&!e.weekdayMismatch&&!e.nullInput&&!e.invalidFormat&&!e.userInvalidated&&(!e.meridiem||e.meridiem&&n);if(t._strict&&(s=s&&0===e.charsLeftOver&&0===e.unusedTokens.length&&void 0===e.bigHour),null!=Object.isFrozen&&Object.isFrozen(t))return s;t._isValid=s}return t._isValid}function p(t){var e=c(NaN);return null!=t?d(f(e),t):f(e).userInvalidated=!0,e}i=Array.prototype.some?Array.prototype.some:function(t){for(var e=Object(this),i=e.length>>>0,n=0;n<i;n++)if(n in e&&t.call(this,e[n],n,e))return!0;return!1};var g=n.momentProperties=[];function v(t,e){var i,n,s;if(o(e._isAMomentObject)||(t._isAMomentObject=e._isAMomentObject),o(e._i)||(t._i=e._i),o(e._f)||(t._f=e._f),o(e._l)||(t._l=e._l),o(e._strict)||(t._strict=e._strict),o(e._tzm)||(t._tzm=e._tzm),o(e._isUTC)||(t._isUTC=e._isUTC),o(e._offset)||(t._offset=e._offset),o(e._pf)||(t._pf=f(e)),o(e._locale)||(t._locale=e._locale),g.length>0)for(i=0;i<g.length;i++)o(s=e[n=g[i]])||(t[n]=s);return t}var y=!1;function _(t){v(this,t),this._d=new Date(null!=t._d?t._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===y&&(y=!0,n.updateOffset(this),y=!1)}function b(t){return t instanceof _||null!=t&&null!=t._isAMomentObject}function w(t){return t<0?Math.ceil(t)||0:Math.floor(t)}function k(t){var e=+t,i=0;return 0!==e&&isFinite(e)&&(i=w(e)),i}function D(t,e,i){var n,s=Math.min(t.length,e.length),r=Math.abs(t.length-e.length),o=0;for(n=0;n<s;n++)(i&&t[n]!==e[n]||!i&&k(t[n])!==k(e[n]))&&o++;return o+r}function S(t){!1===n.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function x(t,e){var i=!0;return d((function(){if(null!=n.deprecationHandler&&n.deprecationHandler(null,t),i){for(var s,r=[],o=0;o<arguments.length;o++){if(s="","object"==typeof arguments[o]){for(var a in s+="\n["+o+"] ",arguments[0])s+=a+": "+arguments[0][a]+", ";s=s.slice(0,-2)}else s=arguments[o];r.push(s)}S(t+"\nArguments: "+Array.prototype.slice.call(r).join("")+"\n"+(new Error).stack),i=!1}return e.apply(this,arguments)}),e)}var M,T={};function O(t,e){null!=n.deprecationHandler&&n.deprecationHandler(t,e),T[t]||(S(e),T[t]=!0)}function C(t){return t instanceof Function||"[object Function]"===Object.prototype.toString.call(t)}function Y(t,e){var i,n=d({},t);for(i in e)u(e,i)&&(r(t[i])&&r(e[i])?(n[i]={},d(n[i],t[i]),d(n[i],e[i])):null!=e[i]?n[i]=e[i]:delete n[i]);for(i in t)u(t,i)&&!u(e,i)&&r(t[i])&&(n[i]=d({},n[i]));return n}function P(t){null!=t&&this.set(t)}n.suppressDeprecationWarnings=!1,n.deprecationHandler=null,M=Object.keys?Object.keys:function(t){var e,i=[];for(e in t)u(t,e)&&i.push(e);return i};var E={};function L(t,e){var i=t.toLowerCase();E[i]=E[i+"s"]=E[e]=t}function I(t){return"string"==typeof t?E[t]||E[t.toLowerCase()]:void 0}function A(t){var e,i,n={};for(i in t)u(t,i)&&(e=I(i))&&(n[e]=t[i]);return n}var N={};function R(t,e){N[t]=e}function j(t,e,i){var n=""+Math.abs(t),s=e-n.length;return(t>=0?i?"+":"":"-")+Math.pow(10,Math.max(0,s)).toString().substr(1)+n}var F=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,H=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,G={},W={};function z(t,e,i,n){var s=n;"string"==typeof n&&(s=function(){return this[n]()}),t&&(W[t]=s),e&&(W[e[0]]=function(){return j(s.apply(this,arguments),e[1],e[2])}),i&&(W[i]=function(){return this.localeData().ordinal(s.apply(this,arguments),t)})}function U(t,e){return t.isValid()?(e=V(e,t.localeData()),G[e]=G[e]||function(t){var e,i,n,s=t.match(F);for(e=0,i=s.length;e<i;e++)W[s[e]]?s[e]=W[s[e]]:s[e]=(n=s[e]).match(/\[[\s\S]/)?n.replace(/^\[|\]$/g,""):n.replace(/\\/g,"");return function(e){var n,r="";for(n=0;n<i;n++)r+=C(s[n])?s[n].call(e,t):s[n];return r}}(e),G[e](t)):t.localeData().invalidDate()}function V(t,e){var i=5;function n(t){return e.longDateFormat(t)||t}for(H.lastIndex=0;i>=0&&H.test(t);)t=t.replace(H,n),H.lastIndex=0,i-=1;return t}var B=/\d/,X=/\d\d/,q=/\d{3}/,Z=/\d{4}/,$=/[+-]?\d{6}/,J=/\d\d?/,K=/\d\d\d\d?/,Q=/\d\d\d\d\d\d?/,tt=/\d{1,3}/,et=/\d{1,4}/,it=/[+-]?\d{1,6}/,nt=/\d+/,st=/[+-]?\d+/,rt=/Z|[+-]\d\d:?\d\d/gi,ot=/Z|[+-]\d\d(?::?\d\d)?/gi,at=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,lt={};function ht(t,e,i){lt[t]=C(e)?e:function(t,n){return t&&i?i:e}}function ut(t,e){return u(lt,t)?lt[t](e._strict,e._locale):new RegExp(dt(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(t,e,i,n,s){return e||i||n||s}))))}function dt(t){return t.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var ct={};function ft(t,e){var i,n=e;for("string"==typeof t&&(t=[t]),a(e)&&(n=function(t,i){i[e]=k(t)}),i=0;i<t.length;i++)ct[t[i]]=n}function mt(t,e){ft(t,(function(t,i,n,s){n._w=n._w||{},e(t,n._w,n,s)}))}function pt(t,e,i){null!=e&&u(ct,t)&&ct[t](e,i._a,i,t)}var gt=0,vt=1,yt=2,_t=3,bt=4,wt=5,kt=6,Dt=7,St=8;function xt(t){return Mt(t)?366:365}function Mt(t){return t%4==0&&t%100!=0||t%400==0}z("Y",0,0,(function(){var t=this.year();return t<=9999?""+t:"+"+t})),z(0,["YY",2],0,(function(){return this.year()%100})),z(0,["YYYY",4],0,"year"),z(0,["YYYYY",5],0,"year"),z(0,["YYYYYY",6,!0],0,"year"),L("year","y"),R("year",1),ht("Y",st),ht("YY",J,X),ht("YYYY",et,Z),ht("YYYYY",it,$),ht("YYYYYY",it,$),ft(["YYYYY","YYYYYY"],gt),ft("YYYY",(function(t,e){e[gt]=2===t.length?n.parseTwoDigitYear(t):k(t)})),ft("YY",(function(t,e){e[gt]=n.parseTwoDigitYear(t)})),ft("Y",(function(t,e){e[gt]=parseInt(t,10)})),n.parseTwoDigitYear=function(t){return k(t)+(k(t)>68?1900:2e3)};var Tt,Ot=Ct("FullYear",!0);function Ct(t,e){return function(i){return null!=i?(Pt(this,t,i),n.updateOffset(this,e),this):Yt(this,t)}}function Yt(t,e){return t.isValid()?t._d["get"+(t._isUTC?"UTC":"")+e]():NaN}function Pt(t,e,i){t.isValid()&&!isNaN(i)&&("FullYear"===e&&Mt(t.year())&&1===t.month()&&29===t.date()?t._d["set"+(t._isUTC?"UTC":"")+e](i,t.month(),Et(i,t.month())):t._d["set"+(t._isUTC?"UTC":"")+e](i))}function Et(t,e){if(isNaN(t)||isNaN(e))return NaN;var i,n=(e%(i=12)+i)%i;return t+=(e-n)/12,1===n?Mt(t)?29:28:31-n%7%2}Tt=Array.prototype.indexOf?Array.prototype.indexOf:function(t){var e;for(e=0;e<this.length;++e)if(this[e]===t)return e;return-1},z("M",["MM",2],"Mo",(function(){return this.month()+1})),z("MMM",0,0,(function(t){return this.localeData().monthsShort(this,t)})),z("MMMM",0,0,(function(t){return this.localeData().months(this,t)})),L("month","M"),R("month",8),ht("M",J),ht("MM",J,X),ht("MMM",(function(t,e){return e.monthsShortRegex(t)})),ht("MMMM",(function(t,e){return e.monthsRegex(t)})),ft(["M","MM"],(function(t,e){e[vt]=k(t)-1})),ft(["MMM","MMMM"],(function(t,e,i,n){var s=i._locale.monthsParse(t,n,i._strict);null!=s?e[vt]=s:f(i).invalidMonth=t}));var Lt=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,It="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),At="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");function Nt(t,e,i){var n,s,r,o=t.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],n=0;n<12;++n)r=c([2e3,n]),this._shortMonthsParse[n]=this.monthsShort(r,"").toLocaleLowerCase(),this._longMonthsParse[n]=this.months(r,"").toLocaleLowerCase();return i?"MMM"===e?-1!==(s=Tt.call(this._shortMonthsParse,o))?s:null:-1!==(s=Tt.call(this._longMonthsParse,o))?s:null:"MMM"===e?-1!==(s=Tt.call(this._shortMonthsParse,o))?s:-1!==(s=Tt.call(this._longMonthsParse,o))?s:null:-1!==(s=Tt.call(this._longMonthsParse,o))?s:-1!==(s=Tt.call(this._shortMonthsParse,o))?s:null}function Rt(t,e){var i;if(!t.isValid())return t;if("string"==typeof e)if(/^\d+$/.test(e))e=k(e);else if(!a(e=t.localeData().monthsParse(e)))return t;return i=Math.min(t.date(),Et(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,i),t}function jt(t){return null!=t?(Rt(this,t),n.updateOffset(this,!0),this):Yt(this,"Month")}var Ft=at,Ht=at;function Gt(){function t(t,e){return e.length-t.length}var e,i,n=[],s=[],r=[];for(e=0;e<12;e++)i=c([2e3,e]),n.push(this.monthsShort(i,"")),s.push(this.months(i,"")),r.push(this.months(i,"")),r.push(this.monthsShort(i,""));for(n.sort(t),s.sort(t),r.sort(t),e=0;e<12;e++)n[e]=dt(n[e]),s[e]=dt(s[e]);for(e=0;e<24;e++)r[e]=dt(r[e]);this._monthsRegex=new RegExp("^("+r.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+n.join("|")+")","i")}function Wt(t,e,i,n,s,r,o){var a;return t<100&&t>=0?(a=new Date(t+400,e,i,n,s,r,o),isFinite(a.getFullYear())&&a.setFullYear(t)):a=new Date(t,e,i,n,s,r,o),a}function zt(t){var e;if(t<100&&t>=0){var i=Array.prototype.slice.call(arguments);i[0]=t+400,e=new Date(Date.UTC.apply(null,i)),isFinite(e.getUTCFullYear())&&e.setUTCFullYear(t)}else e=new Date(Date.UTC.apply(null,arguments));return e}function Ut(t,e,i){var n=7+e-i;return-(7+zt(t,0,n).getUTCDay()-e)%7+n-1}function Vt(t,e,i,n,s){var r,o,a=1+7*(e-1)+(7+i-n)%7+Ut(t,n,s);return a<=0?o=xt(r=t-1)+a:a>xt(t)?(r=t+1,o=a-xt(t)):(r=t,o=a),{year:r,dayOfYear:o}}function Bt(t,e,i){var n,s,r=Ut(t.year(),e,i),o=Math.floor((t.dayOfYear()-r-1)/7)+1;return o<1?n=o+Xt(s=t.year()-1,e,i):o>Xt(t.year(),e,i)?(n=o-Xt(t.year(),e,i),s=t.year()+1):(s=t.year(),n=o),{week:n,year:s}}function Xt(t,e,i){var n=Ut(t,e,i),s=Ut(t+1,e,i);return(xt(t)-n+s)/7}function qt(t,e){return t.slice(e,7).concat(t.slice(0,e))}z("w",["ww",2],"wo","week"),z("W",["WW",2],"Wo","isoWeek"),L("week","w"),L("isoWeek","W"),R("week",5),R("isoWeek",5),ht("w",J),ht("ww",J,X),ht("W",J),ht("WW",J,X),mt(["w","ww","W","WW"],(function(t,e,i,n){e[n.substr(0,1)]=k(t)})),z("d",0,"do","day"),z("dd",0,0,(function(t){return this.localeData().weekdaysMin(this,t)})),z("ddd",0,0,(function(t){return this.localeData().weekdaysShort(this,t)})),z("dddd",0,0,(function(t){return this.localeData().weekdays(this,t)})),z("e",0,0,"weekday"),z("E",0,0,"isoWeekday"),L("day","d"),L("weekday","e"),L("isoWeekday","E"),R("day",11),R("weekday",11),R("isoWeekday",11),ht("d",J),ht("e",J),ht("E",J),ht("dd",(function(t,e){return e.weekdaysMinRegex(t)})),ht("ddd",(function(t,e){return e.weekdaysShortRegex(t)})),ht("dddd",(function(t,e){return e.weekdaysRegex(t)})),mt(["dd","ddd","dddd"],(function(t,e,i,n){var s=i._locale.weekdaysParse(t,n,i._strict);null!=s?e.d=s:f(i).invalidWeekday=t})),mt(["d","e","E"],(function(t,e,i,n){e[n]=k(t)}));var Zt="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),$t="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Jt="Su_Mo_Tu_We_Th_Fr_Sa".split("_");function Kt(t,e,i){var n,s,r,o=t.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],n=0;n<7;++n)r=c([2e3,1]).day(n),this._minWeekdaysParse[n]=this.weekdaysMin(r,"").toLocaleLowerCase(),this._shortWeekdaysParse[n]=this.weekdaysShort(r,"").toLocaleLowerCase(),this._weekdaysParse[n]=this.weekdays(r,"").toLocaleLowerCase();return i?"dddd"===e?-1!==(s=Tt.call(this._weekdaysParse,o))?s:null:"ddd"===e?-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:null:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:null:"dddd"===e?-1!==(s=Tt.call(this._weekdaysParse,o))?s:-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:null:"ddd"===e?-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:-1!==(s=Tt.call(this._weekdaysParse,o))?s:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:null:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:-1!==(s=Tt.call(this._weekdaysParse,o))?s:-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:null}var te=at,ee=at,ie=at;function ne(){function t(t,e){return e.length-t.length}var e,i,n,s,r,o=[],a=[],l=[],h=[];for(e=0;e<7;e++)i=c([2e3,1]).day(e),n=this.weekdaysMin(i,""),s=this.weekdaysShort(i,""),r=this.weekdays(i,""),o.push(n),a.push(s),l.push(r),h.push(n),h.push(s),h.push(r);for(o.sort(t),a.sort(t),l.sort(t),h.sort(t),e=0;e<7;e++)a[e]=dt(a[e]),l[e]=dt(l[e]),h[e]=dt(h[e]);this._weekdaysRegex=new RegExp("^("+h.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+a.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function se(){return this.hours()%12||12}function re(t,e){z(t,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)}))}function oe(t,e){return e._meridiemParse}z("H",["HH",2],0,"hour"),z("h",["hh",2],0,se),z("k",["kk",2],0,(function(){return this.hours()||24})),z("hmm",0,0,(function(){return""+se.apply(this)+j(this.minutes(),2)})),z("hmmss",0,0,(function(){return""+se.apply(this)+j(this.minutes(),2)+j(this.seconds(),2)})),z("Hmm",0,0,(function(){return""+this.hours()+j(this.minutes(),2)})),z("Hmmss",0,0,(function(){return""+this.hours()+j(this.minutes(),2)+j(this.seconds(),2)})),re("a",!0),re("A",!1),L("hour","h"),R("hour",13),ht("a",oe),ht("A",oe),ht("H",J),ht("h",J),ht("k",J),ht("HH",J,X),ht("hh",J,X),ht("kk",J,X),ht("hmm",K),ht("hmmss",Q),ht("Hmm",K),ht("Hmmss",Q),ft(["H","HH"],_t),ft(["k","kk"],(function(t,e,i){var n=k(t);e[_t]=24===n?0:n})),ft(["a","A"],(function(t,e,i){i._isPm=i._locale.isPM(t),i._meridiem=t})),ft(["h","hh"],(function(t,e,i){e[_t]=k(t),f(i).bigHour=!0})),ft("hmm",(function(t,e,i){var n=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n)),f(i).bigHour=!0})),ft("hmmss",(function(t,e,i){var n=t.length-4,s=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n,2)),e[wt]=k(t.substr(s)),f(i).bigHour=!0})),ft("Hmm",(function(t,e,i){var n=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n))})),ft("Hmmss",(function(t,e,i){var n=t.length-4,s=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n,2)),e[wt]=k(t.substr(s))}));var ae,le=Ct("Hours",!0),he={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{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"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:It,monthsShort:At,week:{dow:0,doy:6},weekdays:Zt,weekdaysMin:Jt,weekdaysShort:$t,meridiemParse:/[ap]\.?m?\.?/i},ue={},de={};function ce(t){return t?t.toLowerCase().replace("_","-"):t}function fe(e){var i=null;if(!ue[e]&&t&&t.exports)try{i=ae._abbr,Qt(),me(i)}catch(t){}return ue[e]}function me(t,e){var i;return t&&((i=o(e)?ge(t):pe(t,e))?ae=i:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+t+" not found. Did you forget to load it?")),ae._abbr}function pe(t,e){if(null!==e){var i,n=he;if(e.abbr=t,null!=ue[t])O("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),n=ue[t]._config;else if(null!=e.parentLocale)if(null!=ue[e.parentLocale])n=ue[e.parentLocale]._config;else{if(null==(i=fe(e.parentLocale)))return de[e.parentLocale]||(de[e.parentLocale]=[]),de[e.parentLocale].push({name:t,config:e}),null;n=i._config}return ue[t]=new P(Y(n,e)),de[t]&&de[t].forEach((function(t){pe(t.name,t.config)})),me(t),ue[t]}return delete ue[t],null}function ge(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return ae;if(!s(t)){if(e=fe(t))return e;t=[t]}return function(t){for(var e,i,n,s,r=0;r<t.length;){for(e=(s=ce(t[r]).split("-")).length,i=(i=ce(t[r+1]))?i.split("-"):null;e>0;){if(n=fe(s.slice(0,e).join("-")))return n;if(i&&i.length>=e&&D(s,i,!0)>=e-1)break;e--}r++}return ae}(t)}function ve(t){var e,i=t._a;return i&&-2===f(t).overflow&&(e=i[vt]<0||i[vt]>11?vt:i[yt]<1||i[yt]>Et(i[gt],i[vt])?yt:i[_t]<0||i[_t]>24||24===i[_t]&&(0!==i[bt]||0!==i[wt]||0!==i[kt])?_t:i[bt]<0||i[bt]>59?bt:i[wt]<0||i[wt]>59?wt:i[kt]<0||i[kt]>999?kt:-1,f(t)._overflowDayOfYear&&(e<gt||e>yt)&&(e=yt),f(t)._overflowWeeks&&-1===e&&(e=Dt),f(t)._overflowWeekday&&-1===e&&(e=St),f(t).overflow=e),t}function ye(t,e,i){return null!=t?t:null!=e?e:i}function _e(t){var e,i,s,r,o,a=[];if(!t._d){for(s=function(t){var e=new Date(n.now());return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}(t),t._w&&null==t._a[yt]&&null==t._a[vt]&&function(t){var e,i,n,s,r,o,a,l;if(null!=(e=t._w).GG||null!=e.W||null!=e.E)r=1,o=4,i=ye(e.GG,t._a[gt],Bt(Ie(),1,4).year),n=ye(e.W,1),((s=ye(e.E,1))<1||s>7)&&(l=!0);else{r=t._locale._week.dow,o=t._locale._week.doy;var h=Bt(Ie(),r,o);i=ye(e.gg,t._a[gt],h.year),n=ye(e.w,h.week),null!=e.d?((s=e.d)<0||s>6)&&(l=!0):null!=e.e?(s=e.e+r,(e.e<0||e.e>6)&&(l=!0)):s=r}n<1||n>Xt(i,r,o)?f(t)._overflowWeeks=!0:null!=l?f(t)._overflowWeekday=!0:(a=Vt(i,n,s,r,o),t._a[gt]=a.year,t._dayOfYear=a.dayOfYear)}(t),null!=t._dayOfYear&&(o=ye(t._a[gt],s[gt]),(t._dayOfYear>xt(o)||0===t._dayOfYear)&&(f(t)._overflowDayOfYear=!0),i=zt(o,0,t._dayOfYear),t._a[vt]=i.getUTCMonth(),t._a[yt]=i.getUTCDate()),e=0;e<3&&null==t._a[e];++e)t._a[e]=a[e]=s[e];for(;e<7;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[_t]&&0===t._a[bt]&&0===t._a[wt]&&0===t._a[kt]&&(t._nextDay=!0,t._a[_t]=0),t._d=(t._useUTC?zt:Wt).apply(null,a),r=t._useUTC?t._d.getUTCDay():t._d.getDay(),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[_t]=24),t._w&&void 0!==t._w.d&&t._w.d!==r&&(f(t).weekdayMismatch=!0)}}var be=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,we=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,ke=/Z|[+-]\d\d(?::?\d\d)?/,De=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],Se=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],xe=/^\/?Date\((\-?\d+)/i;function Me(t){var e,i,n,s,r,o,a=t._i,l=be.exec(a)||we.exec(a);if(l){for(f(t).iso=!0,e=0,i=De.length;e<i;e++)if(De[e][1].exec(l[1])){s=De[e][0],n=!1!==De[e][2];break}if(null==s)return void(t._isValid=!1);if(l[3]){for(e=0,i=Se.length;e<i;e++)if(Se[e][1].exec(l[3])){r=(l[2]||" ")+Se[e][0];break}if(null==r)return void(t._isValid=!1)}if(!n&&null!=r)return void(t._isValid=!1);if(l[4]){if(!ke.exec(l[4]))return void(t._isValid=!1);o="Z"}t._f=s+(r||"")+(o||""),Pe(t)}else t._isValid=!1}var Te=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/;function Oe(t){var e=parseInt(t,10);return e<=49?2e3+e:e<=999?1900+e:e}var Ce={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Ye(t){var e,i,n,s,r,o,a,l=Te.exec(t._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(l){var h=(e=l[4],i=l[3],n=l[2],s=l[5],r=l[6],o=l[7],a=[Oe(e),At.indexOf(i),parseInt(n,10),parseInt(s,10),parseInt(r,10)],o&&a.push(parseInt(o,10)),a);if(!function(t,e,i){return!t||$t.indexOf(t)===new Date(e[0],e[1],e[2]).getDay()||(f(i).weekdayMismatch=!0,i._isValid=!1,!1)}(l[1],h,t))return;t._a=h,t._tzm=function(t,e,i){if(t)return Ce[t];if(e)return 0;var n=parseInt(i,10),s=n%100;return(n-s)/100*60+s}(l[8],l[9],l[10]),t._d=zt.apply(null,t._a),t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),f(t).rfc2822=!0}else t._isValid=!1}function Pe(t){if(t._f!==n.ISO_8601)if(t._f!==n.RFC_2822){t._a=[],f(t).empty=!0;var e,i,s,r,o,a=""+t._i,l=a.length,h=0;for(s=V(t._f,t._locale).match(F)||[],e=0;e<s.length;e++)r=s[e],(i=(a.match(ut(r,t))||[])[0])&&((o=a.substr(0,a.indexOf(i))).length>0&&f(t).unusedInput.push(o),a=a.slice(a.indexOf(i)+i.length),h+=i.length),W[r]?(i?f(t).empty=!1:f(t).unusedTokens.push(r),pt(r,i,t)):t._strict&&!i&&f(t).unusedTokens.push(r);f(t).charsLeftOver=l-h,a.length>0&&f(t).unusedInput.push(a),t._a[_t]<=12&&!0===f(t).bigHour&&t._a[_t]>0&&(f(t).bigHour=void 0),f(t).parsedDateParts=t._a.slice(0),f(t).meridiem=t._meridiem,t._a[_t]=function(t,e,i){var n;return null==i?e:null!=t.meridiemHour?t.meridiemHour(e,i):null!=t.isPM?((n=t.isPM(i))&&e<12&&(e+=12),n||12!==e||(e=0),e):e}(t._locale,t._a[_t],t._meridiem),_e(t),ve(t)}else Ye(t);else Me(t)}function Ee(t){var e=t._i,i=t._f;return t._locale=t._locale||ge(t._l),null===e||void 0===i&&""===e?p({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),b(e)?new _(ve(e)):(l(e)?t._d=e:s(i)?function(t){var e,i,n,s,r;if(0===t._f.length)return f(t).invalidFormat=!0,void(t._d=new Date(NaN));for(s=0;s<t._f.length;s++)r=0,e=v({},t),null!=t._useUTC&&(e._useUTC=t._useUTC),e._f=t._f[s],Pe(e),m(e)&&(r+=f(e).charsLeftOver,r+=10*f(e).unusedTokens.length,f(e).score=r,(null==n||r<n)&&(n=r,i=e));d(t,i||e)}(t):i?Pe(t):function(t){var e=t._i;o(e)?t._d=new Date(n.now()):l(e)?t._d=new Date(e.valueOf()):"string"==typeof e?function(t){var e=xe.exec(t._i);null===e?(Me(t),!1===t._isValid&&(delete t._isValid,Ye(t),!1===t._isValid&&(delete t._isValid,n.createFromInputFallback(t)))):t._d=new Date(+e[1])}(t):s(e)?(t._a=h(e.slice(0),(function(t){return parseInt(t,10)})),_e(t)):r(e)?function(t){if(!t._d){var e=A(t._i);t._a=h([e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],(function(t){return t&&parseInt(t,10)})),_e(t)}}(t):a(e)?t._d=new Date(e):n.createFromInputFallback(t)}(t),m(t)||(t._d=null),t))}function Le(t,e,i,n,o){var a,l={};return!0!==i&&!1!==i||(n=i,i=void 0),(r(t)&&function(t){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(t).length;var e;for(e in t)if(t.hasOwnProperty(e))return!1;return!0}(t)||s(t)&&0===t.length)&&(t=void 0),l._isAMomentObject=!0,l._useUTC=l._isUTC=o,l._l=i,l._i=t,l._f=e,l._strict=n,(a=new _(ve(Ee(l))))._nextDay&&(a.add(1,"d"),a._nextDay=void 0),a}function Ie(t,e,i,n){return Le(t,e,i,n,!1)}n.createFromInputFallback=x("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))})),n.ISO_8601=function(){},n.RFC_2822=function(){};var Ae=x("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var t=Ie.apply(null,arguments);return this.isValid()&&t.isValid()?t<this?this:t:p()})),Ne=x("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var t=Ie.apply(null,arguments);return this.isValid()&&t.isValid()?t>this?this:t:p()}));function Re(t,e){var i,n;if(1===e.length&&s(e[0])&&(e=e[0]),!e.length)return Ie();for(i=e[0],n=1;n<e.length;++n)e[n].isValid()&&!e[n][t](i)||(i=e[n]);return i}var je=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Fe(t){var e=A(t),i=e.year||0,n=e.quarter||0,s=e.month||0,r=e.week||e.isoWeek||0,o=e.day||0,a=e.hour||0,l=e.minute||0,h=e.second||0,u=e.millisecond||0;this._isValid=function(t){for(var e in t)if(-1===Tt.call(je,e)||null!=t[e]&&isNaN(t[e]))return!1;for(var i=!1,n=0;n<je.length;++n)if(t[je[n]]){if(i)return!1;parseFloat(t[je[n]])!==k(t[je[n]])&&(i=!0)}return!0}(e),this._milliseconds=+u+1e3*h+6e4*l+1e3*a*60*60,this._days=+o+7*r,this._months=+s+3*n+12*i,this._data={},this._locale=ge(),this._bubble()}function He(t){return t instanceof Fe}function Ge(t){return t<0?-1*Math.round(-1*t):Math.round(t)}function We(t,e){z(t,0,0,(function(){var t=this.utcOffset(),i="+";return t<0&&(t=-t,i="-"),i+j(~~(t/60),2)+e+j(~~t%60,2)}))}We("Z",":"),We("ZZ",""),ht("Z",ot),ht("ZZ",ot),ft(["Z","ZZ"],(function(t,e,i){i._useUTC=!0,i._tzm=Ue(ot,t)}));var ze=/([\+\-]|\d\d)/gi;function Ue(t,e){var i=(e||"").match(t);if(null===i)return null;var n=((i[i.length-1]||[])+"").match(ze)||["-",0,0],s=60*n[1]+k(n[2]);return 0===s?0:"+"===n[0]?s:-s}function Ve(t,e){var i,s;return e._isUTC?(i=e.clone(),s=(b(t)||l(t)?t.valueOf():Ie(t).valueOf())-i.valueOf(),i._d.setTime(i._d.valueOf()+s),n.updateOffset(i,!1),i):Ie(t).local()}function Be(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Xe(){return!!this.isValid()&&this._isUTC&&0===this._offset}n.updateOffset=function(){};var qe=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,Ze=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function $e(t,e){var i,n,s,r,o,l,h=t,d=null;return He(t)?h={ms:t._milliseconds,d:t._days,M:t._months}:a(t)?(h={},e?h[e]=t:h.milliseconds=t):(d=qe.exec(t))?(i="-"===d[1]?-1:1,h={y:0,d:k(d[yt])*i,h:k(d[_t])*i,m:k(d[bt])*i,s:k(d[wt])*i,ms:k(Ge(1e3*d[kt]))*i}):(d=Ze.exec(t))?(i="-"===d[1]?-1:1,h={y:Je(d[2],i),M:Je(d[3],i),w:Je(d[4],i),d:Je(d[5],i),h:Je(d[6],i),m:Je(d[7],i),s:Je(d[8],i)}):null==h?h={}:"object"==typeof h&&("from"in h||"to"in h)&&(r=Ie(h.from),o=Ie(h.to),s=r.isValid()&&o.isValid()?(o=Ve(o,r),r.isBefore(o)?l=Ke(r,o):((l=Ke(o,r)).milliseconds=-l.milliseconds,l.months=-l.months),l):{milliseconds:0,months:0},(h={}).ms=s.milliseconds,h.M=s.months),n=new Fe(h),He(t)&&u(t,"_locale")&&(n._locale=t._locale),n}function Je(t,e){var i=t&&parseFloat(t.replace(",","."));return(isNaN(i)?0:i)*e}function Ke(t,e){var i={};return i.months=e.month()-t.month()+12*(e.year()-t.year()),t.clone().add(i.months,"M").isAfter(e)&&--i.months,i.milliseconds=+e-+t.clone().add(i.months,"M"),i}function Qe(t,e){return function(i,n){var s;return null===n||isNaN(+n)||(O(e,"moment()."+e+"(period, number) is deprecated. Please use moment()."+e+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),s=i,i=n,n=s),ti(this,$e(i="string"==typeof i?+i:i,n),t),this}}function ti(t,e,i,s){var r=e._milliseconds,o=Ge(e._days),a=Ge(e._months);t.isValid()&&(s=null==s||s,a&&Rt(t,Yt(t,"Month")+a*i),o&&Pt(t,"Date",Yt(t,"Date")+o*i),r&&t._d.setTime(t._d.valueOf()+r*i),s&&n.updateOffset(t,o||a))}$e.fn=Fe.prototype,$e.invalid=function(){return $e(NaN)};var ei=Qe(1,"add"),ii=Qe(-1,"subtract");function ni(t,e){var i=12*(e.year()-t.year())+(e.month()-t.month()),n=t.clone().add(i,"months");return-(i+(e-n<0?(e-n)/(n-t.clone().add(i-1,"months")):(e-n)/(t.clone().add(i+1,"months")-n)))||0}function si(t){var e;return void 0===t?this._locale._abbr:(null!=(e=ge(t))&&(this._locale=e),this)}n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",n.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var ri=x("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(t){return void 0===t?this.localeData():this.locale(t)}));function oi(){return this._locale}var ai=1e3,li=60*ai,hi=60*li,ui=3506328*hi;function di(t,e){return(t%e+e)%e}function ci(t,e,i){return t<100&&t>=0?new Date(t+400,e,i)-ui:new Date(t,e,i).valueOf()}function fi(t,e,i){return t<100&&t>=0?Date.UTC(t+400,e,i)-ui:Date.UTC(t,e,i)}function mi(t,e){z(0,[t,t.length],0,e)}function pi(t,e,i,n,s){var r;return null==t?Bt(this,n,s).year:(e>(r=Xt(t,n,s))&&(e=r),gi.call(this,t,e,i,n,s))}function gi(t,e,i,n,s){var r=Vt(t,e,i,n,s),o=zt(r.year,0,r.dayOfYear);return this.year(o.getUTCFullYear()),this.month(o.getUTCMonth()),this.date(o.getUTCDate()),this}z(0,["gg",2],0,(function(){return this.weekYear()%100})),z(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),mi("gggg","weekYear"),mi("ggggg","weekYear"),mi("GGGG","isoWeekYear"),mi("GGGGG","isoWeekYear"),L("weekYear","gg"),L("isoWeekYear","GG"),R("weekYear",1),R("isoWeekYear",1),ht("G",st),ht("g",st),ht("GG",J,X),ht("gg",J,X),ht("GGGG",et,Z),ht("gggg",et,Z),ht("GGGGG",it,$),ht("ggggg",it,$),mt(["gggg","ggggg","GGGG","GGGGG"],(function(t,e,i,n){e[n.substr(0,2)]=k(t)})),mt(["gg","GG"],(function(t,e,i,s){e[s]=n.parseTwoDigitYear(t)})),z("Q",0,"Qo","quarter"),L("quarter","Q"),R("quarter",7),ht("Q",B),ft("Q",(function(t,e){e[vt]=3*(k(t)-1)})),z("D",["DD",2],"Do","date"),L("date","D"),R("date",9),ht("D",J),ht("DD",J,X),ht("Do",(function(t,e){return t?e._dayOfMonthOrdinalParse||e._ordinalParse:e._dayOfMonthOrdinalParseLenient})),ft(["D","DD"],yt),ft("Do",(function(t,e){e[yt]=k(t.match(J)[0])}));var vi=Ct("Date",!0);z("DDD",["DDDD",3],"DDDo","dayOfYear"),L("dayOfYear","DDD"),R("dayOfYear",4),ht("DDD",tt),ht("DDDD",q),ft(["DDD","DDDD"],(function(t,e,i){i._dayOfYear=k(t)})),z("m",["mm",2],0,"minute"),L("minute","m"),R("minute",14),ht("m",J),ht("mm",J,X),ft(["m","mm"],bt);var yi=Ct("Minutes",!1);z("s",["ss",2],0,"second"),L("second","s"),R("second",15),ht("s",J),ht("ss",J,X),ft(["s","ss"],wt);var _i,bi=Ct("Seconds",!1);for(z("S",0,0,(function(){return~~(this.millisecond()/100)})),z(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),z(0,["SSS",3],0,"millisecond"),z(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),z(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),z(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),z(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),z(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),z(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),L("millisecond","ms"),R("millisecond",16),ht("S",tt,B),ht("SS",tt,X),ht("SSS",tt,q),_i="SSSS";_i.length<=9;_i+="S")ht(_i,nt);function wi(t,e){e[kt]=k(1e3*("0."+t))}for(_i="S";_i.length<=9;_i+="S")ft(_i,wi);var ki=Ct("Milliseconds",!1);z("z",0,0,"zoneAbbr"),z("zz",0,0,"zoneName");var Di=_.prototype;function Si(t){return t}Di.add=ei,Di.calendar=function(t,e){var i=t||Ie(),s=Ve(i,this).startOf("day"),r=n.calendarFormat(this,s)||"sameElse",o=e&&(C(e[r])?e[r].call(this,i):e[r]);return this.format(o||this.localeData().calendar(r,this,Ie(i)))},Di.clone=function(){return new _(this)},Di.diff=function(t,e,i){var n,s,r;if(!this.isValid())return NaN;if(!(n=Ve(t,this)).isValid())return NaN;switch(s=6e4*(n.utcOffset()-this.utcOffset()),e=I(e)){case"year":r=ni(this,n)/12;break;case"month":r=ni(this,n);break;case"quarter":r=ni(this,n)/3;break;case"second":r=(this-n)/1e3;break;case"minute":r=(this-n)/6e4;break;case"hour":r=(this-n)/36e5;break;case"day":r=(this-n-s)/864e5;break;case"week":r=(this-n-s)/6048e5;break;default:r=this-n}return i?r:w(r)},Di.endOf=function(t){var e;if(void 0===(t=I(t))||"millisecond"===t||!this.isValid())return this;var i=this._isUTC?fi:ci;switch(t){case"year":e=i(this.year()+1,0,1)-1;break;case"quarter":e=i(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":e=i(this.year(),this.month()+1,1)-1;break;case"week":e=i(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":e=i(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":e=i(this.year(),this.month(),this.date()+1)-1;break;case"hour":e=this._d.valueOf(),e+=hi-di(e+(this._isUTC?0:this.utcOffset()*li),hi)-1;break;case"minute":e=this._d.valueOf(),e+=li-di(e,li)-1;break;case"second":e=this._d.valueOf(),e+=ai-di(e,ai)-1}return this._d.setTime(e),n.updateOffset(this,!0),this},Di.format=function(t){t||(t=this.isUtc()?n.defaultFormatUtc:n.defaultFormat);var e=U(this,t);return this.localeData().postformat(e)},Di.from=function(t,e){return this.isValid()&&(b(t)&&t.isValid()||Ie(t).isValid())?$e({to:this,from:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()},Di.fromNow=function(t){return this.from(Ie(),t)},Di.to=function(t,e){return this.isValid()&&(b(t)&&t.isValid()||Ie(t).isValid())?$e({from:this,to:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()},Di.toNow=function(t){return this.to(Ie(),t)},Di.get=function(t){return C(this[t=I(t)])?this[t]():this},Di.invalidAt=function(){return f(this).overflow},Di.isAfter=function(t,e){var i=b(t)?t:Ie(t);return!(!this.isValid()||!i.isValid())&&("millisecond"===(e=I(e)||"millisecond")?this.valueOf()>i.valueOf():i.valueOf()<this.clone().startOf(e).valueOf())},Di.isBefore=function(t,e){var i=b(t)?t:Ie(t);return!(!this.isValid()||!i.isValid())&&("millisecond"===(e=I(e)||"millisecond")?this.valueOf()<i.valueOf():this.clone().endOf(e).valueOf()<i.valueOf())},Di.isBetween=function(t,e,i,n){var s=b(t)?t:Ie(t),r=b(e)?e:Ie(e);return!!(this.isValid()&&s.isValid()&&r.isValid())&&("("===(n=n||"()")[0]?this.isAfter(s,i):!this.isBefore(s,i))&&(")"===n[1]?this.isBefore(r,i):!this.isAfter(r,i))},Di.isSame=function(t,e){var i,n=b(t)?t:Ie(t);return!(!this.isValid()||!n.isValid())&&("millisecond"===(e=I(e)||"millisecond")?this.valueOf()===n.valueOf():(i=n.valueOf(),this.clone().startOf(e).valueOf()<=i&&i<=this.clone().endOf(e).valueOf()))},Di.isSameOrAfter=function(t,e){return this.isSame(t,e)||this.isAfter(t,e)},Di.isSameOrBefore=function(t,e){return this.isSame(t,e)||this.isBefore(t,e)},Di.isValid=function(){return m(this)},Di.lang=ri,Di.locale=si,Di.localeData=oi,Di.max=Ne,Di.min=Ae,Di.parsingFlags=function(){return d({},f(this))},Di.set=function(t,e){if("object"==typeof t)for(var i=function(t){var e=[];for(var i in t)e.push({unit:i,priority:N[i]});return e.sort((function(t,e){return t.priority-e.priority})),e}(t=A(t)),n=0;n<i.length;n++)this[i[n].unit](t[i[n].unit]);else if(C(this[t=I(t)]))return this[t](e);return this},Di.startOf=function(t){var e;if(void 0===(t=I(t))||"millisecond"===t||!this.isValid())return this;var i=this._isUTC?fi:ci;switch(t){case"year":e=i(this.year(),0,1);break;case"quarter":e=i(this.year(),this.month()-this.month()%3,1);break;case"month":e=i(this.year(),this.month(),1);break;case"week":e=i(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":e=i(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":e=i(this.year(),this.month(),this.date());break;case"hour":e=this._d.valueOf(),e-=di(e+(this._isUTC?0:this.utcOffset()*li),hi);break;case"minute":e=this._d.valueOf(),e-=di(e,li);break;case"second":e=this._d.valueOf(),e-=di(e,ai)}return this._d.setTime(e),n.updateOffset(this,!0),this},Di.subtract=ii,Di.toArray=function(){var t=this;return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second(),t.millisecond()]},Di.toObject=function(){var t=this;return{years:t.year(),months:t.month(),date:t.date(),hours:t.hours(),minutes:t.minutes(),seconds:t.seconds(),milliseconds:t.milliseconds()}},Di.toDate=function(){return new Date(this.valueOf())},Di.toISOString=function(t){if(!this.isValid())return null;var e=!0!==t,i=e?this.clone().utc():this;return i.year()<0||i.year()>9999?U(i,e?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):C(Date.prototype.toISOString)?e?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",U(i,"Z")):U(i,e?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},Di.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var t="moment",e="";this.isLocal()||(t=0===this.utcOffset()?"moment.utc":"moment.parseZone",e="Z");var i="["+t+'("]',n=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",s=e+'[")]';return this.format(i+n+"-MM-DD[T]HH:mm:ss.SSS"+s)},Di.toJSON=function(){return this.isValid()?this.toISOString():null},Di.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},Di.unix=function(){return Math.floor(this.valueOf()/1e3)},Di.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},Di.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},Di.year=Ot,Di.isLeapYear=function(){return Mt(this.year())},Di.weekYear=function(t){return pi.call(this,t,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},Di.isoWeekYear=function(t){return pi.call(this,t,this.isoWeek(),this.isoWeekday(),1,4)},Di.quarter=Di.quarters=function(t){return null==t?Math.ceil((this.month()+1)/3):this.month(3*(t-1)+this.month()%3)},Di.month=jt,Di.daysInMonth=function(){return Et(this.year(),this.month())},Di.week=Di.weeks=function(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")},Di.isoWeek=Di.isoWeeks=function(t){var e=Bt(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")},Di.weeksInYear=function(){var t=this.localeData()._week;return Xt(this.year(),t.dow,t.doy)},Di.isoWeeksInYear=function(){return Xt(this.year(),1,4)},Di.date=vi,Di.day=Di.days=function(t){if(!this.isValid())return null!=t?this:NaN;var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=function(t,e){return"string"!=typeof t?t:isNaN(t)?"number"==typeof(t=e.weekdaysParse(t))?t:null:parseInt(t,10)}(t,this.localeData()),this.add(t-e,"d")):e},Di.weekday=function(t){if(!this.isValid())return null!=t?this:NaN;var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")},Di.isoWeekday=function(t){if(!this.isValid())return null!=t?this:NaN;if(null!=t){var e=function(t,e){return"string"==typeof t?e.weekdaysParse(t)%7||7:isNaN(t)?null:t}(t,this.localeData());return this.day(this.day()%7?e:e-7)}return this.day()||7},Di.dayOfYear=function(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")},Di.hour=Di.hours=le,Di.minute=Di.minutes=yi,Di.second=Di.seconds=bi,Di.millisecond=Di.milliseconds=ki,Di.utcOffset=function(t,e,i){var s,r=this._offset||0;if(!this.isValid())return null!=t?this:NaN;if(null!=t){if("string"==typeof t){if(null===(t=Ue(ot,t)))return this}else Math.abs(t)<16&&!i&&(t*=60);return!this._isUTC&&e&&(s=Be(this)),this._offset=t,this._isUTC=!0,null!=s&&this.add(s,"m"),r!==t&&(!e||this._changeInProgress?ti(this,$e(t-r,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?r:Be(this)},Di.utc=function(t){return this.utcOffset(0,t)},Di.local=function(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(Be(this),"m")),this},Di.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var t=Ue(rt,this._i);null!=t?this.utcOffset(t):this.utcOffset(0,!0)}return this},Di.hasAlignedHourOffset=function(t){return!!this.isValid()&&(t=t?Ie(t).utcOffset():0,(this.utcOffset()-t)%60==0)},Di.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},Di.isLocal=function(){return!!this.isValid()&&!this._isUTC},Di.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},Di.isUtc=Xe,Di.isUTC=Xe,Di.zoneAbbr=function(){return this._isUTC?"UTC":""},Di.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},Di.dates=x("dates accessor is deprecated. Use date instead.",vi),Di.months=x("months accessor is deprecated. Use month instead",jt),Di.years=x("years accessor is deprecated. Use year instead",Ot),Di.zone=x("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()})),Di.isDSTShifted=x("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!o(this._isDSTShifted))return this._isDSTShifted;var t={};if(v(t,this),(t=Ee(t))._a){var e=t._isUTC?c(t._a):Ie(t._a);this._isDSTShifted=this.isValid()&&D(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}));var xi=P.prototype;function Mi(t,e,i,n){var s=ge(),r=c().set(n,e);return s[i](r,t)}function Ti(t,e,i){if(a(t)&&(e=t,t=void 0),t=t||"",null!=e)return Mi(t,e,i,"month");var n,s=[];for(n=0;n<12;n++)s[n]=Mi(t,n,i,"month");return s}function Oi(t,e,i,n){"boolean"==typeof t?(a(e)&&(i=e,e=void 0),e=e||""):(i=e=t,t=!1,a(e)&&(i=e,e=void 0),e=e||"");var s,r=ge(),o=t?r._week.dow:0;if(null!=i)return Mi(e,(i+o)%7,n,"day");var l=[];for(s=0;s<7;s++)l[s]=Mi(e,(s+o)%7,n,"day");return l}xi.calendar=function(t,e,i){var n=this._calendar[t]||this._calendar.sameElse;return C(n)?n.call(e,i):n},xi.longDateFormat=function(t){var e=this._longDateFormat[t],i=this._longDateFormat[t.toUpperCase()];return e||!i?e:(this._longDateFormat[t]=i.replace(/MMMM|MM|DD|dddd/g,(function(t){return t.slice(1)})),this._longDateFormat[t])},xi.invalidDate=function(){return this._invalidDate},xi.ordinal=function(t){return this._ordinal.replace("%d",t)},xi.preparse=Si,xi.postformat=Si,xi.relativeTime=function(t,e,i,n){var s=this._relativeTime[i];return C(s)?s(t,e,i,n):s.replace(/%d/i,t)},xi.pastFuture=function(t,e){var i=this._relativeTime[t>0?"future":"past"];return C(i)?i(e):i.replace(/%s/i,e)},xi.set=function(t){var e,i;for(i in t)C(e=t[i])?this[i]=e:this["_"+i]=e;this._config=t,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},xi.months=function(t,e){return t?s(this._months)?this._months[t.month()]:this._months[(this._months.isFormat||Lt).test(e)?"format":"standalone"][t.month()]:s(this._months)?this._months:this._months.standalone},xi.monthsShort=function(t,e){return t?s(this._monthsShort)?this._monthsShort[t.month()]:this._monthsShort[Lt.test(e)?"format":"standalone"][t.month()]:s(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},xi.monthsParse=function(t,e,i){var n,s,r;if(this._monthsParseExact)return Nt.call(this,t,e,i);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),n=0;n<12;n++){if(s=c([2e3,n]),i&&!this._longMonthsParse[n]&&(this._longMonthsParse[n]=new RegExp("^"+this.months(s,"").replace(".","")+"$","i"),this._shortMonthsParse[n]=new RegExp("^"+this.monthsShort(s,"").replace(".","")+"$","i")),i||this._monthsParse[n]||(r="^"+this.months(s,"")+"|^"+this.monthsShort(s,""),this._monthsParse[n]=new RegExp(r.replace(".",""),"i")),i&&"MMMM"===e&&this._longMonthsParse[n].test(t))return n;if(i&&"MMM"===e&&this._shortMonthsParse[n].test(t))return n;if(!i&&this._monthsParse[n].test(t))return n}},xi.monthsRegex=function(t){return this._monthsParseExact?(u(this,"_monthsRegex")||Gt.call(this),t?this._monthsStrictRegex:this._monthsRegex):(u(this,"_monthsRegex")||(this._monthsRegex=Ht),this._monthsStrictRegex&&t?this._monthsStrictRegex:this._monthsRegex)},xi.monthsShortRegex=function(t){return this._monthsParseExact?(u(this,"_monthsRegex")||Gt.call(this),t?this._monthsShortStrictRegex:this._monthsShortRegex):(u(this,"_monthsShortRegex")||(this._monthsShortRegex=Ft),this._monthsShortStrictRegex&&t?this._monthsShortStrictRegex:this._monthsShortRegex)},xi.week=function(t){return Bt(t,this._week.dow,this._week.doy).week},xi.firstDayOfYear=function(){return this._week.doy},xi.firstDayOfWeek=function(){return this._week.dow},xi.weekdays=function(t,e){var i=s(this._weekdays)?this._weekdays:this._weekdays[t&&!0!==t&&this._weekdays.isFormat.test(e)?"format":"standalone"];return!0===t?qt(i,this._week.dow):t?i[t.day()]:i},xi.weekdaysMin=function(t){return!0===t?qt(this._weekdaysMin,this._week.dow):t?this._weekdaysMin[t.day()]:this._weekdaysMin},xi.weekdaysShort=function(t){return!0===t?qt(this._weekdaysShort,this._week.dow):t?this._weekdaysShort[t.day()]:this._weekdaysShort},xi.weekdaysParse=function(t,e,i){var n,s,r;if(this._weekdaysParseExact)return Kt.call(this,t,e,i);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),n=0;n<7;n++){if(s=c([2e3,1]).day(n),i&&!this._fullWeekdaysParse[n]&&(this._fullWeekdaysParse[n]=new RegExp("^"+this.weekdays(s,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[n]=new RegExp("^"+this.weekdaysShort(s,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[n]=new RegExp("^"+this.weekdaysMin(s,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[n]||(r="^"+this.weekdays(s,"")+"|^"+this.weekdaysShort(s,"")+"|^"+this.weekdaysMin(s,""),this._weekdaysParse[n]=new RegExp(r.replace(".",""),"i")),i&&"dddd"===e&&this._fullWeekdaysParse[n].test(t))return n;if(i&&"ddd"===e&&this._shortWeekdaysParse[n].test(t))return n;if(i&&"dd"===e&&this._minWeekdaysParse[n].test(t))return n;if(!i&&this._weekdaysParse[n].test(t))return n}},xi.weekdaysRegex=function(t){return this._weekdaysParseExact?(u(this,"_weekdaysRegex")||ne.call(this),t?this._weekdaysStrictRegex:this._weekdaysRegex):(u(this,"_weekdaysRegex")||(this._weekdaysRegex=te),this._weekdaysStrictRegex&&t?this._weekdaysStrictRegex:this._weekdaysRegex)},xi.weekdaysShortRegex=function(t){return this._weekdaysParseExact?(u(this,"_weekdaysRegex")||ne.call(this),t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(u(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=ee),this._weekdaysShortStrictRegex&&t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},xi.weekdaysMinRegex=function(t){return this._weekdaysParseExact?(u(this,"_weekdaysRegex")||ne.call(this),t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(u(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=ie),this._weekdaysMinStrictRegex&&t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},xi.isPM=function(t){return"p"===(t+"").toLowerCase().charAt(0)},xi.meridiem=function(t,e,i){return t>11?i?"pm":"PM":i?"am":"AM"},me("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10;return t+(1===k(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th")}}),n.lang=x("moment.lang is deprecated. Use moment.locale instead.",me),n.langData=x("moment.langData is deprecated. Use moment.localeData instead.",ge);var Ci=Math.abs;function Yi(t,e,i,n){var s=$e(e,i);return t._milliseconds+=n*s._milliseconds,t._days+=n*s._days,t._months+=n*s._months,t._bubble()}function Pi(t){return t<0?Math.floor(t):Math.ceil(t)}function Ei(t){return 4800*t/146097}function Li(t){return 146097*t/4800}function Ii(t){return function(){return this.as(t)}}var Ai=Ii("ms"),Ni=Ii("s"),Ri=Ii("m"),ji=Ii("h"),Fi=Ii("d"),Hi=Ii("w"),Gi=Ii("M"),Wi=Ii("Q"),zi=Ii("y");function Ui(t){return function(){return this.isValid()?this._data[t]:NaN}}var Vi=Ui("milliseconds"),Bi=Ui("seconds"),Xi=Ui("minutes"),qi=Ui("hours"),Zi=Ui("days"),$i=Ui("months"),Ji=Ui("years"),Ki=Math.round,Qi={ss:44,s:45,m:45,h:22,d:26,M:11};function tn(t,e,i,n,s){return s.relativeTime(e||1,!!i,t,n)}var en=Math.abs;function nn(t){return(t>0)-(t<0)||+t}function sn(){if(!this.isValid())return this.localeData().invalidDate();var t,e,i=en(this._milliseconds)/1e3,n=en(this._days),s=en(this._months);t=w(i/60),e=w(t/60),i%=60,t%=60;var r=w(s/12),o=s%=12,a=n,l=e,h=t,u=i?i.toFixed(3).replace(/\.?0+$/,""):"",d=this.asSeconds();if(!d)return"P0D";var c=d<0?"-":"",f=nn(this._months)!==nn(d)?"-":"",m=nn(this._days)!==nn(d)?"-":"",p=nn(this._milliseconds)!==nn(d)?"-":"";return c+"P"+(r?f+r+"Y":"")+(o?f+o+"M":"")+(a?m+a+"D":"")+(l||h||u?"T":"")+(l?p+l+"H":"")+(h?p+h+"M":"")+(u?p+u+"S":"")}var rn=Fe.prototype;return rn.isValid=function(){return this._isValid},rn.abs=function(){var t=this._data;return this._milliseconds=Ci(this._milliseconds),this._days=Ci(this._days),this._months=Ci(this._months),t.milliseconds=Ci(t.milliseconds),t.seconds=Ci(t.seconds),t.minutes=Ci(t.minutes),t.hours=Ci(t.hours),t.months=Ci(t.months),t.years=Ci(t.years),this},rn.add=function(t,e){return Yi(this,t,e,1)},rn.subtract=function(t,e){return Yi(this,t,e,-1)},rn.as=function(t){if(!this.isValid())return NaN;var e,i,n=this._milliseconds;if("month"===(t=I(t))||"quarter"===t||"year"===t)switch(e=this._days+n/864e5,i=this._months+Ei(e),t){case"month":return i;case"quarter":return i/3;case"year":return i/12}else switch(e=this._days+Math.round(Li(this._months)),t){case"week":return e/7+n/6048e5;case"day":return e+n/864e5;case"hour":return 24*e+n/36e5;case"minute":return 1440*e+n/6e4;case"second":return 86400*e+n/1e3;case"millisecond":return Math.floor(864e5*e)+n;default:throw new Error("Unknown unit "+t)}},rn.asMilliseconds=Ai,rn.asSeconds=Ni,rn.asMinutes=Ri,rn.asHours=ji,rn.asDays=Fi,rn.asWeeks=Hi,rn.asMonths=Gi,rn.asQuarters=Wi,rn.asYears=zi,rn.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*k(this._months/12):NaN},rn._bubble=function(){var t,e,i,n,s,r=this._milliseconds,o=this._days,a=this._months,l=this._data;return r>=0&&o>=0&&a>=0||r<=0&&o<=0&&a<=0||(r+=864e5*Pi(Li(a)+o),o=0,a=0),l.milliseconds=r%1e3,t=w(r/1e3),l.seconds=t%60,e=w(t/60),l.minutes=e%60,i=w(e/60),l.hours=i%24,o+=w(i/24),s=w(Ei(o)),a+=s,o-=Pi(Li(s)),n=w(a/12),a%=12,l.days=o,l.months=a,l.years=n,this},rn.clone=function(){return $e(this)},rn.get=function(t){return t=I(t),this.isValid()?this[t+"s"]():NaN},rn.milliseconds=Vi,rn.seconds=Bi,rn.minutes=Xi,rn.hours=qi,rn.days=Zi,rn.weeks=function(){return w(this.days()/7)},rn.months=$i,rn.years=Ji,rn.humanize=function(t){if(!this.isValid())return this.localeData().invalidDate();var e=this.localeData(),i=function(t,e,i){var n=$e(t).abs(),s=Ki(n.as("s")),r=Ki(n.as("m")),o=Ki(n.as("h")),a=Ki(n.as("d")),l=Ki(n.as("M")),h=Ki(n.as("y")),u=s<=Qi.ss&&["s",s]||s<Qi.s&&["ss",s]||r<=1&&["m"]||r<Qi.m&&["mm",r]||o<=1&&["h"]||o<Qi.h&&["hh",o]||a<=1&&["d"]||a<Qi.d&&["dd",a]||l<=1&&["M"]||l<Qi.M&&["MM",l]||h<=1&&["y"]||["yy",h];return u[2]=e,u[3]=+t>0,u[4]=i,tn.apply(null,u)}(this,!t,e);return t&&(i=e.pastFuture(+this,i)),e.postformat(i)},rn.toISOString=sn,rn.toString=sn,rn.toJSON=sn,rn.locale=si,rn.localeData=oi,rn.toIsoString=x("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",sn),rn.lang=ri,z("X",0,0,"unix"),z("x",0,0,"valueOf"),ht("x",st),ht("X",/[+-]?\d+(\.\d{1,3})?/),ft("X",(function(t,e,i){i._d=new Date(1e3*parseFloat(t,10))})),ft("x",(function(t,e,i){i._d=new Date(k(t))})),n.version="2.24.0",e=Ie,n.fn=Di,n.min=function(){return Re("isBefore",[].slice.call(arguments,0))},n.max=function(){return Re("isAfter",[].slice.call(arguments,0))},n.now=function(){return Date.now?Date.now():+new Date},n.utc=c,n.unix=function(t){return Ie(1e3*t)},n.months=function(t,e){return Ti(t,e,"months")},n.isDate=l,n.locale=me,n.invalid=p,n.duration=$e,n.isMoment=b,n.weekdays=function(t,e,i){return Oi(t,e,i,"weekdays")},n.parseZone=function(){return Ie.apply(null,arguments).parseZone()},n.localeData=ge,n.isDuration=He,n.monthsShort=function(t,e){return Ti(t,e,"monthsShort")},n.weekdaysMin=function(t,e,i){return Oi(t,e,i,"weekdaysMin")},n.defineLocale=pe,n.updateLocale=function(t,e){if(null!=e){var i,n,s=he;null!=(n=fe(t))&&(s=n._config),e=Y(s,e),(i=new P(e)).parentLocale=ue[t],ue[t]=i,me(t)}else null!=ue[t]&&(null!=ue[t].parentLocale?ue[t]=ue[t].parentLocale:null!=ue[t]&&delete ue[t]);return ue[t]},n.locales=function(){return M(ue)},n.weekdaysShort=function(t,e,i){return Oi(t,e,i,"weekdaysShort")},n.normalizeUnits=I,n.relativeTimeRounding=function(t){return void 0===t?Ki:"function"==typeof t&&(Ki=t,!0)},n.relativeTimeThreshold=function(t,e){return void 0!==Qi[t]&&(void 0===e?Qi[t]:(Qi[t]=e,"s"===t&&(Qi.ss=e-1),!0))},n.calendarFormat=function(t,e){var i=t.diff(e,"days",!0);return i<-6?"sameElse":i<-1?"lastWeek":i<0?"lastDay":i<1?"sameDay":i<2?"nextDay":i<7?"nextWeek":"sameElse"},n.prototype=Di,n.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},n}()})),ee=[],ie=0;ie<256;ie++)ee[ie]=(ie+256).toString(16).substr(1);for(var ne=function(){if("undefined"!=typeof crypto&&crypto.getRandomValues){var t=new Uint8Array(16);return function(){return crypto.getRandomValues(t),t}}var e=new Array(16);return function(){for(var t,i=0;i<16;i++)0==(3&i)&&(t=4294967296*Math.random()),e[i]=t>>>((3&i)<<3)&255;return e}}(),se=[],re=0;re<256;re++)se[re]=(re+256).toString(16).substr(1);var oe=ne(),ae=(oe[0],oe[1],oe[2],oe[3],oe[4],oe[5],oe[6],oe[7],/^\/?Date\((-?\d+)/i);function le(t){return t instanceof Number||"number"==typeof t}function he(t){return t instanceof String||"string"==typeof t}function ue(t){return te.isMoment(t)}function de(t,e){var i;if(void 0!==t){if(null===t)return null;if(!e)return t;if("string"!=typeof e&&!(e instanceof String))throw new Error("Type must be a string");switch(e){case"boolean":case"Boolean":return Boolean(t);case"number":case"Number":return he(t)&&!isNaN(Date.parse(t))?te(t).valueOf():Number(t.valueOf());case"string":case"String":return String(t);case"Date":if(le(t))return new Date(t);if(t instanceof Date)return new Date(t.valueOf());if(ue(t))return new Date(t.valueOf());if(he(t))return(i=ae.exec(t))?new Date(Number(i[1])):te(new Date(t)).toDate();throw new Error("Cannot convert object of type "+ce(t)+" to type Date");case"Moment":if(le(t))return te(t);if(t instanceof Date)return te(t.valueOf());if(ue(t))return te(t);if(he(t))return i=ae.exec(t),te(i?Number(i[1]):t);throw new Error("Cannot convert object of type "+ce(t)+" to type Date");case"ISODate":if(le(t))return new Date(t);if(t instanceof Date)return t.toISOString();if(ue(t))return t.toDate().toISOString();if(he(t))return(i=ae.exec(t))?new Date(Number(i[1])).toISOString():te(t).format();throw new Error("Cannot convert object of type "+ce(t)+" to type ISODate");case"ASPDate":if(le(t))return"/Date("+t+")/";if(t instanceof Date)return"/Date("+t.valueOf()+")/";if(he(t))return"/Date("+((i=ae.exec(t))?new Date(Number(i[1])).valueOf():new Date(t).valueOf())+")/";throw new Error("Cannot convert object of type "+ce(t)+" to type ASPDate");default:throw new Error("Unknown type ".concat(e))}}}function ce(t){var e=Kt(t);return"object"===e?null===t?"null":t instanceof Boolean?"Boolean":t instanceof Number?"Number":t instanceof String?"String":Array.isArray(t)?"Array":t instanceof Date?"Date":"Object":"number"===e?"Number":"boolean"===e?"Boolean":"string"===e?"String":void 0===e?"undefined":e}function fe(t){return"string"==typeof t||"number"==typeof t}var me=function(){function t(e){Rt(this,t),this._queue=[],this._timeout=null,this._extended=null,this.delay=null,this.max=1/0,this.setOptions(e)}return Ft(t,[{key:"setOptions",value:function(t){t&&void 0!==t.delay&&(this.delay=t.delay),t&&void 0!==t.max&&(this.max=t.max),this._flushIfNeeded()}},{key:"destroy",value:function(){if(this.flush(),this._extended){for(var t=this._extended.object,e=this._extended.methods,i=0;i<e.length;i++){var n=e[i];n.original?t[n.name]=n.original:delete t[n.name]}this._extended=null}}},{key:"replace",value:function(t,e){var i=this,n=t[e];if(!n)throw new Error("Method "+e+" undefined");t[e]=function(){for(var t=arguments.length,e=new Array(t),s=0;s<t;s++)e[s]=arguments[s];i.queue({args:e,fn:n,context:this})}}},{key:"queue",value:function(t){"function"==typeof t?this._queue.push({fn:t}):this._queue.push(t),this._flushIfNeeded()}},{key:"_flushIfNeeded",value:function(){var t=this;this._queue.length>this.max&&this.flush(),null!=this._timeout&&(clearTimeout(this._timeout),this._timeout=null),this.queue.length>0&&"number"==typeof this.delay&&(this._timeout=setTimeout((function(){t.flush()}),this.delay))}},{key:"flush",value:function(){this._queue.splice(0).forEach((function(t){t.fn.apply(t.context||t.fn,t.args||[])}))}}],[{key:"extend",value:function(e,i){var n=new t(i);if(void 0!==e.flush)throw new Error("Target object already has a property flush");e.flush=function(){n.flush()};var s=[{name:"flush",original:void 0}];if(i&&i.replace)for(var r=0;r<i.replace.length;r++){var o=i.replace[r];s.push({name:o,original:e[o]}),n.replace(e,o)}return n._extended={object:e,methods:s},n}}]),t}();var pe=function(t){if(Array.isArray(t)){for(var e=0,i=new Array(t.length);e<t.length;e++)i[e]=t[e];return i}};var ge=function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)};var ve=function(){throw new TypeError("Invalid attempt to spread non-iterable instance")};var ye=function(t){return pe(t)||ge(t)||ve()},_e=function(){function t(){Rt(this,t),this._subscribers={"*":[],add:[],remove:[],update:[]},this.subscribe=t.prototype.on,this.unsubscribe=t.prototype.off}return Ft(t,[{key:"_trigger",value:function(t,e,i){if("*"===t)throw new Error("Cannot trigger event *");for(var n=[].concat(ye(this._subscribers[t]),ye(this._subscribers["*"])),s=0,r=n.length;s<r;s++){var o=n[s];o.callback&&o.callback(t,e,null!=i?i:null)}}},{key:"on",value:function(t,e){this._subscribers[t].push({callback:e})}},{key:"off",value:function(t,e){this._subscribers[t]=this._subscribers[t].filter((function(t){return t.callback!==e}))}}]),t}();function be(t,e){var i=Object.keys(t);return Object.getOwnPropertySymbols&&i.push.apply(i,Object.getOwnPropertySymbols(t)),e&&(i=i.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i}var we=function(t){function e(t,i){var n;if(Rt(this,e),n=Gt(this,Wt(e).call(this)),t&&!Array.isArray(t)&&(i=t,t=[]),n._options=i||{},n._data=Object.create({}),n.length=0,n._idProp=n._options.fieldId||"id",n._type={},n._options.type)for(var s=Object.keys(n._options.type),r=0,o=s.length;r<o;r++){var a=s[r],l=n._options.type[a];n._type[a]="Date"==l||"ISODate"==l||"ASPDate"==l?"Date":l}return t&&t.length&&n.add(t),n.setOptions(i),n}return Ut(e,t),Ft(e,[{key:"setOptions",value:function(t){t&&void 0!==t.queue&&(!1===t.queue?this._queue&&(this._queue.destroy(),delete this._queue):(this._queue||(this._queue=me.extend(this,{replace:["add","update","remove"]})),t.queue&&"object"===Nt(t.queue)&&this._queue.setOptions(t.queue)))}},{key:"add",value:function(t,e){var i,n=[];if(Array.isArray(t))for(var s=0,r=t.length;s<r;s++)i=this._addItem(t[s]),n.push(i);else{if(!t||"object"!==Nt(t))throw new Error("Unknown dataType");i=this._addItem(t),n.push(i)}return n.length&&this._trigger("add",{items:n},e),n}},{key:"update",value:function(t,e){var i=this,n=[],s=[],r=[],o=[],a=this._idProp,l=function(t){var e=t[a];if(null!=e&&i._data[e]){var l=t,h=Object.assign({},i._data[e]),u=i._updateItem(l);s.push(u),o.push(l),r.push(h)}else{var d=i._addItem(t);n.push(d)}};if(Array.isArray(t))for(var h=0,u=t.length;h<u;h++)t[h]&&"object"===Nt(t[h])?l(t[h]):console.warn("Ignoring input item, which is not an object at index "+h);else{if(!t||"object"!==Nt(t))throw new Error("Unknown dataType");l(t)}if(n.length&&this._trigger("add",{items:n},e),s.length){var d={items:s,oldData:r,data:o};this._trigger("update",d,e)}return n.concat(s)}},{key:"get",value:function(t,e){var i=void 0,n=void 0,s=void 0;fe(t)?(i=t,s=e):Array.isArray(t)?(n=t,s=e):s=t;var r=s&&"Object"===s.returnType?"Object":"Array",o=s&&s.type||this._options.type,a=s&&s.filter,l=[],h=null,u=null,d=null;if(null!=i)(h=this._getItem(i,o))&&a&&!a(h)&&(h=null);else if(null!=n)for(var c=0,f=n.length;c<f;c++)null==(h=this._getItem(n[c],o))||a&&!a(h)||l.push(h);else for(var m=0,p=(u=Object.keys(this._data)).length;m<p;m++)d=u[m],null==(h=this._getItem(d,o))||a&&!a(h)||l.push(h);if(s&&s.order&&null==i&&this._sort(l,s.order),s&&s.fields){var g=s.fields;if(null!=i&&null!=h)h=this._filterFields(h,g);else for(var v=0,y=l.length;v<y;v++)l[v]=this._filterFields(l[v],g)}if("Object"==r){for(var _={},b=0,w=l.length;b<w;b++){var k=l[b];_[k[this._idProp]]=k}return _}return null!=i?h:l}},{key:"getIds",value:function(t){var e,i,n=this._data,s=t&&t.filter,r=t&&t.order,o=t&&t.type||this._options.type,a=Object.keys(n),l=[];if(s)if(r){i=[];for(var h=0,u=a.length;h<u;h++){var d=a[h];s(e=this._getItem(d,o))&&i.push(e)}this._sort(i,r);for(var c=0,f=i.length;c<f;c++)l.push(i[c][this._idProp])}else for(var m=0,p=a.length;m<p;m++){var g=a[m];s(e=this._getItem(g,o))&&l.push(e[this._idProp])}else if(r){i=[];for(var v=0,y=a.length;v<y;v++){var _=a[v];i.push(n[_])}this._sort(i,r);for(var b=0,w=i.length;b<w;b++)l.push(i[b][this._idProp])}else for(var k=0,D=a.length;k<D;k++){e=n[a[k]],l.push(e[this._idProp])}return l}},{key:"getDataSet",value:function(){return this}},{key:"forEach",value:function(t,e){var i=e&&e.filter,n=e&&e.type||this._options.type,s=this._data,r=Object.keys(s);if(e&&e.order)for(var o=this.get(e),a=0,l=o.length;a<l;a++){var h=o[a];t(h,h[this._idProp])}else for(var u=0,d=r.length;u<d;u++){var c=r[u],f=this._getItem(c,n);i&&!i(f)||t(f,c)}}},{key:"map",value:function(t,e){for(var i=e&&e.filter,n=e&&e.type||this._options.type,s=[],r=this._data,o=Object.keys(r),a=0,l=o.length;a<l;a++){var h=o[a],u=this._getItem(h,n);i&&!i(u)||s.push(t(u,h))}return e&&e.order&&this._sort(s,e.order),s}},{key:"_filterFields",value:function(t,e){return t?(Array.isArray(e)?e:Object.keys(e)).reduce((function(e,i){return e[i]=t[i],e}),{}):t}},{key:"_sort",value:function(t,e){if("string"==typeof e){var i=e;t.sort((function(t,e){var n=t[i],s=e[i];return n>s?1:n<s?-1:0}))}else{if("function"!=typeof e)throw new TypeError("Order must be a function or a string");t.sort(e)}}},{key:"remove",value:function(t,e){for(var i=[],n=[],s=Array.isArray(t)?t:[t],r=0,o=s.length;r<o;r++){var a=this._remove(s[r]);if(a){var l=a[this._idProp];null!=l&&(i.push(l),n.push(a))}}return i.length&&this._trigger("remove",{items:i,oldData:n},e),i}},{key:"_remove",value:function(t){var e;if(fe(t)?e=t:t&&"object"===Nt(t)&&(e=t[this._idProp]),null!=e&&this._data[e]){var i=this._data[e];return delete this._data[e],--this.length,i}return null}},{key:"clear",value:function(t){for(var e=Object.keys(this._data),i=[],n=0,s=e.length;n<s;n++)i.push(this._data[e[n]]);return this._data={},this.length=0,this._trigger("remove",{items:e,oldData:i},t),e}},{key:"max",value:function(t){for(var e=this._data,i=Object.keys(e),n=null,s=null,r=0,o=i.length;r<o;r++){var a=e[i[r]],l=a[t];null!=l&&(null==s||l>s)&&(n=a,s=l)}return n}},{key:"min",value:function(t){for(var e=this._data,i=Object.keys(e),n=null,s=null,r=0,o=i.length;r<o;r++){var a=e[i[r]],l=a[t];null!=l&&(null==s||l<s)&&(n=a,s=l)}return n}},{key:"distinct",value:function(t){for(var e=this._data,i=Object.keys(e),n=[],s=this._options.type&&this._options.type[t]||null,r=0,o=0,a=i.length;o<a;o++){for(var l=e[i[o]][t],h=!1,u=0;u<r;u++)if(n[u]==l){h=!0;break}h||void 0===l||(n[r]=l,r++)}if(s)for(var d=0,c=n.length;d<c;d++)n[d]=de(n[d],s);return n}},{key:"_addItem",value:function(t){var e=t[this._idProp];if(null!=e){if(this._data[e])throw new Error("Cannot add item: item with id "+e+" already exists")}else e=Jt(),t[this._idProp]=e;for(var i={},n=Object.keys(t),s=0,r=n.length;s<r;s++){var o=n[s],a=this._type[o];i[o]=de(t[o],a)}return this._data[e]=i,this.length++,e}},{key:"_getItem",value:function(t,e){var i,n=this._data[t];if(!n)return null;var s=Object.keys(n);if(e){i={};for(var r=0,o=s.length;r<o;r++){var a=s[r],l=n[a];i[a]=de(l,e[a])}}else i=function(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?be(i,!0).forEach((function(e){It(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):be(i).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}({},n);return null==i[this._idProp]&&(i[this._idProp]=n.id),i}},{key:"_updateItem",value:function(t){var e=t[this._idProp];if(null==e)throw new Error("Cannot update item: item has no id (item: "+JSON.stringify(t)+")");var i=this._data[e];if(!i)throw new Error("Cannot update item: no item with id "+e+" found");for(var n=Object.keys(t),s=0,r=n.length;s<r;s++){var o=n[s],a=this._type[o];i[o]=de(t[o],a)}return e}}]),e}(_e),ke=function(t){function e(t,i){var n;return Rt(this,e),(n=Gt(this,Wt(e).call(this))).length=0,n._ids={},n._options=i||{},n.listener=n._onEvent.bind(Ht(n)),n.setData(t),n}return Ut(e,t),Ft(e,[{key:"setData",value:function(t){if(this._data){this._data.off&&this._data.off("*",this.listener);var e=this._data.getIds({filter:this._options.filter}),i=this._data.get(e);this._ids={},this.length=0,this._trigger("remove",{items:e,oldData:i})}if(null!=t){this._data=t;for(var n=this._data.getIds({filter:this._options.filter}),s=0,r=n.length;s<r;s++){var o=n[s];this._ids[o]=!0}this.length=n.length,this._trigger("add",{items:n})}else this._data=new we;this._data.on&&this._data.on("*",this.listener)}},{key:"refresh",value:function(){for(var t=this._data.getIds({filter:this._options.filter}),e=Object.keys(this._ids),i={},n=[],s=[],r=[],o=0,a=t.length;o<a;o++){var l=t[o];i[l]=!0,this._ids[l]||(n.push(l),this._ids[l]=!0)}for(var h=0,u=e.length;h<u;h++){var d=e[h],c=this._data.get(d);null==c?console.error("If you see this, report it please."):i[d]||(s.push(d),r.push(c),delete this._ids[d])}this.length+=n.length-s.length,n.length&&this._trigger("add",{items:n}),s.length&&this._trigger("remove",{items:s,oldData:r})}},{key:"get",value:function(t,e){if(null==this._data)return null;var i,n=null;fe(t)||Array.isArray(t)?(n=t,i=e):i=t;var s=Object.assign({},this._options,i),r=this._options.filter,o=i&&i.filter;return r&&o&&(s.filter=function(t){return r(t)&&o(t)}),null==n?this._data.get(s):this._data.get(n,s)}},{key:"getIds",value:function(t){if(this._data.length){var e,i=this._options.filter,n=null!=t?t.filter:null;return e=n?i?function(t){return i(t)&&n(t)}:n:i,this._data.getIds({filter:e,order:t&&t.order})}return[]}},{key:"forEach",value:function(t,e){if(this._data){var i,n=this._options.filter,s=e&&e.filter;i=s?n?function(t){return n(t)&&s(t)}:s:n,this._data.forEach(t,{filter:i,order:e&&e.order})}}},{key:"map",value:function(t,e){if(this._data){var i,n=this._options.filter,s=e&&e.filter;return i=s?n?function(t){return n(t)&&s(t)}:s:n,this._data.map(t,{filter:i,order:e&&e.order})}return[]}},{key:"getDataSet",value:function(){return this._data.getDataSet()}},{key:"_onEvent",value:function(t,e,i){if(e&&e.items&&this._data){var n=e.items,s=[],r=[],o=[],a=[],l=[],h=[];switch(t){case"add":for(var u=0,d=n.length;u<d;u++){var c=n[u];this.get(c)&&(this._ids[c]=!0,s.push(c))}break;case"update":for(var f=0,m=n.length;f<m;f++){var p=n[f];this.get(p)?this._ids[p]?(r.push(p),l.push(e.data[f]),a.push(e.oldData[f])):(this._ids[p]=!0,s.push(p)):this._ids[p]&&(delete this._ids[p],o.push(p),h.push(e.oldData[f]))}break;case"remove":for(var g=0,v=n.length;g<v;g++){var y=n[g];this._ids[y]&&(delete this._ids[y],o.push(y),h.push(e.oldData[g]))}}this.length+=s.length-o.length,s.length&&this._trigger("add",{items:s},i),r.length&&this._trigger("update",{items:r,oldData:a,data:l},i),o.length&&this._trigger("remove",{items:o,oldData:h},i)}}}]),e}(_e),De=function(t){try{return!!t()}catch(t){return!0}},Se={}.toString,xe=function(t){return Se.call(t).slice(8,-1)},Me="".split,Te=De((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==xe(t)?Me.call(t,""):Object(t)}:Object,Oe=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},Ce=function(t){return Te(Oe(t))},Ye={},Pe="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Ee(){throw new Error("Dynamic requires are not currently supported by rollup-plugin-commonjs")}function Le(t,e){return t(e={exports:{}},e.exports),e.exports}function Ie(t){return t&&t.default||t}var Ae,Ne,Re,je="object",Fe=function(t){return t&&t.Math==Math&&t},He=Fe(typeof globalThis==je&&globalThis)||Fe(typeof window==je&&window)||Fe(typeof self==je&&self)||Fe(typeof Pe==je&&Pe)||Function("return this")(),Ge=!De((function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})),We=function(t){return"object"==typeof t?null!==t:"function"==typeof t},ze=He.document,Ue=We(ze)&&We(ze.createElement),Ve=function(t){return Ue?ze.createElement(t):{}},Be=!Ge&&!De((function(){return 7!=Object.defineProperty(Ve("div"),"a",{get:function(){return 7}}).a})),Xe=function(t){if(!We(t))throw TypeError(String(t)+" is not an object");return t},qe=function(t,e){if(!We(t))return t;var i,n;if(e&&"function"==typeof(i=t.toString)&&!We(n=i.call(t)))return n;if("function"==typeof(i=t.valueOf)&&!We(n=i.call(t)))return n;if(!e&&"function"==typeof(i=t.toString)&&!We(n=i.call(t)))return n;throw TypeError("Can't convert object to primitive value")},Ze=Object.defineProperty,$e={f:Ge?Ze:function(t,e,i){if(Xe(t),e=qe(e,!0),Xe(i),Be)try{return Ze(t,e,i)}catch(t){}if("get"in i||"set"in i)throw TypeError("Accessors not supported");return"value"in i&&(t[e]=i.value),t}},Je=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},Ke=Ge?function(t,e,i){return $e.f(t,e,Je(1,i))}:function(t,e,i){return t[e]=i,t},Qe=Le((function(t){var e=He["__core-js_shared__"]||function(t,e){try{Ke(He,t,e)}catch(i){He[t]=e}return e}("__core-js_shared__",{});(t.exports=function(t,i){return e[t]||(e[t]=void 0!==i?i:{})})("versions",[]).push({version:"3.2.1",mode:"pure",copyright:"© 2019 Denis Pushkarev (zloirock.ru)"})})),ti=Qe("native-function-to-string",Function.toString),ei=He.WeakMap,ii="function"==typeof ei&&/native code/.test(ti.call(ei)),ni={}.hasOwnProperty,si=function(t,e){return ni.call(t,e)},ri=0,oi=Math.random(),ai=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++ri+oi).toString(36)},li=Qe("keys"),hi=function(t){return li[t]||(li[t]=ai(t))},ui={},di=He.WeakMap;if(ii){var ci=new di,fi=ci.get,mi=ci.has,pi=ci.set;Ae=function(t,e){return pi.call(ci,t,e),e},Ne=function(t){return fi.call(ci,t)||{}},Re=function(t){return mi.call(ci,t)}}else{var gi=hi("state");ui[gi]=!0,Ae=function(t,e){return Ke(t,gi,e),e},Ne=function(t){return si(t,gi)?t[gi]:{}},Re=function(t){return si(t,gi)}}var vi,yi,_i,bi={set:Ae,get:Ne,has:Re,enforce:function(t){return Re(t)?Ne(t):Ae(t,{})},getterFor:function(t){return function(e){var i;if(!We(e)||(i=Ne(e)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return i}}},wi={}.propertyIsEnumerable,ki=Object.getOwnPropertyDescriptor,Di={f:ki&&!wi.call({1:2},1)?function(t){var e=ki(this,t);return!!e&&e.enumerable}:wi},Si=Object.getOwnPropertyDescriptor,xi={f:Ge?Si:function(t,e){if(t=Ce(t),e=qe(e,!0),Be)try{return Si(t,e)}catch(t){}if(si(t,e))return Je(!Di.f.call(t,e),t[e])}},Mi=/#|\.prototype\./,Ti=function(t,e){var i=Ci[Oi(t)];return i==Pi||i!=Yi&&("function"==typeof e?De(e):!!e)},Oi=Ti.normalize=function(t){return String(t).replace(Mi,".").toLowerCase()},Ci=Ti.data={},Yi=Ti.NATIVE="N",Pi=Ti.POLYFILL="P",Ei=Ti,Li={},Ii=function(t){if("function"!=typeof t)throw TypeError(String(t)+" is not a function");return t},Ai=function(t,e,i){if(Ii(t),void 0===e)return t;switch(i){case 0:return function(){return t.call(e)};case 1:return function(i){return t.call(e,i)};case 2:return function(i,n){return t.call(e,i,n)};case 3:return function(i,n,s){return t.call(e,i,n,s)}}return function(){return t.apply(e,arguments)}},Ni=xi.f,Ri=function(t){var e=function(e,i,n){if(this instanceof t){switch(arguments.length){case 0:return new t;case 1:return new t(e);case 2:return new t(e,i)}return new t(e,i,n)}return t.apply(this,arguments)};return e.prototype=t.prototype,e},ji=function(t,e){var i,n,s,r,o,a,l,h,u=t.target,d=t.global,c=t.stat,f=t.proto,m=d?He:c?He[u]:(He[u]||{}).prototype,p=d?Li:Li[u]||(Li[u]={}),g=p.prototype;for(s in e)i=!Ei(d?s:u+(c?".":"#")+s,t.forced)&&m&&si(m,s),o=p[s],i&&(a=t.noTargetGet?(h=Ni(m,s))&&h.value:m[s]),r=i&&a?a:e[s],i&&typeof o==typeof r||(l=t.bind&&i?Ai(r,He):t.wrap&&i?Ri(r):f&&"function"==typeof r?Ai(Function.call,r):r,(t.sham||r&&r.sham||o&&o.sham)&&Ke(l,"sham",!0),p[s]=l,f&&(si(Li,n=u+"Prototype")||Ke(Li,n,{}),Li[n][s]=r,t.real&&g&&!g[s]&&Ke(g,s,r)))},Fi=function(t){return Object(Oe(t))},Hi=!De((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),Gi=hi("IE_PROTO"),Wi=Object.prototype,zi=Hi?Object.getPrototypeOf:function(t){return t=Fi(t),si(t,Gi)?t[Gi]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?Wi:null},Ui=!!Object.getOwnPropertySymbols&&!De((function(){return!String(Symbol())})),Vi=He.Symbol,Bi=Qe("wks"),Xi=function(t){return Bi[t]||(Bi[t]=Ui&&Vi[t]||(Ui?Vi:ai)("Symbol."+t))},qi=(Xi("iterator"),!1);[].keys&&("next"in(_i=[].keys())?(yi=zi(zi(_i)))!==Object.prototype&&(vi=yi):qi=!0),null==vi&&(vi={});var Zi={IteratorPrototype:vi,BUGGY_SAFARI_ITERATORS:qi},$i=Math.ceil,Ji=Math.floor,Ki=function(t){return isNaN(t=+t)?0:(t>0?Ji:$i)(t)},Qi=Math.min,tn=function(t){return t>0?Qi(Ki(t),9007199254740991):0},en=Math.max,nn=Math.min,sn=function(t,e){var i=Ki(t);return i<0?en(i+e,0):nn(i,e)},rn=function(t){return function(e,i,n){var s,r=Ce(e),o=tn(r.length),a=sn(n,o);if(t&&i!=i){for(;o>a;)if((s=r[a++])!=s)return!0}else for(;o>a;a++)if((t||a in r)&&r[a]===i)return t||a||0;return!t&&-1}},on={includes:rn(!0),indexOf:rn(!1)},an=on.indexOf,ln=function(t,e){var i,n=Ce(t),s=0,r=[];for(i in n)!si(ui,i)&&si(n,i)&&r.push(i);for(;e.length>s;)si(n,i=e[s++])&&(~an(r,i)||r.push(i));return r},hn=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],un=Object.keys||function(t){return ln(t,hn)},dn=Ge?Object.defineProperties:function(t,e){Xe(t);for(var i,n=un(e),s=n.length,r=0;s>r;)$e.f(t,i=n[r++],e[i]);return t},cn=function(t){return"function"==typeof t?t:void 0},fn=function(t,e){return arguments.length<2?cn(Li[t])||cn(He[t]):Li[t]&&Li[t][e]||He[t]&&He[t][e]},mn=fn("document","documentElement"),pn=hi("IE_PROTO"),gn=function(){},vn=function(){var t,e=Ve("iframe"),i=hn.length;for(e.style.display="none",mn.appendChild(e),e.src=String("javascript:"),(t=e.contentWindow.document).open(),t.write("<script>document.F=Object<\/script>"),t.close(),vn=t.F;i--;)delete vn.prototype[hn[i]];return vn()},yn=Object.create||function(t,e){var i;return null!==t?(gn.prototype=Xe(t),i=new gn,gn.prototype=null,i[pn]=t):i=vn(),void 0===e?i:dn(i,e)};ui[pn]=!0;var _n=Xi("toStringTag"),bn="Arguments"==xe(function(){return arguments}()),wn=function(t){var e,i,n;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(i=function(t,e){try{return t[e]}catch(t){}}(e=Object(t),_n))?i:bn?xe(e):"Object"==(n=xe(e))&&"function"==typeof e.callee?"Arguments":n},kn={};kn[Xi("toStringTag")]="z";var Dn="[object z]"!==String(kn)?function(){return"[object "+wn(this)+"]"}:kn.toString,Sn=$e.f,xn=Xi("toStringTag"),Mn=Dn!=={}.toString,Tn=function(t,e,i,n){if(t){var s=i?t:t.prototype;si(s,xn)||Sn(s,xn,{configurable:!0,value:e}),n&&Mn&&Ke(s,"toString",Dn)}},On=Zi.IteratorPrototype,Cn=function(){return this},Yn=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,i={};try{(t=Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set).call(i,[]),e=i instanceof Array}catch(t){}return function(i,n){return Xe(i),function(t){if(!We(t)&&null!==t)throw TypeError("Can't set "+String(t)+" as a prototype")}(n),e?t.call(i,n):i.__proto__=n,i}}():void 0),Pn=function(t,e,i,n){n&&n.enumerable?t[e]=i:Ke(t,e,i)},En=Zi.IteratorPrototype,Ln=Zi.BUGGY_SAFARI_ITERATORS,In=Xi("iterator"),An=function(){return this},Nn=function(t,e,i,n,s,r,o){!function(t,e,i){var n=e+" Iterator";t.prototype=yn(On,{next:Je(1,i)}),Tn(t,n,!1,!0),Ye[n]=Cn}(i,e,n);var a,l,h,u=function(t){if(t===s&&p)return p;if(!Ln&&t in f)return f[t];switch(t){case"keys":case"values":case"entries":return function(){return new i(this,t)}}return function(){return new i(this)}},d=e+" Iterator",c=!1,f=t.prototype,m=f[In]||f["@@iterator"]||s&&f[s],p=!Ln&&m||u(s),g="Array"==e&&f.entries||m;if(g&&(a=zi(g.call(new t)),En!==Object.prototype&&a.next&&(Tn(a,d,!0,!0),Ye[d]=An)),"values"==s&&m&&"values"!==m.name&&(c=!0,p=function(){return m.call(this)}),o&&f[In]!==p&&Ke(f,In,p),Ye[e]=p,s)if(l={values:u("values"),keys:r?p:u("keys"),entries:u("entries")},o)for(h in l)!Ln&&!c&&h in f||Pn(f,h,l[h]);else ji({target:e,proto:!0,forced:Ln||c},l);return l},Rn=bi.set,jn=bi.getterFor("Array Iterator");Nn(Array,"Array",(function(t,e){Rn(this,{type:"Array Iterator",target:Ce(t),index:0,kind:e})}),(function(){var t=jn(this),e=t.target,i=t.kind,n=t.index++;return!e||n>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==i?{value:n,done:!1}:"values"==i?{value:e[n],done:!1}:{value:[n,e[n]],done:!1}}),"values");Ye.Arguments=Ye.Array;var Fn=Xi("toStringTag");for(var Hn in{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}){var Gn=He[Hn],Wn=Gn&&Gn.prototype;Wn&&!Wn[Fn]&&Ke(Wn,Fn,Hn),Ye[Hn]=Ye.Array}var zn=Array.isArray||function(t){return"Array"==xe(t)},Un=Xi("species"),Vn=function(t,e){var i;return zn(t)&&("function"!=typeof(i=t.constructor)||i!==Array&&!zn(i.prototype)?We(i)&&null===(i=i[Un])&&(i=void 0):i=void 0),new(void 0===i?Array:i)(0===e?0:e)},Bn=[].push,Xn=function(t){var e=1==t,i=2==t,n=3==t,s=4==t,r=6==t,o=5==t||r;return function(a,l,h,u){for(var d,c,f=Fi(a),m=Te(f),p=Ai(l,h,3),g=tn(m.length),v=0,y=u||Vn,_=e?y(a,g):i?y(a,0):void 0;g>v;v++)if((o||v in m)&&(c=p(d=m[v],v,f),t))if(e)_[v]=c;else if(c)switch(t){case 3:return!0;case 5:return d;case 6:return v;case 2:Bn.call(_,d)}else if(s)return!1;return r?-1:n||s?s:_}},qn={forEach:Xn(0),map:Xn(1),filter:Xn(2),some:Xn(3),every:Xn(4),find:Xn(5),findIndex:Xn(6)},Zn=function(t,e){var i=[][t];return!i||!De((function(){i.call(null,e||function(){throw 1},1)}))},$n=qn.forEach,Jn=Zn("forEach")?function(t){return $n(this,t,arguments.length>1?arguments[1]:void 0)}:[].forEach;ji({target:"Array",proto:!0,forced:[].forEach!=Jn},{forEach:Jn});var Kn=function(t){return Li[t+"Prototype"]},Qn=Kn("Array").forEach,ts=Array.prototype,es={DOMTokenList:!0,NodeList:!0},is=function(t){var e=t.forEach;return t===ts||t instanceof Array&&e===ts.forEach||es.hasOwnProperty(wn(t))?Qn:e},ns=Xi("species"),ss=function(t){return!De((function(){var e=[];return(e.constructor={})[ns]=function(){return{foo:1}},1!==e[t](Boolean).foo}))},rs=qn.filter;ji({target:"Array",proto:!0,forced:!ss("filter")},{filter:function(t){return rs(this,t,arguments.length>1?arguments[1]:void 0)}});var os=Kn("Array").filter,as=Array.prototype,ls=function(t){var e=t.filter;return t===as||t instanceof Array&&e===as.filter?os:e},hs=fn("navigator","userAgent")||"",us=[].slice,ds=/MSIE .\./.test(hs),cs=function(t){return function(e,i){var n=arguments.length>2,s=n?us.call(arguments,2):void 0;return t(n?function(){("function"==typeof e?e:Function(e)).apply(this,s)}:e,i)}};ji({global:!0,bind:!0,forced:ds},{setTimeout:cs(He.setTimeout),setInterval:cs(He.setInterval)});var fs=Li.setTimeout,ms=[].slice,ps={},gs=function(t,e,i){if(!(e in ps)){for(var n=[],s=0;s<e;s++)n[s]="a["+s+"]";ps[e]=Function("C,a","return new C("+n.join(",")+")")}return ps[e](t,i)},vs=Function.bind||function(t){var e=Ii(this),i=ms.call(arguments,1),n=function(){var s=i.concat(ms.call(arguments));return this instanceof n?gs(e,s.length,s):e.apply(t,s)};return We(e.prototype)&&(n.prototype=e.prototype),n};ji({target:"Function",proto:!0},{bind:vs});var ys=Kn("Function").bind,_s=Function.prototype,bs=function(t){var e=t.bind;return t===_s||t instanceof Function&&e===_s.bind?ys:e};ji({target:"Array",stat:!0},{isArray:zn});var ws=Li.Array.isArray,ks=ws;var Ds=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")};ji({target:"Object",stat:!0,forced:!Ge,sham:!Ge},{defineProperty:$e.f});var Ss=Le((function(t){var e=Li.Object,i=t.exports=function(t,i,n){return e.defineProperty(t,i,n)};e.defineProperty.sham&&(i.sham=!0)})),xs=Ss;function Ms(t,e){for(var i=0;i<e.length;i++){var n=e[i];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),xs(t,n.key,n)}}var Ts=function(t,e,i){return e&&Ms(t.prototype,e),i&&Ms(t,i),t},Os={f:Xi},Cs=$e.f,Ys=function(t){var e=Li.Symbol||(Li.Symbol={});si(e,t)||Cs(e,t,{value:Os.f(t)})};Ys("iterator");var Ps=function(t){return function(e,i){var n,s,r=String(Oe(e)),o=Ki(i),a=r.length;return o<0||o>=a?t?"":void 0:(n=r.charCodeAt(o))<55296||n>56319||o+1===a||(s=r.charCodeAt(o+1))<56320||s>57343?t?r.charAt(o):n:t?r.slice(o,o+2):s-56320+(n-55296<<10)+65536}},Es={codeAt:Ps(!1),charAt:Ps(!0)}.charAt,Ls=bi.set,Is=bi.getterFor("String Iterator");Nn(String,"String",(function(t){Ls(this,{type:"String Iterator",string:String(t),index:0})}),(function(){var t,e=Is(this),i=e.string,n=e.index;return n>=i.length?{value:void 0,done:!0}:(t=Es(i,n),e.index+=t.length,{value:t,done:!1})}));var As=Os.f("iterator"),Ns=function(t,e,i){var n=qe(e);n in t?$e.f(t,n,Je(0,i)):t[n]=i},Rs=Xi("isConcatSpreadable"),js=!De((function(){var t=[];return t[Rs]=!1,t.concat()[0]!==t})),Fs=ss("concat"),Hs=function(t){if(!We(t))return!1;var e=t[Rs];return void 0!==e?!!e:zn(t)};ji({target:"Array",proto:!0,forced:!js||!Fs},{concat:function(t){var e,i,n,s,r,o=Fi(this),a=Vn(o,0),l=0;for(e=-1,n=arguments.length;e<n;e++)if(r=-1===e?o:arguments[e],Hs(r)){if(l+(s=tn(r.length))>9007199254740991)throw TypeError("Maximum allowed index exceeded");for(i=0;i<s;i++,l++)i in r&&Ns(a,l,r[i])}else{if(l>=9007199254740991)throw TypeError("Maximum allowed index exceeded");Ns(a,l++,r)}return a.length=l,a}});var Gs=Object.freeze({}),Ws=hn.concat("length","prototype"),zs={f:Object.getOwnPropertyNames||function(t){return ln(t,Ws)}},Us=zs.f,Vs={}.toString,Bs="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],Xs={f:function(t){return Bs&&"[object Window]"==Vs.call(t)?function(t){try{return Us(t)}catch(t){return Bs.slice()}}(t):Us(Ce(t))}},qs={f:Object.getOwnPropertySymbols},Zs=qn.forEach,$s=hi("hidden"),Js=Xi("toPrimitive"),Ks=bi.set,Qs=bi.getterFor("Symbol"),tr=Object.prototype,er=He.Symbol,ir=He.JSON,nr=ir&&ir.stringify,sr=xi.f,rr=$e.f,or=Xs.f,ar=Di.f,lr=Qe("symbols"),hr=Qe("op-symbols"),ur=Qe("string-to-symbol-registry"),dr=Qe("symbol-to-string-registry"),cr=Qe("wks"),fr=He.QObject,mr=!fr||!fr.prototype||!fr.prototype.findChild,pr=Ge&&De((function(){return 7!=yn(rr({},"a",{get:function(){return rr(this,"a",{value:7}).a}})).a}))?function(t,e,i){var n=sr(tr,e);n&&delete tr[e],rr(t,e,i),n&&t!==tr&&rr(tr,e,n)}:rr,gr=function(t,e){var i=lr[t]=yn(er.prototype);return Ks(i,{type:"Symbol",tag:t,description:e}),Ge||(i.description=e),i},vr=Ui&&"symbol"==typeof er.iterator?function(t){return"symbol"==typeof t}:function(t){return Object(t)instanceof er},yr=function(t,e,i){t===tr&&yr(hr,e,i),Xe(t);var n=qe(e,!0);return Xe(i),si(lr,n)?(i.enumerable?(si(t,$s)&&t[$s][n]&&(t[$s][n]=!1),i=yn(i,{enumerable:Je(0,!1)})):(si(t,$s)||rr(t,$s,Je(1,{})),t[$s][n]=!0),pr(t,n,i)):rr(t,n,i)},_r=function(t,e){Xe(t);var i=Ce(e),n=un(i).concat(Dr(i));return Zs(n,(function(e){Ge&&!br.call(i,e)||yr(t,e,i[e])})),t},br=function(t){var e=qe(t,!0),i=ar.call(this,e);return!(this===tr&&si(lr,e)&&!si(hr,e))&&(!(i||!si(this,e)||!si(lr,e)||si(this,$s)&&this[$s][e])||i)},wr=function(t,e){var i=Ce(t),n=qe(e,!0);if(i!==tr||!si(lr,n)||si(hr,n)){var s=sr(i,n);return!s||!si(lr,n)||si(i,$s)&&i[$s][n]||(s.enumerable=!0),s}},kr=function(t){var e=or(Ce(t)),i=[];return Zs(e,(function(t){si(lr,t)||si(ui,t)||i.push(t)})),i},Dr=function(t){var e=t===tr,i=or(e?hr:Ce(t)),n=[];return Zs(i,(function(t){!si(lr,t)||e&&!si(tr,t)||n.push(lr[t])})),n};Ui||(Pn((er=function(){if(this instanceof er)throw TypeError("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,e=ai(t),i=function(t){this===tr&&i.call(hr,t),si(this,$s)&&si(this[$s],e)&&(this[$s][e]=!1),pr(this,e,Je(1,t))};return Ge&&mr&&pr(tr,e,{configurable:!0,set:i}),gr(e,t)}).prototype,"toString",(function(){return Qs(this).tag})),Di.f=br,$e.f=yr,xi.f=wr,zs.f=Xs.f=kr,qs.f=Dr,Ge&&rr(er.prototype,"description",{configurable:!0,get:function(){return Qs(this).description}}),Os.f=function(t){return gr(Xi(t),t)}),ji({global:!0,wrap:!0,forced:!Ui,sham:!Ui},{Symbol:er}),Zs(un(cr),(function(t){Ys(t)})),ji({target:"Symbol",stat:!0,forced:!Ui},{for:function(t){var e=String(t);if(si(ur,e))return ur[e];var i=er(e);return ur[e]=i,dr[i]=e,i},keyFor:function(t){if(!vr(t))throw TypeError(t+" is not a symbol");if(si(dr,t))return dr[t]},useSetter:function(){mr=!0},useSimple:function(){mr=!1}}),ji({target:"Object",stat:!0,forced:!Ui,sham:!Ge},{create:function(t,e){return void 0===e?yn(t):_r(yn(t),e)},defineProperty:yr,defineProperties:_r,getOwnPropertyDescriptor:wr}),ji({target:"Object",stat:!0,forced:!Ui},{getOwnPropertyNames:kr,getOwnPropertySymbols:Dr}),ji({target:"Object",stat:!0,forced:De((function(){qs.f(1)}))},{getOwnPropertySymbols:function(t){return qs.f(Fi(t))}}),ir&&ji({target:"JSON",stat:!0,forced:!Ui||De((function(){var t=er();return"[null]"!=nr([t])||"{}"!=nr({a:t})||"{}"!=nr(Object(t))}))},{stringify:function(t){for(var e,i,n=[t],s=1;arguments.length>s;)n.push(arguments[s++]);if(i=e=n[1],(We(e)||void 0!==t)&&!vr(t))return zn(e)||(e=function(t,e){if("function"==typeof i&&(e=i.call(this,t,e)),!vr(e))return e}),n[1]=e,nr.apply(ir,n)}}),er.prototype[Js]||Ke(er.prototype,Js,er.prototype.valueOf),Tn(er,"Symbol"),ui[$s]=!0,Ys("asyncIterator");var Sr=Object.freeze({});Ys("hasInstance"),Ys("isConcatSpreadable"),Ys("match"),Ys("matchAll"),Ys("replace"),Ys("search"),Ys("species"),Ys("split"),Ys("toPrimitive"),Ys("toStringTag"),Ys("unscopables"),Tn(Math,"Math",!0),Tn(He.JSON,"JSON",!0),Ie(Gs),Ie(Sr);var xr=Li.Symbol;Ys("asyncDispose"),Ys("dispose"),Ys("observable"),Ys("patternMatch"),Ys("replaceAll");var Mr=xr,Tr=Le((function(t){function e(i){return t.exports=e="function"==typeof Mr&&"symbol"==typeof As?function(t){return typeof t}:function(t){return t&&"function"==typeof Mr&&t.constructor===Mr&&t!==Mr.prototype?"symbol":typeof t},e(i)}t.exports=e}));var Or=function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t};var Cr=function(t,e){return!e||"object"!==Tr(e)&&"function"!=typeof e?Or(t):e},Yr=De((function(){zi(1)}));ji({target:"Object",stat:!0,forced:Yr,sham:!Hi},{getPrototypeOf:function(t){return zi(Fi(t))}});var Pr=Li.Object.getPrototypeOf;ji({target:"Object",stat:!0},{setPrototypeOf:Yn});var Er=Li.Object.setPrototypeOf,Lr=Le((function(t){function e(i){return t.exports=e=Er?Pr:function(t){return t.__proto__||Pr(t)},e(i)}t.exports=e}));ji({target:"Object",stat:!0,sham:!Ge},{create:yn});var Ir=Li.Object,Ar=function(t,e){return Ir.create(t,e)},Nr=Ar,Rr=Le((function(t){function e(i,n){return t.exports=e=Er||function(t,e){return t.__proto__=e,t},e(i,n)}t.exports=e}));var jr=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function");t.prototype=Nr(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&Rr(t,e)},Fr=Le((function(t,e){t.exports=function(){var e,i;function n(){return e.apply(null,arguments)}function s(t){return t instanceof Array||"[object Array]"===Object.prototype.toString.call(t)}function r(t){return null!=t&&"[object Object]"===Object.prototype.toString.call(t)}function o(t){return void 0===t}function a(t){return"number"==typeof t||"[object Number]"===Object.prototype.toString.call(t)}function l(t){return t instanceof Date||"[object Date]"===Object.prototype.toString.call(t)}function h(t,e){var i,n=[];for(i=0;i<t.length;++i)n.push(e(t[i],i));return n}function u(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function d(t,e){for(var i in e)u(e,i)&&(t[i]=e[i]);return u(e,"toString")&&(t.toString=e.toString),u(e,"valueOf")&&(t.valueOf=e.valueOf),t}function c(t,e,i,n){return Le(t,e,i,n,!0).utc()}function f(t){return null==t._pf&&(t._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null,rfc2822:!1,weekdayMismatch:!1}),t._pf}function m(t){if(null==t._isValid){var e=f(t),n=i.call(e.parsedDateParts,(function(t){return null!=t})),s=!isNaN(t._d.getTime())&&e.overflow<0&&!e.empty&&!e.invalidMonth&&!e.invalidWeekday&&!e.weekdayMismatch&&!e.nullInput&&!e.invalidFormat&&!e.userInvalidated&&(!e.meridiem||e.meridiem&&n);if(t._strict&&(s=s&&0===e.charsLeftOver&&0===e.unusedTokens.length&&void 0===e.bigHour),null!=Object.isFrozen&&Object.isFrozen(t))return s;t._isValid=s}return t._isValid}function p(t){var e=c(NaN);return null!=t?d(f(e),t):f(e).userInvalidated=!0,e}i=Array.prototype.some?Array.prototype.some:function(t){for(var e=Object(this),i=e.length>>>0,n=0;n<i;n++)if(n in e&&t.call(this,e[n],n,e))return!0;return!1};var g=n.momentProperties=[];function v(t,e){var i,n,s;if(o(e._isAMomentObject)||(t._isAMomentObject=e._isAMomentObject),o(e._i)||(t._i=e._i),o(e._f)||(t._f=e._f),o(e._l)||(t._l=e._l),o(e._strict)||(t._strict=e._strict),o(e._tzm)||(t._tzm=e._tzm),o(e._isUTC)||(t._isUTC=e._isUTC),o(e._offset)||(t._offset=e._offset),o(e._pf)||(t._pf=f(e)),o(e._locale)||(t._locale=e._locale),g.length>0)for(i=0;i<g.length;i++)o(s=e[n=g[i]])||(t[n]=s);return t}var y=!1;function _(t){v(this,t),this._d=new Date(null!=t._d?t._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===y&&(y=!0,n.updateOffset(this),y=!1)}function b(t){return t instanceof _||null!=t&&null!=t._isAMomentObject}function w(t){return t<0?Math.ceil(t)||0:Math.floor(t)}function k(t){var e=+t,i=0;return 0!==e&&isFinite(e)&&(i=w(e)),i}function D(t,e,i){var n,s=Math.min(t.length,e.length),r=Math.abs(t.length-e.length),o=0;for(n=0;n<s;n++)(i&&t[n]!==e[n]||!i&&k(t[n])!==k(e[n]))&&o++;return o+r}function S(t){!1===n.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+t)}function x(t,e){var i=!0;return d((function(){if(null!=n.deprecationHandler&&n.deprecationHandler(null,t),i){for(var s,r=[],o=0;o<arguments.length;o++){if(s="","object"==typeof arguments[o]){for(var a in s+="\n["+o+"] ",arguments[0])s+=a+": "+arguments[0][a]+", ";s=s.slice(0,-2)}else s=arguments[o];r.push(s)}S(t+"\nArguments: "+Array.prototype.slice.call(r).join("")+"\n"+(new Error).stack),i=!1}return e.apply(this,arguments)}),e)}var M,T={};function O(t,e){null!=n.deprecationHandler&&n.deprecationHandler(t,e),T[t]||(S(e),T[t]=!0)}function C(t){return t instanceof Function||"[object Function]"===Object.prototype.toString.call(t)}function Y(t,e){var i,n=d({},t);for(i in e)u(e,i)&&(r(t[i])&&r(e[i])?(n[i]={},d(n[i],t[i]),d(n[i],e[i])):null!=e[i]?n[i]=e[i]:delete n[i]);for(i in t)u(t,i)&&!u(e,i)&&r(t[i])&&(n[i]=d({},n[i]));return n}function P(t){null!=t&&this.set(t)}n.suppressDeprecationWarnings=!1,n.deprecationHandler=null,M=Object.keys?Object.keys:function(t){var e,i=[];for(e in t)u(t,e)&&i.push(e);return i};var E={};function L(t,e){var i=t.toLowerCase();E[i]=E[i+"s"]=E[e]=t}function I(t){return"string"==typeof t?E[t]||E[t.toLowerCase()]:void 0}function A(t){var e,i,n={};for(i in t)u(t,i)&&(e=I(i))&&(n[e]=t[i]);return n}var N={};function R(t,e){N[t]=e}function j(t,e,i){var n=""+Math.abs(t),s=e-n.length;return(t>=0?i?"+":"":"-")+Math.pow(10,Math.max(0,s)).toString().substr(1)+n}var F=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|YYYYYY|YYYYY|YYYY|YY|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,H=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,G={},W={};function z(t,e,i,n){var s=n;"string"==typeof n&&(s=function(){return this[n]()}),t&&(W[t]=s),e&&(W[e[0]]=function(){return j(s.apply(this,arguments),e[1],e[2])}),i&&(W[i]=function(){return this.localeData().ordinal(s.apply(this,arguments),t)})}function U(t,e){return t.isValid()?(e=V(e,t.localeData()),G[e]=G[e]||function(t){var e,i,n,s=t.match(F);for(e=0,i=s.length;e<i;e++)W[s[e]]?s[e]=W[s[e]]:s[e]=(n=s[e]).match(/\[[\s\S]/)?n.replace(/^\[|\]$/g,""):n.replace(/\\/g,"");return function(e){var n,r="";for(n=0;n<i;n++)r+=C(s[n])?s[n].call(e,t):s[n];return r}}(e),G[e](t)):t.localeData().invalidDate()}function V(t,e){var i=5;function n(t){return e.longDateFormat(t)||t}for(H.lastIndex=0;i>=0&&H.test(t);)t=t.replace(H,n),H.lastIndex=0,i-=1;return t}var B=/\d/,X=/\d\d/,q=/\d{3}/,Z=/\d{4}/,$=/[+-]?\d{6}/,J=/\d\d?/,K=/\d\d\d\d?/,Q=/\d\d\d\d\d\d?/,tt=/\d{1,3}/,et=/\d{1,4}/,it=/[+-]?\d{1,6}/,nt=/\d+/,st=/[+-]?\d+/,rt=/Z|[+-]\d\d:?\d\d/gi,ot=/Z|[+-]\d\d(?::?\d\d)?/gi,at=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,lt={};function ht(t,e,i){lt[t]=C(e)?e:function(t,n){return t&&i?i:e}}function ut(t,e){return u(lt,t)?lt[t](e._strict,e._locale):new RegExp(dt(t.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(t,e,i,n,s){return e||i||n||s}))))}function dt(t){return t.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var ct={};function ft(t,e){var i,n=e;for("string"==typeof t&&(t=[t]),a(e)&&(n=function(t,i){i[e]=k(t)}),i=0;i<t.length;i++)ct[t[i]]=n}function mt(t,e){ft(t,(function(t,i,n,s){n._w=n._w||{},e(t,n._w,n,s)}))}function pt(t,e,i){null!=e&&u(ct,t)&&ct[t](e,i._a,i,t)}var gt=0,vt=1,yt=2,_t=3,bt=4,wt=5,kt=6,Dt=7,St=8;function xt(t){return Mt(t)?366:365}function Mt(t){return t%4==0&&t%100!=0||t%400==0}z("Y",0,0,(function(){var t=this.year();return t<=9999?""+t:"+"+t})),z(0,["YY",2],0,(function(){return this.year()%100})),z(0,["YYYY",4],0,"year"),z(0,["YYYYY",5],0,"year"),z(0,["YYYYYY",6,!0],0,"year"),L("year","y"),R("year",1),ht("Y",st),ht("YY",J,X),ht("YYYY",et,Z),ht("YYYYY",it,$),ht("YYYYYY",it,$),ft(["YYYYY","YYYYYY"],gt),ft("YYYY",(function(t,e){e[gt]=2===t.length?n.parseTwoDigitYear(t):k(t)})),ft("YY",(function(t,e){e[gt]=n.parseTwoDigitYear(t)})),ft("Y",(function(t,e){e[gt]=parseInt(t,10)})),n.parseTwoDigitYear=function(t){return k(t)+(k(t)>68?1900:2e3)};var Tt,Ot=Ct("FullYear",!0);function Ct(t,e){return function(i){return null!=i?(Pt(this,t,i),n.updateOffset(this,e),this):Yt(this,t)}}function Yt(t,e){return t.isValid()?t._d["get"+(t._isUTC?"UTC":"")+e]():NaN}function Pt(t,e,i){t.isValid()&&!isNaN(i)&&("FullYear"===e&&Mt(t.year())&&1===t.month()&&29===t.date()?t._d["set"+(t._isUTC?"UTC":"")+e](i,t.month(),Et(i,t.month())):t._d["set"+(t._isUTC?"UTC":"")+e](i))}function Et(t,e){if(isNaN(t)||isNaN(e))return NaN;var i,n=(e%(i=12)+i)%i;return t+=(e-n)/12,1===n?Mt(t)?29:28:31-n%7%2}Tt=Array.prototype.indexOf?Array.prototype.indexOf:function(t){var e;for(e=0;e<this.length;++e)if(this[e]===t)return e;return-1},z("M",["MM",2],"Mo",(function(){return this.month()+1})),z("MMM",0,0,(function(t){return this.localeData().monthsShort(this,t)})),z("MMMM",0,0,(function(t){return this.localeData().months(this,t)})),L("month","M"),R("month",8),ht("M",J),ht("MM",J,X),ht("MMM",(function(t,e){return e.monthsShortRegex(t)})),ht("MMMM",(function(t,e){return e.monthsRegex(t)})),ft(["M","MM"],(function(t,e){e[vt]=k(t)-1})),ft(["MMM","MMMM"],(function(t,e,i,n){var s=i._locale.monthsParse(t,n,i._strict);null!=s?e[vt]=s:f(i).invalidMonth=t}));var Lt=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,It="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),At="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");function Nt(t,e,i){var n,s,r,o=t.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],n=0;n<12;++n)r=c([2e3,n]),this._shortMonthsParse[n]=this.monthsShort(r,"").toLocaleLowerCase(),this._longMonthsParse[n]=this.months(r,"").toLocaleLowerCase();return i?"MMM"===e?-1!==(s=Tt.call(this._shortMonthsParse,o))?s:null:-1!==(s=Tt.call(this._longMonthsParse,o))?s:null:"MMM"===e?-1!==(s=Tt.call(this._shortMonthsParse,o))?s:-1!==(s=Tt.call(this._longMonthsParse,o))?s:null:-1!==(s=Tt.call(this._longMonthsParse,o))?s:-1!==(s=Tt.call(this._shortMonthsParse,o))?s:null}function Rt(t,e){var i;if(!t.isValid())return t;if("string"==typeof e)if(/^\d+$/.test(e))e=k(e);else if(!a(e=t.localeData().monthsParse(e)))return t;return i=Math.min(t.date(),Et(t.year(),e)),t._d["set"+(t._isUTC?"UTC":"")+"Month"](e,i),t}function jt(t){return null!=t?(Rt(this,t),n.updateOffset(this,!0),this):Yt(this,"Month")}var Ft=at,Ht=at;function Gt(){function t(t,e){return e.length-t.length}var e,i,n=[],s=[],r=[];for(e=0;e<12;e++)i=c([2e3,e]),n.push(this.monthsShort(i,"")),s.push(this.months(i,"")),r.push(this.months(i,"")),r.push(this.monthsShort(i,""));for(n.sort(t),s.sort(t),r.sort(t),e=0;e<12;e++)n[e]=dt(n[e]),s[e]=dt(s[e]);for(e=0;e<24;e++)r[e]=dt(r[e]);this._monthsRegex=new RegExp("^("+r.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+n.join("|")+")","i")}function Wt(t,e,i,n,s,r,o){var a;return t<100&&t>=0?(a=new Date(t+400,e,i,n,s,r,o),isFinite(a.getFullYear())&&a.setFullYear(t)):a=new Date(t,e,i,n,s,r,o),a}function zt(t){var e;if(t<100&&t>=0){var i=Array.prototype.slice.call(arguments);i[0]=t+400,e=new Date(Date.UTC.apply(null,i)),isFinite(e.getUTCFullYear())&&e.setUTCFullYear(t)}else e=new Date(Date.UTC.apply(null,arguments));return e}function Ut(t,e,i){var n=7+e-i;return-(7+zt(t,0,n).getUTCDay()-e)%7+n-1}function Vt(t,e,i,n,s){var r,o,a=1+7*(e-1)+(7+i-n)%7+Ut(t,n,s);return a<=0?o=xt(r=t-1)+a:a>xt(t)?(r=t+1,o=a-xt(t)):(r=t,o=a),{year:r,dayOfYear:o}}function Bt(t,e,i){var n,s,r=Ut(t.year(),e,i),o=Math.floor((t.dayOfYear()-r-1)/7)+1;return o<1?n=o+Xt(s=t.year()-1,e,i):o>Xt(t.year(),e,i)?(n=o-Xt(t.year(),e,i),s=t.year()+1):(s=t.year(),n=o),{week:n,year:s}}function Xt(t,e,i){var n=Ut(t,e,i),s=Ut(t+1,e,i);return(xt(t)-n+s)/7}function qt(t,e){return t.slice(e,7).concat(t.slice(0,e))}z("w",["ww",2],"wo","week"),z("W",["WW",2],"Wo","isoWeek"),L("week","w"),L("isoWeek","W"),R("week",5),R("isoWeek",5),ht("w",J),ht("ww",J,X),ht("W",J),ht("WW",J,X),mt(["w","ww","W","WW"],(function(t,e,i,n){e[n.substr(0,1)]=k(t)})),z("d",0,"do","day"),z("dd",0,0,(function(t){return this.localeData().weekdaysMin(this,t)})),z("ddd",0,0,(function(t){return this.localeData().weekdaysShort(this,t)})),z("dddd",0,0,(function(t){return this.localeData().weekdays(this,t)})),z("e",0,0,"weekday"),z("E",0,0,"isoWeekday"),L("day","d"),L("weekday","e"),L("isoWeekday","E"),R("day",11),R("weekday",11),R("isoWeekday",11),ht("d",J),ht("e",J),ht("E",J),ht("dd",(function(t,e){return e.weekdaysMinRegex(t)})),ht("ddd",(function(t,e){return e.weekdaysShortRegex(t)})),ht("dddd",(function(t,e){return e.weekdaysRegex(t)})),mt(["dd","ddd","dddd"],(function(t,e,i,n){var s=i._locale.weekdaysParse(t,n,i._strict);null!=s?e.d=s:f(i).invalidWeekday=t})),mt(["d","e","E"],(function(t,e,i,n){e[n]=k(t)}));var Zt="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),$t="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Jt="Su_Mo_Tu_We_Th_Fr_Sa".split("_");function Kt(t,e,i){var n,s,r,o=t.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],n=0;n<7;++n)r=c([2e3,1]).day(n),this._minWeekdaysParse[n]=this.weekdaysMin(r,"").toLocaleLowerCase(),this._shortWeekdaysParse[n]=this.weekdaysShort(r,"").toLocaleLowerCase(),this._weekdaysParse[n]=this.weekdays(r,"").toLocaleLowerCase();return i?"dddd"===e?-1!==(s=Tt.call(this._weekdaysParse,o))?s:null:"ddd"===e?-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:null:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:null:"dddd"===e?-1!==(s=Tt.call(this._weekdaysParse,o))?s:-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:null:"ddd"===e?-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:-1!==(s=Tt.call(this._weekdaysParse,o))?s:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:null:-1!==(s=Tt.call(this._minWeekdaysParse,o))?s:-1!==(s=Tt.call(this._weekdaysParse,o))?s:-1!==(s=Tt.call(this._shortWeekdaysParse,o))?s:null}var Qt=at,te=at,ee=at;function ie(){function t(t,e){return e.length-t.length}var e,i,n,s,r,o=[],a=[],l=[],h=[];for(e=0;e<7;e++)i=c([2e3,1]).day(e),n=this.weekdaysMin(i,""),s=this.weekdaysShort(i,""),r=this.weekdays(i,""),o.push(n),a.push(s),l.push(r),h.push(n),h.push(s),h.push(r);for(o.sort(t),a.sort(t),l.sort(t),h.sort(t),e=0;e<7;e++)a[e]=dt(a[e]),l[e]=dt(l[e]),h[e]=dt(h[e]);this._weekdaysRegex=new RegExp("^("+h.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+a.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+o.join("|")+")","i")}function ne(){return this.hours()%12||12}function se(t,e){z(t,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),e)}))}function re(t,e){return e._meridiemParse}z("H",["HH",2],0,"hour"),z("h",["hh",2],0,ne),z("k",["kk",2],0,(function(){return this.hours()||24})),z("hmm",0,0,(function(){return""+ne.apply(this)+j(this.minutes(),2)})),z("hmmss",0,0,(function(){return""+ne.apply(this)+j(this.minutes(),2)+j(this.seconds(),2)})),z("Hmm",0,0,(function(){return""+this.hours()+j(this.minutes(),2)})),z("Hmmss",0,0,(function(){return""+this.hours()+j(this.minutes(),2)+j(this.seconds(),2)})),se("a",!0),se("A",!1),L("hour","h"),R("hour",13),ht("a",re),ht("A",re),ht("H",J),ht("h",J),ht("k",J),ht("HH",J,X),ht("hh",J,X),ht("kk",J,X),ht("hmm",K),ht("hmmss",Q),ht("Hmm",K),ht("Hmmss",Q),ft(["H","HH"],_t),ft(["k","kk"],(function(t,e,i){var n=k(t);e[_t]=24===n?0:n})),ft(["a","A"],(function(t,e,i){i._isPm=i._locale.isPM(t),i._meridiem=t})),ft(["h","hh"],(function(t,e,i){e[_t]=k(t),f(i).bigHour=!0})),ft("hmm",(function(t,e,i){var n=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n)),f(i).bigHour=!0})),ft("hmmss",(function(t,e,i){var n=t.length-4,s=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n,2)),e[wt]=k(t.substr(s)),f(i).bigHour=!0})),ft("Hmm",(function(t,e,i){var n=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n))})),ft("Hmmss",(function(t,e,i){var n=t.length-4,s=t.length-2;e[_t]=k(t.substr(0,n)),e[bt]=k(t.substr(n,2)),e[wt]=k(t.substr(s))}));var oe,ae=Ct("Hours",!0),le={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{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"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:It,monthsShort:At,week:{dow:0,doy:6},weekdays:Zt,weekdaysMin:Jt,weekdaysShort:$t,meridiemParse:/[ap]\.?m?\.?/i},he={},ue={};function de(t){return t?t.toLowerCase().replace("_","-"):t}function ce(e){var i=null;if(!he[e]&&t&&t.exports)try{i=oe._abbr,Ee(),fe(i)}catch(t){}return he[e]}function fe(t,e){var i;return t&&((i=o(e)?pe(t):me(t,e))?oe=i:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+t+" not found. Did you forget to load it?")),oe._abbr}function me(t,e){if(null!==e){var i,n=le;if(e.abbr=t,null!=he[t])O("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),n=he[t]._config;else if(null!=e.parentLocale)if(null!=he[e.parentLocale])n=he[e.parentLocale]._config;else{if(null==(i=ce(e.parentLocale)))return ue[e.parentLocale]||(ue[e.parentLocale]=[]),ue[e.parentLocale].push({name:t,config:e}),null;n=i._config}return he[t]=new P(Y(n,e)),ue[t]&&ue[t].forEach((function(t){me(t.name,t.config)})),fe(t),he[t]}return delete he[t],null}function pe(t){var e;if(t&&t._locale&&t._locale._abbr&&(t=t._locale._abbr),!t)return oe;if(!s(t)){if(e=ce(t))return e;t=[t]}return function(t){for(var e,i,n,s,r=0;r<t.length;){for(e=(s=de(t[r]).split("-")).length,i=(i=de(t[r+1]))?i.split("-"):null;e>0;){if(n=ce(s.slice(0,e).join("-")))return n;if(i&&i.length>=e&&D(s,i,!0)>=e-1)break;e--}r++}return oe}(t)}function ge(t){var e,i=t._a;return i&&-2===f(t).overflow&&(e=i[vt]<0||i[vt]>11?vt:i[yt]<1||i[yt]>Et(i[gt],i[vt])?yt:i[_t]<0||i[_t]>24||24===i[_t]&&(0!==i[bt]||0!==i[wt]||0!==i[kt])?_t:i[bt]<0||i[bt]>59?bt:i[wt]<0||i[wt]>59?wt:i[kt]<0||i[kt]>999?kt:-1,f(t)._overflowDayOfYear&&(e<gt||e>yt)&&(e=yt),f(t)._overflowWeeks&&-1===e&&(e=Dt),f(t)._overflowWeekday&&-1===e&&(e=St),f(t).overflow=e),t}function ve(t,e,i){return null!=t?t:null!=e?e:i}function ye(t){var e,i,s,r,o,a=[];if(!t._d){for(s=function(t){var e=new Date(n.now());return t._useUTC?[e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate()]:[e.getFullYear(),e.getMonth(),e.getDate()]}(t),t._w&&null==t._a[yt]&&null==t._a[vt]&&function(t){var e,i,n,s,r,o,a,l;if(null!=(e=t._w).GG||null!=e.W||null!=e.E)r=1,o=4,i=ve(e.GG,t._a[gt],Bt(Ie(),1,4).year),n=ve(e.W,1),((s=ve(e.E,1))<1||s>7)&&(l=!0);else{r=t._locale._week.dow,o=t._locale._week.doy;var h=Bt(Ie(),r,o);i=ve(e.gg,t._a[gt],h.year),n=ve(e.w,h.week),null!=e.d?((s=e.d)<0||s>6)&&(l=!0):null!=e.e?(s=e.e+r,(e.e<0||e.e>6)&&(l=!0)):s=r}n<1||n>Xt(i,r,o)?f(t)._overflowWeeks=!0:null!=l?f(t)._overflowWeekday=!0:(a=Vt(i,n,s,r,o),t._a[gt]=a.year,t._dayOfYear=a.dayOfYear)}(t),null!=t._dayOfYear&&(o=ve(t._a[gt],s[gt]),(t._dayOfYear>xt(o)||0===t._dayOfYear)&&(f(t)._overflowDayOfYear=!0),i=zt(o,0,t._dayOfYear),t._a[vt]=i.getUTCMonth(),t._a[yt]=i.getUTCDate()),e=0;e<3&&null==t._a[e];++e)t._a[e]=a[e]=s[e];for(;e<7;e++)t._a[e]=a[e]=null==t._a[e]?2===e?1:0:t._a[e];24===t._a[_t]&&0===t._a[bt]&&0===t._a[wt]&&0===t._a[kt]&&(t._nextDay=!0,t._a[_t]=0),t._d=(t._useUTC?zt:Wt).apply(null,a),r=t._useUTC?t._d.getUTCDay():t._d.getDay(),null!=t._tzm&&t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),t._nextDay&&(t._a[_t]=24),t._w&&void 0!==t._w.d&&t._w.d!==r&&(f(t).weekdayMismatch=!0)}}var _e=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,be=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([\+\-]\d\d(?::?\d\d)?|\s*Z)?)?$/,we=/Z|[+-]\d\d(?::?\d\d)?/,ke=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/]],De=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Se=/^\/?Date\((\-?\d+)/i;function xe(t){var e,i,n,s,r,o,a=t._i,l=_e.exec(a)||be.exec(a);if(l){for(f(t).iso=!0,e=0,i=ke.length;e<i;e++)if(ke[e][1].exec(l[1])){s=ke[e][0],n=!1!==ke[e][2];break}if(null==s)return void(t._isValid=!1);if(l[3]){for(e=0,i=De.length;e<i;e++)if(De[e][1].exec(l[3])){r=(l[2]||" ")+De[e][0];break}if(null==r)return void(t._isValid=!1)}if(!n&&null!=r)return void(t._isValid=!1);if(l[4]){if(!we.exec(l[4]))return void(t._isValid=!1);o="Z"}t._f=s+(r||"")+(o||""),Ye(t)}else t._isValid=!1}var Me=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/;function Te(t){var e=parseInt(t,10);return e<=49?2e3+e:e<=999?1900+e:e}var Oe={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Ce(t){var e,i,n,s,r,o,a,l=Me.exec(t._i.replace(/\([^)]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(l){var h=(e=l[4],i=l[3],n=l[2],s=l[5],r=l[6],o=l[7],a=[Te(e),At.indexOf(i),parseInt(n,10),parseInt(s,10),parseInt(r,10)],o&&a.push(parseInt(o,10)),a);if(!function(t,e,i){return!t||$t.indexOf(t)===new Date(e[0],e[1],e[2]).getDay()||(f(i).weekdayMismatch=!0,i._isValid=!1,!1)}(l[1],h,t))return;t._a=h,t._tzm=function(t,e,i){if(t)return Oe[t];if(e)return 0;var n=parseInt(i,10),s=n%100;return(n-s)/100*60+s}(l[8],l[9],l[10]),t._d=zt.apply(null,t._a),t._d.setUTCMinutes(t._d.getUTCMinutes()-t._tzm),f(t).rfc2822=!0}else t._isValid=!1}function Ye(t){if(t._f!==n.ISO_8601)if(t._f!==n.RFC_2822){t._a=[],f(t).empty=!0;var e,i,s,r,o,a=""+t._i,l=a.length,h=0;for(s=V(t._f,t._locale).match(F)||[],e=0;e<s.length;e++)r=s[e],(i=(a.match(ut(r,t))||[])[0])&&((o=a.substr(0,a.indexOf(i))).length>0&&f(t).unusedInput.push(o),a=a.slice(a.indexOf(i)+i.length),h+=i.length),W[r]?(i?f(t).empty=!1:f(t).unusedTokens.push(r),pt(r,i,t)):t._strict&&!i&&f(t).unusedTokens.push(r);f(t).charsLeftOver=l-h,a.length>0&&f(t).unusedInput.push(a),t._a[_t]<=12&&!0===f(t).bigHour&&t._a[_t]>0&&(f(t).bigHour=void 0),f(t).parsedDateParts=t._a.slice(0),f(t).meridiem=t._meridiem,t._a[_t]=function(t,e,i){var n;return null==i?e:null!=t.meridiemHour?t.meridiemHour(e,i):null!=t.isPM?((n=t.isPM(i))&&e<12&&(e+=12),n||12!==e||(e=0),e):e}(t._locale,t._a[_t],t._meridiem),ye(t),ge(t)}else Ce(t);else xe(t)}function Pe(t){var e=t._i,i=t._f;return t._locale=t._locale||pe(t._l),null===e||void 0===i&&""===e?p({nullInput:!0}):("string"==typeof e&&(t._i=e=t._locale.preparse(e)),b(e)?new _(ge(e)):(l(e)?t._d=e:s(i)?function(t){var e,i,n,s,r;if(0===t._f.length)return f(t).invalidFormat=!0,void(t._d=new Date(NaN));for(s=0;s<t._f.length;s++)r=0,e=v({},t),null!=t._useUTC&&(e._useUTC=t._useUTC),e._f=t._f[s],Ye(e),m(e)&&(r+=f(e).charsLeftOver,r+=10*f(e).unusedTokens.length,f(e).score=r,(null==n||r<n)&&(n=r,i=e));d(t,i||e)}(t):i?Ye(t):function(t){var e=t._i;o(e)?t._d=new Date(n.now()):l(e)?t._d=new Date(e.valueOf()):"string"==typeof e?function(t){var e=Se.exec(t._i);null===e?(xe(t),!1===t._isValid&&(delete t._isValid,Ce(t),!1===t._isValid&&(delete t._isValid,n.createFromInputFallback(t)))):t._d=new Date(+e[1])}(t):s(e)?(t._a=h(e.slice(0),(function(t){return parseInt(t,10)})),ye(t)):r(e)?function(t){if(!t._d){var e=A(t._i);t._a=h([e.year,e.month,e.day||e.date,e.hour,e.minute,e.second,e.millisecond],(function(t){return t&&parseInt(t,10)})),ye(t)}}(t):a(e)?t._d=new Date(e):n.createFromInputFallback(t)}(t),m(t)||(t._d=null),t))}function Le(t,e,i,n,o){var a,l={};return!0!==i&&!1!==i||(n=i,i=void 0),(r(t)&&function(t){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(t).length;var e;for(e in t)if(t.hasOwnProperty(e))return!1;return!0}(t)||s(t)&&0===t.length)&&(t=void 0),l._isAMomentObject=!0,l._useUTC=l._isUTC=o,l._l=i,l._i=t,l._f=e,l._strict=n,(a=new _(ge(Pe(l))))._nextDay&&(a.add(1,"d"),a._nextDay=void 0),a}function Ie(t,e,i,n){return Le(t,e,i,n,!1)}n.createFromInputFallback=x("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and will be removed in an upcoming major release. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(t){t._d=new Date(t._i+(t._useUTC?" UTC":""))})),n.ISO_8601=function(){},n.RFC_2822=function(){};var Ae=x("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var t=Ie.apply(null,arguments);return this.isValid()&&t.isValid()?t<this?this:t:p()})),Ne=x("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var t=Ie.apply(null,arguments);return this.isValid()&&t.isValid()?t>this?this:t:p()}));function Re(t,e){var i,n;if(1===e.length&&s(e[0])&&(e=e[0]),!e.length)return Ie();for(i=e[0],n=1;n<e.length;++n)e[n].isValid()&&!e[n][t](i)||(i=e[n]);return i}var je=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Fe(t){var e=A(t),i=e.year||0,n=e.quarter||0,s=e.month||0,r=e.week||e.isoWeek||0,o=e.day||0,a=e.hour||0,l=e.minute||0,h=e.second||0,u=e.millisecond||0;this._isValid=function(t){for(var e in t)if(-1===Tt.call(je,e)||null!=t[e]&&isNaN(t[e]))return!1;for(var i=!1,n=0;n<je.length;++n)if(t[je[n]]){if(i)return!1;parseFloat(t[je[n]])!==k(t[je[n]])&&(i=!0)}return!0}(e),this._milliseconds=+u+1e3*h+6e4*l+1e3*a*60*60,this._days=+o+7*r,this._months=+s+3*n+12*i,this._data={},this._locale=pe(),this._bubble()}function He(t){return t instanceof Fe}function Ge(t){return t<0?-1*Math.round(-1*t):Math.round(t)}function We(t,e){z(t,0,0,(function(){var t=this.utcOffset(),i="+";return t<0&&(t=-t,i="-"),i+j(~~(t/60),2)+e+j(~~t%60,2)}))}We("Z",":"),We("ZZ",""),ht("Z",ot),ht("ZZ",ot),ft(["Z","ZZ"],(function(t,e,i){i._useUTC=!0,i._tzm=Ue(ot,t)}));var ze=/([\+\-]|\d\d)/gi;function Ue(t,e){var i=(e||"").match(t);if(null===i)return null;var n=((i[i.length-1]||[])+"").match(ze)||["-",0,0],s=60*n[1]+k(n[2]);return 0===s?0:"+"===n[0]?s:-s}function Ve(t,e){var i,s;return e._isUTC?(i=e.clone(),s=(b(t)||l(t)?t.valueOf():Ie(t).valueOf())-i.valueOf(),i._d.setTime(i._d.valueOf()+s),n.updateOffset(i,!1),i):Ie(t).local()}function Be(t){return 15*-Math.round(t._d.getTimezoneOffset()/15)}function Xe(){return!!this.isValid()&&this._isUTC&&0===this._offset}n.updateOffset=function(){};var qe=/^(\-|\+)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)(\.\d*)?)?$/,Ze=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function $e(t,e){var i,n,s,r,o,l,h=t,d=null;return He(t)?h={ms:t._milliseconds,d:t._days,M:t._months}:a(t)?(h={},e?h[e]=t:h.milliseconds=t):(d=qe.exec(t))?(i="-"===d[1]?-1:1,h={y:0,d:k(d[yt])*i,h:k(d[_t])*i,m:k(d[bt])*i,s:k(d[wt])*i,ms:k(Ge(1e3*d[kt]))*i}):(d=Ze.exec(t))?(i="-"===d[1]?-1:1,h={y:Je(d[2],i),M:Je(d[3],i),w:Je(d[4],i),d:Je(d[5],i),h:Je(d[6],i),m:Je(d[7],i),s:Je(d[8],i)}):null==h?h={}:"object"==typeof h&&("from"in h||"to"in h)&&(r=Ie(h.from),o=Ie(h.to),s=r.isValid()&&o.isValid()?(o=Ve(o,r),r.isBefore(o)?l=Ke(r,o):((l=Ke(o,r)).milliseconds=-l.milliseconds,l.months=-l.months),l):{milliseconds:0,months:0},(h={}).ms=s.milliseconds,h.M=s.months),n=new Fe(h),He(t)&&u(t,"_locale")&&(n._locale=t._locale),n}function Je(t,e){var i=t&&parseFloat(t.replace(",","."));return(isNaN(i)?0:i)*e}function Ke(t,e){var i={};return i.months=e.month()-t.month()+12*(e.year()-t.year()),t.clone().add(i.months,"M").isAfter(e)&&--i.months,i.milliseconds=+e-+t.clone().add(i.months,"M"),i}function Qe(t,e){return function(i,n){var s;return null===n||isNaN(+n)||(O(e,"moment()."+e+"(period, number) is deprecated. Please use moment()."+e+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),s=i,i=n,n=s),ti(this,$e(i="string"==typeof i?+i:i,n),t),this}}function ti(t,e,i,s){var r=e._milliseconds,o=Ge(e._days),a=Ge(e._months);t.isValid()&&(s=null==s||s,a&&Rt(t,Yt(t,"Month")+a*i),o&&Pt(t,"Date",Yt(t,"Date")+o*i),r&&t._d.setTime(t._d.valueOf()+r*i),s&&n.updateOffset(t,o||a))}$e.fn=Fe.prototype,$e.invalid=function(){return $e(NaN)};var ei=Qe(1,"add"),ii=Qe(-1,"subtract");function ni(t,e){var i=12*(e.year()-t.year())+(e.month()-t.month()),n=t.clone().add(i,"months");return-(i+(e-n<0?(e-n)/(n-t.clone().add(i-1,"months")):(e-n)/(t.clone().add(i+1,"months")-n)))||0}function si(t){var e;return void 0===t?this._locale._abbr:(null!=(e=pe(t))&&(this._locale=e),this)}n.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",n.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var ri=x("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(t){return void 0===t?this.localeData():this.locale(t)}));function oi(){return this._locale}var ai=1e3,li=60*ai,hi=60*li,ui=3506328*hi;function di(t,e){return(t%e+e)%e}function ci(t,e,i){return t<100&&t>=0?new Date(t+400,e,i)-ui:new Date(t,e,i).valueOf()}function fi(t,e,i){return t<100&&t>=0?Date.UTC(t+400,e,i)-ui:Date.UTC(t,e,i)}function mi(t,e){z(0,[t,t.length],0,e)}function pi(t,e,i,n,s){var r;return null==t?Bt(this,n,s).year:(e>(r=Xt(t,n,s))&&(e=r),gi.call(this,t,e,i,n,s))}function gi(t,e,i,n,s){var r=Vt(t,e,i,n,s),o=zt(r.year,0,r.dayOfYear);return this.year(o.getUTCFullYear()),this.month(o.getUTCMonth()),this.date(o.getUTCDate()),this}z(0,["gg",2],0,(function(){return this.weekYear()%100})),z(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),mi("gggg","weekYear"),mi("ggggg","weekYear"),mi("GGGG","isoWeekYear"),mi("GGGGG","isoWeekYear"),L("weekYear","gg"),L("isoWeekYear","GG"),R("weekYear",1),R("isoWeekYear",1),ht("G",st),ht("g",st),ht("GG",J,X),ht("gg",J,X),ht("GGGG",et,Z),ht("gggg",et,Z),ht("GGGGG",it,$),ht("ggggg",it,$),mt(["gggg","ggggg","GGGG","GGGGG"],(function(t,e,i,n){e[n.substr(0,2)]=k(t)})),mt(["gg","GG"],(function(t,e,i,s){e[s]=n.parseTwoDigitYear(t)})),z("Q",0,"Qo","quarter"),L("quarter","Q"),R("quarter",7),ht("Q",B),ft("Q",(function(t,e){e[vt]=3*(k(t)-1)})),z("D",["DD",2],"Do","date"),L("date","D"),R("date",9),ht("D",J),ht("DD",J,X),ht("Do",(function(t,e){return t?e._dayOfMonthOrdinalParse||e._ordinalParse:e._dayOfMonthOrdinalParseLenient})),ft(["D","DD"],yt),ft("Do",(function(t,e){e[yt]=k(t.match(J)[0])}));var vi=Ct("Date",!0);z("DDD",["DDDD",3],"DDDo","dayOfYear"),L("dayOfYear","DDD"),R("dayOfYear",4),ht("DDD",tt),ht("DDDD",q),ft(["DDD","DDDD"],(function(t,e,i){i._dayOfYear=k(t)})),z("m",["mm",2],0,"minute"),L("minute","m"),R("minute",14),ht("m",J),ht("mm",J,X),ft(["m","mm"],bt);var yi=Ct("Minutes",!1);z("s",["ss",2],0,"second"),L("second","s"),R("second",15),ht("s",J),ht("ss",J,X),ft(["s","ss"],wt);var _i,bi=Ct("Seconds",!1);for(z("S",0,0,(function(){return~~(this.millisecond()/100)})),z(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),z(0,["SSS",3],0,"millisecond"),z(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),z(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),z(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),z(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),z(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),z(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),L("millisecond","ms"),R("millisecond",16),ht("S",tt,B),ht("SS",tt,X),ht("SSS",tt,q),_i="SSSS";_i.length<=9;_i+="S")ht(_i,nt);function wi(t,e){e[kt]=k(1e3*("0."+t))}for(_i="S";_i.length<=9;_i+="S")ft(_i,wi);var ki=Ct("Milliseconds",!1);z("z",0,0,"zoneAbbr"),z("zz",0,0,"zoneName");var Di=_.prototype;function Si(t){return t}Di.add=ei,Di.calendar=function(t,e){var i=t||Ie(),s=Ve(i,this).startOf("day"),r=n.calendarFormat(this,s)||"sameElse",o=e&&(C(e[r])?e[r].call(this,i):e[r]);return this.format(o||this.localeData().calendar(r,this,Ie(i)))},Di.clone=function(){return new _(this)},Di.diff=function(t,e,i){var n,s,r;if(!this.isValid())return NaN;if(!(n=Ve(t,this)).isValid())return NaN;switch(s=6e4*(n.utcOffset()-this.utcOffset()),e=I(e)){case"year":r=ni(this,n)/12;break;case"month":r=ni(this,n);break;case"quarter":r=ni(this,n)/3;break;case"second":r=(this-n)/1e3;break;case"minute":r=(this-n)/6e4;break;case"hour":r=(this-n)/36e5;break;case"day":r=(this-n-s)/864e5;break;case"week":r=(this-n-s)/6048e5;break;default:r=this-n}return i?r:w(r)},Di.endOf=function(t){var e;if(void 0===(t=I(t))||"millisecond"===t||!this.isValid())return this;var i=this._isUTC?fi:ci;switch(t){case"year":e=i(this.year()+1,0,1)-1;break;case"quarter":e=i(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":e=i(this.year(),this.month()+1,1)-1;break;case"week":e=i(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":e=i(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":e=i(this.year(),this.month(),this.date()+1)-1;break;case"hour":e=this._d.valueOf(),e+=hi-di(e+(this._isUTC?0:this.utcOffset()*li),hi)-1;break;case"minute":e=this._d.valueOf(),e+=li-di(e,li)-1;break;case"second":e=this._d.valueOf(),e+=ai-di(e,ai)-1}return this._d.setTime(e),n.updateOffset(this,!0),this},Di.format=function(t){t||(t=this.isUtc()?n.defaultFormatUtc:n.defaultFormat);var e=U(this,t);return this.localeData().postformat(e)},Di.from=function(t,e){return this.isValid()&&(b(t)&&t.isValid()||Ie(t).isValid())?$e({to:this,from:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()},Di.fromNow=function(t){return this.from(Ie(),t)},Di.to=function(t,e){return this.isValid()&&(b(t)&&t.isValid()||Ie(t).isValid())?$e({from:this,to:t}).locale(this.locale()).humanize(!e):this.localeData().invalidDate()},Di.toNow=function(t){return this.to(Ie(),t)},Di.get=function(t){return C(this[t=I(t)])?this[t]():this},Di.invalidAt=function(){return f(this).overflow},Di.isAfter=function(t,e){var i=b(t)?t:Ie(t);return!(!this.isValid()||!i.isValid())&&("millisecond"===(e=I(e)||"millisecond")?this.valueOf()>i.valueOf():i.valueOf()<this.clone().startOf(e).valueOf())},Di.isBefore=function(t,e){var i=b(t)?t:Ie(t);return!(!this.isValid()||!i.isValid())&&("millisecond"===(e=I(e)||"millisecond")?this.valueOf()<i.valueOf():this.clone().endOf(e).valueOf()<i.valueOf())},Di.isBetween=function(t,e,i,n){var s=b(t)?t:Ie(t),r=b(e)?e:Ie(e);return!!(this.isValid()&&s.isValid()&&r.isValid())&&("("===(n=n||"()")[0]?this.isAfter(s,i):!this.isBefore(s,i))&&(")"===n[1]?this.isBefore(r,i):!this.isAfter(r,i))},Di.isSame=function(t,e){var i,n=b(t)?t:Ie(t);return!(!this.isValid()||!n.isValid())&&("millisecond"===(e=I(e)||"millisecond")?this.valueOf()===n.valueOf():(i=n.valueOf(),this.clone().startOf(e).valueOf()<=i&&i<=this.clone().endOf(e).valueOf()))},Di.isSameOrAfter=function(t,e){return this.isSame(t,e)||this.isAfter(t,e)},Di.isSameOrBefore=function(t,e){return this.isSame(t,e)||this.isBefore(t,e)},Di.isValid=function(){return m(this)},Di.lang=ri,Di.locale=si,Di.localeData=oi,Di.max=Ne,Di.min=Ae,Di.parsingFlags=function(){return d({},f(this))},Di.set=function(t,e){if("object"==typeof t)for(var i=function(t){var e=[];for(var i in t)e.push({unit:i,priority:N[i]});return e.sort((function(t,e){return t.priority-e.priority})),e}(t=A(t)),n=0;n<i.length;n++)this[i[n].unit](t[i[n].unit]);else if(C(this[t=I(t)]))return this[t](e);return this},Di.startOf=function(t){var e;if(void 0===(t=I(t))||"millisecond"===t||!this.isValid())return this;var i=this._isUTC?fi:ci;switch(t){case"year":e=i(this.year(),0,1);break;case"quarter":e=i(this.year(),this.month()-this.month()%3,1);break;case"month":e=i(this.year(),this.month(),1);break;case"week":e=i(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":e=i(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":e=i(this.year(),this.month(),this.date());break;case"hour":e=this._d.valueOf(),e-=di(e+(this._isUTC?0:this.utcOffset()*li),hi);break;case"minute":e=this._d.valueOf(),e-=di(e,li);break;case"second":e=this._d.valueOf(),e-=di(e,ai)}return this._d.setTime(e),n.updateOffset(this,!0),this},Di.subtract=ii,Di.toArray=function(){var t=this;return[t.year(),t.month(),t.date(),t.hour(),t.minute(),t.second(),t.millisecond()]},Di.toObject=function(){var t=this;return{years:t.year(),months:t.month(),date:t.date(),hours:t.hours(),minutes:t.minutes(),seconds:t.seconds(),milliseconds:t.milliseconds()}},Di.toDate=function(){return new Date(this.valueOf())},Di.toISOString=function(t){if(!this.isValid())return null;var e=!0!==t,i=e?this.clone().utc():this;return i.year()<0||i.year()>9999?U(i,e?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):C(Date.prototype.toISOString)?e?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",U(i,"Z")):U(i,e?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},Di.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var t="moment",e="";this.isLocal()||(t=0===this.utcOffset()?"moment.utc":"moment.parseZone",e="Z");var i="["+t+'("]',n=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",s=e+'[")]';return this.format(i+n+"-MM-DD[T]HH:mm:ss.SSS"+s)},Di.toJSON=function(){return this.isValid()?this.toISOString():null},Di.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},Di.unix=function(){return Math.floor(this.valueOf()/1e3)},Di.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},Di.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},Di.year=Ot,Di.isLeapYear=function(){return Mt(this.year())},Di.weekYear=function(t){return pi.call(this,t,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},Di.isoWeekYear=function(t){return pi.call(this,t,this.isoWeek(),this.isoWeekday(),1,4)},Di.quarter=Di.quarters=function(t){return null==t?Math.ceil((this.month()+1)/3):this.month(3*(t-1)+this.month()%3)},Di.month=jt,Di.daysInMonth=function(){return Et(this.year(),this.month())},Di.week=Di.weeks=function(t){var e=this.localeData().week(this);return null==t?e:this.add(7*(t-e),"d")},Di.isoWeek=Di.isoWeeks=function(t){var e=Bt(this,1,4).week;return null==t?e:this.add(7*(t-e),"d")},Di.weeksInYear=function(){var t=this.localeData()._week;return Xt(this.year(),t.dow,t.doy)},Di.isoWeeksInYear=function(){return Xt(this.year(),1,4)},Di.date=vi,Di.day=Di.days=function(t){if(!this.isValid())return null!=t?this:NaN;var e=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=t?(t=function(t,e){return"string"!=typeof t?t:isNaN(t)?"number"==typeof(t=e.weekdaysParse(t))?t:null:parseInt(t,10)}(t,this.localeData()),this.add(t-e,"d")):e},Di.weekday=function(t){if(!this.isValid())return null!=t?this:NaN;var e=(this.day()+7-this.localeData()._week.dow)%7;return null==t?e:this.add(t-e,"d")},Di.isoWeekday=function(t){if(!this.isValid())return null!=t?this:NaN;if(null!=t){var e=function(t,e){return"string"==typeof t?e.weekdaysParse(t)%7||7:isNaN(t)?null:t}(t,this.localeData());return this.day(this.day()%7?e:e-7)}return this.day()||7},Di.dayOfYear=function(t){var e=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==t?e:this.add(t-e,"d")},Di.hour=Di.hours=ae,Di.minute=Di.minutes=yi,Di.second=Di.seconds=bi,Di.millisecond=Di.milliseconds=ki,Di.utcOffset=function(t,e,i){var s,r=this._offset||0;if(!this.isValid())return null!=t?this:NaN;if(null!=t){if("string"==typeof t){if(null===(t=Ue(ot,t)))return this}else Math.abs(t)<16&&!i&&(t*=60);return!this._isUTC&&e&&(s=Be(this)),this._offset=t,this._isUTC=!0,null!=s&&this.add(s,"m"),r!==t&&(!e||this._changeInProgress?ti(this,$e(t-r,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,n.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?r:Be(this)},Di.utc=function(t){return this.utcOffset(0,t)},Di.local=function(t){return this._isUTC&&(this.utcOffset(0,t),this._isUTC=!1,t&&this.subtract(Be(this),"m")),this},Di.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var t=Ue(rt,this._i);null!=t?this.utcOffset(t):this.utcOffset(0,!0)}return this},Di.hasAlignedHourOffset=function(t){return!!this.isValid()&&(t=t?Ie(t).utcOffset():0,(this.utcOffset()-t)%60==0)},Di.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},Di.isLocal=function(){return!!this.isValid()&&!this._isUTC},Di.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},Di.isUtc=Xe,Di.isUTC=Xe,Di.zoneAbbr=function(){return this._isUTC?"UTC":""},Di.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},Di.dates=x("dates accessor is deprecated. Use date instead.",vi),Di.months=x("months accessor is deprecated. Use month instead",jt),Di.years=x("years accessor is deprecated. Use year instead",Ot),Di.zone=x("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(t,e){return null!=t?("string"!=typeof t&&(t=-t),this.utcOffset(t,e),this):-this.utcOffset()})),Di.isDSTShifted=x("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!o(this._isDSTShifted))return this._isDSTShifted;var t={};if(v(t,this),(t=Pe(t))._a){var e=t._isUTC?c(t._a):Ie(t._a);this._isDSTShifted=this.isValid()&&D(t._a,e.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted}));var xi=P.prototype;function Mi(t,e,i,n){var s=pe(),r=c().set(n,e);return s[i](r,t)}function Ti(t,e,i){if(a(t)&&(e=t,t=void 0),t=t||"",null!=e)return Mi(t,e,i,"month");var n,s=[];for(n=0;n<12;n++)s[n]=Mi(t,n,i,"month");return s}function Oi(t,e,i,n){"boolean"==typeof t?(a(e)&&(i=e,e=void 0),e=e||""):(i=e=t,t=!1,a(e)&&(i=e,e=void 0),e=e||"");var s,r=pe(),o=t?r._week.dow:0;if(null!=i)return Mi(e,(i+o)%7,n,"day");var l=[];for(s=0;s<7;s++)l[s]=Mi(e,(s+o)%7,n,"day");return l}xi.calendar=function(t,e,i){var n=this._calendar[t]||this._calendar.sameElse;return C(n)?n.call(e,i):n},xi.longDateFormat=function(t){var e=this._longDateFormat[t],i=this._longDateFormat[t.toUpperCase()];return e||!i?e:(this._longDateFormat[t]=i.replace(/MMMM|MM|DD|dddd/g,(function(t){return t.slice(1)})),this._longDateFormat[t])},xi.invalidDate=function(){return this._invalidDate},xi.ordinal=function(t){return this._ordinal.replace("%d",t)},xi.preparse=Si,xi.postformat=Si,xi.relativeTime=function(t,e,i,n){var s=this._relativeTime[i];return C(s)?s(t,e,i,n):s.replace(/%d/i,t)},xi.pastFuture=function(t,e){var i=this._relativeTime[t>0?"future":"past"];return C(i)?i(e):i.replace(/%s/i,e)},xi.set=function(t){var e,i;for(i in t)C(e=t[i])?this[i]=e:this["_"+i]=e;this._config=t,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},xi.months=function(t,e){return t?s(this._months)?this._months[t.month()]:this._months[(this._months.isFormat||Lt).test(e)?"format":"standalone"][t.month()]:s(this._months)?this._months:this._months.standalone},xi.monthsShort=function(t,e){return t?s(this._monthsShort)?this._monthsShort[t.month()]:this._monthsShort[Lt.test(e)?"format":"standalone"][t.month()]:s(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},xi.monthsParse=function(t,e,i){var n,s,r;if(this._monthsParseExact)return Nt.call(this,t,e,i);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),n=0;n<12;n++){if(s=c([2e3,n]),i&&!this._longMonthsParse[n]&&(this._longMonthsParse[n]=new RegExp("^"+this.months(s,"").replace(".","")+"$","i"),this._shortMonthsParse[n]=new RegExp("^"+this.monthsShort(s,"").replace(".","")+"$","i")),i||this._monthsParse[n]||(r="^"+this.months(s,"")+"|^"+this.monthsShort(s,""),this._monthsParse[n]=new RegExp(r.replace(".",""),"i")),i&&"MMMM"===e&&this._longMonthsParse[n].test(t))return n;if(i&&"MMM"===e&&this._shortMonthsParse[n].test(t))return n;if(!i&&this._monthsParse[n].test(t))return n}},xi.monthsRegex=function(t){return this._monthsParseExact?(u(this,"_monthsRegex")||Gt.call(this),t?this._monthsStrictRegex:this._monthsRegex):(u(this,"_monthsRegex")||(this._monthsRegex=Ht),this._monthsStrictRegex&&t?this._monthsStrictRegex:this._monthsRegex)},xi.monthsShortRegex=function(t){return this._monthsParseExact?(u(this,"_monthsRegex")||Gt.call(this),t?this._monthsShortStrictRegex:this._monthsShortRegex):(u(this,"_monthsShortRegex")||(this._monthsShortRegex=Ft),this._monthsShortStrictRegex&&t?this._monthsShortStrictRegex:this._monthsShortRegex)},xi.week=function(t){return Bt(t,this._week.dow,this._week.doy).week},xi.firstDayOfYear=function(){return this._week.doy},xi.firstDayOfWeek=function(){return this._week.dow},xi.weekdays=function(t,e){var i=s(this._weekdays)?this._weekdays:this._weekdays[t&&!0!==t&&this._weekdays.isFormat.test(e)?"format":"standalone"];return!0===t?qt(i,this._week.dow):t?i[t.day()]:i},xi.weekdaysMin=function(t){return!0===t?qt(this._weekdaysMin,this._week.dow):t?this._weekdaysMin[t.day()]:this._weekdaysMin},xi.weekdaysShort=function(t){return!0===t?qt(this._weekdaysShort,this._week.dow):t?this._weekdaysShort[t.day()]:this._weekdaysShort},xi.weekdaysParse=function(t,e,i){var n,s,r;if(this._weekdaysParseExact)return Kt.call(this,t,e,i);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),n=0;n<7;n++){if(s=c([2e3,1]).day(n),i&&!this._fullWeekdaysParse[n]&&(this._fullWeekdaysParse[n]=new RegExp("^"+this.weekdays(s,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[n]=new RegExp("^"+this.weekdaysShort(s,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[n]=new RegExp("^"+this.weekdaysMin(s,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[n]||(r="^"+this.weekdays(s,"")+"|^"+this.weekdaysShort(s,"")+"|^"+this.weekdaysMin(s,""),this._weekdaysParse[n]=new RegExp(r.replace(".",""),"i")),i&&"dddd"===e&&this._fullWeekdaysParse[n].test(t))return n;if(i&&"ddd"===e&&this._shortWeekdaysParse[n].test(t))return n;if(i&&"dd"===e&&this._minWeekdaysParse[n].test(t))return n;if(!i&&this._weekdaysParse[n].test(t))return n}},xi.weekdaysRegex=function(t){return this._weekdaysParseExact?(u(this,"_weekdaysRegex")||ie.call(this),t?this._weekdaysStrictRegex:this._weekdaysRegex):(u(this,"_weekdaysRegex")||(this._weekdaysRegex=Qt),this._weekdaysStrictRegex&&t?this._weekdaysStrictRegex:this._weekdaysRegex)},xi.weekdaysShortRegex=function(t){return this._weekdaysParseExact?(u(this,"_weekdaysRegex")||ie.call(this),t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(u(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=te),this._weekdaysShortStrictRegex&&t?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},xi.weekdaysMinRegex=function(t){return this._weekdaysParseExact?(u(this,"_weekdaysRegex")||ie.call(this),t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(u(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=ee),this._weekdaysMinStrictRegex&&t?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},xi.isPM=function(t){return"p"===(t+"").toLowerCase().charAt(0)},xi.meridiem=function(t,e,i){return t>11?i?"pm":"PM":i?"am":"AM"},fe("en",{dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(t){var e=t%10;return t+(1===k(t%100/10)?"th":1===e?"st":2===e?"nd":3===e?"rd":"th")}}),n.lang=x("moment.lang is deprecated. Use moment.locale instead.",fe),n.langData=x("moment.langData is deprecated. Use moment.localeData instead.",pe);var Ci=Math.abs;function Yi(t,e,i,n){var s=$e(e,i);return t._milliseconds+=n*s._milliseconds,t._days+=n*s._days,t._months+=n*s._months,t._bubble()}function Pi(t){return t<0?Math.floor(t):Math.ceil(t)}function Ei(t){return 4800*t/146097}function Li(t){return 146097*t/4800}function Ii(t){return function(){return this.as(t)}}var Ai=Ii("ms"),Ni=Ii("s"),Ri=Ii("m"),ji=Ii("h"),Fi=Ii("d"),Hi=Ii("w"),Gi=Ii("M"),Wi=Ii("Q"),zi=Ii("y");function Ui(t){return function(){return this.isValid()?this._data[t]:NaN}}var Vi=Ui("milliseconds"),Bi=Ui("seconds"),Xi=Ui("minutes"),qi=Ui("hours"),Zi=Ui("days"),$i=Ui("months"),Ji=Ui("years"),Ki=Math.round,Qi={ss:44,s:45,m:45,h:22,d:26,M:11};function tn(t,e,i,n,s){return s.relativeTime(e||1,!!i,t,n)}var en=Math.abs;function nn(t){return(t>0)-(t<0)||+t}function sn(){if(!this.isValid())return this.localeData().invalidDate();var t,e,i=en(this._milliseconds)/1e3,n=en(this._days),s=en(this._months);t=w(i/60),e=w(t/60),i%=60,t%=60;var r=w(s/12),o=s%=12,a=n,l=e,h=t,u=i?i.toFixed(3).replace(/\.?0+$/,""):"",d=this.asSeconds();if(!d)return"P0D";var c=d<0?"-":"",f=nn(this._months)!==nn(d)?"-":"",m=nn(this._days)!==nn(d)?"-":"",p=nn(this._milliseconds)!==nn(d)?"-":"";return c+"P"+(r?f+r+"Y":"")+(o?f+o+"M":"")+(a?m+a+"D":"")+(l||h||u?"T":"")+(l?p+l+"H":"")+(h?p+h+"M":"")+(u?p+u+"S":"")}var rn=Fe.prototype;return rn.isValid=function(){return this._isValid},rn.abs=function(){var t=this._data;return this._milliseconds=Ci(this._milliseconds),this._days=Ci(this._days),this._months=Ci(this._months),t.milliseconds=Ci(t.milliseconds),t.seconds=Ci(t.seconds),t.minutes=Ci(t.minutes),t.hours=Ci(t.hours),t.months=Ci(t.months),t.years=Ci(t.years),this},rn.add=function(t,e){return Yi(this,t,e,1)},rn.subtract=function(t,e){return Yi(this,t,e,-1)},rn.as=function(t){if(!this.isValid())return NaN;var e,i,n=this._milliseconds;if("month"===(t=I(t))||"quarter"===t||"year"===t)switch(e=this._days+n/864e5,i=this._months+Ei(e),t){case"month":return i;case"quarter":return i/3;case"year":return i/12}else switch(e=this._days+Math.round(Li(this._months)),t){case"week":return e/7+n/6048e5;case"day":return e+n/864e5;case"hour":return 24*e+n/36e5;case"minute":return 1440*e+n/6e4;case"second":return 86400*e+n/1e3;case"millisecond":return Math.floor(864e5*e)+n;default:throw new Error("Unknown unit "+t)}},rn.asMilliseconds=Ai,rn.asSeconds=Ni,rn.asMinutes=Ri,rn.asHours=ji,rn.asDays=Fi,rn.asWeeks=Hi,rn.asMonths=Gi,rn.asQuarters=Wi,rn.asYears=zi,rn.valueOf=function(){return this.isValid()?this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*k(this._months/12):NaN},rn._bubble=function(){var t,e,i,n,s,r=this._milliseconds,o=this._days,a=this._months,l=this._data;return r>=0&&o>=0&&a>=0||r<=0&&o<=0&&a<=0||(r+=864e5*Pi(Li(a)+o),o=0,a=0),l.milliseconds=r%1e3,t=w(r/1e3),l.seconds=t%60,e=w(t/60),l.minutes=e%60,i=w(e/60),l.hours=i%24,o+=w(i/24),s=w(Ei(o)),a+=s,o-=Pi(Li(s)),n=w(a/12),a%=12,l.days=o,l.months=a,l.years=n,this},rn.clone=function(){return $e(this)},rn.get=function(t){return t=I(t),this.isValid()?this[t+"s"]():NaN},rn.milliseconds=Vi,rn.seconds=Bi,rn.minutes=Xi,rn.hours=qi,rn.days=Zi,rn.weeks=function(){return w(this.days()/7)},rn.months=$i,rn.years=Ji,rn.humanize=function(t){if(!this.isValid())return this.localeData().invalidDate();var e=this.localeData(),i=function(t,e,i){var n=$e(t).abs(),s=Ki(n.as("s")),r=Ki(n.as("m")),o=Ki(n.as("h")),a=Ki(n.as("d")),l=Ki(n.as("M")),h=Ki(n.as("y")),u=s<=Qi.ss&&["s",s]||s<Qi.s&&["ss",s]||r<=1&&["m"]||r<Qi.m&&["mm",r]||o<=1&&["h"]||o<Qi.h&&["hh",o]||a<=1&&["d"]||a<Qi.d&&["dd",a]||l<=1&&["M"]||l<Qi.M&&["MM",l]||h<=1&&["y"]||["yy",h];return u[2]=e,u[3]=+t>0,u[4]=i,tn.apply(null,u)}(this,!t,e);return t&&(i=e.pastFuture(+this,i)),e.postformat(i)},rn.toISOString=sn,rn.toString=sn,rn.toJSON=sn,rn.locale=si,rn.localeData=oi,rn.toIsoString=x("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",sn),rn.lang=ri,z("X",0,0,"unix"),z("x",0,0,"valueOf"),ht("x",st),ht("X",/[+-]?\d+(\.\d{1,3})?/),ft("X",(function(t,e,i){i._d=new Date(1e3*parseFloat(t,10))})),ft("x",(function(t,e,i){i._d=new Date(k(t))})),n.version="2.24.0",e=Ie,n.fn=Di,n.min=function(){return Re("isBefore",[].slice.call(arguments,0))},n.max=function(){return Re("isAfter",[].slice.call(arguments,0))},n.now=function(){return Date.now?Date.now():+new Date},n.utc=c,n.unix=function(t){return Ie(1e3*t)},n.months=function(t,e){return Ti(t,e,"months")},n.isDate=l,n.locale=fe,n.invalid=p,n.duration=$e,n.isMoment=b,n.weekdays=function(t,e,i){return Oi(t,e,i,"weekdays")},n.parseZone=function(){return Ie.apply(null,arguments).parseZone()},n.localeData=pe,n.isDuration=He,n.monthsShort=function(t,e){return Ti(t,e,"monthsShort")},n.weekdaysMin=function(t,e,i){return Oi(t,e,i,"weekdaysMin")},n.defineLocale=me,n.updateLocale=function(t,e){if(null!=e){var i,n,s=le;null!=(n=ce(t))&&(s=n._config),e=Y(s,e),(i=new P(e)).parentLocale=he[t],he[t]=i,fe(t)}else null!=he[t]&&(null!=he[t].parentLocale?he[t]=he[t].parentLocale:null!=he[t]&&delete he[t]);return he[t]},n.locales=function(){return M(he)},n.weekdaysShort=function(t,e,i){return Oi(t,e,i,"weekdaysShort")},n.normalizeUnits=I,n.relativeTimeRounding=function(t){return void 0===t?Ki:"function"==typeof t&&(Ki=t,!0)},n.relativeTimeThreshold=function(t,e){return void 0!==Qi[t]&&(void 0===e?Qi[t]:(Qi[t]=e,"s"===t&&(Qi.ss=e-1),!0))},n.calendarFormat=function(t,e){var i=t.diff(e,"days",!0);return i<-6?"sameElse":i<-1?"lastWeek":i<0?"lastDay":i<1?"sameDay":i<2?"nextDay":i<7?"nextWeek":"sameElse"},n.prototype=Di,n.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},n}()})),Hr="undefined"!=typeof window&&window.moment||Fr,Gr=Ss;ji({target:"Object",stat:!0,forced:!Ge,sham:!Ge},{defineProperties:dn});var Wr=Le((function(t){var e=Li.Object,i=t.exports=function(t,i){return e.defineProperties(t,i)};e.defineProperties.sham&&(i.sham=!0)})),zr=fn("Reflect","ownKeys")||function(t){var e=zs.f(Xe(t)),i=qs.f;return i?e.concat(i(t)):e};ji({target:"Object",stat:!0,sham:!Ge},{getOwnPropertyDescriptors:function(t){for(var e,i,n=Ce(t),s=xi.f,r=zr(n),o={},a=0;r.length>a;)void 0!==(i=s(n,e=r[a++]))&&Ns(o,e,i);return o}});var Ur=Li.Object.getOwnPropertyDescriptors,Vr=xi.f,Br=De((function(){Vr(1)}));ji({target:"Object",stat:!0,forced:!Ge||Br,sham:!Ge},{getOwnPropertyDescriptor:function(t,e){return Vr(Ce(t),e)}});var Xr=Le((function(t){var e=Li.Object,i=t.exports=function(t,i){return e.getOwnPropertyDescriptor(t,i)};e.getOwnPropertyDescriptor.sham&&(i.sham=!0)})),qr=Li.Object.getOwnPropertySymbols,Zr=De((function(){un(1)}));ji({target:"Object",stat:!0,forced:Zr},{keys:function(t){return un(Fi(t))}});var $r=Li.Object.keys;var Jr=function(t,e,i){return e in t?xs(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t};function Kr(t,e){var i=$r(t);if(qr){var n=qr(t);e&&(n=ls(n).call(n,(function(e){return Xr(t,e).enumerable}))),i.push.apply(i,n)}return i}var Qr=/^\/?Date\((-?\d+)/i;var to=function(t){for(var e=1;e<arguments.length;e++){var i,n=null!=arguments[e]?arguments[e]:{};if(e%2)is(i=Kr(n,!0)).call(i,(function(e){Jr(t,e,n[e])}));else if(Ur)Wr(t,Ur(n));else{var s;is(s=Kr(n)).call(s,(function(e){Gr(t,e,Xr(n,e))}))}}return t}({},St,{convert:function(t,e){var i;if(void 0!==t){if(null===t)return null;if(!e)return t;if("string"!=typeof e&&!(e instanceof String))throw new Error("Type must be a string");switch(e){case"boolean":case"Boolean":return Boolean(t);case"number":case"Number":return D(t)&&!isNaN(Date.parse(t))?Fr(t).valueOf():Number(t.valueOf());case"string":case"String":return String(t);case"Date":if(w(t))return new Date(t);if(t instanceof Date)return new Date(t.valueOf());if(Fr.isMoment(t))return new Date(t.valueOf());if(D(t))return(i=Qr.exec(t))?new Date(Number(i[1])):Fr(new Date(t)).toDate();throw new Error("Cannot convert object of type "+N(t)+" to type Date");case"Moment":if(w(t))return Fr(t);if(t instanceof Date)return Fr(t.valueOf());if(Fr.isMoment(t))return Fr(t);if(D(t))return i=Qr.exec(t),Fr(i?Number(i[1]):t);throw new Error("Cannot convert object of type "+N(t)+" to type Date");case"ISODate":if(w(t))return new Date(t);if(t instanceof Date)return t.toISOString();if(Fr.isMoment(t))return t.toDate().toISOString();if(D(t))return(i=Qr.exec(t))?new Date(Number(i[1])).toISOString():Fr(t).format();throw new Error("Cannot convert object of type "+N(t)+" to type ISODate");case"ASPDate":if(w(t))return"/Date("+t+")/";if(t instanceof Date||Fr.isMoment(t))return"/Date("+t.valueOf()+")/";if(D(t))return"/Date("+((i=Qr.exec(t))?new Date(Number(i[1])).valueOf():new Date(t).valueOf())+")/";throw new Error("Cannot convert object of type "+N(t)+" to type ASPDate");default:throw new Error("Unknown type ".concat(e))}}}}),eo="\t\n\v\f\r \u2028\u2029\ufeff",io="["+eo+"]",no=RegExp("^"+io+io+"*"),so=RegExp(io+io+"*$"),ro=function(t){return function(e){var i=String(Oe(e));return 1&t&&(i=i.replace(no,"")),2&t&&(i=i.replace(so,"")),i}},oo={start:ro(1),end:ro(2),trim:ro(3)},ao=oo.trim,lo=He.parseFloat,ho=1/lo(eo+"-0")!=-1/0?function(t){var e=ao(String(t)),i=lo(e);return 0===i&&"-"==e.charAt(0)?-0:i}:lo;ji({global:!0,forced:parseFloat!=ho},{parseFloat:ho});var uo=Li.parseFloat;ji({target:"Date",stat:!0},{now:function(){return(new Date).getTime()}});var co=Li.Date.now,fo=Li.JSON||(Li.JSON={stringify:JSON.stringify}),mo=function(t){return fo.stringify.apply(fo,arguments)},po=Kn("Array").concat,go=Array.prototype,vo=function(t){var e=t.concat;return t===go||t instanceof Array&&e===go.concat?po:e},yo=function(){function t(e,i){Ds(this,t),this.options=null,this.props=null}return Ts(t,[{key:"setOptions",value:function(t){t&&to.extend(this.options,t)}},{key:"redraw",value:function(){return!1}},{key:"destroy",value:function(){}},{key:"_isResized",value:function(){var t=this.props._previousWidth!==this.props.width||this.props._previousHeight!==this.props.height;return this.props._previousWidth=this.props.width,this.props._previousHeight=this.props.height,t}}]),t}(),_o=[].sort,bo=[1,2,3],wo=De((function(){bo.sort(void 0)})),ko=De((function(){bo.sort(null)})),Do=Zn("sort");ji({target:"Array",proto:!0,forced:wo||!ko||Do},{sort:function(t){return void 0===t?_o.call(Fi(this)):_o.call(Fi(this),Ii(t))}});var So=Kn("Array").sort,xo=Array.prototype,Mo=function(t){var e=t.sort;return t===xo||t instanceof Array&&e===xo.sort?So:e};ji({target:"String",proto:!0},{repeat:"".repeat||function(t){var e=String(Oe(this)),i="",n=Ki(t);if(n<0||n==1/0)throw RangeError("Wrong number of repetitions");for(;n>0;(n>>>=1)&&(e+=e))1&n&&(i+=e);return i}});var To=Kn("String").repeat,Oo=String.prototype,Co=function(t){var e=t.repeat;return"string"==typeof t||t===Oo||t instanceof String&&e===Oo.repeat?To:e};function Yo(t,e,i){if(i&&!ks(i))return Yo(t,e,[i]);if(e.hiddenDates=[],i&&1==ks(i)){for(var n,s=0;s<i.length;s++)if(void 0===Co(i[s])){var r={};r.start=t(i[s].start).toDate().valueOf(),r.end=t(i[s].end).toDate().valueOf(),e.hiddenDates.push(r)}Mo(n=e.hiddenDates).call(n,(function(t,e){return t.start-e.start}))}}function Po(t,e,i){if(i&&!ks(i))return Po(t,e,[i]);if(i&&void 0!==e.domProps.centerContainer.width){Yo(t,e,i);for(var n=t(e.range.start),s=t(e.range.end),r=(e.range.end-e.range.start)/e.domProps.centerContainer.width,o=0;o<i.length;o++)if(void 0!==Co(i[o])){var a=t(i[o].start),l=t(i[o].end);if("Invalid Date"==a._d)throw new Error("Supplied start date is not valid: ".concat(i[o].start));if("Invalid Date"==l._d)throw new Error("Supplied end date is not valid: ".concat(i[o].end));if(l-a>=4*r){var h=0,u=s.clone();switch(Co(i[o])){case"daily":a.day()!=l.day()&&(h=1),a.dayOfYear(n.dayOfYear()),a.year(n.year()),a.subtract(7,"days"),l.dayOfYear(n.dayOfYear()),l.year(n.year()),l.subtract(7-h,"days"),u.add(1,"weeks");break;case"weekly":var d=l.diff(a,"days"),c=a.day();a.date(n.date()),a.month(n.month()),a.year(n.year()),l=a.clone(),a.day(c),l.day(c),l.add(d,"days"),a.subtract(1,"weeks"),l.subtract(1,"weeks"),u.add(1,"weeks");break;case"monthly":a.month()!=l.month()&&(h=1),a.month(n.month()),a.year(n.year()),a.subtract(1,"months"),l.month(n.month()),l.year(n.year()),l.subtract(1,"months"),l.add(h,"months"),u.add(1,"months");break;case"yearly":a.year()!=l.year()&&(h=1),a.year(n.year()),a.subtract(1,"years"),l.year(n.year()),l.subtract(1,"years"),l.add(h,"years"),u.add(1,"years");break;default:return void console.log("Wrong repeat format, allowed are: daily, weekly, monthly, yearly. Given:",Co(i[o]))}for(;a<u;)switch(e.hiddenDates.push({start:a.valueOf(),end:l.valueOf()}),Co(i[o])){case"daily":a.add(1,"days"),l.add(1,"days");break;case"weekly":a.add(1,"weeks"),l.add(1,"weeks");break;case"monthly":a.add(1,"months"),l.add(1,"months");break;case"yearly":a.add(1,"y"),l.add(1,"y");break;default:return void console.log("Wrong repeat format, allowed are: daily, weekly, monthly, yearly. Given:",Co(i[o]))}e.hiddenDates.push({start:a.valueOf(),end:l.valueOf()})}}Eo(e);var f=Wo(e.range.start,e.hiddenDates),m=Wo(e.range.end,e.hiddenDates),p=e.range.start,g=e.range.end;1==f.hidden&&(p=1==e.range.startToFront?f.startDate-1:f.endDate+1),1==m.hidden&&(g=1==e.range.endToFront?m.startDate-1:m.endDate+1),1!=f.hidden&&1!=m.hidden||e.range._applyRange(p,g)}}function Eo(t){for(var e,i=t.hiddenDates,n=[],s=0;s<i.length;s++)for(var r=0;r<i.length;r++)s!=r&&1!=i[r].remove&&1!=i[s].remove&&(i[r].start>=i[s].start&&i[r].end<=i[s].end?i[r].remove=!0:i[r].start>=i[s].start&&i[r].start<=i[s].end?(i[s].end=i[r].end,i[r].remove=!0):i[r].end>=i[s].start&&i[r].end<=i[s].end&&(i[s].start=i[r].start,i[r].remove=!0));for(s=0;s<i.length;s++)!0!==i[s].remove&&n.push(i[s]);t.hiddenDates=n,Mo(e=t.hiddenDates).call(e,(function(t,e){return t.start-e.start}))}function Lo(t,e,i){for(var n=!1,s=e.current.valueOf(),r=0;r<e.hiddenDates.length;r++){var o=e.hiddenDates[r].start,a=e.hiddenDates[r].end;if(s>=o&&s<a){n=!0;break}}if(1==n&&s<e._end.valueOf()&&s!=i){var l=t(i),h=t(a);l.year()!=h.year()?e.switchedYear=!0:l.month()!=h.month()?e.switchedMonth=!0:l.dayOfYear()!=h.dayOfYear()&&(e.switchedDay=!0),e.current=h}}function Io(t,e,i){var n;if(0==t.body.hiddenDates.length)return n=t.range.conversion(i),(e.valueOf()-n.offset)*n.scale;var s=Wo(e,t.body.hiddenDates);1==s.hidden&&(e=s.startDate);var r=No(t.body.hiddenDates,t.range.start,t.range.end);if(e<t.range.start){n=t.range.conversion(i,r);var o=Ro(t.body.hiddenDates,e,n.offset);return e=t.options.moment(e).toDate().valueOf(),e+=o,-(n.offset-e.valueOf())*n.scale}if(e>t.range.end){var a={start:t.range.start,end:e};return e=jo(t.options.moment,t.body.hiddenDates,a,e),n=t.range.conversion(i,r),(e.valueOf()-n.offset)*n.scale}return e=jo(t.options.moment,t.body.hiddenDates,t.range,e),n=t.range.conversion(i,r),(e.valueOf()-n.offset)*n.scale}function Ao(t,e,i){if(0==t.body.hiddenDates.length){var n=t.range.conversion(i);return new Date(e/n.scale+n.offset)}var s=No(t.body.hiddenDates,t.range.start,t.range.end),r=(t.range.end-t.range.start-s)*e/i,o=Ho(t.body.hiddenDates,t.range,r);return new Date(o+r+t.range.start)}function No(t,e,i){for(var n=0,s=0;s<t.length;s++){var r=t[s].start,o=t[s].end;r>=e&&o<i&&(n+=o-r)}return n}function Ro(t,e,i){for(var n=0,s=0;s<t.length;s++){var r=t[s].start,o=t[s].end;r>=e&&o<=i&&(n+=o-r)}return n}function jo(t,e,i,n){return n=t(n).toDate().valueOf(),n-=Fo(t,e,i,n)}function Fo(t,e,i,n){var s=0;n=t(n).toDate().valueOf();for(var r=0;r<e.length;r++){var o=e[r].start,a=e[r].end;o>=i.start&&a<i.end&&n>=a&&(s+=a-o)}return s}function Ho(t,e,i){for(var n=0,s=0,r=e.start,o=0;o<t.length;o++){var a=t[o].start,l=t[o].end;if(a>=e.start&&l<e.end){if(s+=a-r,r=l,s>=i)break;n+=l-a}}return n}function Go(t,e,i,n){var s=Wo(e,t);return 1==s.hidden?i<0?1==n?s.startDate-(s.endDate-e)-1:s.startDate-1:1==n?s.endDate+(e-s.startDate)+1:s.endDate+1:e}function Wo(t,e){for(var i=0;i<e.length;i++){var n=e[i].start,s=e[i].end;if(t>=n&&t<s)return{hidden:!0,startDate:n,endDate:s}}return{hidden:!1,startDate:n,endDate:s}}var zo=Object.freeze({convertHiddenOptions:Yo,updateHiddenDates:Po,removeDuplicates:Eo,printDates:function(t){for(var e=0;e<t.length;e++)console.log(e,new Date(t[e].start),new Date(t[e].end),t[e].start,t[e].end,t[e].remove)},stepOverHiddenDates:Lo,toScreen:Io,toTime:Ao,getHiddenDurationBetween:No,getHiddenDurationBeforeStart:Ro,correctTimeForHidden:jo,getHiddenDurationBefore:Fo,getAccumulatedHiddenDuration:Ho,snapAwayFromHidden:Go,getIsHidden:Wo}),Uo=function(t){function e(t,i){var n,s,r,o,a,l,h,u;Ds(this,e),u=Cr(this,Lr(e).call(this));var d=Hr().hours(0).minutes(0).seconds(0).milliseconds(0),c=d.clone().add(-3,"days").valueOf(),f=d.clone().add(3,"days").valueOf();return u.millisecondsPerPixelCache=void 0,void 0===i?(u.start=c,u.end=f):(u.start=i.start||c,u.end=i.end||f),u.rolling=!1,u.body=t,u.deltaDifference=0,u.scaleOffset=0,u.startToFront=!1,u.endToFront=!0,u.defaultOptions={rtl:!1,start:null,end:null,moment:Hr,direction:"horizontal",moveable:!0,zoomable:!0,min:null,max:null,zoomMin:10,zoomMax:31536e10,rollingMode:{follow:!1,offset:.5}},u.options=to.extend({},u.defaultOptions),u.props={touch:{}},u.animationTimer=null,u.body.emitter.on("panstart",bs(n=u._onDragStart).call(n,Or(u))),u.body.emitter.on("panmove",bs(s=u._onDrag).call(s,Or(u))),u.body.emitter.on("panend",bs(r=u._onDragEnd).call(r,Or(u))),u.body.emitter.on("mousewheel",bs(o=u._onMouseWheel).call(o,Or(u))),u.body.emitter.on("touch",bs(a=u._onTouch).call(a,Or(u))),u.body.emitter.on("pinch",bs(l=u._onPinch).call(l,Or(u))),u.body.dom.rollingModeBtn.addEventListener("click",bs(h=u.startRolling).call(h,Or(u))),u.setOptions(i),u}return jr(e,t),Ts(e,[{key:"setOptions",value:function(t){if(t){to.selectiveExtend(["animation","direction","min","max","zoomMin","zoomMax","moveable","zoomable","moment","activate","hiddenDates","zoomKey","zoomFriction","rtl","showCurrentTime","rollingMode","horizontalScroll"],this.options,t),t.rollingMode&&t.rollingMode.follow&&this.startRolling(),("start"in t||"end"in t)&&this.setRange(t.start,t.end)}}},{key:"startRolling",value:function(){var t=this;!function e(){t.stopRolling(),t.rolling=!0;var i=t.end-t.start,n=to.convert(new Date,"Date").valueOf(),s=t.options.rollingMode&&t.options.rollingMode.offset||.5,r=n-i*s,o=n+i*(1-s);t.setRange(r,o,{animation:!1}),(i=1/t.conversion(t.body.domProps.center.width).scale/10)<30&&(i=30),i>1e3&&(i=1e3),t.body.dom.rollingModeBtn.style.visibility="hidden",t.currentTimeTimer=fs(e,i)}()}},{key:"stopRolling",value:function(){void 0!==this.currentTimeTimer&&(clearTimeout(this.currentTimeTimer),this.rolling=!1,this.body.dom.rollingModeBtn.style.visibility="visible")}},{key:"setRange",value:function(t,e,i,n,s){i||(i={}),!0!==i.byUser&&(i.byUser=!1);var r=this,o=null!=t?to.convert(t,"Date").valueOf():null,a=null!=e?to.convert(e,"Date").valueOf():null;if(this._cancelAnimation(),this.millisecondsPerPixelCache=void 0,i.animation){var l,h=this.start,u=this.end,d="object"===Tr(i.animation)&&"duration"in i.animation?i.animation.duration:500,c="object"===Tr(i.animation)&&"easingFunction"in i.animation?i.animation.easingFunction:"easeInOutQuad",f=to.easingFunctions[c];if(!f)throw new Error(vo(l="Unknown easing function ".concat(mo(c),". Choose from: ")).call(l,$r(to.easingFunctions).join(", ")));var m=co(),p=!1;return function t(){if(!r.props.touch.dragging){var e=co()-m,l=f(e/d),c=e>d,v=c||null===o?o:h+(o-h)*l,y=c||null===a?a:u+(a-u)*l;g=r._applyRange(v,y),Po(r.options.moment,r.body,r.options.hiddenDates),p=p||g;var _={start:new Date(r.start),end:new Date(r.end),byUser:i.byUser,event:i.event};if(s&&s(l,g,c),g&&r.body.emitter.emit("rangechange",_),c){if(p&&(r.body.emitter.emit("rangechanged",_),n))return n()}else r.animationTimer=fs(t,20)}}()}var g=this._applyRange(o,a);if(Po(this.options.moment,this.body,this.options.hiddenDates),g){var v={start:new Date(this.start),end:new Date(this.end),byUser:i.byUser,event:i.event};if(this.body.emitter.emit("rangechange",v),clearTimeout(r.timeoutID),r.timeoutID=fs((function(){r.body.emitter.emit("rangechanged",v)}),200),n)return n()}}},{key:"getMillisecondsPerPixel",value:function(){return void 0===this.millisecondsPerPixelCache&&(this.millisecondsPerPixelCache=(this.end-this.start)/this.body.dom.center.clientWidth),this.millisecondsPerPixelCache}},{key:"_cancelAnimation",value:function(){this.animationTimer&&(clearTimeout(this.animationTimer),this.animationTimer=null)}},{key:"_applyRange",value:function(t,e){var i,n=null!=t?to.convert(t,"Date").valueOf():this.start,s=null!=e?to.convert(e,"Date").valueOf():this.end,r=null!=this.options.max?to.convert(this.options.max,"Date").valueOf():null,o=null!=this.options.min?to.convert(this.options.min,"Date").valueOf():null;if(isNaN(n)||null===n)throw new Error('Invalid start "'.concat(t,'"'));if(isNaN(s)||null===s)throw new Error('Invalid end "'.concat(e,'"'));if(s<n&&(s=n),null!==o&&n<o&&(n+=i=o-n,s+=i,null!=r&&s>r&&(s=r)),null!==r&&s>r&&(n-=i=s-r,s-=i,null!=o&&n<o&&(n=o)),null!==this.options.zoomMin){var a=uo(this.options.zoomMin);if(a<0&&(a=0),s-n<a){this.end-this.start===a&&n>=this.start-.5&&s<=this.end?(n=this.start,s=this.end):(n-=(i=a-(s-n))/2,s+=i/2)}}if(null!==this.options.zoomMax){var l=uo(this.options.zoomMax);l<0&&(l=0),s-n>l&&(this.end-this.start===l&&n<this.start&&s>this.end?(n=this.start,s=this.end):(n+=(i=s-n-l)/2,s-=i/2))}var h=this.start!=n||this.end!=s;return n>=this.start&&n<=this.end||s>=this.start&&s<=this.end||this.start>=n&&this.start<=s||this.end>=n&&this.end<=s||this.body.emitter.emit("checkRangedItems"),this.start=n,this.end=s,h}},{key:"getRange",value:function(){return{start:this.start,end:this.end}}},{key:"conversion",value:function(t,i){return e.conversion(this.start,this.end,t,i)}},{key:"_onDragStart",value:function(t){this.deltaDifference=0,this.previousDelta=0,this.options.moveable&&this._isInsideRange(t)&&this.props.touch.allowDragging&&(this.stopRolling(),this.props.touch.start=this.start,this.props.touch.end=this.end,this.props.touch.dragging=!0,this.body.dom.root&&(this.body.dom.root.style.cursor="move"))}},{key:"_onDrag",value:function(t){if(t&&this.props.touch.dragging&&this.options.moveable&&this.props.touch.allowDragging){var e=this.options.direction;Vo(e);var i="horizontal"==e?t.deltaX:t.deltaY;i-=this.deltaDifference;var n=this.props.touch.end-this.props.touch.start;n-=No(this.body.hiddenDates,this.start,this.end);var s,r="horizontal"==e?this.body.domProps.center.width:this.body.domProps.center.height;s=this.options.rtl?i/r*n:-i/r*n;var o=this.props.touch.start+s,a=this.props.touch.end+s,l=Go(this.body.hiddenDates,o,this.previousDelta-i,!0),h=Go(this.body.hiddenDates,a,this.previousDelta-i,!0);if(l!=o||h!=a)return this.deltaDifference+=i,this.props.touch.start=l,this.props.touch.end=h,void this._onDrag(t);this.previousDelta=i,this._applyRange(o,a);var u=new Date(this.start),d=new Date(this.end);this.body.emitter.emit("rangechange",{start:u,end:d,byUser:!0,event:t}),this.body.emitter.emit("panmove")}}},{key:"_onDragEnd",value:function(t){this.props.touch.dragging&&this.options.moveable&&this.props.touch.allowDragging&&(this.props.touch.dragging=!1,this.body.dom.root&&(this.body.dom.root.style.cursor="auto"),this.body.emitter.emit("rangechanged",{start:new Date(this.start),end:new Date(this.end),byUser:!0,event:t}))}},{key:"_onMouseWheel",value:function(t){var e=0;if(t.wheelDelta?e=t.wheelDelta/120:t.detail?e=-t.detail/3:t.deltaY&&(e=-t.deltaY/3),!(this.options.zoomKey&&!t[this.options.zoomKey]&&this.options.zoomable||!this.options.zoomable&&this.options.moveable)&&this.options.zoomable&&this.options.moveable&&this._isInsideRange(t)&&e){var i,n,s=this.options.zoomFriction||5;if(i=e<0?1-e/s:1/(1+e/s),this.rolling){var r=this.options.rollingMode&&this.options.rollingMode.offset||.5;n=this.start+(this.end-this.start)*r}else{var o=this.getPointer({x:t.clientX,y:t.clientY},this.body.dom.center);n=this._pointerToDate(o)}this.zoom(i,n,e,t),t.preventDefault()}}},{key:"_onTouch",value:function(t){this.props.touch.start=this.start,this.props.touch.end=this.end,this.props.touch.allowDragging=!0,this.props.touch.center=null,this.scaleOffset=0,this.deltaDifference=0,to.preventDefault(t)}},{key:"_onPinch",value:function(t){if(this.options.zoomable&&this.options.moveable){to.preventDefault(t),this.props.touch.allowDragging=!1,this.props.touch.center||(this.props.touch.center=this.getPointer(t.center,this.body.dom.center)),this.stopRolling();var e=1/(t.scale+this.scaleOffset),i=this._pointerToDate(this.props.touch.center),n=No(this.body.hiddenDates,this.start,this.end),s=Fo(this.options.moment,this.body.hiddenDates,this,i),r=n-s,o=i-s+(this.props.touch.start-(i-s))*e,a=i+r+(this.props.touch.end-(i+r))*e;this.startToFront=1-e<=0,this.endToFront=e-1<=0;var l=Go(this.body.hiddenDates,o,1-e,!0),h=Go(this.body.hiddenDates,a,e-1,!0);l==o&&h==a||(this.props.touch.start=l,this.props.touch.end=h,this.scaleOffset=1-t.scale,o=l,a=h);var u={animation:!1,byUser:!0,event:t};this.setRange(o,a,u),this.startToFront=!1,this.endToFront=!0}}},{key:"_isInsideRange",value:function(t){var e=t.center?t.center.x:t.clientX,i=this.body.dom.centerContainer.getBoundingClientRect(),n=this.options.rtl?e-i.left:i.right-e,s=this.body.util.toTime(n);return s>=this.start&&s<=this.end}},{key:"_pointerToDate",value:function(t){var e,i=this.options.direction;if(Vo(i),"horizontal"==i)return this.body.util.toTime(t.x).valueOf();var n=this.body.domProps.center.height;return e=this.conversion(n),t.y/e.scale+e.offset}},{key:"getPointer",value:function(t,e){var i=e.getBoundingClientRect();return this.options.rtl?{x:i.right-t.x,y:t.y-i.top}:{x:t.x-i.left,y:t.y-i.top}}},{key:"zoom",value:function(t,e,i,n){null==e&&(e=(this.start+this.end)/2);var s=No(this.body.hiddenDates,this.start,this.end),r=Fo(this.options.moment,this.body.hiddenDates,this,e),o=s-r,a=e-r+(this.start-(e-r))*t,l=e+o+(this.end-(e+o))*t;this.startToFront=!(i>0),this.endToFront=!(-i>0);var h=Go(this.body.hiddenDates,a,i,!0),u=Go(this.body.hiddenDates,l,-i,!0);h==a&&u==l||(a=h,l=u);var d={animation:!1,byUser:!0,event:n};this.setRange(a,l,d),this.startToFront=!1,this.endToFront=!0}},{key:"move",value:function(t){var e=this.end-this.start,i=this.start+e*t,n=this.end+e*t;this.start=i,this.end=n}},{key:"moveTo",value:function(t){var e=(this.start+this.end)/2-t,i=this.start-e,n=this.end-e;this.setRange(i,n,{animation:!1,byUser:!0,event:null})}}],[{key:"conversion",value:function(t,e,i,n){return void 0===n&&(n=0),0!=i&&e-t!=0?{offset:t,scale:i/(e-t-n)}:{offset:0,scale:1}}}]),e}(yo);function Vo(t){if("horizontal"!=t&&"vertical"!=t)throw new TypeError('Unknown direction "'.concat(t,'". Choose "horizontal" or "vertical".'))}var Bo=Li.setInterval,Xo=qn.some;ji({target:"Array",proto:!0,forced:Zn("some")},{some:function(t){return Xo(this,t,arguments.length>1?arguments[1]:void 0)}});var qo=Kn("Array").some,Zo=Array.prototype,$o=function(t){var e=t.some;return t===Zo||t instanceof Array&&e===Zo.some?qo:e},Jo=Math.max,Ko=Math.min;ji({target:"Array",proto:!0,forced:!ss("splice")},{splice:function(t,e){var i,n,s,r,o,a,l=Fi(this),h=tn(l.length),u=sn(t,h),d=arguments.length;if(0===d?i=n=0:1===d?(i=0,n=h-u):(i=d-2,n=Ko(Jo(Ki(e),0),h-u)),h+i-n>9007199254740991)throw TypeError("Maximum allowed length exceeded");for(s=Vn(l,n),r=0;r<n;r++)(o=u+r)in l&&Ns(s,r,l[o]);if(s.length=n,i<n){for(r=u;r<h-n;r++)a=r+i,(o=r+n)in l?l[a]=l[o]:delete l[a];for(r=h;r>h-n+i;r--)delete l[r-1]}else if(i>n)for(r=h-n;r>u;r--)a=r+i-1,(o=r+n-1)in l?l[a]=l[o]:delete l[a];for(r=0;r<i;r++)l[r+u]=arguments[r+2];return l.length=h-n+i,s}});var Qo=Kn("Array").splice,ta=Array.prototype,ea=function(t){var e=t.splice;return t===ta||t instanceof Array&&e===ta.splice?Qo:e},ia=on.indexOf,na=[].indexOf,sa=!!na&&1/[1].indexOf(1,-0)<0,ra=Zn("indexOf");ji({target:"Array",proto:!0,forced:sa||ra},{indexOf:function(t){return sa?na.apply(this,arguments)||0:ia(this,t,arguments.length>1?arguments[1]:void 0)}});var oa=Kn("Array").indexOf,aa=Array.prototype,la=function(t){var e=t.indexOf;return t===aa||t instanceof Array&&e===aa.indexOf?oa:e},ha=ua;function ua(t){if(t)return function(t){for(var e in ua.prototype)t[e]=ua.prototype[e];return t}(t)}ua.prototype.on=ua.prototype.addEventListener=function(t,e){return this._callbacks=this._callbacks||{},(this._callbacks[t]=this._callbacks[t]||[]).push(e),this},ua.prototype.once=function(t,e){var i=this;function n(){i.off(t,n),e.apply(this,arguments)}return this._callbacks=this._callbacks||{},n.fn=e,this.on(t,n),this},ua.prototype.off=ua.prototype.removeListener=ua.prototype.removeAllListeners=ua.prototype.removeEventListener=function(t,e){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var i,n=this._callbacks[t];if(!n)return this;if(1==arguments.length)return delete this._callbacks[t],this;for(var s=0;s<n.length;s++)if((i=n[s])===e||i.fn===e){n.splice(s,1);break}return this},ua.prototype.emit=function(t){this._callbacks=this._callbacks||{};var e=[].slice.call(arguments,1),i=this._callbacks[t];if(i)for(var n=0,s=(i=i.slice(0)).length;n<s;++n)i[n].apply(this,e);return this},ua.prototype.listeners=function(t){return this._callbacks=this._callbacks||{},this._callbacks[t]||[]},ua.prototype.hasListeners=function(t){return!!this.listeners(t).length};var da=Le((function(t,e){var i;t.exports=(i=null,function t(e,n){var s=n||{preventDefault:!1};if(e.Manager){var r=e,o=function(e,i){var n=Object.create(s);return i&&r.assign(n,i),t(new r(e,n),n)};return r.assign(o,r),o.Manager=function(e,i){var n=Object.create(s);return i&&r.assign(n,i),t(new r.Manager(e,n),n)},o}var a=Object.create(e),l=e.element;function h(t){return t.match(/[^ ]+/g)}function u(t){if("hammer.input"!==t.type){if(t.srcEvent._handled||(t.srcEvent._handled={}),t.srcEvent._handled[t.type])return;t.srcEvent._handled[t.type]=!0}var e=!1;t.stopPropagation=function(){e=!0};var n=t.srcEvent.stopPropagation.bind(t.srcEvent);"function"==typeof n&&(t.srcEvent.stopPropagation=function(){n(),t.stopPropagation()}),t.firstTarget=i;for(var s=i;s&&!e;){var r=s.hammer;if(r)for(var o,a=0;a<r.length;a++)if(o=r[a]._handlers[t.type])for(var l=0;l<o.length&&!e;l++)o[l](t);s=s.parentNode}}return l.hammer||(l.hammer=[]),l.hammer.push(a),e.on("hammer.input",(function(t){!0!==s.preventDefault&&s.preventDefault!==t.pointerType||t.preventDefault(),t.isFirst&&(i=t.target)})),a._handlers={},a.on=function(t,i){return h(t).forEach((function(t){var n=a._handlers[t];n||(a._handlers[t]=n=[],e.on(t,u)),n.push(i)})),a},a.off=function(t,i){return h(t).forEach((function(t){var n=a._handlers[t];n&&((n=i?n.filter((function(t){return t!==i})):[]).length>0?a._handlers[t]=n:(e.off(t,u),delete a._handlers[t]))})),a},a.emit=function(t,n){i=n.target,e.emit(t,n)},a.destroy=function(){var t=e.element.hammer,i=t.indexOf(a);-1!==i&&t.splice(i,1),t.length||delete e.element.hammer,a._handlers={},e.destroy()},a})}));function ca(){return(ca=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var i=arguments[e];for(var n in i)Object.prototype.hasOwnProperty.call(i,n)&&(t[n]=i[n])}return t}).apply(this,arguments)}function fa(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,t.__proto__=e}function ma(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}var pa,ga="function"!=typeof Object.assign?function(t){if(null==t)throw new TypeError("Cannot convert undefined or null to object");for(var e=Object(t),i=1;i<arguments.length;i++){var n=arguments[i];if(null!=n)for(var s in n)n.hasOwnProperty(s)&&(e[s]=n[s])}return e}:Object.assign,va=["","webkit","Moz","MS","ms","o"],ya="undefined"==typeof document?{style:{}}:document.createElement("div"),_a="function",ba=Math.round,wa=Math.abs,ka=Date.now;function Da(t,e){for(var i,n,s=e[0].toUpperCase()+e.slice(1),r=0;r<va.length;){if((n=(i=va[r])?i+s:e)in t)return n;r++}}pa="undefined"==typeof window?{}:window;var Sa=Da(ya.style,"touchAction"),xa=void 0!==Sa;var Ma="auto",Ta="manipulation",Oa="none",Ca="pan-x",Ya="pan-y",Pa=function(){if(!xa)return!1;var t={},e=pa.CSS&&pa.CSS.supports;return["auto","manipulation","pan-y","pan-x","pan-x pan-y","none"].forEach((function(i){return t[i]=!e||pa.CSS.supports("touch-action",i)})),t}(),Ea="ontouchstart"in pa,La=void 0!==Da(pa,"PointerEvent"),Ia=Ea&&/mobile|tablet|ip(ad|hone|od)|android/i.test(navigator.userAgent),Aa="touch",Na="mouse",Ra=25,ja=1,Fa=2,Ha=4,Ga=8,Wa=1,za=2,Ua=4,Va=8,Ba=16,Xa=za|Ua,qa=Va|Ba,Za=Xa|qa,$a=["x","y"],Ja=["clientX","clientY"];function Ka(t,e,i){var n;if(t)if(t.forEach)t.forEach(e,i);else if(void 0!==t.length)for(n=0;n<t.length;)e.call(i,t[n],n,t),n++;else for(n in t)t.hasOwnProperty(n)&&e.call(i,t[n],n,t)}function Qa(t,e){return typeof t===_a?t.apply(e&&e[0]||void 0,e):t}function tl(t,e){return t.indexOf(e)>-1}var el=function(){function t(t,e){this.manager=t,this.set(e)}var e=t.prototype;return e.set=function(t){"compute"===t&&(t=this.compute()),xa&&this.manager.element.style&&Pa[t]&&(this.manager.element.style[Sa]=t),this.actions=t.toLowerCase().trim()},e.update=function(){this.set(this.manager.options.touchAction)},e.compute=function(){var t=[];return Ka(this.manager.recognizers,(function(e){Qa(e.options.enable,[e])&&(t=t.concat(e.getTouchAction()))})),function(t){if(tl(t,Oa))return Oa;var e=tl(t,Ca),i=tl(t,Ya);return e&&i?Oa:e||i?e?Ca:Ya:tl(t,Ta)?Ta:Ma}(t.join(" "))},e.preventDefaults=function(t){var e=t.srcEvent,i=t.offsetDirection;if(this.manager.session.prevented)e.preventDefault();else{var n=this.actions,s=tl(n,Oa)&&!Pa[Oa],r=tl(n,Ya)&&!Pa[Ya],o=tl(n,Ca)&&!Pa[Ca];if(s){var a=1===t.pointers.length,l=t.distance<2,h=t.deltaTime<250;if(a&&l&&h)return}if(!o||!r)return s||r&&i&Xa||o&&i&qa?this.preventSrc(e):void 0}},e.preventSrc=function(t){this.manager.session.prevented=!0,t.preventDefault()},t}();function il(t,e){for(;t;){if(t===e)return!0;t=t.parentNode}return!1}function nl(t){var e=t.length;if(1===e)return{x:ba(t[0].clientX),y:ba(t[0].clientY)};for(var i=0,n=0,s=0;s<e;)i+=t[s].clientX,n+=t[s].clientY,s++;return{x:ba(i/e),y:ba(n/e)}}function sl(t){for(var e=[],i=0;i<t.pointers.length;)e[i]={clientX:ba(t.pointers[i].clientX),clientY:ba(t.pointers[i].clientY)},i++;return{timeStamp:ka(),pointers:e,center:nl(e),deltaX:t.deltaX,deltaY:t.deltaY}}function rl(t,e,i){i||(i=$a);var n=e[i[0]]-t[i[0]],s=e[i[1]]-t[i[1]];return Math.sqrt(n*n+s*s)}function ol(t,e,i){i||(i=$a);var n=e[i[0]]-t[i[0]],s=e[i[1]]-t[i[1]];return 180*Math.atan2(s,n)/Math.PI}function al(t,e){return t===e?Wa:wa(t)>=wa(e)?t<0?za:Ua:e<0?Va:Ba}function ll(t,e,i){return{x:e/t||0,y:i/t||0}}function hl(t,e){var i=t.session,n=e.pointers,s=n.length;i.firstInput||(i.firstInput=sl(e)),s>1&&!i.firstMultiple?i.firstMultiple=sl(e):1===s&&(i.firstMultiple=!1);var r=i.firstInput,o=i.firstMultiple,a=o?o.center:r.center,l=e.center=nl(n);e.timeStamp=ka(),e.deltaTime=e.timeStamp-r.timeStamp,e.angle=ol(a,l),e.distance=rl(a,l),function(t,e){var i=e.center,n=t.offsetDelta||{},s=t.prevDelta||{},r=t.prevInput||{};e.eventType!==ja&&r.eventType!==Ha||(s=t.prevDelta={x:r.deltaX||0,y:r.deltaY||0},n=t.offsetDelta={x:i.x,y:i.y}),e.deltaX=s.x+(i.x-n.x),e.deltaY=s.y+(i.y-n.y)}(i,e),e.offsetDirection=al(e.deltaX,e.deltaY);var h,u,d=ll(e.deltaTime,e.deltaX,e.deltaY);e.overallVelocityX=d.x,e.overallVelocityY=d.y,e.overallVelocity=wa(d.x)>wa(d.y)?d.x:d.y,e.scale=o?(h=o.pointers,rl((u=n)[0],u[1],Ja)/rl(h[0],h[1],Ja)):1,e.rotation=o?function(t,e){return ol(e[1],e[0],Ja)+ol(t[1],t[0],Ja)}(o.pointers,n):0,e.maxPointers=i.prevInput?e.pointers.length>i.prevInput.maxPointers?e.pointers.length:i.prevInput.maxPointers:e.pointers.length,function(t,e){var i,n,s,r,o=t.lastInterval||e,a=e.timeStamp-o.timeStamp;if(e.eventType!==Ga&&(a>Ra||void 0===o.velocity)){var l=e.deltaX-o.deltaX,h=e.deltaY-o.deltaY,u=ll(a,l,h);n=u.x,s=u.y,i=wa(u.x)>wa(u.y)?u.x:u.y,r=al(l,h),t.lastInterval=e}else i=o.velocity,n=o.velocityX,s=o.velocityY,r=o.direction;e.velocity=i,e.velocityX=n,e.velocityY=s,e.direction=r}(i,e);var c,f=t.element,m=e.srcEvent;il(c=m.composedPath?m.composedPath()[0]:m.path?m.path[0]:m.target,f)&&(f=c),e.target=f}function ul(t,e,i){var n=i.pointers.length,s=i.changedPointers.length,r=e&ja&&n-s==0,o=e&(Ha|Ga)&&n-s==0;i.isFirst=!!r,i.isFinal=!!o,r&&(t.session={}),i.eventType=e,hl(t,i),t.emit("hammer.input",i),t.recognize(i),t.session.prevInput=i}function dl(t){return t.trim().split(/\s+/g)}function cl(t,e,i){Ka(dl(e),(function(e){t.addEventListener(e,i,!1)}))}function fl(t,e,i){Ka(dl(e),(function(e){t.removeEventListener(e,i,!1)}))}function ml(t){var e=t.ownerDocument||t;return e.defaultView||e.parentWindow||window}var pl=function(){function t(t,e){var i=this;this.manager=t,this.callback=e,this.element=t.element,this.target=t.options.inputTarget,this.domHandler=function(e){Qa(t.options.enable,[t])&&i.handler(e)},this.init()}var e=t.prototype;return e.handler=function(){},e.init=function(){this.evEl&&cl(this.element,this.evEl,this.domHandler),this.evTarget&&cl(this.target,this.evTarget,this.domHandler),this.evWin&&cl(ml(this.element),this.evWin,this.domHandler)},e.destroy=function(){this.evEl&&fl(this.element,this.evEl,this.domHandler),this.evTarget&&fl(this.target,this.evTarget,this.domHandler),this.evWin&&fl(ml(this.element),this.evWin,this.domHandler)},t}();function gl(t,e,i){if(t.indexOf&&!i)return t.indexOf(e);for(var n=0;n<t.length;){if(i&&t[n][i]==e||!i&&t[n]===e)return n;n++}return-1}var vl={pointerdown:ja,pointermove:Fa,pointerup:Ha,pointercancel:Ga,pointerout:Ga},yl={2:Aa,3:"pen",4:Na,5:"kinect"},_l="pointerdown",bl="pointermove pointerup pointercancel";pa.MSPointerEvent&&!pa.PointerEvent&&(_l="MSPointerDown",bl="MSPointerMove MSPointerUp MSPointerCancel");var wl=function(t){function e(){var i,n=e.prototype;return n.evEl=_l,n.evWin=bl,(i=t.apply(this,arguments)||this).store=i.manager.session.pointerEvents=[],i}return fa(e,t),e.prototype.handler=function(t){var e=this.store,i=!1,n=t.type.toLowerCase().replace("ms",""),s=vl[n],r=yl[t.pointerType]||t.pointerType,o=r===Aa,a=gl(e,t.pointerId,"pointerId");s&ja&&(0===t.button||o)?a<0&&(e.push(t),a=e.length-1):s&(Ha|Ga)&&(i=!0),a<0||(e[a]=t,this.callback(this.manager,s,{pointers:e,changedPointers:[t],pointerType:r,srcEvent:t}),i&&e.splice(a,1))},e}(pl);function kl(t){return Array.prototype.slice.call(t,0)}function Dl(t,e,i){for(var n=[],s=[],r=0;r<t.length;){var o=e?t[r][e]:t[r];gl(s,o)<0&&n.push(t[r]),s[r]=o,r++}return i&&(n=e?n.sort((function(t,i){return t[e]>i[e]})):n.sort()),n}var Sl={touchstart:ja,touchmove:Fa,touchend:Ha,touchcancel:Ga},xl="touchstart touchmove touchend touchcancel",Ml=function(t){function e(){var i;return e.prototype.evTarget=xl,(i=t.apply(this,arguments)||this).targetIds={},i}return fa(e,t),e.prototype.handler=function(t){var e=Sl[t.type],i=Tl.call(this,t,e);i&&this.callback(this.manager,e,{pointers:i[0],changedPointers:i[1],pointerType:Aa,srcEvent:t})},e}(pl);function Tl(t,e){var i,n,s=kl(t.touches),r=this.targetIds;if(e&(ja|Fa)&&1===s.length)return r[s[0].identifier]=!0,[s,s];var o=kl(t.changedTouches),a=[],l=this.target;if(n=s.filter((function(t){return il(t.target,l)})),e===ja)for(i=0;i<n.length;)r[n[i].identifier]=!0,i++;for(i=0;i<o.length;)r[o[i].identifier]&&a.push(o[i]),e&(Ha|Ga)&&delete r[o[i].identifier],i++;return a.length?[Dl(n.concat(a),"identifier",!0),a]:void 0}var Ol={mousedown:ja,mousemove:Fa,mouseup:Ha},Cl="mousedown",Yl="mousemove mouseup",Pl=function(t){function e(){var i,n=e.prototype;return n.evEl=Cl,n.evWin=Yl,(i=t.apply(this,arguments)||this).pressed=!1,i}return fa(e,t),e.prototype.handler=function(t){var e=Ol[t.type];e&ja&&0===t.button&&(this.pressed=!0),e&Fa&&1!==t.which&&(e=Ha),this.pressed&&(e&Ha&&(this.pressed=!1),this.callback(this.manager,e,{pointers:[t],changedPointers:[t],pointerType:Na,srcEvent:t}))},e}(pl),El=2500,Ll=25;function Il(t){var e=t.changedPointers[0];if(e.identifier===this.primaryTouch){var i={x:e.clientX,y:e.clientY},n=this.lastTouches;this.lastTouches.push(i);setTimeout((function(){var t=n.indexOf(i);t>-1&&n.splice(t,1)}),El)}}function Al(t,e){t&ja?(this.primaryTouch=e.changedPointers[0].identifier,Il.call(this,e)):t&(Ha|Ga)&&Il.call(this,e)}function Nl(t){for(var e=t.srcEvent.clientX,i=t.srcEvent.clientY,n=0;n<this.lastTouches.length;n++){var s=this.lastTouches[n],r=Math.abs(e-s.x),o=Math.abs(i-s.y);if(r<=Ll&&o<=Ll)return!0}return!1}var Rl=function(){return function(t){function e(e,i){var n;return(n=t.call(this,e,i)||this).handler=function(t,e,i){var s=i.pointerType===Aa,r=i.pointerType===Na;if(!(r&&i.sourceCapabilities&&i.sourceCapabilities.firesTouchEvents)){if(s)Al.call(ma(ma(n)),e,i);else if(r&&Nl.call(ma(ma(n)),i))return;n.callback(t,e,i)}},n.touch=new Ml(n.manager,n.handler),n.mouse=new Pl(n.manager,n.handler),n.primaryTouch=null,n.lastTouches=[],n}return fa(e,t),e.prototype.destroy=function(){this.touch.destroy(),this.mouse.destroy()},e}(pl)}();function jl(t,e,i){return!!Array.isArray(t)&&(Ka(t,i[e],i),!0)}var Fl=1,Hl=2,Gl=4,Wl=8,zl=Wl,Ul=16,Vl=1;function Bl(t,e){var i=e.manager;return i?i.get(t):t}function Xl(t){return t&Ul?"cancel":t&Wl?"end":t&Gl?"move":t&Hl?"start":""}var ql=function(){function t(t){void 0===t&&(t={}),this.options=ca({enable:!0},t),this.id=Vl++,this.manager=null,this.state=Fl,this.simultaneous={},this.requireFail=[]}var e=t.prototype;return e.set=function(t){return ga(this.options,t),this.manager&&this.manager.touchAction.update(),this},e.recognizeWith=function(t){if(jl(t,"recognizeWith",this))return this;var e=this.simultaneous;return e[(t=Bl(t,this)).id]||(e[t.id]=t,t.recognizeWith(this)),this},e.dropRecognizeWith=function(t){return jl(t,"dropRecognizeWith",this)?this:(t=Bl(t,this),delete this.simultaneous[t.id],this)},e.requireFailure=function(t){if(jl(t,"requireFailure",this))return this;var e=this.requireFail;return-1===gl(e,t=Bl(t,this))&&(e.push(t),t.requireFailure(this)),this},e.dropRequireFailure=function(t){if(jl(t,"dropRequireFailure",this))return this;t=Bl(t,this);var e=gl(this.requireFail,t);return e>-1&&this.requireFail.splice(e,1),this},e.hasRequireFailures=function(){return this.requireFail.length>0},e.canRecognizeWith=function(t){return!!this.simultaneous[t.id]},e.emit=function(t){var e=this,i=this.state;function n(i){e.manager.emit(i,t)}i<Wl&&n(e.options.event+Xl(i)),n(e.options.event),t.additionalEvent&&n(t.additionalEvent),i>=Wl&&n(e.options.event+Xl(i))},e.tryEmit=function(t){if(this.canEmit())return this.emit(t);this.state=32},e.canEmit=function(){for(var t=0;t<this.requireFail.length;){if(!(this.requireFail[t].state&(32|Fl)))return!1;t++}return!0},e.recognize=function(t){var e=ga({},t);if(!Qa(this.options.enable,[this,e]))return this.reset(),void(this.state=32);this.state&(zl|Ul|32)&&(this.state=Fl),this.state=this.process(e),this.state&(Hl|Gl|Wl|Ul)&&this.tryEmit(e)},e.process=function(t){},e.getTouchAction=function(){},e.reset=function(){},t}(),Zl=function(t){function e(e){var i;return void 0===e&&(e={}),(i=t.call(this,ca({event:"tap",pointers:1,taps:1,interval:300,time:250,threshold:9,posThreshold:10},e))||this).pTime=!1,i.pCenter=!1,i._timer=null,i._input=null,i.count=0,i}fa(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Ta]},i.process=function(t){var e=this,i=this.options,n=t.pointers.length===i.pointers,s=t.distance<i.threshold,r=t.deltaTime<i.time;if(this.reset(),t.eventType&ja&&0===this.count)return this.failTimeout();if(s&&r&&n){if(t.eventType!==Ha)return this.failTimeout();var o=!this.pTime||t.timeStamp-this.pTime<i.interval,a=!this.pCenter||rl(this.pCenter,t.center)<i.posThreshold;if(this.pTime=t.timeStamp,this.pCenter=t.center,a&&o?this.count+=1:this.count=1,this._input=t,0===this.count%i.taps)return this.hasRequireFailures()?(this._timer=setTimeout((function(){e.state=zl,e.tryEmit()}),i.interval),Hl):zl}return 32},i.failTimeout=function(){var t=this;return this._timer=setTimeout((function(){t.state=32}),this.options.interval),32},i.reset=function(){clearTimeout(this._timer)},i.emit=function(){this.state===zl&&(this._input.tapCount=this.count,this.manager.emit(this.options.event,this._input))},e}(ql),$l=function(t){function e(e){return void 0===e&&(e={}),t.call(this,ca({pointers:1},e))||this}fa(e,t);var i=e.prototype;return i.attrTest=function(t){var e=this.options.pointers;return 0===e||t.pointers.length===e},i.process=function(t){var e=this.state,i=t.eventType,n=e&(Hl|Gl),s=this.attrTest(t);return n&&(i&Ga||!s)?e|Ul:n||s?i&Ha?e|Wl:e&Hl?e|Gl:Hl:32},e}(ql);function Jl(t){return t===Ba?"down":t===Va?"up":t===za?"left":t===Ua?"right":""}var Kl=function(t){function e(e){var i;return void 0===e&&(e={}),(i=t.call(this,ca({event:"pan",threshold:10,pointers:1,direction:Za},e))||this).pX=null,i.pY=null,i}fa(e,t);var i=e.prototype;return i.getTouchAction=function(){var t=this.options.direction,e=[];return t&Xa&&e.push(Ya),t&qa&&e.push(Ca),e},i.directionTest=function(t){var e=this.options,i=!0,n=t.distance,s=t.direction,r=t.deltaX,o=t.deltaY;return s&e.direction||(e.direction&Xa?(s=0===r?Wa:r<0?za:Ua,i=r!==this.pX,n=Math.abs(t.deltaX)):(s=0===o?Wa:o<0?Va:Ba,i=o!==this.pY,n=Math.abs(t.deltaY))),t.direction=s,i&&n>e.threshold&&s&e.direction},i.attrTest=function(t){return $l.prototype.attrTest.call(this,t)&&(this.state&Hl||!(this.state&Hl)&&this.directionTest(t))},i.emit=function(e){this.pX=e.deltaX,this.pY=e.deltaY;var i=Jl(e.direction);i&&(e.additionalEvent=this.options.event+i),t.prototype.emit.call(this,e)},e}($l),Ql=function(t){function e(e){return void 0===e&&(e={}),t.call(this,ca({event:"swipe",threshold:10,velocity:.3,direction:Xa|qa,pointers:1},e))||this}fa(e,t);var i=e.prototype;return i.getTouchAction=function(){return Kl.prototype.getTouchAction.call(this)},i.attrTest=function(e){var i,n=this.options.direction;return n&(Xa|qa)?i=e.overallVelocity:n&Xa?i=e.overallVelocityX:n&qa&&(i=e.overallVelocityY),t.prototype.attrTest.call(this,e)&&n&e.offsetDirection&&e.distance>this.options.threshold&&e.maxPointers===this.options.pointers&&wa(i)>this.options.velocity&&e.eventType&Ha},i.emit=function(t){var e=Jl(t.offsetDirection);e&&this.manager.emit(this.options.event+e,t),this.manager.emit(this.options.event,t)},e}($l),th=function(t){function e(e){return void 0===e&&(e={}),t.call(this,ca({event:"pinch",threshold:0,pointers:2},e))||this}fa(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Oa]},i.attrTest=function(e){return t.prototype.attrTest.call(this,e)&&(Math.abs(e.scale-1)>this.options.threshold||this.state&Hl)},i.emit=function(e){if(1!==e.scale){var i=e.scale<1?"in":"out";e.additionalEvent=this.options.event+i}t.prototype.emit.call(this,e)},e}($l),eh=function(t){function e(e){return void 0===e&&(e={}),t.call(this,ca({event:"rotate",threshold:0,pointers:2},e))||this}fa(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Oa]},i.attrTest=function(e){return t.prototype.attrTest.call(this,e)&&(Math.abs(e.rotation)>this.options.threshold||this.state&Hl)},e}($l),ih=function(t){function e(e){var i;return void 0===e&&(e={}),(i=t.call(this,ca({event:"press",pointers:1,time:251,threshold:9},e))||this)._timer=null,i._input=null,i}fa(e,t);var i=e.prototype;return i.getTouchAction=function(){return[Ma]},i.process=function(t){var e=this,i=this.options,n=t.pointers.length===i.pointers,s=t.distance<i.threshold,r=t.deltaTime>i.time;if(this._input=t,!s||!n||t.eventType&(Ha|Ga)&&!r)this.reset();else if(t.eventType&ja)this.reset(),this._timer=setTimeout((function(){e.state=zl,e.tryEmit()}),i.time);else if(t.eventType&Ha)return zl;return 32},i.reset=function(){clearTimeout(this._timer)},i.emit=function(t){this.state===zl&&(t&&t.eventType&Ha?this.manager.emit(this.options.event+"up",t):(this._input.timeStamp=ka(),this.manager.emit(this.options.event,this._input)))},e}(ql),nh={domEvents:!1,touchAction:"compute",enable:!0,inputTarget:null,inputClass:null,cssProps:{userSelect:"none",touchSelect:"none",touchCallout:"none",contentZooming:"none",userDrag:"none",tapHighlightColor:"rgba(0,0,0,0)"}},sh=[[eh,{enable:!1}],[th,{enable:!1},["rotate"]],[Ql,{direction:Xa}],[Kl,{direction:Xa},["swipe"]],[Zl],[Zl,{event:"doubletap",taps:2},["tap"]],[ih]];function rh(t,e){var i,n=t.element;n.style&&(Ka(t.options.cssProps,(function(s,r){i=Da(n.style,r),e?(t.oldCssProps[i]=n.style[i],n.style[i]=s):n.style[i]=t.oldCssProps[i]||""})),e||(t.oldCssProps={}))}var oh=function(){function t(t,e){var i,n=this;this.options=ga({},nh,e||{}),this.options.inputTarget=this.options.inputTarget||t,this.handlers={},this.session={},this.recognizers=[],this.oldCssProps={},this.element=t,this.input=new((i=this).options.inputClass||(La?wl:Ia?Ml:Ea?Rl:Pl))(i,ul),this.touchAction=new el(this,this.options.touchAction),rh(this,!0),Ka(this.options.recognizers,(function(t){var e=n.add(new t[0](t[1]));t[2]&&e.recognizeWith(t[2]),t[3]&&e.requireFailure(t[3])}),this)}var e=t.prototype;return e.set=function(t){return ga(this.options,t),t.touchAction&&this.touchAction.update(),t.inputTarget&&(this.input.destroy(),this.input.target=t.inputTarget,this.input.init()),this},e.stop=function(t){this.session.stopped=t?2:1},e.recognize=function(t){var e=this.session;if(!e.stopped){var i;this.touchAction.preventDefaults(t);var n=this.recognizers,s=e.curRecognizer;(!s||s&&s.state&zl)&&(e.curRecognizer=null,s=null);for(var r=0;r<n.length;)i=n[r],2===e.stopped||s&&i!==s&&!i.canRecognizeWith(s)?i.reset():i.recognize(t),!s&&i.state&(Hl|Gl|Wl)&&(e.curRecognizer=i,s=i),r++}},e.get=function(t){if(t instanceof ql)return t;for(var e=this.recognizers,i=0;i<e.length;i++)if(e[i].options.event===t)return e[i];return null},e.add=function(t){if(jl(t,"add",this))return this;var e=this.get(t.options.event);return e&&this.remove(e),this.recognizers.push(t),t.manager=this,this.touchAction.update(),t},e.remove=function(t){if(jl(t,"remove",this))return this;var e=this.get(t);if(t){var i=this.recognizers,n=gl(i,e);-1!==n&&(i.splice(n,1),this.touchAction.update())}return this},e.on=function(t,e){if(void 0===t||void 0===e)return this;var i=this.handlers;return Ka(dl(t),(function(t){i[t]=i[t]||[],i[t].push(e)})),this},e.off=function(t,e){if(void 0===t)return this;var i=this.handlers;return Ka(dl(t),(function(t){e?i[t]&&i[t].splice(gl(i[t],e),1):delete i[t]})),this},e.emit=function(t,e){this.options.domEvents&&function(t,e){var i=document.createEvent("Event");i.initEvent(t,!0,!0),i.gesture=e,e.target.dispatchEvent(i)}(t,e);var i=this.handlers[t]&&this.handlers[t].slice();if(i&&i.length){e.type=t,e.preventDefault=function(){e.srcEvent.preventDefault()};for(var n=0;n<i.length;)i[n](e),n++}},e.destroy=function(){this.element&&rh(this,!1),this.handlers={},this.session={},this.input.destroy(),this.element=null},t}(),ah={touchstart:ja,touchmove:Fa,touchend:Ha,touchcancel:Ga},lh="touchstart",hh="touchstart touchmove touchend touchcancel",uh=function(t){function e(){var i,n=e.prototype;return n.evTarget=lh,n.evWin=hh,(i=t.apply(this,arguments)||this).started=!1,i}return fa(e,t),e.prototype.handler=function(t){var e=ah[t.type];if(e===ja&&(this.started=!0),this.started){var i=dh.call(this,t,e);e&(Ha|Ga)&&i[0].length-i[1].length==0&&(this.started=!1),this.callback(this.manager,e,{pointers:i[0],changedPointers:i[1],pointerType:Aa,srcEvent:t})}},e}(pl);function dh(t,e){var i=kl(t.touches),n=kl(t.changedTouches);return e&(Ha|Ga)&&(i=Dl(i.concat(n),"identifier",!0)),[i,n]}function ch(t,e,i){var n="DEPRECATED METHOD: "+e+"\n"+i+" AT \n";return function(){var e=new Error("get-stack-trace"),i=e&&e.stack?e.stack.replace(/^[^\(]+?[\n$]/gm,"").replace(/^\s+at\s+/gm,"").replace(/^Object.<anonymous>\s*\(/gm,"{anonymous}()@"):"Unknown Stack Trace",s=window.console&&(window.console.warn||window.console.log);return s&&s.call(window.console,n,i),t.apply(this,arguments)}}var fh=ch((function(t,e,i){for(var n=Object.keys(e),s=0;s<n.length;)(!i||i&&void 0===t[n[s]])&&(t[n[s]]=e[n[s]]),s++;return t}),"extend","Use `assign`."),mh=ch((function(t,e){return fh(t,e,!0)}),"merge","Use `assign`.");function ph(t,e,i){var n,s=e.prototype;(n=t.prototype=Object.create(s)).constructor=t,n._super=s,i&&ga(n,i)}function gh(t,e){return function(){return t.apply(e,arguments)}}var vh,yh=function(){var t=function(t,e){return void 0===e&&(e={}),new oh(t,ca({recognizers:sh.concat()},e))};return t.VERSION="2.0.17-rc",t.DIRECTION_ALL=Za,t.DIRECTION_DOWN=Ba,t.DIRECTION_LEFT=za,t.DIRECTION_RIGHT=Ua,t.DIRECTION_UP=Va,t.DIRECTION_HORIZONTAL=Xa,t.DIRECTION_VERTICAL=qa,t.DIRECTION_NONE=Wa,t.DIRECTION_DOWN=Ba,t.INPUT_START=ja,t.INPUT_MOVE=Fa,t.INPUT_END=Ha,t.INPUT_CANCEL=Ga,t.STATE_POSSIBLE=Fl,t.STATE_BEGAN=Hl,t.STATE_CHANGED=Gl,t.STATE_ENDED=Wl,t.STATE_RECOGNIZED=zl,t.STATE_CANCELLED=Ul,t.STATE_FAILED=32,t.Manager=oh,t.Input=pl,t.TouchAction=el,t.TouchInput=Ml,t.MouseInput=Pl,t.PointerEventInput=wl,t.TouchMouseInput=Rl,t.SingleTouchInput=uh,t.Recognizer=ql,t.AttrRecognizer=$l,t.Tap=Zl,t.Pan=Kl,t.Swipe=Ql,t.Pinch=th,t.Rotate=eh,t.Press=ih,t.on=cl,t.off=fl,t.each=Ka,t.merge=mh,t.extend=fh,t.bindFn=gh,t.assign=ga,t.inherit=ph,t.bindFn=gh,t.prefixed=Da,t.toArray=kl,t.inArray=gl,t.uniqueArray=Dl,t.splitStr=dl,t.boolOrFn=Qa,t.hasParent=il,t.addEventListeners=cl,t.removeEventListeners=fl,t.defaults=ga({},nh,{preset:sh}),t}();"undefined"!=typeof window?vh=da(window.Hammer||yh,{preventDefault:"mouse"}):vh=function(){return{on:t=function(){},off:t,destroy:t,emit:t,get:function(e){return{set:t}}};var t};var _h=vh;function bh(t,e){e.inputHandler=function(t){t.isFirst&&e(t)},t.on("hammer.input",e.inputHandler)}var wh=oo.trim,kh=He.parseInt,Dh=/^[+-]?0[Xx]/,Sh=8!==kh(eo+"08")||22!==kh(eo+"0x16")?function(t,e){var i=wh(String(t));return kh(i,e>>>0||(Dh.test(i)?16:10))}:kh;ji({global:!0,forced:parseInt!=Sh},{parseInt:Sh});var xh=Li.parseInt,Mh=function(){function t(e,i,n,s,r){Ds(this,t),this.moment=r&&r.moment||Hr,this.current=this.moment(),this._start=this.moment(),this._end=this.moment(),this.autoScale=!0,this.scale="day",this.step=1,this.setRange(e,i,n),this.switchedDay=!1,this.switchedMonth=!1,this.switchedYear=!1,ks(s)?this.hiddenDates=s:this.hiddenDates=null!=s?[s]:[],this.format=t.FORMAT,this.options=r||{}}return Ts(t,[{key:"setMoment",value:function(t){this.moment=t,this.current=this.moment(this.current.valueOf()),this._start=this.moment(this._start.valueOf()),this._end=this.moment(this._end.valueOf())}},{key:"setFormat",value:function(e){var i=to.deepExtend({},t.FORMAT);this.format=to.deepExtend(i,e)}},{key:"setRange",value:function(t,e,i){if(!(t instanceof Date&&e instanceof Date))throw"No legal start or end date in method setRange";this._start=null!=t?this.moment(t.valueOf()):co(),this._end=null!=e?this.moment(e.valueOf()):co(),this.autoScale&&this.setMinimumStep(i)}},{key:"start",value:function(){this.current=this._start.clone(),this.roundToMinor()}},{key:"roundToMinor",value:function(){switch("week"==this.scale&&this.current.weekday(0),this.scale){case"year":this.current.year(this.step*Math.floor(this.current.year()/this.step)),this.current.month(0);case"month":this.current.date(1);case"week":case"day":case"weekday":this.current.hours(0);case"hour":this.current.minutes(0);case"minute":this.current.seconds(0);case"second":this.current.milliseconds(0)}if(1!=this.step){var t=this.current.clone();switch(this.scale){case"millisecond":this.current.subtract(this.current.milliseconds()%this.step,"milliseconds");break;case"second":this.current.subtract(this.current.seconds()%this.step,"seconds");break;case"minute":this.current.subtract(this.current.minutes()%this.step,"minutes");break;case"hour":this.current.subtract(this.current.hours()%this.step,"hours");break;case"weekday":case"day":this.current.subtract((this.current.date()-1)%this.step,"day");break;case"week":this.current.subtract(this.current.week()%this.step,"week");break;case"month":this.current.subtract(this.current.month()%this.step,"month");break;case"year":this.current.subtract(this.current.year()%this.step,"year")}t.isSame(this.current)||(this.current=this.moment(Go(this.hiddenDates,this.current.valueOf(),-1,!0)))}}},{key:"hasNext",value:function(){return this.current.valueOf()<=this._end.valueOf()}},{key:"next",value:function(){var t=this.current.valueOf();switch(this.scale){case"millisecond":this.current.add(this.step,"millisecond");break;case"second":this.current.add(this.step,"second");break;case"minute":this.current.add(this.step,"minute");break;case"hour":this.current.add(this.step,"hour"),this.current.month()<6?this.current.subtract(this.current.hours()%this.step,"hour"):this.current.hours()%this.step!=0&&this.current.add(this.step-this.current.hours()%this.step,"hour");break;case"weekday":case"day":this.current.add(this.step,"day");break;case"week":if(0!==this.current.weekday())this.current.weekday(0),this.current.add(this.step,"week");else if(!1===this.options.showMajorLabels)this.current.add(this.step,"week");else{var e=this.current.clone();e.add(1,"week"),e.isSame(this.current,"month")?this.current.add(this.step,"week"):(this.current.add(this.step,"week"),this.current.date(1))}break;case"month":this.current.add(this.step,"month");break;case"year":this.current.add(this.step,"year")}if(1!=this.step)switch(this.scale){case"millisecond":this.current.milliseconds()>0&&this.current.milliseconds()<this.step&&this.current.milliseconds(0);break;case"second":this.current.seconds()>0&&this.current.seconds()<this.step&&this.current.seconds(0);break;case"minute":this.current.minutes()>0&&this.current.minutes()<this.step&&this.current.minutes(0);break;case"hour":this.current.hours()>0&&this.current.hours()<this.step&&this.current.hours(0);break;case"weekday":case"day":this.current.date()<this.step+1&&this.current.date(1);break;case"week":this.current.week()<this.step&&this.current.week(1);break;case"month":this.current.month()<this.step&&this.current.month(0)}this.current.valueOf()==t&&(this.current=this._end.clone()),this.switchedDay=!1,this.switchedMonth=!1,this.switchedYear=!1,Lo(this.moment,this,t)}},{key:"getCurrent",value:function(){return this.current.clone()}},{key:"setScale",value:function(t){t&&"string"==typeof t.scale&&(this.scale=t.scale,this.step=t.step>0?t.step:1,this.autoScale=!1)}},{key:"setAutoScale",value:function(t){this.autoScale=t}},{key:"setMinimumStep",value:function(t){if(null!=t){31104e9>t&&(this.scale="year",this.step=1e3),15552e9>t&&(this.scale="year",this.step=500),31104e8>t&&(this.scale="year",this.step=100),15552e8>t&&(this.scale="year",this.step=50),31104e7>t&&(this.scale="year",this.step=10),15552e7>t&&(this.scale="year",this.step=5),31104e6>t&&(this.scale="year",this.step=1),7776e6>t&&(this.scale="month",this.step=3),2592e6>t&&(this.scale="month",this.step=1),6048e5>t&&(this.scale="week",this.step=1),1728e5>t&&(this.scale="day",this.step=2),864e5>t&&(this.scale="day",this.step=1),432e5>t&&(this.scale="weekday",this.step=1),144e5>t&&(this.scale="hour",this.step=4),36e5>t&&(this.scale="hour",this.step=1),9e5>t&&(this.scale="minute",this.step=15),6e5>t&&(this.scale="minute",this.step=10),3e5>t&&(this.scale="minute",this.step=5),6e4>t&&(this.scale="minute",this.step=1),15e3>t&&(this.scale="second",this.step=15),1e4>t&&(this.scale="second",this.step=10),5e3>t&&(this.scale="second",this.step=5),1e3>t&&(this.scale="second",this.step=1),200>t&&(this.scale="millisecond",this.step=200),100>t&&(this.scale="millisecond",this.step=100),50>t&&(this.scale="millisecond",this.step=50),10>t&&(this.scale="millisecond",this.step=10),5>t&&(this.scale="millisecond",this.step=5),1>t&&(this.scale="millisecond",this.step=1)}}},{key:"isMajor",value:function(){if(1==this.switchedYear)switch(this.scale){case"year":case"month":case"week":case"weekday":case"day":case"hour":case"minute":case"second":case"millisecond":return!0;default:return!1}else if(1==this.switchedMonth)switch(this.scale){case"week":case"weekday":case"day":case"hour":case"minute":case"second":case"millisecond":return!0;default:return!1}else if(1==this.switchedDay)switch(this.scale){case"millisecond":case"second":case"minute":case"hour":return!0;default:return!1}var t=this.moment(this.current);switch(this.scale){case"millisecond":return 0==t.milliseconds();case"second":return 0==t.seconds();case"minute":return 0==t.hours()&&0==t.minutes();case"hour":return 0==t.hours();case"weekday":case"day":case"week":return 1==t.date();case"month":return 0==t.month();case"year":default:return!1}}},{key:"getLabelMinor",value:function(t){if(null==t&&(t=this.current),t instanceof Date&&(t=this.moment(t)),"function"==typeof this.format.minorLabels)return this.format.minorLabels(t,this.scale,this.step);var e=this.format.minorLabels[this.scale];switch(this.scale){case"week":if(1===t.date()&&0!==t.weekday())return"";default:return e&&e.length>0?this.moment(t).format(e):""}}},{key:"getLabelMajor",value:function(t){if(null==t&&(t=this.current),t instanceof Date&&(t=this.moment(t)),"function"==typeof this.format.majorLabels)return this.format.majorLabels(t,this.scale,this.step);var e=this.format.majorLabels[this.scale];return e&&e.length>0?this.moment(t).format(e):""}},{key:"getClassName",value:function(){var t,e=this.moment,i=this.moment(this.current),n=i.locale?i.locale("en"):i.lang("en"),s=this.step,r=[];function o(t){return t/s%2==0?" vis-even":" vis-odd"}function a(t){return t.isSame(co(),"day")?" vis-today":t.isSame(e().add(1,"day"),"day")?" vis-tomorrow":t.isSame(e().add(-1,"day"),"day")?" vis-yesterday":""}function l(t){return t.isSame(co(),"week")?" vis-current-week":""}function h(t){return t.isSame(co(),"month")?" vis-current-month":""}switch(this.scale){case"millisecond":r.push(a(n)),r.push(o(n.milliseconds()));break;case"second":r.push(a(n)),r.push(o(n.seconds()));break;case"minute":r.push(a(n)),r.push(o(n.minutes()));break;case"hour":r.push(vo(t="vis-h".concat(n.hours())).call(t,4==this.step?"-h"+(n.hours()+4):"")),r.push(a(n)),r.push(o(n.hours()));break;case"weekday":r.push("vis-".concat(n.format("dddd").toLowerCase())),r.push(a(n)),r.push(l(n)),r.push(o(n.date()));break;case"day":r.push("vis-day".concat(n.date())),r.push("vis-".concat(n.format("MMMM").toLowerCase())),r.push(a(n)),r.push(h(n)),r.push(this.step<=2?a(n):""),r.push(this.step<=2?"vis-".concat(n.format("dddd").toLowerCase()):""),r.push(o(n.date()-1));break;case"week":r.push("vis-week".concat(n.format("w"))),r.push(l(n)),r.push(o(n.week()));break;case"month":r.push("vis-".concat(n.format("MMMM").toLowerCase())),r.push(h(n)),r.push(o(n.month()));break;case"year":r.push("vis-year".concat(n.year())),r.push(function(t){return t.isSame(co(),"year")?" vis-current-year":""}(n)),r.push(o(n.year()))}return ls(r).call(r,String).join(" ")}}],[{key:"snap",value:function(t,e,i){var n=Hr(t);if("year"==e){var s=n.year()+Math.round(n.month()/12);n.year(Math.round(s/i)*i),n.month(0),n.date(0),n.hours(0),n.minutes(0),n.seconds(0),n.milliseconds(0)}else if("month"==e)n.date()>15?(n.date(1),n.add(1,"month")):n.date(1),n.hours(0),n.minutes(0),n.seconds(0),n.milliseconds(0);else if("week"==e)n.weekday()>2?(n.weekday(0),n.add(1,"week")):n.weekday(0),n.hours(0),n.minutes(0),n.seconds(0),n.milliseconds(0);else if("day"==e){switch(i){case 5:case 2:n.hours(24*Math.round(n.hours()/24));break;default:n.hours(12*Math.round(n.hours()/12))}n.minutes(0),n.seconds(0),n.milliseconds(0)}else if("weekday"==e){switch(i){case 5:case 2:n.hours(12*Math.round(n.hours()/12));break;default:n.hours(6*Math.round(n.hours()/6))}n.minutes(0),n.seconds(0),n.milliseconds(0)}else if("hour"==e){switch(i){case 4:n.minutes(60*Math.round(n.minutes()/60));break;default:n.minutes(30*Math.round(n.minutes()/30))}n.seconds(0),n.milliseconds(0)}else if("minute"==e){switch(i){case 15:case 10:n.minutes(5*Math.round(n.minutes()/5)),n.seconds(0);break;case 5:n.seconds(60*Math.round(n.seconds()/60));break;default:n.seconds(30*Math.round(n.seconds()/30))}n.milliseconds(0)}else if("second"==e)switch(i){case 15:case 10:n.seconds(5*Math.round(n.seconds()/5)),n.milliseconds(0);break;case 5:n.milliseconds(1e3*Math.round(n.milliseconds()/1e3));break;default:n.milliseconds(500*Math.round(n.milliseconds()/500))}else if("millisecond"==e){var r=i>5?i/2:1;n.milliseconds(Math.round(n.milliseconds()/r)*r)}return n}}]),t}();Mh.FORMAT={minorLabels:{millisecond:"SSS",second:"s",minute:"HH:mm",hour:"HH:mm",weekday:"ddd D",day:"D",week:"w",month:"MMM",year:"YYYY"},majorLabels:{millisecond:"HH:mm:ss",second:"D MMMM HH:mm",minute:"ddd D MMMM",hour:"ddd D MMMM",weekday:"MMMM YYYY",day:"MMMM YYYY",week:"MMMM YYYY",month:"YYYY",year:""}};var Th=function(t){function e(t,i){var n;return Ds(this,e),(n=Cr(this,Lr(e).call(this))).dom={foreground:null,lines:[],majorTexts:[],minorTexts:[],redundant:{lines:[],majorTexts:[],minorTexts:[]}},n.props={range:{start:0,end:0,minimumStep:0},lineTop:0},n.defaultOptions={orientation:{axis:"bottom"},showMinorLabels:!0,showMajorLabels:!0,maxMinorChars:7,format:Mh.FORMAT,moment:Hr,timeAxis:null},n.options=to.extend({},n.defaultOptions),n.body=t,n._create(),n.setOptions(i),n}return jr(e,t),Ts(e,[{key:"setOptions",value:function(t){t&&(to.selectiveExtend(["showMinorLabels","showMajorLabels","maxMinorChars","hiddenDates","timeAxis","moment","rtl"],this.options,t),to.selectiveDeepExtend(["format"],this.options,t),"orientation"in t&&("string"==typeof t.orientation?this.options.orientation.axis=t.orientation:"object"===Tr(t.orientation)&&"axis"in t.orientation&&(this.options.orientation.axis=t.orientation.axis)),"locale"in t&&("function"==typeof Hr.locale?Hr.locale(t.locale):Hr.lang(t.locale)))}},{key:"_create",value:function(){this.dom.foreground=document.createElement("div"),this.dom.background=document.createElement("div"),this.dom.foreground.className="vis-time-axis vis-foreground",this.dom.background.className="vis-time-axis vis-background"}},{key:"destroy",value:function(){this.dom.foreground.parentNode&&this.dom.foreground.parentNode.removeChild(this.dom.foreground),this.dom.background.parentNode&&this.dom.background.parentNode.removeChild(this.dom.background),this.body=null}},{key:"redraw",value:function(){var t=this.props,e=this.dom.foreground,i=this.dom.background,n="top"==this.options.orientation.axis?this.body.dom.top:this.body.dom.bottom,s=e.parentNode!==n;this._calculateCharSize();var r=this.options.showMinorLabels&&"none"!==this.options.orientation.axis,o=this.options.showMajorLabels&&"none"!==this.options.orientation.axis;t.minorLabelHeight=r?t.minorCharHeight:0,t.majorLabelHeight=o?t.majorCharHeight:0,t.height=t.minorLabelHeight+t.majorLabelHeight,t.width=e.offsetWidth,t.minorLineHeight=this.body.domProps.root.height-t.majorLabelHeight-("top"==this.options.orientation.axis?this.body.domProps.bottom.height:this.body.domProps.top.height),t.minorLineWidth=1,t.majorLineHeight=t.minorLineHeight+t.majorLabelHeight,t.majorLineWidth=1;var a=e.nextSibling,l=i.nextSibling;return e.parentNode&&e.parentNode.removeChild(e),i.parentNode&&i.parentNode.removeChild(i),e.style.height="".concat(this.props.height,"px"),this._repaintLabels(),a?n.insertBefore(e,a):n.appendChild(e),l?this.body.dom.backgroundVertical.insertBefore(i,l):this.body.dom.backgroundVertical.appendChild(i),this._isResized()||s}},{key:"_repaintLabels",value:function(){var t=this.options.orientation.axis,e=to.convert(this.body.range.start,"Number"),i=to.convert(this.body.range.end,"Number"),n=this.body.util.toTime((this.props.minorCharWidth||10)*this.options.maxMinorChars).valueOf(),s=n-Fo(this.options.moment,this.body.hiddenDates,this.body.range,n);s-=this.body.util.toTime(0).valueOf();var r=new Mh(new Date(e),new Date(i),s,this.body.hiddenDates,this.options);r.setMoment(this.options.moment),this.options.format&&r.setFormat(this.options.format),this.options.timeAxis&&r.setScale(this.options.timeAxis),this.step=r;var o,a,l,h,u,d,c=this.dom;c.redundant.lines=c.lines,c.redundant.majorTexts=c.majorTexts,c.redundant.minorTexts=c.minorTexts,c.lines=[],c.majorTexts=[],c.minorTexts=[];var f,m,p,g=0,v=void 0,y=0;for(r.start(),a=r.getCurrent(),h=this.body.util.toScreen(a);r.hasNext()&&y<1e3;){switch(y++,u=r.isMajor(),p=r.getClassName(),o=a,l=h,r.next(),a=r.getCurrent(),f=g,g=(h=this.body.util.toScreen(a))-l,r.scale){case"week":d=!0;break;default:d=g>=.4*f}if(this.options.showMinorLabels&&d){var _=this._repaintMinorText(l,r.getLabelMinor(o),t,p);_.style.width="".concat(g,"px")}u&&this.options.showMajorLabels?(l>0&&(null==v&&(v=l),_=this._repaintMajorText(l,r.getLabelMajor(o),t,p)),m=this._repaintMajorLine(l,g,t,p)):d?m=this._repaintMinorLine(l,g,t,p):m&&(m.style.width="".concat(xh(m.style.width)+g,"px"))}if(1e3!==y||Oh||(console.warn("Something is wrong with the Timeline scale. Limited drawing of grid lines to ".concat(1e3," lines.")),Oh=!0),this.options.showMajorLabels){var b=this.body.util.toTime(0),w=r.getLabelMajor(b),k=w.length*(this.props.majorCharWidth||10)+10;(null==v||k<v)&&this._repaintMajorText(0,w,t,p)}is(to).call(to,this.dom.redundant,(function(t){for(;t.length;){var e=t.pop();e&&e.parentNode&&e.parentNode.removeChild(e)}}))}},{key:"_repaintMinorText",value:function(t,e,i,n){var s=this.dom.redundant.minorTexts.shift();if(!s){var r=document.createTextNode("");(s=document.createElement("div")).appendChild(r),this.dom.foreground.appendChild(s)}this.dom.minorTexts.push(s),s.innerHTML=e;var o="top"==i?this.props.majorLabelHeight:0;return this._setXY(s,t,o),s.className="vis-text vis-minor ".concat(n),s}},{key:"_repaintMajorText",value:function(t,e,i,n){var s=this.dom.redundant.majorTexts.shift();if(!s){var r=document.createElement("div");(s=document.createElement("div")).appendChild(r),this.dom.foreground.appendChild(s)}s.childNodes[0].innerHTML=e,s.className="vis-text vis-major ".concat(n);var o="top"==i?0:this.props.minorLabelHeight;return this._setXY(s,t,o),this.dom.majorTexts.push(s),s}},{key:"_setXY",value:function(t,e,i){var n,s=this.options.rtl?-1*e:e;t.style.transform=vo(n="translate(".concat(s,"px, ")).call(n,i,"px)")}},{key:"_repaintMinorLine",value:function(t,e,i,n){var s,r=this.dom.redundant.lines.shift();r||(r=document.createElement("div"),this.dom.background.appendChild(r)),this.dom.lines.push(r);var o=this.props;r.style.width="".concat(e,"px"),r.style.height="".concat(o.minorLineHeight,"px");var a="top"==i?o.majorLabelHeight:this.body.domProps.top.height,l=t-o.minorLineWidth/2;return this._setXY(r,l,a),r.className=vo(s="vis-grid ".concat(this.options.rtl?"vis-vertical-rtl":"vis-vertical"," vis-minor ")).call(s,n),r}},{key:"_repaintMajorLine",value:function(t,e,i,n){var s,r=this.dom.redundant.lines.shift();r||(r=document.createElement("div"),this.dom.background.appendChild(r)),this.dom.lines.push(r);var o=this.props;r.style.width="".concat(e,"px"),r.style.height="".concat(o.majorLineHeight,"px");var a="top"==i?0:this.body.domProps.top.height,l=t-o.majorLineWidth/2;return this._setXY(r,l,a),r.className=vo(s="vis-grid ".concat(this.options.rtl?"vis-vertical-rtl":"vis-vertical"," vis-major ")).call(s,n),r}},{key:"_calculateCharSize",value:function(){this.dom.measureCharMinor||(this.dom.measureCharMinor=document.createElement("DIV"),this.dom.measureCharMinor.className="vis-text vis-minor vis-measure",this.dom.measureCharMinor.style.position="absolute",this.dom.measureCharMinor.appendChild(document.createTextNode("0")),this.dom.foreground.appendChild(this.dom.measureCharMinor)),this.props.minorCharHeight=this.dom.measureCharMinor.clientHeight,this.props.minorCharWidth=this.dom.measureCharMinor.clientWidth,this.dom.measureCharMajor||(this.dom.measureCharMajor=document.createElement("DIV"),this.dom.measureCharMajor.className="vis-text vis-major vis-measure",this.dom.measureCharMajor.style.position="absolute",this.dom.measureCharMajor.appendChild(document.createTextNode("0")),this.dom.foreground.appendChild(this.dom.measureCharMajor)),this.props.majorCharHeight=this.dom.measureCharMajor.clientHeight,this.props.majorCharWidth=this.dom.measureCharMajor.clientWidth}}]),e}(yo),Oh=!1,Ch=Le((function(t,e){t.exports=function(t){var e,i=t&&t.preventDefault||!1,n=t&&t.container||window,s={},r={keydown:{},keyup:{}},o={};for(e=97;e<=122;e++)o[String.fromCharCode(e)]={code:e-97+65,shift:!1};for(e=65;e<=90;e++)o[String.fromCharCode(e)]={code:e,shift:!0};for(e=0;e<=9;e++)o[""+e]={code:48+e,shift:!1};for(e=1;e<=12;e++)o["F"+e]={code:111+e,shift:!1};for(e=0;e<=9;e++)o["num"+e]={code:96+e,shift:!1};o["num*"]={code:106,shift:!1},o["num+"]={code:107,shift:!1},o["num-"]={code:109,shift:!1},o["num/"]={code:111,shift:!1},o["num."]={code:110,shift:!1},o.left={code:37,shift:!1},o.up={code:38,shift:!1},o.right={code:39,shift:!1},o.down={code:40,shift:!1},o.space={code:32,shift:!1},o.enter={code:13,shift:!1},o.shift={code:16,shift:void 0},o.esc={code:27,shift:!1},o.backspace={code:8,shift:!1},o.tab={code:9,shift:!1},o.ctrl={code:17,shift:!1},o.alt={code:18,shift:!1},o.delete={code:46,shift:!1},o.pageup={code:33,shift:!1},o.pagedown={code:34,shift:!1},o["="]={code:187,shift:!1},o["-"]={code:189,shift:!1},o["]"]={code:221,shift:!1},o["["]={code:219,shift:!1};var a=function(t){h(t,"keydown")},l=function(t){h(t,"keyup")},h=function(t,e){if(void 0!==r[e][t.keyCode]){for(var n=r[e][t.keyCode],s=0;s<n.length;s++)void 0===n[s].shift?n[s].fn(t):1==n[s].shift&&1==t.shiftKey?n[s].fn(t):0==n[s].shift&&0==t.shiftKey&&n[s].fn(t);1==i&&t.preventDefault()}};return s.bind=function(t,e,i){if(void 0===i&&(i="keydown"),void 0===o[t])throw new Error("unsupported key: "+t);void 0===r[i][o[t].code]&&(r[i][o[t].code]=[]),r[i][o[t].code].push({fn:e,shift:o[t].shift})},s.bindAll=function(t,e){for(var i in void 0===e&&(e="keydown"),o)o.hasOwnProperty(i)&&s.bind(i,t,e)},s.getKey=function(t){for(var e in o)if(o.hasOwnProperty(e)){if(1==t.shiftKey&&1==o[e].shift&&t.keyCode==o[e].code)return e;if(0==t.shiftKey&&0==o[e].shift&&t.keyCode==o[e].code)return e;if(t.keyCode==o[e].code&&"shift"==e)return e}return"unknown key, currently not supported"},s.unbind=function(t,e,i){if(void 0===i&&(i="keydown"),void 0===o[t])throw new Error("unsupported key: "+t);if(void 0!==e){var n=[],s=r[i][o[t].code];if(void 0!==s)for(var a=0;a<s.length;a++)s[a].fn==e&&s[a].shift==o[t].shift||n.push(r[i][o[t].code][a]);r[i][o[t].code]=n}else r[i][o[t].code]=[]},s.reset=function(){r={keydown:{},keyup:{}}},s.destroy=function(){r={keydown:{},keyup:{}},n.removeEventListener("keydown",a,!0),n.removeEventListener("keyup",l,!0)},n.addEventListener("keydown",a,!0),n.addEventListener("keyup",l,!0),s}}));function Yh(t){var e,i;this.active=!1,this.dom={container:t},this.dom.overlay=document.createElement("div"),this.dom.overlay.className="vis-overlay",this.dom.container.appendChild(this.dom.overlay),this.hammer=_h(this.dom.overlay),this.hammer.on("tap",bs(e=this._onTapOverlay).call(e,this));var n=this,s=["tap","doubletap","press","pinch","pan","panstart","panmove","panend"];is(s).call(s,(function(t){n.hammer.on(t,(function(t){t.stopPropagation()}))})),document&&document.body&&(this.onClick=function(e){(function(t,e){for(;t;){if(t===e)return!0;t=t.parentNode}return!1})(e.target,t)||n.deactivate()},document.body.addEventListener("click",this.onClick)),void 0!==this.keycharm&&this.keycharm.destroy(),this.keycharm=Ch(),this.escListener=bs(i=this.deactivate).call(i,this)}ha(Yh.prototype),Yh.current=null,Yh.prototype.destroy=function(){this.deactivate(),this.dom.overlay.parentNode.removeChild(this.dom.overlay),this.onClick&&document.body.removeEventListener("click",this.onClick),void 0!==this.keycharm&&this.keycharm.destroy(),this.keycharm=null,this.hammer.destroy(),this.hammer=null},Yh.prototype.activate=function(){var t;Yh.current&&Yh.current.deactivate(),Yh.current=this,this.active=!0,this.dom.overlay.style.display="none",to.addClassName(this.dom.container,"vis-active"),this.emit("change"),this.emit("activate"),bs(t=this.keycharm).call(t,"esc",this.escListener)},Yh.prototype.deactivate=function(){this.active=!1,this.dom.overlay.style.display="",to.removeClassName(this.dom.container,"vis-active"),this.keycharm.unbind("esc",this.escListener),this.emit("change"),this.emit("deactivate")},Yh.prototype._onTapOverlay=function(t){this.activate(),t.stopPropagation()};Le((function(t,e){(function(t){t.defineLocale("it",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Oggi alle] LT",nextDay:"[Domani alle] LT",nextWeek:"dddd [alle] LT",lastDay:"[Ieri alle] LT",lastWeek:function(){switch(this.day()){case 0:return"[la scorsa] dddd [alle] LT";default:return"[lo scorso] dddd [alle] LT"}},sameElse:"L"},relativeTime:{future:function(t){return(/^[0-9].+$/.test(t)?"tra":"in")+" "+t},past:"%s fa",s:"alcuni secondi",ss:"%d secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})})(Fr)})),Le((function(t,e){(function(t){var e="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),i="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_"),n=[/^jan/i,/^feb/i,/^maart|mrt.?$/i,/^apr/i,/^mei$/i,/^jun[i.]?$/i,/^jul[i.]?$/i,/^aug/i,/^sep/i,/^okt/i,/^nov/i,/^dec/i],s=/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\.?|feb\.?|mrt\.?|apr\.?|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i;t.defineLocale("nl",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(t,n){return t?/-MMM-/.test(n)?i[t.month()]:e[t.month()]:e},monthsRegex:s,monthsShortRegex:s,monthsStrictRegex:/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,monthsShortStrictRegex:/^(jan\.?|feb\.?|mrt\.?|apr\.?|mei|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i,monthsParse:n,longMonthsParse:n,shortMonthsParse:n,weekdays:"zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),weekdaysShort:"zo._ma._di._wo._do._vr._za.".split("_"),weekdaysMin:"zo_ma_di_wo_do_vr_za".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[vandaag om] LT",nextDay:"[morgen om] LT",nextWeek:"dddd [om] LT",lastDay:"[gisteren om] LT",lastWeek:"[afgelopen] dddd [om] LT",sameElse:"L"},relativeTime:{future:"over %s",past:"%s geleden",s:"een paar seconden",ss:"%d seconden",m:"één minuut",mm:"%d minuten",h:"één uur",hh:"%d uur",d:"één dag",dd:"%d dagen",M:"één maand",MM:"%d maanden",y:"één jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(t){return t+(1===t||8===t||t>=20?"ste":"de")},week:{dow:1,doy:4}})})(Fr)})),Le((function(t,e){(function(t){function e(t,e,i,n){var s={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[t+" Tage",t+" Tagen"],M:["ein Monat","einem Monat"],MM:[t+" Monate",t+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[t+" Jahre",t+" Jahren"]};return e?s[i][0]:s[i][1]}t.defineLocale("de",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:e,mm:"%d Minuten",h:e,hh:"%d Stunden",d:e,dd:e,M:e,MM:e,y:e,yy:e},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})})(Fr)})),Le((function(t,e){(function(t){t.defineLocale("fr",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsParseExact:!0,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|)/,ordinal:function(t,e){switch(e){case"D":return t+(1===t?"er":"");default:case"M":case"Q":case"DDD":case"d":return t+(1===t?"er":"e");case"w":case"W":return t+(1===t?"re":"e")}},week:{dow:1,doy:4}})})(Fr)})),Le((function(t,e){(function(t){var e="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),i="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),n=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],s=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;t.defineLocale("es",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(t,n){return t?/-MMM-/.test(n)?i[t.month()]:e[t.month()]:e},monthsRegex:s,monthsShortRegex:s,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:n,longMonthsParse:n,shortMonthsParse:n,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})})(Fr)})),Le((function(t,e){(function(t){function e(t,e,i){var n,s;return"m"===i?e?"хвилина":"хвилину":"h"===i?e?"година":"годину":t+" "+(n=+t,s={ss:e?"секунда_секунди_секунд":"секунду_секунди_секунд",mm:e?"хвилина_хвилини_хвилин":"хвилину_хвилини_хвилин",hh:e?"година_години_годин":"годину_години_годин",dd:"день_дні_днів",MM:"місяць_місяці_місяців",yy:"рік_роки_років"}[i].split("_"),n%10==1&&n%100!=11?s[0]:n%10>=2&&n%10<=4&&(n%100<10||n%100>=20)?s[1]:s[2])}function i(t){return function(){return t+"о"+(11===this.hours()?"б":"")+"] LT"}}t.defineLocale("uk",{months:{format:"січня_лютого_березня_квітня_травня_червня_липня_серпня_вересня_жовтня_листопада_грудня".split("_"),standalone:"січень_лютий_березень_квітень_травень_червень_липень_серпень_вересень_жовтень_листопад_грудень".split("_")},monthsShort:"січ_лют_бер_квіт_трав_черв_лип_серп_вер_жовт_лист_груд".split("_"),weekdays:function(t,e){var i={nominative:"неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота".split("_"),accusative:"неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу".split("_"),genitive:"неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи".split("_")};return!0===t?i.nominative.slice(1,7).concat(i.nominative.slice(0,1)):t?i[/(\[[ВвУу]\]) ?dddd/.test(e)?"accusative":/\[?(?:минулої|наступної)? ?\] ?dddd/.test(e)?"genitive":"nominative"][t.day()]:i.nominative},weekdaysShort:"нд_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY р.",LLL:"D MMMM YYYY р., HH:mm",LLLL:"dddd, D MMMM YYYY р., HH:mm"},calendar:{sameDay:i("[Сьогодні "),nextDay:i("[Завтра "),lastDay:i("[Вчора "),nextWeek:i("[У] dddd ["),lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return i("[Минулої] dddd [").call(this);case 1:case 2:case 4:return i("[Минулого] dddd [").call(this)}},sameElse:"L"},relativeTime:{future:"за %s",past:"%s тому",s:"декілька секунд",ss:e,m:e,mm:e,h:"годину",hh:e,d:"день",dd:e,M:"місяць",MM:e,y:"рік",yy:e},meridiemParse:/ночі|ранку|дня|вечора/,isPM:function(t){return/^(дня|вечора)$/.test(t)},meridiem:function(t,e,i){return t<4?"ночі":t<12?"ранку":t<17?"дня":"вечора"},dayOfMonthOrdinalParse:/\d{1,2}-(й|го)/,ordinal:function(t,e){switch(e){case"M":case"d":case"DDD":case"w":case"W":return t+"-й";case"D":return t+"-го";default:return t}},week:{dow:1,doy:7}})})(Fr)})),Le((function(t,e){(function(t){function e(t,e,i){var n,s;return"m"===i?e?"минута":"минуту":t+" "+(n=+t,s={ss:e?"секунда_секунды_секунд":"секунду_секунды_секунд",mm:e?"минута_минуты_минут":"минуту_минуты_минут",hh:"час_часа_часов",dd:"день_дня_дней",MM:"месяц_месяца_месяцев",yy:"год_года_лет"}[i].split("_"),n%10==1&&n%100!=11?s[0]:n%10>=2&&n%10<=4&&(n%100<10||n%100>=20)?s[1]:s[2])}var i=[/^янв/i,/^фев/i,/^мар/i,/^апр/i,/^ма[йя]/i,/^июн/i,/^июл/i,/^авг/i,/^сен/i,/^окт/i,/^ноя/i,/^дек/i];t.defineLocale("ru",{months:{format:"января_февраля_марта_апреля_мая_июня_июля_августа_сентября_октября_ноября_декабря".split("_"),standalone:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_")},monthsShort:{format:"янв._февр._мар._апр._мая_июня_июля_авг._сент._окт._нояб._дек.".split("_"),standalone:"янв._февр._март_апр._май_июнь_июль_авг._сент._окт._нояб._дек.".split("_")},weekdays:{standalone:"воскресенье_понедельник_вторник_среда_четверг_пятница_суббота".split("_"),format:"воскресенье_понедельник_вторник_среду_четверг_пятницу_субботу".split("_"),isFormat:/\[ ?[Вв] ?(?:прошлую|следующую|эту)? ?\] ?dddd/},weekdaysShort:"вс_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"вс_пн_вт_ср_чт_пт_сб".split("_"),monthsParse:i,longMonthsParse:i,shortMonthsParse:i,monthsRegex:/^(январ[ья]|янв\.?|феврал[ья]|февр?\.?|марта?|мар\.?|апрел[ья]|апр\.?|ма[йя]|июн[ья]|июн\.?|июл[ья]|июл\.?|августа?|авг\.?|сентябр[ья]|сент?\.?|октябр[ья]|окт\.?|ноябр[ья]|нояб?\.?|декабр[ья]|дек\.?)/i,monthsShortRegex:/^(январ[ья]|янв\.?|феврал[ья]|февр?\.?|марта?|мар\.?|апрел[ья]|апр\.?|ма[йя]|июн[ья]|июн\.?|июл[ья]|июл\.?|августа?|авг\.?|сентябр[ья]|сент?\.?|октябр[ья]|окт\.?|ноябр[ья]|нояб?\.?|декабр[ья]|дек\.?)/i,monthsStrictRegex:/^(январ[яь]|феврал[яь]|марта?|апрел[яь]|ма[яй]|июн[яь]|июл[яь]|августа?|сентябр[яь]|октябр[яь]|ноябр[яь]|декабр[яь])/i,monthsShortStrictRegex:/^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., H:mm",LLLL:"dddd, D MMMM YYYY г., H:mm"},calendar:{sameDay:"[Сегодня, в] LT",nextDay:"[Завтра, в] LT",lastDay:"[Вчера, в] LT",nextWeek:function(t){if(t.week()===this.week())return 2===this.day()?"[Во] dddd, [в] LT":"[В] dddd, [в] LT";switch(this.day()){case 0:return"[В следующее] dddd, [в] LT";case 1:case 2:case 4:return"[В следующий] dddd, [в] LT";case 3:case 5:case 6:return"[В следующую] dddd, [в] LT"}},lastWeek:function(t){if(t.week()===this.week())return 2===this.day()?"[Во] dddd, [в] LT":"[В] dddd, [в] LT";switch(this.day()){case 0:return"[В прошлое] dddd, [в] LT";case 1:case 2:case 4:return"[В прошлый] dddd, [в] LT";case 3:case 5:case 6:return"[В прошлую] dddd, [в] LT"}},sameElse:"L"},relativeTime:{future:"через %s",past:"%s назад",s:"несколько секунд",ss:e,m:e,mm:e,h:"час",hh:e,d:"день",dd:e,M:"месяц",MM:e,y:"год",yy:e},meridiemParse:/ночи|утра|дня|вечера/i,isPM:function(t){return/^(дня|вечера)$/.test(t)},meridiem:function(t,e,i){return t<4?"ночи":t<12?"утра":t<17?"дня":"вечера"},dayOfMonthOrdinalParse:/\d{1,2}-(й|го|я)/,ordinal:function(t,e){switch(e){case"M":case"d":case"DDD":return t+"-й";case"D":return t+"-го";case"w":case"W":return t+"-я";default:return t}},week:{dow:1,doy:4}})})(Fr)})),Le((function(t,e){(function(t){t.defineLocale("ja",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),weekdaysShort:"日_月_火_水_木_金_土".split("_"),weekdaysMin:"日_月_火_水_木_金_土".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日 HH:mm",LLLL:"YYYY年M月D日 dddd HH:mm",l:"YYYY/MM/DD",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日(ddd) HH:mm"},meridiemParse:/午前|午後/i,isPM:function(t){return"午後"===t},meridiem:function(t,e,i){return t<12?"午前":"午後"},calendar:{sameDay:"[今日] LT",nextDay:"[明日] LT",nextWeek:function(t){return t.week()<this.week()?"[来週]dddd LT":"dddd LT"},lastDay:"[昨日] LT",lastWeek:function(t){return this.week()<t.week()?"[先週]dddd LT":"dddd LT"},sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}日/,ordinal:function(t,e){switch(e){case"d":case"D":case"DDD":return t+"日";default:return t}},relativeTime:{future:"%s後",past:"%s前",s:"数秒",ss:"%d秒",m:"1分",mm:"%d分",h:"1時間",hh:"%d時間",d:"1日",dd:"%d日",M:"1ヶ月",MM:"%dヶ月",y:"1年",yy:"%d年"}})})(Fr)}));var Ph={current:"current",time:"time",deleteSelected:"Delete selected"},Eh={current:"attuale",time:"tempo",deleteSelected:"Cancella la selezione"},Lh={current:"huidige",time:"tijd",deleteSelected:"Selectie verwijderen"},Ih={current:"Aktuelle",time:"Zeit",deleteSelected:"Lösche Auswahl"},Ah={current:"actuel",time:"heure",deleteSelected:"Effacer la selection"},Nh={current:"corriente",time:"hora",deleteSelected:"Eliminar selección"},Rh={current:"поточний",time:"час",deleteSelected:"Видалити обране"},jh={current:"текущее",time:"время",deleteSelected:"Удалить выбранное"},Fh={current:"現在",time:"時刻",deleteSelected:"選択されたものを削除"},Hh={en:Ph,en_EN:Ph,en_US:Ph,it:Eh,it_IT:Eh,it_CH:Eh,nl:Lh,nl_NL:Lh,nl_BE:Lh,de:Ih,de_DE:Ih,fr:Ah,fr_FR:Ah,fr_CA:Ah,fr_BE:Ah,es:Nh,es_ES:Nh,uk:Rh,uk_UA:Rh,ru:jh,ru_RU:jh,ja:Fh,ja_JP:Fh},Gh=function(t){function e(t,i){var n,s;Ds(this,e),(s=Cr(this,Lr(e).call(this))).body=t,s.defaultOptions={moment:Hr,locales:Hh,locale:"en",id:void 0,title:void 0},s.options=to.extend({},s.defaultOptions),s.setOptions(i),s.options.locales=to.extend({},Hh,s.options.locales);var r=s.defaultOptions.locales[s.defaultOptions.locale];return is(n=$r(s.options.locales)).call(n,(function(t){s.options.locales[t]=to.extend({},r,s.options.locales[t])})),i&&i.time?s.customTime=i.time:s.customTime=new Date,s.eventParams={},s._create(),s}return jr(e,t),Ts(e,[{key:"setOptions",value:function(t){t&&to.selectiveExtend(["moment","locale","locales","id","title","rtl"],this.options,t)}},{key:"_create",value:function(){var t,e,i,n=document.createElement("div");n["custom-time"]=this,n.className="vis-custom-time ".concat(this.options.id||""),n.style.position="absolute",n.style.top="0px",n.style.height="100%",this.bar=n;var s=document.createElement("div");function r(t){this.body.range._onMouseWheel(t)}s.style.position="relative",s.style.top="0px",this.options.rtl?s.style.right="-10px":s.style.left="-10px",s.style.height="100%",s.style.width="20px",s.addEventListener?(s.addEventListener("mousewheel",bs(r).call(r,this),!1),s.addEventListener("DOMMouseScroll",bs(r).call(r,this),!1)):s.attachEvent("onmousewheel",bs(r).call(r,this)),n.appendChild(s),this.hammer=new _h(s),this.hammer.on("panstart",bs(t=this._onDragStart).call(t,this)),this.hammer.on("panmove",bs(e=this._onDrag).call(e,this)),this.hammer.on("panend",bs(i=this._onDragEnd).call(i,this)),this.hammer.get("pan").set({threshold:5,direction:_h.DIRECTION_ALL})}},{key:"destroy",value:function(){this.hide(),this.hammer.destroy(),this.hammer=null,this.body=null}},{key:"redraw",value:function(){var t=this.body.dom.backgroundVertical;this.bar.parentNode!=t&&(this.bar.parentNode&&this.bar.parentNode.removeChild(this.bar),t.appendChild(this.bar));var e=this.body.util.toScreen(this.customTime),i=this.options.locales[this.options.locale];i||(this.warned||(console.warn("WARNING: options.locales['".concat(this.options.locale,"'] not found. See https://visjs.github.io/vis-timeline/docs/timeline/#Localization")),this.warned=!0),i=this.options.locales.en);var n,s=this.options.title;void 0===s?s=(s=vo(n="".concat(i.time,": ")).call(n,this.options.moment(this.customTime).format("dddd, MMMM Do YYYY, H:mm:ss"))).charAt(0).toUpperCase()+s.substring(1):"function"==typeof s&&(s=s.call(this.customTime));return this.options.rtl?this.bar.style.right="".concat(e,"px"):this.bar.style.left="".concat(e,"px"),this.bar.title=s,!1}},{key:"hide",value:function(){this.bar.parentNode&&this.bar.parentNode.removeChild(this.bar)}},{key:"setCustomTime",value:function(t){this.customTime=to.convert(t,"Date"),this.redraw()}},{key:"getCustomTime",value:function(){return new Date(this.customTime.valueOf())}},{key:"setCustomMarker",value:function(t,e){var i,n,s=document.createElement("div");(s.className="vis-custom-time-marker",s.innerHTML=t,s.style.position="absolute",e)&&(s.setAttribute("contenteditable","true"),s.addEventListener("pointerdown",(function(){s.focus()})),s.addEventListener("input",bs(i=this._onMarkerChange).call(i,this)),s.title=t,s.addEventListener("blur",bs(n=function(t){this.title!=t.target.innerHTML&&(this._onMarkerChanged(t),this.title=t.target.innerHTML)}).call(n,this)));this.bar.appendChild(s)}},{key:"setCustomTitle",value:function(t){this.options.title=t}},{key:"_onDragStart",value:function(t){this.eventParams.dragging=!0,this.eventParams.customTime=this.customTime,t.stopPropagation()}},{key:"_onDrag",value:function(t){if(this.eventParams.dragging){var e=this.options.rtl?-1*t.deltaX:t.deltaX,i=this.body.util.toScreen(this.eventParams.customTime)+e,n=this.body.util.toTime(i);this.setCustomTime(n),this.body.emitter.emit("timechange",{id:this.options.id,time:new Date(this.customTime.valueOf()),event:t}),t.stopPropagation()}}},{key:"_onDragEnd",value:function(t){this.eventParams.dragging&&(this.body.emitter.emit("timechanged",{id:this.options.id,time:new Date(this.customTime.valueOf()),event:t}),t.stopPropagation())}},{key:"_onMarkerChange",value:function(t){this.body.emitter.emit("markerchange",{id:this.options.id,title:t.target.innerHTML,event:t}),t.stopPropagation()}},{key:"_onMarkerChanged",value:function(t){this.body.emitter.emit("markerchanged",{id:this.options.id,title:t.target.innerHTML,event:t}),t.stopPropagation()}}],[{key:"customTimeFromTarget",value:function(t){for(var e=t.target;e;){if(e.hasOwnProperty("custom-time"))return e["custom-time"];e=e.parentNode}return null}}]),e}(yo),Wh=function(){function t(){Ds(this,t)}return Ts(t,[{key:"_create",value:function(t){var e,i,n,s=this;this.dom={},this.dom.container=t,this.dom.container.style.position="relative",this.dom.root=document.createElement("div"),this.dom.background=document.createElement("div"),this.dom.backgroundVertical=document.createElement("div"),this.dom.backgroundHorizontal=document.createElement("div"),this.dom.centerContainer=document.createElement("div"),this.dom.leftContainer=document.createElement("div"),this.dom.rightContainer=document.createElement("div"),this.dom.center=document.createElement("div"),this.dom.left=document.createElement("div"),this.dom.right=document.createElement("div"),this.dom.top=document.createElement("div"),this.dom.bottom=document.createElement("div"),this.dom.shadowTop=document.createElement("div"),this.dom.shadowBottom=document.createElement("div"),this.dom.shadowTopLeft=document.createElement("div"),this.dom.shadowBottomLeft=document.createElement("div"),this.dom.shadowTopRight=document.createElement("div"),this.dom.shadowBottomRight=document.createElement("div"),this.dom.rollingModeBtn=document.createElement("div"),this.dom.loadingScreen=document.createElement("div"),this.dom.root.className="vis-timeline",this.dom.background.className="vis-panel vis-background",this.dom.backgroundVertical.className="vis-panel vis-background vis-vertical",this.dom.backgroundHorizontal.className="vis-panel vis-background vis-horizontal",this.dom.centerContainer.className="vis-panel vis-center",this.dom.leftContainer.className="vis-panel vis-left",this.dom.rightContainer.className="vis-panel vis-right",this.dom.top.className="vis-panel vis-top",this.dom.bottom.className="vis-panel vis-bottom",this.dom.left.className="vis-content",this.dom.center.className="vis-content",this.dom.right.className="vis-content",this.dom.shadowTop.className="vis-shadow vis-top",this.dom.shadowBottom.className="vis-shadow vis-bottom",this.dom.shadowTopLeft.className="vis-shadow vis-top",this.dom.shadowBottomLeft.className="vis-shadow vis-bottom",this.dom.shadowTopRight.className="vis-shadow vis-top",this.dom.shadowBottomRight.className="vis-shadow vis-bottom",this.dom.rollingModeBtn.className="vis-rolling-mode-btn",this.dom.loadingScreen.className="vis-loading-screen",this.dom.root.appendChild(this.dom.background),this.dom.root.appendChild(this.dom.backgroundVertical),this.dom.root.appendChild(this.dom.backgroundHorizontal),this.dom.root.appendChild(this.dom.centerContainer),this.dom.root.appendChild(this.dom.leftContainer),this.dom.root.appendChild(this.dom.rightContainer),this.dom.root.appendChild(this.dom.top),this.dom.root.appendChild(this.dom.bottom),this.dom.root.appendChild(this.dom.rollingModeBtn),this.dom.centerContainer.appendChild(this.dom.center),this.dom.leftContainer.appendChild(this.dom.left),this.dom.rightContainer.appendChild(this.dom.right),this.dom.centerContainer.appendChild(this.dom.shadowTop),this.dom.centerContainer.appendChild(this.dom.shadowBottom),this.dom.leftContainer.appendChild(this.dom.shadowTopLeft),this.dom.leftContainer.appendChild(this.dom.shadowBottomLeft),this.dom.rightContainer.appendChild(this.dom.shadowTopRight),this.dom.rightContainer.appendChild(this.dom.shadowBottomRight),this.props={root:{},background:{},centerContainer:{},leftContainer:{},rightContainer:{},center:{},left:{},right:{},top:{},bottom:{},border:{},scrollTop:0,scrollTopMin:0},this.on("rangechange",(function(){!0===s.initialDrawDone&&s._redraw()})),this.on("rangechanged",(function(){s.initialRangeChangeDone||(s.initialRangeChangeDone=!0)})),this.on("touch",bs(e=this._onTouch).call(e,this)),this.on("panmove",bs(i=this._onDrag).call(i,this));var r=this;this._origRedraw=bs(n=this._redraw).call(n,this),this._redraw=to.throttle(this._origRedraw),this.on("_change",(function(t){r.itemSet&&r.itemSet.initialItemSetDrawn&&t&&1==t.queue?r._redraw():r._origRedraw()})),this.hammer=new _h(this.dom.root);var o=this.hammer.get("pinch").set({enable:!0});o&&function(t){t.getTouchAction=function(){return["pan-y"]}}(o),this.hammer.get("pan").set({threshold:5,direction:_h.DIRECTION_ALL}),this.listeners={};var a,l,h=["tap","doubletap","press","pinch","pan","panstart","panmove","panend"];function u(t){this.isActive()&&this.emit("mousewheel",t);var e=0,i=0;if("detail"in t&&(i=-1*t.detail),"wheelDelta"in t&&(i=t.wheelDelta),"wheelDeltaY"in t&&(i=t.wheelDeltaY),"wheelDeltaX"in t&&(e=-1*t.wheelDeltaX),"axis"in t&&t.axis===t.HORIZONTAL_AXIS&&(e=-1*i,i=0),"deltaY"in t&&(i=-1*t.deltaY),"deltaX"in t&&(e=t.deltaX),t.deltaMode&&(1===t.deltaMode?(e*=40,i*=40):(e*=40,i*=800)),this.options.preferZoom){if(!this.options.zoomKey||t[this.options.zoomKey])return}else if(this.options.zoomKey&&t[this.options.zoomKey])return;if(this.options.verticalScroll||this.options.horizontalScroll)if(this.options.verticalScroll&&Math.abs(i)>=Math.abs(e)){var n=this.props.scrollTop,s=n+i;if(this.isActive())this._setScrollTop(s)!==n&&(this._redraw(),this.emit("scroll",t),t.preventDefault())}else if(this.options.horizontalScroll){var r=(Math.abs(e)>=Math.abs(i)?e:i)/120*(this.range.end-this.range.start)/20,o=this.range.start+r,a=this.range.end+r,l={animation:!1,byUser:!0,event:t};this.range.setRange(o,a,l),t.preventDefault()}}is(h).call(h,(function(t){var e=function(e){r.isActive()&&r.emit(t,e)};r.hammer.on(t,e),r.listeners[t]=e})),bh(this.hammer,(function(t){r.emit("touch",t)})),a=this.hammer,(l=function(t){r.emit("release",t)}).inputHandler=function(t){t.isFinal&&l(t)},a.on("hammer.input",l.inputHandler);var d="onwheel"in document.createElement("div")?"wheel":void 0!==document.onmousewheel?"mousewheel":this.dom.centerContainer.addEventListener?"DOMMouseScroll":"onmousewheel";function c(t){if(r.options.verticalScroll&&(t.preventDefault(),r.isActive())){var e=-t.target.scrollTop;r._setScrollTop(e),r._redraw(),r.emit("scrollSide",t)}}this.dom.top.addEventListener,this.dom.bottom.addEventListener,this.dom.centerContainer.addEventListener(d,bs(u).call(u,this),!1),this.dom.top.addEventListener(d,bs(u).call(u,this),!1),this.dom.bottom.addEventListener(d,bs(u).call(u,this),!1),this.dom.left.parentNode.addEventListener("scroll",bs(c).call(c,this)),this.dom.right.parentNode.addEventListener("scroll",bs(c).call(c,this));var f=!1;function m(t){var e;if(t.preventDefault&&(r.emit("dragover",r.getEventProperties(t)),t.preventDefault()),la(e=t.target.className).call(e,"timeline")>-1&&!f)return t.dataTransfer.dropEffect="move",f=!0,!1}function p(t){t.preventDefault&&t.preventDefault(),t.stopPropagation&&t.stopPropagation();try{var e=JSON.parse(t.dataTransfer.getData("text"));if(!e||!e.content)return}catch(t){return!1}return f=!1,t.center={x:t.clientX,y:t.clientY},"item"!==e.target?r.itemSet._onAddItem(t):r.itemSet._onDropObjectOnItem(t),r.emit("drop",r.getEventProperties(t)),!1}if(this.dom.center.addEventListener("dragover",bs(m).call(m,this),!1),this.dom.center.addEventListener("drop",bs(p).call(p,this),!1),this.customTimes=[],this.touch={},this.redrawCount=0,this.initialDrawDone=!1,this.initialRangeChangeDone=!1,!t)throw new Error("No container provided");t.appendChild(this.dom.root),t.appendChild(this.dom.loadingScreen)}},{key:"setOptions",value:function(t){var e;if(t){if(to.selectiveExtend(["width","height","minHeight","maxHeight","autoResize","start","end","clickToUse","dataAttributes","hiddenDates","locale","locales","moment","preferZoom","rtl","zoomKey","horizontalScroll","verticalScroll"],this.options,t),this.dom.rollingModeBtn.style.visibility="hidden",this.options.rtl&&(this.dom.container.style.direction="rtl",this.dom.backgroundVertical.className="vis-panel vis-background vis-vertical-rtl"),this.options.verticalScroll&&(this.options.rtl?this.dom.rightContainer.className="vis-panel vis-right vis-vertical-scroll":this.dom.leftContainer.className="vis-panel vis-left vis-vertical-scroll"),"object"!==Tr(this.options.orientation)&&(this.options.orientation={item:void 0,axis:void 0}),"orientation"in t&&("string"==typeof t.orientation?this.options.orientation={item:t.orientation,axis:t.orientation}:"object"===Tr(t.orientation)&&("item"in t.orientation&&(this.options.orientation.item=t.orientation.item),"axis"in t.orientation&&(this.options.orientation.axis=t.orientation.axis))),"both"===this.options.orientation.axis){if(!this.timeAxis2){var i=this.timeAxis2=new Th(this.body);i.setOptions=function(t){var e=t?to.extend({},t):{};e.orientation="top",Th.prototype.setOptions.call(i,e)},this.components.push(i)}}else if(this.timeAxis2){var n,s,r=la(n=this.components).call(n,this.timeAxis2);if(-1!==r)ea(s=this.components).call(s,r,1);this.timeAxis2.destroy(),this.timeAxis2=null}"function"==typeof t.drawPoints&&(t.drawPoints={onRender:t.drawPoints}),"hiddenDates"in this.options&&Yo(this.options.moment,this.body,this.options.hiddenDates),"clickToUse"in t&&(t.clickToUse?this.activator||(this.activator=new Yh(this.dom.root)):this.activator&&(this.activator.destroy(),delete this.activator)),this._initAutoResize()}if(is(e=this.components).call(e,(function(e){return e.setOptions(t)})),"configure"in t){var o;this.configurator||(this.configurator=this._createConfigurator()),this.configurator.setOptions(t.configure);var a=to.deepExtend({},this.options);is(o=this.components).call(o,(function(t){to.deepExtend(a,t.options)})),this.configurator.setModuleOptions({global:a})}this._redraw()}},{key:"isActive",value:function(){return!this.activator||this.activator.active}},{key:"destroy",value:function(){var t;for(var e in this.setItems(null),this.setGroups(null),this.off(),this._stopAutoResize(),this.dom.root.parentNode&&this.dom.root.parentNode.removeChild(this.dom.root),this.dom=null,this.activator&&(this.activator.destroy(),delete this.activator),this.listeners)this.listeners.hasOwnProperty(e)&&delete this.listeners[e];this.listeners=null,this.hammer&&this.hammer.destroy(),this.hammer=null,is(t=this.components).call(t,(function(t){return t.destroy()})),this.body=null}},{key:"setCustomTime",value:function(t,e){var i,n=ls(i=this.customTimes).call(i,(function(t){return e===t.options.id}));if(0===n.length)throw new Error("No custom time bar found with id ".concat(mo(e)));n.length>0&&n[0].setCustomTime(t)}},{key:"getCustomTime",value:function(t){var e,i=ls(e=this.customTimes).call(e,(function(e){return e.options.id===t}));if(0===i.length)throw new Error("No custom time bar found with id ".concat(mo(t)));return i[0].getCustomTime()}},{key:"setCustomTimeMarker",value:function(t,e,i){var n,s=ls(n=this.customTimes).call(n,(function(t){return t.options.id===e}));if(0===s.length)throw new Error("No custom time bar found with id ".concat(mo(e)));s.length>0&&s[0].setCustomMarker(t,i)}},{key:"setCustomTimeTitle",value:function(t,e){var i,n=ls(i=this.customTimes).call(i,(function(t){return t.options.id===e}));if(0===n.length)throw new Error("No custom time bar found with id ".concat(mo(e)));if(n.length>0)return n[0].setCustomTitle(t)}},{key:"getEventProperties",value:function(t){return{event:t}}},{key:"addCustomTime",value:function(t,e){var i,n=void 0!==t?to.convert(t,"Date").valueOf():new Date;if($o(i=this.customTimes).call(i,(function(t){return t.options.id===e})))throw new Error("A custom time with id ".concat(mo(e)," already exists"));var s=new Gh(this.body,to.extend({},this.options,{time:n,id:e}));return this.customTimes.push(s),this.components.push(s),this._redraw(),e}},{key:"removeCustomTime",value:function(t){var e,i=this,n=ls(e=this.customTimes).call(e,(function(e){return e.options.id===t}));if(0===n.length)throw new Error("No custom time bar found with id ".concat(mo(t)));is(n).call(n,(function(t){var e,n,s,r;ea(e=i.customTimes).call(e,la(n=i.customTimes).call(n,t),1),ea(s=i.components).call(s,la(r=i.components).call(r,t),1),t.destroy()}))}},{key:"getVisibleItems",value:function(){return this.itemSet&&this.itemSet.getVisibleItems()||[]}},{key:"getVisibleGroups",value:function(){return this.itemSet&&this.itemSet.getVisibleGroups()||[]}},{key:"fit",value:function(t,e){var i=this.getDataRange();if(null!==i.min||null!==i.max){var n=i.max-i.min,s=new Date(i.min.valueOf()-.01*n),r=new Date(i.max.valueOf()+.01*n),o=!t||void 0===t.animation||t.animation;this.range.setRange(s,r,{animation:o},e)}}},{key:"getDataRange",value:function(){throw new Error("Cannot invoke abstract method getDataRange")}},{key:"setWindow",value:function(t,e,i,n){var s,r;"function"==typeof arguments[2]&&(n=arguments[2],i={}),1==arguments.length?(s=void 0===(r=arguments[0]).animation||r.animation,this.range.setRange(r.start,r.end,{animation:s})):2==arguments.length&&"function"==typeof arguments[1]?(r=arguments[0],n=arguments[1],s=void 0===r.animation||r.animation,this.range.setRange(r.start,r.end,{animation:s},n)):(s=!i||void 0===i.animation||i.animation,this.range.setRange(t,e,{animation:s},n))}},{key:"moveTo",value:function(t,e,i){"function"==typeof arguments[1]&&(i=arguments[1],e={});var n=this.range.end-this.range.start,s=to.convert(t,"Date").valueOf(),r=s-n/2,o=s+n/2,a=!e||void 0===e.animation||e.animation;this.range.setRange(r,o,{animation:a},i)}},{key:"getWindow",value:function(){var t=this.range.getRange();return{start:new Date(t.start),end:new Date(t.end)}}},{key:"zoomIn",value:function(t,e,i){if(!(!t||t<0||t>1)){"function"==typeof arguments[1]&&(i=arguments[1],e={});var n=this.getWindow(),s=n.start.valueOf(),r=n.end.valueOf(),o=r-s,a=o/(1+t),l=(o-a)/2,h=s+l,u=r-l;this.setWindow(h,u,e,i)}}},{key:"zoomOut",value:function(t,e,i){if(!(!t||t<0||t>1)){"function"==typeof arguments[1]&&(i=arguments[1],e={});var n=this.getWindow(),s=n.start.valueOf(),r=n.end.valueOf(),o=r-s,a=s-o*t/2,l=r+o*t/2;this.setWindow(a,l,e,i)}}},{key:"redraw",value:function(){this._redraw()}},{key:"_redraw",value:function(){var t;this.redrawCount++;var e=this.dom;if(e&&e.container&&0!=e.root.offsetWidth){var i=!1,n=this.options,s=this.props;Po(this.options.moment,this.body,this.options.hiddenDates),"top"==n.orientation?(to.addClassName(e.root,"vis-top"),to.removeClassName(e.root,"vis-bottom")):(to.removeClassName(e.root,"vis-top"),to.addClassName(e.root,"vis-bottom")),n.rtl?(to.addClassName(e.root,"vis-rtl"),to.removeClassName(e.root,"vis-ltr")):(to.addClassName(e.root,"vis-ltr"),to.removeClassName(e.root,"vis-rtl")),e.root.style.maxHeight=to.option.asSize(n.maxHeight,""),e.root.style.minHeight=to.option.asSize(n.minHeight,""),e.root.style.width=to.option.asSize(n.width,"");var r=e.root.offsetWidth;s.border.left=1,s.border.right=1,s.border.top=1,s.border.bottom=1,s.center.height=e.center.offsetHeight,s.left.height=e.left.offsetHeight,s.right.height=e.right.offsetHeight,s.top.height=e.top.clientHeight||-s.border.top,s.bottom.height=e.bottom.clientHeight||-s.border.bottom;var o=Math.max(s.left.height,s.center.height,s.right.height),a=s.top.height+o+s.bottom.height+s.border.top+s.border.bottom;e.root.style.height=to.option.asSize(n.height,"".concat(a,"px")),s.root.height=e.root.offsetHeight,s.background.height=s.root.height;var l=s.root.height-s.top.height-s.bottom.height;s.centerContainer.height=l,s.leftContainer.height=l,s.rightContainer.height=s.leftContainer.height,s.root.width=r,s.background.width=s.root.width,this.initialDrawDone||(s.scrollbarWidth=to.getScrollBarWidth());var h=e.leftContainer.clientWidth,u=e.rightContainer.clientWidth;n.verticalScroll?n.rtl?(s.left.width=h||-s.border.left,s.right.width=u+s.scrollbarWidth||-s.border.right):(s.left.width=h+s.scrollbarWidth||-s.border.left,s.right.width=u||-s.border.right):(s.left.width=h||-s.border.left,s.right.width=u||-s.border.right),this._setDOM();var d=this._updateScrollTop();"top"!=n.orientation.item&&(d+=Math.max(s.centerContainer.height-s.center.height-s.border.top-s.border.bottom,0)),e.center.style.transform="translateY(".concat(d,"px)");var c=0==s.scrollTop?"hidden":"",f=s.scrollTop==s.scrollTopMin?"hidden":"";e.shadowTop.style.visibility=c,e.shadowBottom.style.visibility=f,e.shadowTopLeft.style.visibility=c,e.shadowBottomLeft.style.visibility=f,e.shadowTopRight.style.visibility=c,e.shadowBottomRight.style.visibility=f,n.verticalScroll&&(e.rightContainer.className="vis-panel vis-right vis-vertical-scroll",e.leftContainer.className="vis-panel vis-left vis-vertical-scroll",e.shadowTopRight.style.visibility="hidden",e.shadowBottomRight.style.visibility="hidden",e.shadowTopLeft.style.visibility="hidden",e.shadowBottomLeft.style.visibility="hidden",e.left.style.top="0px",e.right.style.top="0px"),(!n.verticalScroll||s.center.height<s.centerContainer.height)&&(e.left.style.top="".concat(d,"px"),e.right.style.top="".concat(d,"px"),e.rightContainer.className=e.rightContainer.className.replace(new RegExp("(?:^|\\s)vis-vertical-scroll(?:\\s|$)")," "),e.leftContainer.className=e.leftContainer.className.replace(new RegExp("(?:^|\\s)vis-vertical-scroll(?:\\s|$)")," "),s.left.width=h||-s.border.left,s.right.width=u||-s.border.right,this._setDOM());var m=s.center.height>s.centerContainer.height;this.hammer.get("pan").set({direction:m?_h.DIRECTION_ALL:_h.DIRECTION_HORIZONTAL}),is(t=this.components).call(t,(function(t){i=t.redraw()||i}));if(i){if(this.redrawCount<5)return void this.body.emitter.emit("_change");console.log("WARNING: infinite loop in redraw?")}else this.redrawCount=0;this.body.emitter.emit("changed")}}},{key:"_setDOM",value:function(){var t=this.props,e=this.dom;t.leftContainer.width=t.left.width,t.rightContainer.width=t.right.width;var i=t.root.width-t.left.width-t.right.width;t.center.width=i,t.centerContainer.width=i,t.top.width=i,t.bottom.width=i,e.background.style.height="".concat(t.background.height,"px"),e.backgroundVertical.style.height="".concat(t.background.height,"px"),e.backgroundHorizontal.style.height="".concat(t.centerContainer.height,"px"),e.centerContainer.style.height="".concat(t.centerContainer.height,"px"),e.leftContainer.style.height="".concat(t.leftContainer.height,"px"),e.rightContainer.style.height="".concat(t.rightContainer.height,"px"),e.background.style.width="".concat(t.background.width,"px"),e.backgroundVertical.style.width="".concat(t.centerContainer.width,"px"),e.backgroundHorizontal.style.width="".concat(t.background.width,"px"),e.centerContainer.style.width="".concat(t.center.width,"px"),e.top.style.width="".concat(t.top.width,"px"),e.bottom.style.width="".concat(t.bottom.width,"px"),e.background.style.left="0",e.background.style.top="0",e.backgroundVertical.style.left="".concat(t.left.width+t.border.left,"px"),e.backgroundVertical.style.top="0",e.backgroundHorizontal.style.left="0",e.backgroundHorizontal.style.top="".concat(t.top.height,"px"),e.centerContainer.style.left="".concat(t.left.width,"px"),e.centerContainer.style.top="".concat(t.top.height,"px"),e.leftContainer.style.left="0",e.leftContainer.style.top="".concat(t.top.height,"px"),e.rightContainer.style.left="".concat(t.left.width+t.center.width,"px"),e.rightContainer.style.top="".concat(t.top.height,"px"),e.top.style.left="".concat(t.left.width,"px"),e.top.style.top="0",e.bottom.style.left="".concat(t.left.width,"px"),e.bottom.style.top="".concat(t.top.height+t.centerContainer.height,"px"),e.center.style.left="0",e.left.style.left="0",e.right.style.left="0"}},{key:"setCurrentTime",value:function(t){if(!this.currentTime)throw new Error("Option showCurrentTime must be true");this.currentTime.setCurrentTime(t)}},{key:"getCurrentTime",value:function(){if(!this.currentTime)throw new Error("Option showCurrentTime must be true");return this.currentTime.getCurrentTime()}},{key:"_toTime",value:function(t){return Ao(this,t,this.props.center.width)}},{key:"_toGlobalTime",value:function(t){return Ao(this,t,this.props.root.width)}},{key:"_toScreen",value:function(t){return Io(this,t,this.props.center.width)}},{key:"_toGlobalScreen",value:function(t){return Io(this,t,this.props.root.width)}},{key:"_initAutoResize",value:function(){1==this.options.autoResize?this._startAutoResize():this._stopAutoResize()}},{key:"_startAutoResize",value:function(){var t=this;this._stopAutoResize(),this._onResize=function(){if(1==t.options.autoResize){if(t.dom.root){var e=t.dom.root.offsetHeight,i=t.dom.root.offsetWidth;i==t.props.lastWidth&&e==t.props.lastHeight||(t.props.lastWidth=i,t.props.lastHeight=e,t.props.scrollbarWidth=to.getScrollBarWidth(),t.body.emitter.emit("_change"))}}else t._stopAutoResize()},to.addEventListener(window,"resize",this._onResize),t.dom.root&&(t.props.lastWidth=t.dom.root.offsetWidth,t.props.lastHeight=t.dom.root.offsetHeight),this.watchTimer=Bo(this._onResize,1e3)}},{key:"_stopAutoResize",value:function(){this.watchTimer&&(clearInterval(this.watchTimer),this.watchTimer=void 0),this._onResize&&(to.removeEventListener(window,"resize",this._onResize),this._onResize=null)}},{key:"_onTouch",value:function(t){this.touch.allowDragging=!0,this.touch.initialScrollTop=this.props.scrollTop}},{key:"_onPinch",value:function(t){this.touch.allowDragging=!1}},{key:"_onDrag",value:function(t){if(t&&this.touch.allowDragging){var e=t.deltaY,i=this._getScrollTop(),n=this._setScrollTop(this.touch.initialScrollTop+e);this.options.verticalScroll&&(this.dom.left.parentNode.scrollTop=-this.props.scrollTop,this.dom.right.parentNode.scrollTop=-this.props.scrollTop),n!=i&&this.emit("verticalDrag")}}},{key:"_setScrollTop",value:function(t){return this.props.scrollTop=t,this._updateScrollTop(),this.props.scrollTop}},{key:"_updateScrollTop",value:function(){var t=Math.min(this.props.centerContainer.height-this.props.center.height,0);return t!=this.props.scrollTopMin&&("top"!=this.options.orientation.item&&(this.props.scrollTop+=t-this.props.scrollTopMin),this.props.scrollTopMin=t),this.props.scrollTop>0&&(this.props.scrollTop=0),this.props.scrollTop<t&&(this.props.scrollTop=t),this.options.verticalScroll&&(this.dom.left.parentNode.scrollTop=-this.props.scrollTop,this.dom.right.parentNode.scrollTop=-this.props.scrollTop),this.props.scrollTop}},{key:"_getScrollTop",value:function(){return this.props.scrollTop}},{key:"_createConfigurator",value:function(){throw new Error("Cannot invoke abstract method _createConfigurator")}}]),t}();ha(Wh.prototype);var zh=function(t){function e(t,i){var n,s;Ds(this,e),(s=Cr(this,Lr(e).call(this))).body=t,s.defaultOptions={rtl:!1,showCurrentTime:!0,alignCurrentTime:void 0,moment:Hr,locales:Hh,locale:"en"},s.options=to.extend({},s.defaultOptions),s.setOptions(i),s.options.locales=to.extend({},Hh,s.options.locales);var r=s.defaultOptions.locales[s.defaultOptions.locale];return is(n=$r(s.options.locales)).call(n,(function(t){s.options.locales[t]=to.extend({},r,s.options.locales[t])})),s.offset=0,s._create(),s}return jr(e,t),Ts(e,[{key:"_create",value:function(){var t=document.createElement("div");t.className="vis-current-time",t.style.position="absolute",t.style.top="0px",t.style.height="100%",this.bar=t}},{key:"destroy",value:function(){this.options.showCurrentTime=!1,this.redraw(),this.body=null}},{key:"setOptions",value:function(t){t&&to.selectiveExtend(["rtl","showCurrentTime","alignCurrentTime","moment","locale","locales"],this.options,t)}},{key:"redraw",value:function(){if(this.options.showCurrentTime){var t,e,i=this.body.dom.backgroundVertical;this.bar.parentNode!=i&&(this.bar.parentNode&&this.bar.parentNode.removeChild(this.bar),i.appendChild(this.bar),this.start());var n=this.options.moment(co()+this.offset);this.options.alignCurrentTime&&(n=n.startOf(this.options.alignCurrentTime));var s=this.body.util.toScreen(n),r=this.options.locales[this.options.locale];r||(this.warned||(console.warn("WARNING: options.locales['".concat(this.options.locale,"'] not found. See https://visjs.github.io/vis-timeline/docs/timeline/#Localization")),this.warned=!0),r=this.options.locales.en);var o=vo(t=vo(e="".concat(r.current," ")).call(e,r.time,": ")).call(t,n.format("dddd, MMMM Do YYYY, H:mm:ss"));o=o.charAt(0).toUpperCase()+o.substring(1),this.options.rtl?this.bar.style.transform="translateX(".concat(-1*s,"px)"):this.bar.style.transform="translateX(".concat(s,"px)"),this.bar.title=o}else this.bar.parentNode&&this.bar.parentNode.removeChild(this.bar),this.stop();return!1}},{key:"start",value:function(){var t=this;!function e(){t.stop();var i=1/t.body.range.conversion(t.body.domProps.center.width).scale/10;i<30&&(i=30),i>1e3&&(i=1e3),t.redraw(),t.body.emitter.emit("currentTimeTick"),t.currentTimeTimer=fs(e,i)}()}},{key:"stop",value:function(){void 0!==this.currentTimeTimer&&(clearTimeout(this.currentTimeTimer),delete this.currentTimeTimer)}},{key:"setCurrentTime",value:function(t){var e=to.convert(t,"Date").valueOf(),i=co();this.offset=e-i,this.redraw()}},{key:"getCurrentTime",value:function(){return new Date(co()+this.offset)}}]),e}(yo),Uh=!De((function(){return Object.isExtensible(Object.preventExtensions({}))})),Vh=Le((function(t){var e=$e.f,i=ai("meta"),n=0,s=Object.isExtensible||function(){return!0},r=function(t){e(t,i,{value:{objectID:"O"+ ++n,weakData:{}}})},o=t.exports={REQUIRED:!1,fastKey:function(t,e){if(!We(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!si(t,i)){if(!s(t))return"F";if(!e)return"E";r(t)}return t[i].objectID},getWeakData:function(t,e){if(!si(t,i)){if(!s(t))return!0;if(!e)return!1;r(t)}return t[i].weakData},onFreeze:function(t){return Uh&&o.REQUIRED&&s(t)&&!si(t,i)&&r(t),t}};ui[i]=!0})),Bh=(Vh.REQUIRED,Vh.fastKey,Vh.getWeakData,Vh.onFreeze,Xi("iterator")),Xh=Array.prototype,qh=function(t){return void 0!==t&&(Ye.Array===t||Xh[Bh]===t)},Zh=Xi("iterator"),$h=function(t){if(null!=t)return t[Zh]||t["@@iterator"]||Ye[wn(t)]},Jh=function(t,e,i,n){try{return n?e(Xe(i)[0],i[1]):e(i)}catch(e){var s=t.return;throw void 0!==s&&Xe(s.call(t)),e}},Kh=Le((function(t){var e=function(t,e){this.stopped=t,this.result=e};(t.exports=function(t,i,n,s,r){var o,a,l,h,u,d,c=Ai(i,n,s?2:1);if(r)o=t;else{if("function"!=typeof(a=$h(t)))throw TypeError("Target is not iterable");if(qh(a)){for(l=0,h=tn(t.length);h>l;l++)if((u=s?c(Xe(d=t[l])[0],d[1]):c(t[l]))&&u instanceof e)return u;return new e(!1)}o=a.call(t)}for(;!(d=o.next()).done;)if((u=Jh(o,c,d.value,s))&&u instanceof e)return u;return new e(!1)}).stop=function(t){return new e(!0,t)}})),Qh=function(t,e,i){if(!(t instanceof e))throw TypeError("Incorrect "+(i?i+" ":"")+"invocation");return t},tu=$e.f,eu=qn.forEach,iu=bi.set,nu=bi.getterFor,su=function(t,e,i){for(var n in e)i&&i.unsafe&&t[n]?t[n]=e[n]:Pn(t,n,e[n],i);return t},ru=Xi("species"),ou=$e.f,au=Vh.fastKey,lu=bi.set,hu=bi.getterFor,uu=(function(t,e,i,n,s){var r,o=He[t],a=o&&o.prototype,l=n?"set":"add",h={};if(Ge&&"function"==typeof o&&(s||a.forEach&&!De((function(){(new o).entries().next()})))){r=e((function(e,i){iu(Qh(e,r,t),{type:t,collection:new o}),null!=i&&Kh(i,e[l],e,n)}));var u=nu(t);eu(["add","clear","delete","forEach","get","has","set","keys","values","entries"],(function(t){var e="add"==t||"set"==t;t in a&&(!s||"clear"!=t)&&Ke(r.prototype,t,(function(i,n){var r=u(this).collection;if(!e&&s&&!We(i))return"get"==t&&void 0;var o=r[t](0===i?0:i,n);return e?this:o}))})),s||tu(r.prototype,"size",{get:function(){return u(this).collection.size}})}else r=i.getConstructor(e,t,n,l),Vh.REQUIRED=!0;Tn(r,t,!1,!0),h[t]=r,ji({global:!0,forced:!0},h),s||i.setStrong(r,t,n)}("Set",(function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}}),{getConstructor:function(t,e,i,n){var s=t((function(t,r){Qh(t,s,e),lu(t,{type:e,index:yn(null),first:void 0,last:void 0,size:0}),Ge||(t.size=0),null!=r&&Kh(r,t[n],t,i)})),r=hu(e),o=function(t,e,i){var n,s,o=r(t),l=a(t,e);return l?l.value=i:(o.last=l={index:s=au(e,!0),key:e,value:i,previous:n=o.last,next:void 0,removed:!1},o.first||(o.first=l),n&&(n.next=l),Ge?o.size++:t.size++,"F"!==s&&(o.index[s]=l)),t},a=function(t,e){var i,n=r(t),s=au(e);if("F"!==s)return n.index[s];for(i=n.first;i;i=i.next)if(i.key==e)return i};return su(s.prototype,{clear:function(){for(var t=r(this),e=t.index,i=t.first;i;)i.removed=!0,i.previous&&(i.previous=i.previous.next=void 0),delete e[i.index],i=i.next;t.first=t.last=void 0,Ge?t.size=0:this.size=0},delete:function(t){var e=r(this),i=a(this,t);if(i){var n=i.next,s=i.previous;delete e.index[i.index],i.removed=!0,s&&(s.next=n),n&&(n.previous=s),e.first==i&&(e.first=n),e.last==i&&(e.last=s),Ge?e.size--:this.size--}return!!i},forEach:function(t){for(var e,i=r(this),n=Ai(t,arguments.length>1?arguments[1]:void 0,3);e=e?e.next:i.first;)for(n(e.value,e.key,this);e&&e.removed;)e=e.previous},has:function(t){return!!a(this,t)}}),su(s.prototype,i?{get:function(t){var e=a(this,t);return e&&e.value},set:function(t,e){return o(this,0===t?0:t,e)}}:{add:function(t){return o(this,t=0===t?0:t,t)}}),Ge&&ou(s.prototype,"size",{get:function(){return r(this).size}}),s},setStrong:function(t,e,i){var n=e+" Iterator",s=hu(e),r=hu(n);Nn(t,e,(function(t,e){lu(this,{type:n,target:t,state:s(t),kind:e,last:void 0})}),(function(){for(var t=r(this),e=t.kind,i=t.last;i&&i.removed;)i=i.previous;return t.target&&(t.last=i=i?i.next:t.state.first)?"keys"==e?{value:i.key,done:!1}:"values"==e?{value:i.value,done:!1}:{value:[i.key,i.value],done:!1}:(t.target=void 0,{value:void 0,done:!0})}),i?"entries":"values",!i,!0),function(t){var e=fn(t),i=$e.f;Ge&&e&&!e[ru]&&i(e,ru,{configurable:!0,get:function(){return this}})}(e)}}),Li.Set),du=qn.map;ji({target:"Array",proto:!0,forced:!ss("map")},{map:function(t){return du(this,t,arguments.length>1?arguments[1]:void 0)}});var cu=Kn("Array").map,fu=Array.prototype,mu=function(t){var e=t.map;return t===fu||t instanceof Array&&e===fu.map?cu:e},pu=Ar,gu=qn.find,vu=!0;"find"in[]&&Array(1).find((function(){vu=!1})),ji({target:"Array",proto:!0,forced:vu},{find:function(t){return gu(this,t,arguments.length>1?arguments[1]:void 0)}});var yu=Kn("Array").find,_u=Array.prototype,bu=function(t){var e=t.find;return t===_u||t instanceof Array&&e===_u.find?yu:e},wu=function(t){var e=$h(t);if("function"!=typeof e)throw TypeError(String(t)+" is not iterable");return Xe(e.call(t))},ku=ws;var Du=function(t){if(ku(t)){for(var e=0,i=new Array(t.length);e<t.length;e++)i[e]=t[e];return i}},Su=Xi("iterator"),xu=!1;try{var Mu=0,Tu={next:function(){return{done:!!Mu++}},return:function(){xu=!0}};Tu[Su]=function(){return this},Array.from(Tu,(function(){throw 2}))}catch(t){}var Ou=!function(t,e){if(!e&&!xu)return!1;var i=!1;try{var n={};n[Su]=function(){return{next:function(){return{done:i=!0}}}},t(n)}catch(t){}return i}((function(t){Array.from(t)}));ji({target:"Array",stat:!0,forced:Ou},{from:function(t){var e,i,n,s,r=Fi(t),o="function"==typeof this?this:Array,a=arguments.length,l=a>1?arguments[1]:void 0,h=void 0!==l,u=0,d=$h(r);if(h&&(l=Ai(l,a>2?arguments[2]:void 0,2)),null==d||o==Array&&qh(d))for(i=new o(e=tn(r.length));e>u;u++)Ns(i,u,h?l(r[u],u):r[u]);else for(s=d.call(r),i=new o;!(n=s.next()).done;u++)Ns(i,u,h?Jh(s,l,[n.value,u],!0):n.value);return i.length=u,i}});var Cu=Li.Array.from,Yu=Xi("iterator"),Pu=function(t){var e=Object(t);return void 0!==e[Yu]||"@@iterator"in e||Ye.hasOwnProperty(wn(e))};var Eu=function(t){if(Pu(Object(t))||"[object Arguments]"===Object.prototype.toString.call(t))return Cu(t)};var Lu=function(){throw new TypeError("Invalid attempt to spread non-iterable instance")};var Iu=function(t){return Du(t)||Eu(t)||Lu()},Au=Object.assign,Nu=!Au||De((function(){var t={},e={},i=Symbol();return t[i]=7,"abcdefghijklmnopqrst".split("").forEach((function(t){e[t]=t})),7!=Au({},t)[i]||"abcdefghijklmnopqrst"!=un(Au({},e)).join("")}))?function(t,e){for(var i=Fi(t),n=arguments.length,s=1,r=qs.f,o=Di.f;n>s;)for(var a,l=Te(arguments[s++]),h=r?un(l).concat(r(l)):un(l),u=h.length,d=0;u>d;)a=h[d++],Ge&&!o.call(l,a)||(i[a]=l[a]);return i}:Au;ji({target:"Object",stat:!0,forced:Object.assign!==Nu},{assign:Nu});var Ru=Li.Object.assign,ju=on.includes;ji({target:"Array",proto:!0},{includes:function(t){return ju(this,t,arguments.length>1?arguments[1]:void 0)}});var Fu=Kn("Array").includes,Hu=Xi("match"),Gu=function(t){if(function(t){var e;return We(t)&&(void 0!==(e=t[Hu])?!!e:"RegExp"==xe(t))}(t))throw TypeError("The method doesn't accept regular expressions");return t},Wu=Xi("match");ji({target:"String",proto:!0,forced:!function(t){var e=/./;try{"/./"[t](e)}catch(i){try{return e[Wu]=!1,"/./"[t](e)}catch(t){}}return!1}("includes")},{includes:function(t){return!!~String(Oe(this)).indexOf(Gu(t),arguments.length>1?arguments[1]:void 0)}});var zu=Kn("String").includes,Uu=Array.prototype,Vu=String.prototype,Bu=function(t){var e=t.includes;return t===Uu||t instanceof Array&&e===Uu.includes?Fu:"string"==typeof t||t===Vu||t instanceof String&&e===Vu.includes?zu:e},Xu=Xi("species"),qu=[].slice,Zu=Math.max;ji({target:"Array",proto:!0,forced:!ss("slice")},{slice:function(t,e){var i,n,s,r=Ce(this),o=tn(r.length),a=sn(t,o),l=sn(void 0===e?o:e,o);if(zn(r)&&("function"!=typeof(i=r.constructor)||i!==Array&&!zn(i.prototype)?We(i)&&null===(i=i[Xu])&&(i=void 0):i=void 0,i===Array||void 0===i))return qu.call(r,a,l);for(n=new(void 0===i?Array:i)(Zu(l-a,0)),s=0;a<l;a++,s++)a in r&&Ns(n,s,r[a]);return n.length=s,n}});var $u=Kn("Array").slice,Ju=Array.prototype,Ku=function(t){var e=t.slice;return t===Ju||t instanceof Array&&e===Ju.slice?$u:e},Qu=.001;function td(t){Mo(t).call(t,(function(t,e){return t.data.start-e.data.start}))}function ed(t){Mo(t).call(t,(function(t,e){return("end"in t.data?t.data.end:t.data.start)-("end"in e.data?e.data.end:e.data.start)}))}function id(t,e,i,n){if(i)for(var s=0;s<t.length;s++)t[s].top=null;for(s=0;s<t.length;s++){var r=t[s];if(r.stack&&null===r.top){r.top=e.axis;var o=!1;do{for(var a=null,l=0,h=t.length;l<h;l++){var u=t[l];if(o=n()||!1)return!0;if(null!==u.top&&u!==r&&u.stack&&ad(r,u,e.item,u.options.rtl)){a=u;break}}null!=a&&(r.top=a.top+a.height+e.item.vertical)}while(a)}}return o}function nd(t,e,i){for(var n=0;n<t.length;n++)t[n].top=null;var s=i.height;for(n=0;n<t.length;n++){var r=t[n];if(r.stack&&null===r.top){r.top=r.baseTop;do{for(var o=null,a=0,l=t.length;a<l;a++){var h=t[a];if(null!==h.top&&h!==r&&ad(r,h,e.item,h.options.rtl)){o=h;break}}null!=o&&(r.top=o.top+o.height+e.item.vertical),r.top+r.height>s&&(s=r.top+r.height)}while(o)}}i.height=s-i.top+.5*e.item.vertical}function sd(t,e,i,n){for(var s=0;s<t.length;s++)if(null==t[s].data.subgroup)t[s].top=e.item.vertical;else if(void 0!==t[s].data.subgroup&&n){var r=0;for(var o in i)i.hasOwnProperty(o)&&1==i[o].visible&&i[o].index<i[t[s].data.subgroup].index&&(r+=i[o].height,i[t[s].data.subgroup].top=r);t[s].top=r+.5*e.item.vertical}n||rd(t,e,i)}function rd(t,e,i){for(var n in i)if(i.hasOwnProperty(n)){i[n].top=0;do{var s=null;for(var r in i)if(null!==i[r].top&&r!==n&&i[n].index>i[r].index&&ld(i[n],i[r])){s=i[r];break}null!=s&&(i[n].top=s.top+s.height)}while(s)}for(var o=0;o<t.length;o++)void 0!==t[o].data.subgroup&&(t[o].top=i[t[o].data.subgroup].top+.5*e.item.vertical)}function od(t,e,i){var n=!1,s=[];for(var r in i)i[r].hasOwnProperty("index")?s[i[r].index]=r:s.push(r);for(var o=0;o<s.length;o++)if(r=s[o],i.hasOwnProperty(r)){for(var a in n=n||i[r].stack,i[r].top=0,i)i[a].visible&&i[r].index>i[a].index&&(i[r].top+=i[a].height);for(var l=t[r],h=0;h<l.length;h++)void 0!==l[h].data.subgroup&&(l[h].top=i[l[h].data.subgroup].top+.5*e.item.vertical,i[r].stack&&(l[h].baseTop=l[h].top));n&&i[r].stack&&nd(t[r],e,i[r])}}function ad(t,e,i,n){return n?t.right-i.horizontal+Qu<e.right+e.width&&t.right+t.width+i.horizontal-Qu>e.right&&t.top-i.vertical+Qu<e.top+e.height&&t.top+t.height+i.vertical-Qu>e.top:t.left-i.horizontal+Qu<e.left+e.width&&t.left+t.width+i.horizontal-Qu>e.left&&t.top-i.vertical+Qu<e.top+e.height&&t.top+t.height+i.vertical-Qu>e.top}function ld(t,e){return t.start<=e.start&&t.end>=e.start&&t.top<e.top+e.height&&t.top+t.height>e.top||e.start<=t.start&&e.end>=t.start&&e.top<t.top+t.height&&e.top+e.height>t.top}var hd=Object.freeze({orderByStart:td,orderByEnd:ed,stack:id,substack:nd,nostack:sd,stackSubgroups:rd,stackSubgroupsWithInnerStack:od,collision:ad,collisionByTimes:ld}),ud="__background__",dd=function(){function t(e,i,n){if(Ds(this,t),this.groupId=e,this.subgroups={},this.subgroupStack={},this.subgroupStackAll=!1,this.subgroupVisibility={},this.doInnerStack=!1,this.shouldBailStackItems=!1,this.subgroupIndex=0,this.subgroupOrderer=i&&i.subgroupOrder,this.itemSet=n,this.isVisible=null,this.stackDirty=!0,i&&i.nestedGroups&&(this.nestedGroups=i.nestedGroups,0==i.showNested?this.showNested=!1:this.showNested=!0),i&&i.subgroupStack)if("boolean"==typeof i.subgroupStack)this.doInnerStack=i.subgroupStack,this.subgroupStackAll=i.subgroupStack;else for(var s in i.subgroupStack)this.subgroupStack[s]=i.subgroupStack[s],this.doInnerStack=this.doInnerStack||i.subgroupStack[s];i&&i.heightMode?this.heightMode=i.heightMode:this.heightMode=n.options.groupHeightMode,this.nestedInGroup=null,this.dom={},this.props={label:{width:0,height:0}},this.className=null,this.items={},this.visibleItems=[],this.itemsInRange=[],this.orderedItems={byStart:[],byEnd:[]},this.checkRangedItems=!1;var r=this;this.itemSet.body.emitter.on("checkRangedItems",(function(){r.checkRangedItems=!0})),this._create(),this.setData(i)}return Ts(t,[{key:"_create",value:function(){var t=document.createElement("div");this.itemSet.options.groupEditable.order?t.className="vis-label draggable":t.className="vis-label",this.dom.label=t;var e=document.createElement("div");e.className="vis-inner",t.appendChild(e),this.dom.inner=e;var i=document.createElement("div");i.className="vis-group",i["vis-group"]=this,this.dom.foreground=i,this.dom.background=document.createElement("div"),this.dom.background.className="vis-group",this.dom.axis=document.createElement("div"),this.dom.axis.className="vis-group",this.dom.marker=document.createElement("div"),this.dom.marker.style.visibility="hidden",this.dom.marker.style.position="absolute",this.dom.marker.innerHTML="",this.dom.background.appendChild(this.dom.marker)}},{key:"setData",value:function(t){if(!this.itemSet.groupTouchParams.isDragging){var e,i,n;if(t&&t.subgroupVisibility)for(var s in t.subgroupVisibility)this.subgroupVisibility[s]=t.subgroupVisibility[s];if(this.itemSet.options&&this.itemSet.options.groupTemplate)e=(i=bs(n=this.itemSet.options.groupTemplate).call(n,this))(t,this.dom.inner);else e=t&&t.content;if(e instanceof Element){for(;this.dom.inner.firstChild;)this.dom.inner.removeChild(this.dom.inner.firstChild);this.dom.inner.appendChild(e)}else e instanceof Object&&e.isReactComponent||(e instanceof Object?i(t,this.dom.inner):this.dom.inner.innerHTML=null!=e?e:this.groupId||"");this.dom.label.title=t&&t.title||"",this.dom.inner.firstChild?to.removeClassName(this.dom.inner,"vis-hidden"):to.addClassName(this.dom.inner,"vis-hidden"),t&&t.nestedGroups?(this.nestedGroups&&this.nestedGroups==t.nestedGroups||(this.nestedGroups=t.nestedGroups),void 0===t.showNested&&void 0!==this.showNested||(0==t.showNested?this.showNested=!1:this.showNested=!0),to.addClassName(this.dom.label,"vis-nesting-group"),this.showNested?(to.removeClassName(this.dom.label,"collapsed"),to.addClassName(this.dom.label,"expanded")):(to.removeClassName(this.dom.label,"expanded"),to.addClassName(this.dom.label,"collapsed"))):this.nestedGroups&&(this.nestedGroups=null,to.removeClassName(this.dom.label,"collapsed"),to.removeClassName(this.dom.label,"expanded"),to.removeClassName(this.dom.label,"vis-nesting-group")),t&&(t.treeLevel||t.nestedInGroup)?(to.addClassName(this.dom.label,"vis-nested-group"),t.treeLevel?to.addClassName(this.dom.label,"vis-group-level-"+t.treeLevel):to.addClassName(this.dom.label,"vis-group-level-unknown-but-gte1")):to.addClassName(this.dom.label,"vis-group-level-0");var r=t&&t.className||null;r!=this.className&&(this.className&&(to.removeClassName(this.dom.label,this.className),to.removeClassName(this.dom.foreground,this.className),to.removeClassName(this.dom.background,this.className),to.removeClassName(this.dom.axis,this.className)),to.addClassName(this.dom.label,r),to.addClassName(this.dom.foreground,r),to.addClassName(this.dom.background,r),to.addClassName(this.dom.axis,r),this.className=r),this.style&&(to.removeCssText(this.dom.label,this.style),this.style=null),t&&t.style&&(to.addCssText(this.dom.label,t.style),this.style=t.style)}}},{key:"getLabelWidth",value:function(){return this.props.label.width}},{key:"_didMarkerHeightChange",value:function(){var t=this.dom.marker.clientHeight;if(t!=this.lastMarkerHeight){this.lastMarkerHeight=t;var e={},i=0;if(is(to).call(to,this.items,(function(t,n){if(t.dirty=!0,t.displayed){e[n]=t.redraw(!0),i=e[n].length}})),i>0)for(var n=function(t){is(to).call(to,e,(function(e){e[t]()}))},s=0;s<i;s++)n(s);return!0}return!1}},{key:"_calculateGroupSizeAndPosition",value:function(){var t=this.dom.foreground,e=t.offsetTop,i=t.offsetLeft,n=t.offsetWidth;this.top=e,this.right=i,this.width=n}},{key:"_shouldBailItemsRedraw",value:function(){var t=this,e=this.itemSet.options.onTimeout,i={relativeBailingTime:this.itemSet.itemsSettingTime,bailTimeMs:e&&e.timeoutMs,userBailFunction:e&&e.callback,shouldBailStackItems:this.shouldBailStackItems},n=null;if(!this.itemSet.initialDrawDone){if(i.shouldBailStackItems)return!0;Math.abs(co()-new Date(i.relativeBailingTime))>i.bailTimeMs&&(i.userBailFunction&&null==this.itemSet.userContinueNotBail?i.userBailFunction((function(e){t.itemSet.userContinueNotBail=e,n=!e})):n=0==t.itemSet.userContinueNotBail)}return n}},{key:"_redrawItems",value:function(t,e,i,n){var s=this;if(t||this.stackDirty||this.isVisible&&!e){var r,o,a,l,h,u,d={byEnd:ls(r=this.orderedItems.byEnd).call(r,(function(t){return!t.isCluster})),byStart:ls(o=this.orderedItems.byStart).call(o,(function(t){return!t.isCluster}))},c={byEnd:Iu(new uu(ls(a=mu(l=this.orderedItems.byEnd).call(l,(function(t){return t.cluster}))).call(a,(function(t){return!!t})))),byStart:Iu(new uu(ls(h=mu(u=this.orderedItems.byStart).call(u,(function(t){return t.cluster}))).call(h,(function(t){return!!t}))))},f=function(){var t,e,i,r=s._updateItemsInRange(d,ls(t=s.visibleItems).call(t,(function(t){return!t.isCluster})),n),o=s._updateClustersInRange(c,ls(e=s.visibleItems).call(e,(function(t){return t.isCluster})),n);return vo(i=[]).call(i,Iu(r),Iu(o))},m=function(t){var e={},i=function(i){var n,r=ls(n=s.visibleItems).call(n,(function(t){return t.data.subgroup===i}));e[i]=t?Mo(r).call(r,(function(e,i){return t(e.data,i.data)})):r};for(var n in s.subgroups)i(n);return e};if("function"==typeof this.itemSet.options.order){var p=this;if(this.doInnerStack&&this.itemSet.options.stackSubgroups){od(m(this.itemSet.options.order),i,this.subgroups),this.visibleItems=f(),this._updateSubGroupHeights(i)}else{var g,v,y,_;this.visibleItems=f(),this._updateSubGroupHeights(i);var b=Mo(g=ls(v=Ku(y=this.visibleItems).call(y)).call(v,(function(t){return t.isCluster||!t.isCluster&&!t.cluster}))).call(g,(function(t,e){return p.itemSet.options.order(t.data,e.data)}));this.shouldBailStackItems=id(b,i,!0,bs(_=this._shouldBailItemsRedraw).call(_,this))}}else{var w;if(this.visibleItems=f(),this._updateSubGroupHeights(i),this.itemSet.options.stack)if(this.doInnerStack&&this.itemSet.options.stackSubgroups)od(m(),i,this.subgroups);else this.shouldBailStackItems=id(this.visibleItems,i,!0,bs(w=this._shouldBailItemsRedraw).call(w,this));else sd(this.visibleItems,i,this.subgroups,this.itemSet.options.stackSubgroups)}for(var k=0;k<this.visibleItems.length;k++)this.visibleItems[k].repositionX(),void 0!==this.subgroupVisibility[this.visibleItems[k].data.subgroup]&&(this.subgroupVisibility[this.visibleItems[k].data.subgroup]||this.visibleItems[k].hide());this.itemSet.options.cluster&&is(to).call(to,this.items,(function(t){t.cluster&&t.displayed&&t.hide()})),this.shouldBailStackItems&&this.itemSet.body.emitter.emit("destroyTimeline"),this.stackDirty=!1}}},{key:"_didResize",value:function(t,e){t=to.updateProperty(this,"height",e)||t;var i=this.dom.inner.clientWidth,n=this.dom.inner.clientHeight;return t=to.updateProperty(this.props.label,"width",i)||t,t=to.updateProperty(this.props.label,"height",n)||t}},{key:"_applyGroupHeight",value:function(t){this.dom.background.style.height="".concat(t,"px"),this.dom.foreground.style.height="".concat(t,"px"),this.dom.label.style.height="".concat(t,"px")}},{key:"_updateItemsVerticalPosition",value:function(t){for(var e=0,i=this.visibleItems.length;e<i;e++){var n=this.visibleItems[e];n.repositionY(t),this.isVisible||this.groupId==ud||n.displayed&&n.hide()}}},{key:"redraw",value:function(t,e,i,n){var s,r,o,a,l,h,u,d=this,c=!1,f=this.isVisible,m=[function(){i=d._didMarkerHeightChange.call(d)||i},bs(s=this._updateSubGroupHeights).call(s,this,e),bs(r=this._calculateGroupSizeAndPosition).call(r,this),function(){var i;d.isVisible=bs(i=d._isGroupVisible).call(i,d)(t,e)},function(){var n;bs(n=d._redrawItems).call(n,d)(i,f,e,t)},bs(o=this._updateSubgroupsSizes).call(o,this),function(){var t;h=bs(t=d._calculateHeight).call(t,d)(e)},bs(a=this._calculateGroupSizeAndPosition).call(a,this),function(){var t;c=bs(t=d._didResize).call(t,d)(c,h)},function(){var t;bs(t=d._applyGroupHeight).call(t,d)(h)},function(){var t;bs(t=d._updateItemsVerticalPosition).call(t,d)(e)},bs(l=function(){return!d.isVisible&&d.height&&(c=!1),c}).call(l,this)];return n?m:(is(m).call(m,(function(t){u=t()})),u)}},{key:"_updateSubGroupHeights",value:function(t){var e=this;if($r(this.subgroups).length>0){var i=this;this._resetSubgroups(),is(to).call(to,this.visibleItems,(function(n){void 0!==n.data.subgroup&&(i.subgroups[n.data.subgroup].height=Math.max(i.subgroups[n.data.subgroup].height,n.height+t.item.vertical),i.subgroups[n.data.subgroup].visible=void 0===e.subgroupVisibility[n.data.subgroup]||Boolean(e.subgroupVisibility[n.data.subgroup]))}))}}},{key:"_isGroupVisible",value:function(t,e){return this.top<=t.body.domProps.centerContainer.height-t.body.domProps.scrollTop+e.axis&&this.top+this.height+e.axis>=-t.body.domProps.scrollTop}},{key:"_calculateHeight",value:function(t){var e,i;if((i="fixed"===this.heightMode?to.toArray(this.items):this.visibleItems).length>0){var n=i[0].top,s=i[0].top+i[0].height;if(is(to).call(to,i,(function(t){n=Math.min(n,t.top),s=Math.max(s,t.top+t.height)})),n>t.axis){var r=n-t.axis;s-=r,is(to).call(to,i,(function(t){t.top-=r}))}e=Math.ceil(s+t.item.vertical/2),"fitItems"!==this.heightMode&&(e=Math.max(e,this.props.label.height))}else e=this.props.label.height;return e}},{key:"show",value:function(){this.dom.label.parentNode||this.itemSet.dom.labelSet.appendChild(this.dom.label),this.dom.foreground.parentNode||this.itemSet.dom.foreground.appendChild(this.dom.foreground),this.dom.background.parentNode||this.itemSet.dom.background.appendChild(this.dom.background),this.dom.axis.parentNode||this.itemSet.dom.axis.appendChild(this.dom.axis)}},{key:"hide",value:function(){var t=this.dom.label;t.parentNode&&t.parentNode.removeChild(t);var e=this.dom.foreground;e.parentNode&&e.parentNode.removeChild(e);var i=this.dom.background;i.parentNode&&i.parentNode.removeChild(i);var n=this.dom.axis;n.parentNode&&n.parentNode.removeChild(n)}},{key:"add",value:function(t){var e;if(this.items[t.id]=t,t.setParent(this),this.stackDirty=!0,void 0!==t.data.subgroup&&(this._addToSubgroup(t),this.orderSubgroups()),!Bu(e=this.visibleItems).call(e,t)){var i=this.itemSet.body.range;this._checkIfVisible(t,this.visibleItems,i)}}},{key:"_addToSubgroup",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.data.subgroup;null!=e&&void 0===this.subgroups[e]&&(this.subgroups[e]={height:0,top:0,start:t.data.start,end:t.data.end||t.data.start,visible:!1,index:this.subgroupIndex,items:[],stack:this.subgroupStackAll||this.subgroupStack[e]||!1},this.subgroupIndex++),new Date(t.data.start)<new Date(this.subgroups[e].start)&&(this.subgroups[e].start=t.data.start);var i=t.data.end||t.data.start;new Date(i)>new Date(this.subgroups[e].end)&&(this.subgroups[e].end=i),this.subgroups[e].items.push(t)}},{key:"_updateSubgroupsSizes",value:function(){var t=this;if(t.subgroups){var e=function(e){var i,n=t.subgroups[e].items[0].data.end||t.subgroups[e].items[0].data.start,s=t.subgroups[e].items[0].data.start,r=n-1;is(i=t.subgroups[e].items).call(i,(function(t){new Date(t.data.start)<new Date(s)&&(s=t.data.start);var e=t.data.end||t.data.start;new Date(e)>new Date(r)&&(r=e)})),t.subgroups[e].start=s,t.subgroups[e].end=new Date(r-1)};for(var i in t.subgroups)e(i)}}},{key:"orderSubgroups",value:function(){if(void 0!==this.subgroupOrderer){var t=[];if("string"==typeof this.subgroupOrderer){for(var e in this.subgroups)t.push({subgroup:e,sortField:this.subgroups[e].items[0].data[this.subgroupOrderer]});Mo(t).call(t,(function(t,e){return t.sortField-e.sortField}))}else if("function"==typeof this.subgroupOrderer){for(var i in this.subgroups)t.push(this.subgroups[i].items[0].data);Mo(t).call(t,this.subgroupOrderer)}if(t.length>0)for(var n=0;n<t.length;n++)this.subgroups[t[n].subgroup].index=n}}},{key:"_resetSubgroups",value:function(){for(var t in this.subgroups)this.subgroups.hasOwnProperty(t)&&(this.subgroups[t].visible=!1,this.subgroups[t].height=0)}},{key:"remove",value:function(t){var e,i;delete this.items[t.id],t.setParent(null),this.stackDirty=!0;var n=la(e=this.visibleItems).call(e,t);-1!=n&&ea(i=this.visibleItems).call(i,n,1),void 0!==t.data.subgroup&&(this._removeFromSubgroup(t),this.orderSubgroups())}},{key:"_removeFromSubgroup",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t.data.subgroup;if(null!=e){var i=this.subgroups[e];if(i){var n,s,r=la(n=i.items).call(n,t);if(r>=0)ea(s=i.items).call(s,r,1),i.items.length?this._updateSubgroupsSizes():delete this.subgroups[e]}}}},{key:"removeFromDataSet",value:function(t){this.itemSet.removeItem(t.id)}},{key:"order",value:function(){for(var t=to.toArray(this.items),e=[],i=[],n=0;n<t.length;n++)void 0!==t[n].data.end&&i.push(t[n]),e.push(t[n]);this.orderedItems={byStart:e,byEnd:i},td(this.orderedItems.byStart),ed(this.orderedItems.byEnd)}},{key:"_updateItemsInRange",value:function(t,e,i){var n=[],s={};if(!this.isVisible&&this.groupId!=ud){for(var r=0;r<e.length;r++){var o=e[r];o.displayed&&o.hide()}return n}var a=(i.end-i.start)/4,l=i.start-a,h=i.end+a;if(e.length>0)for(var u=0;u<e.length;u++)this._checkIfVisibleWithReference(e[u],n,s,i);var d=to.binarySearchCustom(t.byStart,(function(t){return t<l?-1:t<=h?0:1}),"data","start");if(this._traceVisible(d,t.byStart,n,s,(function(t){return t.data.start<l||t.data.start>h})),1==this.checkRangedItems){this.checkRangedItems=!1;for(var c=0;c<t.byEnd.length;c++)this._checkIfVisibleWithReference(t.byEnd[c],n,s,i)}else{var f=to.binarySearchCustom(t.byEnd,(function(t){return t<l?-1:0}),"data","end");this._traceVisible(f,t.byEnd,n,s,(function(t){return t.data.end<l||t.data.start>h}))}for(var m={},p=0,g=0;g<n.length;g++){var v=n[g];if(!v.displayed){m[g]=v.redraw(!0),p=m[g].length}}if(p>0)for(var y=function(t){is(to).call(to,m,(function(e){e[t]()}))},_=0;_<p;_++)y(_);for(var b=0;b<n.length;b++)n[b].repositionX();return n}},{key:"_traceVisible",value:function(t,e,i,n,s){if(-1!=t){for(var r=t;r>=0;r--){var o=e[r];if(s(o))break;o.isCluster&&!o.hasItems()||o.cluster||void 0===n[o.id]&&(n[o.id]=!0,i.push(o))}for(var a=t+1;a<e.length;a++){var l=e[a];if(s(l))break;l.isCluster&&!l.hasItems()||l.cluster||void 0===n[l.id]&&(n[l.id]=!0,i.push(l))}}}},{key:"_checkIfVisible",value:function(t,e,i){t.isVisible(i)?(t.displayed||t.show(),t.repositionX(),e.push(t)):t.displayed&&t.hide()}},{key:"_checkIfVisibleWithReference",value:function(t,e,i,n){t.isVisible(n)?void 0===i[t.id]&&(i[t.id]=!0,e.push(t)):t.displayed&&t.hide()}},{key:"_updateClustersInRange",value:function(t,e,i){var n=[],s={};if(e.length>0)for(var r=0;r<e.length;r++)this._checkIfVisibleWithReference(e[r],n,s,i);for(var o=0;o<t.byStart.length;o++)this._checkIfVisibleWithReference(t.byStart[o],n,s,i);for(var a=0;a<t.byEnd.length;a++)this._checkIfVisibleWithReference(t.byEnd[a],n,s,i);for(var l={},h=0,u=0;u<n.length;u++){var d=n[u];if(!d.displayed){l[u]=d.redraw(!0),h=l[u].length}}if(h>0)for(var c=0;c<h;c++)is(to).call(to,l,(function(t){t[c]()}));for(var f=0;f<n.length;f++)n[f].repositionX();return n}},{key:"changeSubgroup",value:function(t,e,i){this._removeFromSubgroup(t,e),this._addToSubgroup(t,i),this.orderSubgroups()}}]),t}(),cd=function(t){function e(t,i,n){var s;return Ds(this,e),(s=Cr(this,Lr(e).call(this,t,i,n))).width=0,s.height=0,s.top=0,s.left=0,s}return jr(e,t),Ts(e,[{key:"redraw",value:function(t,e,i){this.visibleItems=this._updateItemsInRange(this.orderedItems,this.visibleItems,t),this.width=this.dom.background.offsetWidth,this.dom.background.style.height="0";for(var n=0,s=this.visibleItems.length;n<s;n++){this.visibleItems[n].repositionY(e)}return!1}},{key:"show",value:function(){this.dom.background.parentNode||this.itemSet.dom.background.appendChild(this.dom.background)}}]),e}(dd),fd=function(){function t(e,i,n){var s,r=this;Ds(this,t),this.id=null,this.parent=null,this.data=e,this.dom=null,this.conversion=i||{},this.defaultOptions={locales:Hh,locale:"en"},this.options=to.extend({},this.defaultOptions,n),this.options.locales=to.extend({},Hh,this.options.locales);var o=this.defaultOptions.locales[this.defaultOptions.locale];is(s=$r(this.options.locales)).call(s,(function(t){r.options.locales[t]=to.extend({},o,r.options.locales[t])})),this.selected=!1,this.displayed=!1,this.groupShowing=!0,this.selectable=n&&n.selectable||!1,this.dirty=!0,this.top=null,this.right=null,this.left=null,this.width=null,this.height=null,this.setSelectability(e),this.editable=null,this._updateEditStatus()}return Ts(t,[{key:"select",value:function(){this.selectable&&(this.selected=!0,this.dirty=!0,this.displayed&&this.redraw())}},{key:"unselect",value:function(){this.selected=!1,this.dirty=!0,this.displayed&&this.redraw()}},{key:"setData",value:function(t){null!=t.group&&this.data.group!=t.group&&null!=this.parent&&this.parent.itemSet._moveToGroup(this,t.group),this.setSelectability(t),this.parent&&(this.parent.stackDirty=!0),null!=t.subgroup&&this.data.subgroup!=t.subgroup&&null!=this.parent&&this.parent.changeSubgroup(this,this.data.subgroup,t.subgroup),this.data=t,this._updateEditStatus(),this.dirty=!0,this.displayed&&this.redraw()}},{key:"setSelectability",value:function(t){t&&(this.selectable=void 0===t.selectable||Boolean(t.selectable))}},{key:"setParent",value:function(t){this.displayed?(this.hide(),this.parent=t,this.parent&&this.show()):this.parent=t}},{key:"isVisible",value:function(t){return!1}},{key:"show",value:function(){return!1}},{key:"hide",value:function(){return!1}},{key:"redraw",value:function(){}},{key:"repositionX",value:function(){}},{key:"repositionY",value:function(){}},{key:"_repaintDragCenter",value:function(){if(this.selected&&this.options.editable.updateTime&&!this.dom.dragCenter){var t,e,i,n=this,s=document.createElement("div");s.className="vis-drag-center",s.dragCenterItem=this,this.hammerDragCenter=new _h(s),this.hammerDragCenter.on("tap",(function(t){n.parent.itemSet.body.emitter.emit("click",{event:t,item:n.id})})),this.hammerDragCenter.on("doubletap",(function(t){t.stopPropagation(),n.parent.itemSet._onUpdateItem(n),n.parent.itemSet.body.emitter.emit("doubleClick",{event:t,item:n.id})})),this.hammerDragCenter.on("panstart",bs(t=n.parent.itemSet._onDragStart).call(t,n.parent.itemSet)),this.hammerDragCenter.on("panmove",bs(e=n.parent.itemSet._onDrag).call(e,n.parent.itemSet)),this.hammerDragCenter.on("panend",bs(i=n.parent.itemSet._onDragEnd).call(i,n.parent.itemSet)),this.dom.box?this.dom.dragLeft?this.dom.box.insertBefore(s,this.dom.dragLeft):this.dom.box.appendChild(s):this.dom.point&&this.dom.point.appendChild(s),this.dom.dragCenter=s}else!this.selected&&this.dom.dragCenter&&(this.dom.dragCenter.parentNode&&this.dom.dragCenter.parentNode.removeChild(this.dom.dragCenter),this.dom.dragCenter=null,this.hammerDragCenter&&(this.hammerDragCenter.destroy(),this.hammerDragCenter=null))}},{key:"_repaintDeleteButton",value:function(t){var e=(this.options.editable.overrideItems||null==this.editable)&&this.options.editable.remove||!this.options.editable.overrideItems&&null!=this.editable&&this.editable.remove;if(this.selected&&e&&!this.dom.deleteButton){var i=this,n=document.createElement("div");this.options.rtl?n.className="vis-delete-rtl":n.className="vis-delete";var s=this.options.locales[this.options.locale];s||(this.warned||(console.warn("WARNING: options.locales['".concat(this.options.locale,"'] not found. See https://visjs.github.io/vis-timeline/docs/timeline/#Localization")),this.warned=!0),s=this.options.locales.en),n.title=s.deleteSelected,this.hammerDeleteButton=new _h(n).on("tap",(function(t){t.stopPropagation(),i.parent.removeFromDataSet(i)})),t.appendChild(n),this.dom.deleteButton=n}else!this.selected&&this.dom.deleteButton&&(this.dom.deleteButton.parentNode&&this.dom.deleteButton.parentNode.removeChild(this.dom.deleteButton),this.dom.deleteButton=null,this.hammerDeleteButton&&(this.hammerDeleteButton.destroy(),this.hammerDeleteButton=null))}},{key:"_repaintOnItemUpdateTimeTooltip",value:function(t){if(this.options.tooltipOnItemUpdateTime){var e=(this.options.editable.updateTime||!0===this.data.editable)&&!1!==this.data.editable;if(this.selected&&e&&!this.dom.onItemUpdateTimeTooltip){var i=document.createElement("div");i.className="vis-onUpdateTime-tooltip",t.appendChild(i),this.dom.onItemUpdateTimeTooltip=i}else!this.selected&&this.dom.onItemUpdateTimeTooltip&&(this.dom.onItemUpdateTimeTooltip.parentNode&&this.dom.onItemUpdateTimeTooltip.parentNode.removeChild(this.dom.onItemUpdateTimeTooltip),this.dom.onItemUpdateTimeTooltip=null);if(this.dom.onItemUpdateTimeTooltip){this.dom.onItemUpdateTimeTooltip.style.visibility=this.parent.itemSet.touchParams.itemIsDragging?"visible":"hidden",this.dom.onItemUpdateTimeTooltip.style.transform="translateX(-50%)",this.dom.onItemUpdateTimeTooltip.style.left="50%";var n,s,r=this.parent.itemSet.body.domProps.scrollTop;if(("top"==this.options.orientation.item?this.top:this.parent.height-this.top-this.height)+this.parent.top-50<-r?(this.dom.onItemUpdateTimeTooltip.style.bottom="",this.dom.onItemUpdateTimeTooltip.style.top="".concat(this.height+2,"px")):(this.dom.onItemUpdateTimeTooltip.style.top="",this.dom.onItemUpdateTimeTooltip.style.bottom="".concat(this.height+2,"px")),this.options.tooltipOnItemUpdateTime&&this.options.tooltipOnItemUpdateTime.template)n=bs(s=this.options.tooltipOnItemUpdateTime.template).call(s,this)(this.data);else n="start: ".concat(Hr(this.data.start).format("MM/DD/YYYY hh:mm")),this.data.end&&(n+="<br> end: ".concat(Hr(this.data.end).format("MM/DD/YYYY hh:mm")));this.dom.onItemUpdateTimeTooltip.innerHTML=n}}}},{key:"_getItemData",value:function(){return this.parent.itemSet.itemsData.get(this.id)}},{key:"_updateContents",value:function(t){var e,i,n,s,r,o,a=this._getItemData(),l=(this.dom.box||this.dom.point).getElementsByClassName("vis-item-visible-frame")[0];this.options.visibleFrameTemplate?n=(s=bs(r=this.options.visibleFrameTemplate).call(r,this))(a,l):n="";if(l)if(n instanceof Object&&!(n instanceof Element))s(a,l);else if(this._contentToString(this.itemVisibleFrameContent)!==this._contentToString(n)){if(n instanceof Element)l.innerHTML="",l.appendChild(n);else if(null!=n)l.innerHTML=n;else if("background"!=this.data.type||void 0!==this.data.content)throw new Error('Property "content" missing in item '.concat(this.id));this.itemVisibleFrameContent=n}this.options.template?e=(i=bs(o=this.options.template).call(o,this))(a,t,this.data):e=this.data.content;if(e instanceof Object&&!(e instanceof Element))i(a,t);else if(this._contentToString(this.content)!==this._contentToString(e)){if(e instanceof Element)t.innerHTML="",t.appendChild(e);else if(null!=e)t.innerHTML=e;else if("background"!=this.data.type||void 0!==this.data.content)throw new Error('Property "content" missing in item '.concat(this.id));this.content=e}}},{key:"_updateDataAttributes",value:function(t){if(this.options.dataAttributes&&this.options.dataAttributes.length>0){var e=[];if(ks(this.options.dataAttributes))e=this.options.dataAttributes;else{if("all"!=this.options.dataAttributes)return;e=$r(this.data)}var i=!0,n=!1,s=void 0;try{for(var r,o=wu(e);!(i=(r=o.next()).done);i=!0){var a=r.value,l=this.data[a];null!=l?t.setAttribute("data-".concat(a),l):t.removeAttribute("data-".concat(a))}}catch(t){n=!0,s=t}finally{try{i||null==o.return||o.return()}finally{if(n)throw s}}}}},{key:"_updateStyle",value:function(t){this.style&&(to.removeCssText(t,this.style),this.style=null),this.data.style&&(to.addCssText(t,this.data.style),this.style=this.data.style)}},{key:"_contentToString",value:function(t){return"string"==typeof t?t:t&&"outerHTML"in t?t.outerHTML:t}},{key:"_updateEditStatus",value:function(){this.options&&("boolean"==typeof this.options.editable?this.editable={updateTime:this.options.editable,updateGroup:this.options.editable,remove:this.options.editable}:"object"===Tr(this.options.editable)&&(this.editable={},to.selectiveExtend(["updateTime","updateGroup","remove"],this.editable,this.options.editable))),this.options&&this.options.editable&&!0===this.options.editable.overrideItems||this.data&&("boolean"==typeof this.data.editable?this.editable={updateTime:this.data.editable,updateGroup:this.data.editable,remove:this.data.editable}:"object"===Tr(this.data.editable)&&(this.editable={},to.selectiveExtend(["updateTime","updateGroup","remove"],this.editable,this.data.editable)))}},{key:"getWidthLeft",value:function(){return 0}},{key:"getWidthRight",value:function(){return 0}},{key:"getTitle",value:function(){var t;return this.options.tooltip&&this.options.tooltip.template?bs(t=this.options.tooltip.template).call(t,this)(this._getItemData(),this.data):this.data.title}}]),t}();fd.prototype.stack=!0;var md=function(t){function e(t,i,n){var s;if(Ds(this,e),(s=Cr(this,Lr(e).call(this,t,i,n))).props={dot:{width:0,height:0},line:{width:0,height:0}},t&&null==t.start)throw new Error('Property "start" missing in item '.concat(t));return s}return jr(e,t),Ts(e,[{key:"isVisible",value:function(t){if(this.cluster)return!1;var e,i=this.data.align||this.options.align,n=this.width*t.getMillisecondsPerPixel();return e="right"==i?this.data.start.getTime()>t.start&&this.data.start.getTime()-n<t.end:"left"==i?this.data.start.getTime()+n>t.start&&this.data.start.getTime()<t.end:this.data.start.getTime()+n/2>t.start&&this.data.start.getTime()-n/2<t.end,e}},{key:"_createDomElement",value:function(){this.dom||(this.dom={},this.dom.box=document.createElement("DIV"),this.dom.content=document.createElement("DIV"),this.dom.content.className="vis-item-content",this.dom.box.appendChild(this.dom.content),this.dom.line=document.createElement("DIV"),this.dom.line.className="vis-line",this.dom.dot=document.createElement("DIV"),this.dom.dot.className="vis-dot",this.dom.box["vis-item"]=this,this.dirty=!0)}},{key:"_appendDomElement",value:function(){if(!this.parent)throw new Error("Cannot redraw item: no parent attached");if(!this.dom.box.parentNode){var t=this.parent.dom.foreground;if(!t)throw new Error("Cannot redraw item: parent has no foreground container element");t.appendChild(this.dom.box)}if(!this.dom.line.parentNode){var e=this.parent.dom.background;if(!e)throw new Error("Cannot redraw item: parent has no background container element");e.appendChild(this.dom.line)}if(!this.dom.dot.parentNode){var i=this.parent.dom.axis;if(!e)throw new Error("Cannot redraw item: parent has no axis container element");i.appendChild(this.dom.dot)}this.displayed=!0}},{key:"_updateDirtyDomComponents",value:function(){if(this.dirty){this._updateContents(this.dom.content),this._updateDataAttributes(this.dom.box),this._updateStyle(this.dom.box);var t=this.editable.updateTime||this.editable.updateGroup,e=(this.data.className?" "+this.data.className:"")+(this.selected?" vis-selected":"")+(t?" vis-editable":" vis-readonly");this.dom.box.className="vis-item vis-box".concat(e),this.dom.line.className="vis-item vis-line".concat(e),this.dom.dot.className="vis-item vis-dot".concat(e)}}},{key:"_getDomComponentsSizes",value:function(){return{previous:{right:this.dom.box.style.right,left:this.dom.box.style.left},dot:{height:this.dom.dot.offsetHeight,width:this.dom.dot.offsetWidth},line:{width:this.dom.line.offsetWidth},box:{width:this.dom.box.offsetWidth,height:this.dom.box.offsetHeight}}}},{key:"_updateDomComponentsSizes",value:function(t){this.options.rtl?this.dom.box.style.right="0px":this.dom.box.style.left="0px",this.props.dot.height=t.dot.height,this.props.dot.width=t.dot.width,this.props.line.width=t.line.width,this.width=t.box.width,this.height=t.box.height,this.options.rtl?this.dom.box.style.right=t.previous.right:this.dom.box.style.left=t.previous.left,this.dirty=!1}},{key:"_repaintDomAdditionals",value:function(){this._repaintOnItemUpdateTimeTooltip(this.dom.box),this._repaintDragCenter(),this._repaintDeleteButton(this.dom.box)}},{key:"redraw",value:function(t){var e,i,n,s,r,o,a=this,l=[bs(e=this._createDomElement).call(e,this),bs(i=this._appendDomElement).call(i,this),bs(n=this._updateDirtyDomComponents).call(n,this),function(){a.dirty&&(r=a._getDomComponentsSizes())},function(){var t;a.dirty&&bs(t=a._updateDomComponentsSizes).call(t,a)(r)},bs(s=this._repaintDomAdditionals).call(s,this)];return t?l:(is(l).call(l,(function(t){o=t()})),o)}},{key:"show",value:function(t){if(!this.displayed)return this.redraw(t)}},{key:"hide",value:function(){if(this.displayed){var t=this.dom;t.box.parentNode&&t.box.remove(),t.line.parentNode&&t.line.remove(),t.dot.parentNode&&t.dot.remove(),this.displayed=!1}}},{key:"repositionXY",value:function(){var t=this.options.rtl,e=function(t,e,i){var n,s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==e||void 0!==i){var r=s?-1*e:e;t.style.transform=void 0!==i?void 0!==e?vo(n="translate(".concat(r,"px, ")).call(n,i,"px)"):"translateY(".concat(i,"px)"):"translateX(".concat(r,"px)")}};e(this.dom.box,this.boxX,this.boxY,t),e(this.dom.dot,this.dotX,this.dotY,t),e(this.dom.line,this.lineX,this.lineY,t)}},{key:"repositionX",value:function(){var t=this.conversion.toScreen(this.data.start),e=void 0===this.data.align?this.options.align:this.data.align,i=this.props.line.width,n=this.props.dot.width;"right"==e?(this.boxX=t-this.width,this.lineX=t-i,this.dotX=t-i/2-n/2):"left"==e?(this.boxX=t,this.lineX=t,this.dotX=t+i/2-n/2):(this.boxX=t-this.width/2,this.lineX=this.options.rtl?t-i:t-i/2,this.dotX=t-n/2),this.options.rtl?this.right=this.boxX:this.left=this.boxX,this.repositionXY()}},{key:"repositionY",value:function(){var t=this.options.orientation.item,e=this.dom.line.style;if("top"==t){var i=this.parent.top+this.top+1;this.boxY=this.top||0,e.height="".concat(i,"px"),e.bottom="",e.top="0"}else{var n=this.parent.itemSet.props.height-this.parent.top-this.parent.height+this.top;this.boxY=this.parent.height-this.top-(this.height||0),e.height="".concat(n,"px"),e.top="",e.bottom="0"}this.dotY=-this.props.dot.height/2,this.repositionXY()}},{key:"getWidthLeft",value:function(){return this.width/2}},{key:"getWidthRight",value:function(){return this.width/2}}]),e}(fd),pd=function(t){function e(t,i,n){var s;if(Ds(this,e),(s=Cr(this,Lr(e).call(this,t,i,n))).props={dot:{top:0,width:0,height:0},content:{height:0,marginLeft:0,marginRight:0}},t&&null==t.start)throw new Error('Property "start" missing in item '.concat(t));return s}return jr(e,t),Ts(e,[{key:"isVisible",value:function(t){if(this.cluster)return!1;var e=this.width*t.getMillisecondsPerPixel();return this.data.start.getTime()+e>t.start&&this.data.start<t.end}},{key:"_createDomElement",value:function(){this.dom||(this.dom={},this.dom.point=document.createElement("div"),this.dom.content=document.createElement("div"),this.dom.content.className="vis-item-content",this.dom.point.appendChild(this.dom.content),this.dom.dot=document.createElement("div"),this.dom.point.appendChild(this.dom.dot),this.dom.point["vis-item"]=this,this.dirty=!0)}},{key:"_appendDomElement",value:function(){if(!this.parent)throw new Error("Cannot redraw item: no parent attached");if(!this.dom.point.parentNode){var t=this.parent.dom.foreground;if(!t)throw new Error("Cannot redraw item: parent has no foreground container element");t.appendChild(this.dom.point)}this.displayed=!0}},{key:"_updateDirtyDomComponents",value:function(){if(this.dirty){this._updateContents(this.dom.content),this._updateDataAttributes(this.dom.point),this._updateStyle(this.dom.point);var t=this.editable.updateTime||this.editable.updateGroup,e=(this.data.className?" "+this.data.className:"")+(this.selected?" vis-selected":"")+(t?" vis-editable":" vis-readonly");this.dom.point.className="vis-item vis-point".concat(e),this.dom.dot.className="vis-item vis-dot".concat(e)}}},{key:"_getDomComponentsSizes",value:function(){return{dot:{width:this.dom.dot.offsetWidth,height:this.dom.dot.offsetHeight},content:{width:this.dom.content.offsetWidth,height:this.dom.content.offsetHeight},point:{width:this.dom.point.offsetWidth,height:this.dom.point.offsetHeight}}}},{key:"_updateDomComponentsSizes",value:function(t){this.props.dot.width=t.dot.width,this.props.dot.height=t.dot.height,this.props.content.height=t.content.height,this.options.rtl?this.dom.content.style.marginRight="".concat(2*this.props.dot.width,"px"):this.dom.content.style.marginLeft="".concat(2*this.props.dot.width,"px"),this.width=t.point.width,this.height=t.point.height,this.dom.dot.style.top="".concat((this.height-this.props.dot.height)/2,"px");var e=this.props.dot.width,i=this.options.rtl?e/2*-1:e/2;this.dom.dot.style.transform="translateX(".concat(i,"px"),this.dirty=!1}},{key:"_repaintDomAdditionals",value:function(){this._repaintOnItemUpdateTimeTooltip(this.dom.point),this._repaintDragCenter(),this._repaintDeleteButton(this.dom.point)}},{key:"redraw",value:function(t){var e,i,n,s,r,o,a=this,l=[bs(e=this._createDomElement).call(e,this),bs(i=this._appendDomElement).call(i,this),bs(n=this._updateDirtyDomComponents).call(n,this),function(){a.dirty&&(r=a._getDomComponentsSizes())},function(){var t;a.dirty&&bs(t=a._updateDomComponentsSizes).call(t,a)(r)},bs(s=this._repaintDomAdditionals).call(s,this)];return t?l:(is(l).call(l,(function(t){o=t()})),o)}},{key:"repositionXY",value:function(){var t=this.options.rtl,e=function(t,e,i){var n,s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==e||void 0!==i){var r=s?-1*e:e;t.style.transform=void 0!==i?void 0!==e?vo(n="translate(".concat(r,"px, ")).call(n,i,"px)"):"translateY(".concat(i,"px)"):"translateX(".concat(r,"px)")}};e(this.dom.point,this.pointX,this.pointY,t)}},{key:"show",value:function(t){if(!this.displayed)return this.redraw(t)}},{key:"hide",value:function(){this.displayed&&(this.dom.point.parentNode&&this.dom.point.parentNode.removeChild(this.dom.point),this.displayed=!1)}},{key:"repositionX",value:function(){var t=this.conversion.toScreen(this.data.start);this.pointX=t,this.options.rtl?this.right=t-this.props.dot.width:this.left=t-this.props.dot.width,this.repositionXY()}},{key:"repositionY",value:function(){var t=this.options.orientation.item;this.pointY="top"==t?this.top:this.parent.height-this.top-this.height,this.repositionXY()}},{key:"getWidthLeft",value:function(){return this.props.dot.width}},{key:"getWidthRight",value:function(){return this.props.dot.width}}]),e}(fd),gd=function(t){function e(t,i,n){var s;if(Ds(this,e),(s=Cr(this,Lr(e).call(this,t,i,n))).props={content:{width:0}},s.overflow=!1,t){if(null==t.start)throw new Error('Property "start" missing in item '.concat(t.id));if(null==t.end)throw new Error('Property "end" missing in item '.concat(t.id))}return s}return jr(e,t),Ts(e,[{key:"isVisible",value:function(t){return!this.cluster&&(this.data.start<t.end&&this.data.end>t.start)}},{key:"_createDomElement",value:function(){this.dom||(this.dom={},this.dom.box=document.createElement("div"),this.dom.frame=document.createElement("div"),this.dom.frame.className="vis-item-overflow",this.dom.box.appendChild(this.dom.frame),this.dom.visibleFrame=document.createElement("div"),this.dom.visibleFrame.className="vis-item-visible-frame",this.dom.box.appendChild(this.dom.visibleFrame),this.dom.content=document.createElement("div"),this.dom.content.className="vis-item-content",this.dom.frame.appendChild(this.dom.content),this.dom.box["vis-item"]=this,this.dirty=!0)}},{key:"_appendDomElement",value:function(){if(!this.parent)throw new Error("Cannot redraw item: no parent attached");if(!this.dom.box.parentNode){var t=this.parent.dom.foreground;if(!t)throw new Error("Cannot redraw item: parent has no foreground container element");t.appendChild(this.dom.box)}this.displayed=!0}},{key:"_updateDirtyDomComponents",value:function(){if(this.dirty){this._updateContents(this.dom.content),this._updateDataAttributes(this.dom.box),this._updateStyle(this.dom.box);var t=this.editable.updateTime||this.editable.updateGroup,e=(this.data.className?" "+this.data.className:"")+(this.selected?" vis-selected":"")+(t?" vis-editable":" vis-readonly");this.dom.box.className=this.baseClassName+e,this.dom.content.style.maxWidth="none"}}},{key:"_getDomComponentsSizes",value:function(){return this.overflow="hidden"!==window.getComputedStyle(this.dom.frame).overflow,this.whiteSpace="nowrap"!==window.getComputedStyle(this.dom.content).whiteSpace,{content:{width:this.dom.content.offsetWidth},box:{height:this.dom.box.offsetHeight}}}},{key:"_updateDomComponentsSizes",value:function(t){this.props.content.width=t.content.width,this.height=t.box.height,this.dom.content.style.maxWidth="",this.dirty=!1}},{key:"_repaintDomAdditionals",value:function(){this._repaintOnItemUpdateTimeTooltip(this.dom.box),this._repaintDeleteButton(this.dom.box),this._repaintDragCenter(),this._repaintDragLeft(),this._repaintDragRight()}},{key:"redraw",value:function(t){var e,i,n,s,r,o,a=this,l=[bs(e=this._createDomElement).call(e,this),bs(i=this._appendDomElement).call(i,this),bs(n=this._updateDirtyDomComponents).call(n,this),function(){var t;a.dirty&&(r=bs(t=a._getDomComponentsSizes).call(t,a)())},function(){var t;a.dirty&&bs(t=a._updateDomComponentsSizes).call(t,a)(r)},bs(s=this._repaintDomAdditionals).call(s,this)];return t?l:(is(l).call(l,(function(t){o=t()})),o)}},{key:"show",value:function(t){if(!this.displayed)return this.redraw(t)}},{key:"hide",value:function(){if(this.displayed){var t=this.dom.box;t.parentNode&&t.parentNode.removeChild(t),this.displayed=!1}}},{key:"repositionX",value:function(t){var e,i,n=this.parent.width,s=this.conversion.toScreen(this.data.start),r=this.conversion.toScreen(this.data.end),o=void 0===this.data.align?this.options.align:this.data.align;!1===this.data.limitSize||void 0!==t&&!0!==t||(s<-n&&(s=-n),r>2*n&&(r=2*n));var a=Math.max(Math.round(1e3*(r-s))/1e3,1);switch(this.overflow?(this.options.rtl?this.right=s:this.left=s,this.width=a+this.props.content.width,i=this.props.content.width):(this.options.rtl?this.right=s:this.left=s,this.width=a,i=Math.min(r-s,this.props.content.width)),this.options.rtl?this.dom.box.style.transform="translateX(".concat(-1*this.right,"px)"):this.dom.box.style.transform="translateX(".concat(this.left,"px)"),this.dom.box.style.width="".concat(a,"px"),this.whiteSpace&&(this.height=this.dom.box.offsetHeight),o){case"left":this.dom.content.style.transform="translateX(0)";break;case"right":if(this.options.rtl){var l=-1*Math.max(a-i,0);this.dom.content.style.transform="translateX(".concat(l,"px)")}else this.dom.content.style.transform="translateX(".concat(Math.max(a-i,0),"px)");break;case"center":if(this.options.rtl){var h=-1*Math.max((a-i)/2,0);this.dom.content.style.transform="translateX(".concat(h,"px)")}else this.dom.content.style.transform="translateX(".concat(Math.max((a-i)/2,0),"px)");break;default:if(e=this.overflow?r>0?Math.max(-s,0):-i:s<0?-s:0,this.options.rtl){var u=-1*e;this.dom.content.style.transform="translateX(".concat(u,"px)")}else this.dom.content.style.transform="translateX(".concat(e,"px)")}}},{key:"repositionY",value:function(){var t=this.options.orientation.item,e=this.dom.box;e.style.top="".concat("top"==t?this.top:this.parent.height-this.top-this.height,"px")}},{key:"_repaintDragLeft",value:function(){if((this.selected||this.options.itemsAlwaysDraggable.range)&&this.options.editable.updateTime&&!this.dom.dragLeft){var t=document.createElement("div");t.className="vis-drag-left",t.dragLeftItem=this,this.dom.box.appendChild(t),this.dom.dragLeft=t}else this.selected||this.options.itemsAlwaysDraggable.range||!this.dom.dragLeft||(this.dom.dragLeft.parentNode&&this.dom.dragLeft.parentNode.removeChild(this.dom.dragLeft),this.dom.dragLeft=null)}},{key:"_repaintDragRight",value:function(){if((this.selected||this.options.itemsAlwaysDraggable.range)&&this.options.editable.updateTime&&!this.dom.dragRight){var t=document.createElement("div");t.className="vis-drag-right",t.dragRightItem=this,this.dom.box.appendChild(t),this.dom.dragRight=t}else this.selected||this.options.itemsAlwaysDraggable.range||!this.dom.dragRight||(this.dom.dragRight.parentNode&&this.dom.dragRight.parentNode.removeChild(this.dom.dragRight),this.dom.dragRight=null)}}]),e}(fd);gd.prototype.baseClassName="vis-item vis-range";var vd=function(t){function e(t,i,n){var s;if(Ds(this,e),(s=Cr(this,Lr(e).call(this,t,i,n))).props={content:{width:0}},s.overflow=!1,t){if(null==t.start)throw new Error('Property "start" missing in item '.concat(t.id));if(null==t.end)throw new Error('Property "end" missing in item '.concat(t.id))}return s}return jr(e,t),Ts(e,[{key:"isVisible",value:function(t){return this.data.start<t.end&&this.data.end>t.start}},{key:"_createDomElement",value:function(){this.dom||(this.dom={},this.dom.box=document.createElement("div"),this.dom.frame=document.createElement("div"),this.dom.frame.className="vis-item-overflow",this.dom.box.appendChild(this.dom.frame),this.dom.content=document.createElement("div"),this.dom.content.className="vis-item-content",this.dom.frame.appendChild(this.dom.content),this.dirty=!0)}},{key:"_appendDomElement",value:function(){if(!this.parent)throw new Error("Cannot redraw item: no parent attached");if(!this.dom.box.parentNode){var t=this.parent.dom.background;if(!t)throw new Error("Cannot redraw item: parent has no background container element");t.appendChild(this.dom.box)}this.displayed=!0}},{key:"_updateDirtyDomComponents",value:function(){if(this.dirty){this._updateContents(this.dom.content),this._updateDataAttributes(this.dom.content),this._updateStyle(this.dom.box);var t=(this.data.className?" "+this.data.className:"")+(this.selected?" vis-selected":"");this.dom.box.className=this.baseClassName+t}}},{key:"_getDomComponentsSizes",value:function(){return this.overflow="hidden"!==window.getComputedStyle(this.dom.content).overflow,{content:{width:this.dom.content.offsetWidth}}}},{key:"_updateDomComponentsSizes",value:function(t){this.props.content.width=t.content.width,this.height=0,this.dirty=!1}},{key:"_repaintDomAdditionals",value:function(){}},{key:"redraw",value:function(t){var e,i,n,s,r,o,a=this,l=[bs(e=this._createDomElement).call(e,this),bs(i=this._appendDomElement).call(i,this),bs(n=this._updateDirtyDomComponents).call(n,this),function(){var t;a.dirty&&(r=bs(t=a._getDomComponentsSizes).call(t,a)())},function(){var t;a.dirty&&bs(t=a._updateDomComponentsSizes).call(t,a)(r)},bs(s=this._repaintDomAdditionals).call(s,this)];return t?l:(is(l).call(l,(function(t){o=t()})),o)}},{key:"repositionY",value:function(t){var e,i=this.options.orientation.item;if(void 0!==this.data.subgroup){var n=this.data.subgroup;this.dom.box.style.height="".concat(this.parent.subgroups[n].height,"px"),this.dom.box.style.top="".concat("top"==i?this.parent.top+this.parent.subgroups[n].top:this.parent.top+this.parent.height-this.parent.subgroups[n].top-this.parent.subgroups[n].height,"px"),this.dom.box.style.bottom=""}else this.parent instanceof cd?(e=Math.max(this.parent.height,this.parent.itemSet.body.domProps.center.height,this.parent.itemSet.body.domProps.centerContainer.height),this.dom.box.style.bottom="bottom"==i?"0":"",this.dom.box.style.top="top"==i?"0":""):(e=this.parent.height,this.dom.box.style.top="".concat(this.parent.top,"px"),this.dom.box.style.bottom="");this.dom.box.style.height="".concat(e,"px")}}]),e}(fd);vd.prototype.baseClassName="vis-item vis-background",vd.prototype.stack=!1,vd.prototype.show=gd.prototype.show,vd.prototype.hide=gd.prototype.hide,vd.prototype.repositionX=gd.prototype.repositionX;var yd=function(){function t(e,i){Ds(this,t),this.container=e,this.overflowMethod=i||"cap",this.x=0,this.y=0,this.padding=5,this.hidden=!1,this.frame=document.createElement("div"),this.frame.className="vis-tooltip",this.container.appendChild(this.frame)}return Ts(t,[{key:"setPosition",value:function(t,e){this.x=xh(t),this.y=xh(e)}},{key:"setText",value:function(t){t instanceof Element?(this.frame.innerHTML="",this.frame.appendChild(t)):this.frame.innerHTML=t}},{key:"show",value:function(t){if(void 0===t&&(t=!0),!0===t){var e=this.frame.clientHeight,i=this.frame.clientWidth,n=this.frame.parentNode.clientHeight,s=this.frame.parentNode.clientWidth,r=0,o=0;if("flip"==this.overflowMethod||"none"==this.overflowMethod){var a=!1,l=!0;"flip"==this.overflowMethod&&(this.y-e<this.padding&&(l=!1),this.x+i>s-this.padding&&(a=!0)),r=a?this.x-i:this.x,o=l?this.y-e:this.y}else(o=this.y-e)+e+this.padding>n&&(o=n-e-this.padding),o<this.padding&&(o=this.padding),(r=this.x)+i+this.padding>s&&(r=s-i-this.padding),r<this.padding&&(r=this.padding);this.frame.style.left=r+"px",this.frame.style.top=o+"px",this.frame.style.visibility="visible",this.hidden=!1}else this.hide()}},{key:"hide",value:function(){this.hidden=!0,this.frame.style.left="0",this.frame.style.top="0",this.frame.style.visibility="hidden"}},{key:"destroy",value:function(){this.frame.parentNode.removeChild(this.frame)}}]),t}(),_d=qn.every;ji({target:"Array",proto:!0,forced:Zn("every")},{every:function(t){return _d(this,t,arguments.length>1?arguments[1]:void 0)}});var bd=Kn("Array").every,wd=Array.prototype,kd=function(t){var e=t.every;return t===wd||t instanceof Array&&e===wd.every?bd:e},Dd=Di.f,Sd=function(t){return function(e){for(var i,n=Ce(e),s=un(n),r=s.length,o=0,a=[];r>o;)i=s[o++],Ge&&!Dd.call(n,i)||a.push(t?[i,n[i]]:n[i]);return a}},xd={entries:Sd(!0),values:Sd(!1)}.values;ji({target:"Object",stat:!0},{values:function(t){return xd(t)}});var Md=Li.Object.values,Td=function(t){return function(e,i,n,s){Ii(i);var r=Fi(e),o=Te(r),a=tn(r.length),l=t?a-1:0,h=t?-1:1;if(n<2)for(;;){if(l in o){s=o[l],l+=h;break}if(l+=h,t?l<0:a<=l)throw TypeError("Reduce of empty array with no initial value")}for(;t?l>=0:a>l;l+=h)l in o&&(s=i(s,o[l],l,r));return s}},Od={left:Td(!1),right:Td(!0)}.left;ji({target:"Array",proto:!0,forced:Zn("reduce")},{reduce:function(t){return Od(this,t,arguments.length,arguments.length>1?arguments[1]:void 0)}});var Cd=Kn("Array").reduce,Yd=Array.prototype,Pd=function(t){var e=t.reduce;return t===Yd||t instanceof Array&&e===Yd.reduce?Cd:e},Ed=function(t){function e(t,i,n){var s;Ds(this,e);var r=Ru({},{fitOnDoubleClick:!0},n,{editable:!1});if((s=Cr(this,Lr(e).call(this,t,i,r))).props={content:{width:0,height:0}},!t||null==t.uiItems)throw new Error('Property "uiItems" missing in item '+t.id);return s.id=to.randomUUID(),s.group=t.group,s._setupRange(),s.emitter=s.data.eventEmitter,s.range=s.data.range,s.attached=!1,s.isCluster=!0,s.data.isCluster=!0,s}return jr(e,t),Ts(e,[{key:"hasItems",value:function(){return this.data.uiItems&&this.data.uiItems.length&&this.attached}},{key:"setUiItems",value:function(t){this.detach(),this.data.uiItems=t,this._setupRange(),this.attach()}},{key:"isVisible",value:function(t){var e=this.data.end?this.data.end-this.data.start:0,i=this.width*t.getMillisecondsPerPixel(),n=Math.max(e,this.data.start.getTime()+i);return this.data.start<t.end&&n>t.start&&this.hasItems()}},{key:"getData",value:function(){return{isCluster:!0,id:this.id,items:this.data.items||[],data:this.data}}},{key:"redraw",value:function(t){var e,i,n,s,r,o,a,l,h=[bs(e=this._createDomElement).call(e,this),bs(i=this._appendDomElement).call(i,this),bs(n=this._updateDirtyDomComponents).call(n,this),bs(s=function(){this.dirty&&(a=this._getDomComponentsSizes())}).call(s,this),bs(r=function(){var t;this.dirty&&bs(t=this._updateDomComponentsSizes).call(t,this)(a)}).call(r,this),bs(o=this._repaintDomAdditionals).call(o,this)];return t?h:(is(h).call(h,(function(t){l=t()})),l)}},{key:"show",value:function(){this.displayed||this.redraw()}},{key:"hide",value:function(){if(this.displayed){var t=this.dom;t.box.parentNode&&t.box.parentNode.removeChild(t.box),this.options.showStipes&&(t.line.parentNode&&t.line.parentNode.removeChild(t.line),t.dot.parentNode&&t.dot.parentNode.removeChild(t.dot)),this.displayed=!1}}},{key:"repositionX",value:function(){var t=this.conversion.toScreen(this.data.start),e=this.data.end?this.conversion.toScreen(this.data.end):0;if(e)this.repositionXWithRanges(t,e);else{var i=void 0===this.data.align?this.options.align:this.data.align;this.repositionXWithoutRanges(t,i)}this.options.showStipes&&(this.dom.line.style.display=this._isStipeVisible()?"block":"none",this.dom.dot.style.display=this._isStipeVisible()?"block":"none",this._isStipeVisible()&&this.repositionStype(t,e))}},{key:"repositionStype",value:function(t,e){this.dom.line.style.display="block",this.dom.dot.style.display="block";var i=this.dom.line.offsetWidth,n=this.dom.dot.offsetWidth;if(e){var s=i+t+(e-t)/2,r=s-n/2,o=this.options.rtl?-1*s:s,a=this.options.rtl?-1*r:r;this.dom.line.style.transform="translateX(".concat(o,")px"),this.dom.dot.style.transform="translateX(".concat(a,"px)")}else{var l=this.options.rtl?-1*t:t,h=this.options.rtl?-1*(t-n/2):t-n/2;this.dom.line.style.transform="".concat(l,"px"),this.dom.dot.style.transform="".concat(h,"px")}}},{key:"repositionXWithoutRanges",value:function(t,e){"right"==e?this.options.rtl?(this.right=t-this.width,this.dom.box.style.right=this.right+"px"):(this.left=t-this.width,this.dom.box.style.left=this.left+"px"):"left"==e?this.options.rtl?(this.right=t,this.dom.box.style.right=this.right+"px"):(this.left=t,this.dom.box.style.left=this.left+"px"):this.options.rtl?(this.right=t-this.width/2,this.dom.box.style.right=this.right+"px"):(this.left=t-this.width/2,this.dom.box.style.left=this.left+"px")}},{key:"repositionXWithRanges",value:function(t,e){var i=Math.round(Math.max(e-t+.5,1));this.options.rtl?this.right=t:this.left=t,this.width=Math.max(i,this.minWidth||0),this.options.rtl?this.dom.box.style.right=this.right+"px":this.dom.box.style.left=this.left+"px",this.dom.box.style.width=i+"px"}},{key:"repositionY",value:function(){var t=this.options.orientation.item,e=this.dom.box;if(e.style.top="top"==t?(this.top||0)+"px":(this.parent.height-this.top-this.height||0)+"px",this.options.showStipes){if("top"==t)this.dom.line.style.top="0",this.dom.line.style.height=this.parent.top+this.top+1+"px",this.dom.line.style.bottom="";else{var i=this.parent.itemSet.props.height,n=i-this.parent.top-this.parent.height+this.top;this.dom.line.style.top=i-n+"px",this.dom.line.style.bottom="0"}this.dom.dot.style.top=-this.dom.dot.offsetHeight/2+"px"}}},{key:"getWidthLeft",value:function(){return this.width/2}},{key:"getWidthRight",value:function(){return this.width/2}},{key:"move",value:function(){this.repositionX(),this.repositionY()}},{key:"attach",value:function(){var t,e=!0,i=!1,n=void 0;try{for(var s,r=wu(this.data.uiItems);!(e=(s=r.next()).done);e=!0){s.value.cluster=this}}catch(t){i=!0,n=t}finally{try{e||null==r.return||r.return()}finally{if(i)throw n}}this.data.items=mu(t=this.data.uiItems).call(t,(function(t){return t.data})),this.attached=!0,this.dirty=!0}},{key:"detach",value:function(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.hasItems()){var e=!0,i=!1,n=void 0;try{for(var s,r=wu(this.data.uiItems);!(e=(s=r.next()).done);e=!0){var o=s.value;delete o.cluster}}catch(t){i=!0,n=t}finally{try{e||null==r.return||r.return()}finally{if(i)throw n}}this.attached=!1,t&&this.group&&(this.group.remove(this),this.group=null),this.data.items=[],this.dirty=!0}}},{key:"_onDoubleClick",value:function(){this._fit()}},{key:"_setupRange",value:function(){var t,e,i,n=mu(t=this.data.uiItems).call(t,(function(t){return{start:t.data.start.valueOf(),end:t.data.end?t.data.end.valueOf():t.data.start.valueOf()}}));this.data.min=Math.min.apply(Math,Iu(mu(n).call(n,(function(t){return Math.min(t.start,t.end||t.start)})))),this.data.max=Math.max.apply(Math,Iu(mu(n).call(n,(function(t){return Math.max(t.start,t.end||t.start)}))));var s=mu(e=this.data.uiItems).call(e,(function(t){return t.center})),r=Pd(s).call(s,(function(t,e){return t+e}),0)/this.data.uiItems.length;$o(i=this.data.uiItems).call(i,(function(t){return t.data.end}))?(this.data.start=new Date(this.data.min),this.data.end=new Date(this.data.max)):(this.data.start=new Date(r),this.data.end=null)}},{key:"_getUiItems",value:function(){var t,e=this;return this.data.uiItems&&this.data.uiItems.length?ls(t=this.data.uiItems).call(t,(function(t){return t.cluster===e})):[]}},{key:"_createDomElement",value:function(){if(!this.dom){var t;if(this.dom={},this.dom.box=document.createElement("DIV"),this.dom.content=document.createElement("DIV"),this.dom.content.className="vis-item-content",this.dom.box.appendChild(this.dom.content),this.options.showStipes&&(this.dom.line=document.createElement("DIV"),this.dom.line.className="vis-cluster-line",this.dom.line.style.display="none",this.dom.dot=document.createElement("DIV"),this.dom.dot.className="vis-cluster-dot",this.dom.dot.style.display="none"),this.options.fitOnDoubleClick)this.dom.box.ondblclick=bs(t=e.prototype._onDoubleClick).call(t,this);this.dom.box["vis-item"]=this,this.dirty=!0}}},{key:"_appendDomElement",value:function(){if(!this.parent)throw new Error("Cannot redraw item: no parent attached");if(!this.dom.box.parentNode){var t=this.parent.dom.foreground;if(!t)throw new Error("Cannot redraw item: parent has no foreground container element");t.appendChild(this.dom.box)}var e=this.parent.dom.background;if(this.options.showStipes){if(!this.dom.line.parentNode){if(!e)throw new Error("Cannot redraw item: parent has no background container element");e.appendChild(this.dom.line)}if(!this.dom.dot.parentNode){var i=this.parent.dom.axis;if(!e)throw new Error("Cannot redraw item: parent has no axis container element");i.appendChild(this.dom.dot)}}this.displayed=!0}},{key:"_updateDirtyDomComponents",value:function(){if(this.dirty){this._updateContents(this.dom.content),this._updateDataAttributes(this.dom.box),this._updateStyle(this.dom.box);var t=this.baseClassName+" "+(this.data.className?" "+this.data.className:"")+(this.selected?" vis-selected":"")+" vis-readonly";this.dom.box.className="vis-item "+t,this.options.showStipes&&(this.dom.line.className="vis-item vis-cluster-line "+(this.selected?" vis-selected":""),this.dom.dot.className="vis-item vis-cluster-dot "+(this.selected?" vis-selected":"")),this.data.end&&(this.dom.content.style.maxWidth="none")}}},{key:"_getDomComponentsSizes",value:function(){return{previous:{right:this.dom.box.style.right,left:this.dom.box.style.left},box:{width:this.dom.box.offsetWidth,height:this.dom.box.offsetHeight}}}},{key:"_updateDomComponentsSizes",value:function(t){this.options.rtl?this.dom.box.style.right="0px":this.dom.box.style.left="0px",this.data.end?this.minWidth=t.box.width:this.width=t.box.width,this.height=t.box.height,this.options.rtl?this.dom.box.style.right=t.previous.right:this.dom.box.style.left=t.previous.left,this.dirty=!1}},{key:"_repaintDomAdditionals",value:function(){this._repaintOnItemUpdateTimeTooltip(this.dom.box)}},{key:"_isStipeVisible",value:function(){return this.minWidth>=this.width||!this.data.end}},{key:"_getFitRange",value:function(){var t=.05*(this.data.max-this.data.min)/2;return{fitStart:this.data.min-t,fitEnd:this.data.max+t}}},{key:"_fit",value:function(){if(this.emitter){var t=this._getFitRange(),e=t.fitStart,i=t.fitEnd,n={start:new Date(e),end:new Date(i),animation:!0};this.emitter.emit("fit",n)}}},{key:"_getItemData",value:function(){return this.data}}]),e}(fd);Ed.prototype.baseClassName="vis-item vis-range vis-cluster";var Ld="__ungrouped__",Id=function(){function t(e){Ds(this,t),this.itemSet=e,this.groups={},this.cache={},this.cache[-1]=[]}return Ts(t,[{key:"createClusterItem",value:function(t,e,i){return new Ed(t,e,i)}},{key:"setItems",value:function(t,e){this.items=t||[],this.dataChanged=!0,this.applyOnChangedLevel=!1,e&&e.applyOnChangedLevel&&(this.applyOnChangedLevel=e.applyOnChangedLevel)}},{key:"updateData",value:function(){this.dataChanged=!0,this.applyOnChangedLevel=!1}},{key:"getClusters",value:function(t,e,i){var n="boolean"==typeof i?{}:i,s=n.maxItems,r=n.clusterCriteria;r||(r=function(){return!0}),s=s||1;var o=-1,a=0;if(e>0){if(e>=1)return[];o=Math.abs(Math.round(Math.log(100/e)/Math.log(2))),a=Math.abs(Math.pow(2,o))}if(this.dataChanged){var l=o!=this.cacheLevel;(!this.applyOnChangedLevel||l)&&(this._dropLevelsCache(),this._filterData())}this.cacheLevel=o;var h=this.cache[o];if(!h){for(var u in h=[],this.groups)if(this.groups.hasOwnProperty(u))for(var d=this.groups[u],c=d.length,f=0;f<c;){for(var m=d[f],p=1,g=f-1;g>=0&&m.center-d[g].center<a/2;)!d[g].cluster&&r(m.data,d[g].data)&&p++,g--;for(var v=f+1;v<d.length&&d[v].center-m.center<a/2;)r(m.data,d[v].data)&&p++,v++;for(var y=h.length-1;y>=0&&m.center-h[y].center<a;)m.group==h[y].group&&r(m.data,h[y].data)&&p++,y--;if(p>s){for(var _=p-s+1,b=[],w=f;b.length<_&&w<d.length;)r(d[w].data,d[w].data)&&b.push(d[w]),w++;var k=this.itemSet.getGroupId(m.data),D=this.itemSet.groups[k]||this.itemSet.groups[Ld],S=this._getClusterForItems(b,D,t,i);h.push(S),f+=_}else delete m.cluster,f+=1}this.cache[o]=h}return h}},{key:"_filterData",value:function(){var t={};this.groups=t;for(var e=0,i=Md(this.items);e<i.length;e++){var n=i[e],s=n.parent?n.parent.groupId:"",r=t[s];r||(r=[],t[s]=r),r.push(n),n.data.start&&(n.data.end?n.center=(n.data.start.valueOf()+n.data.end.valueOf())/2:n.center=n.data.start.valueOf())}for(var o in t){var a;if(t.hasOwnProperty(o))Mo(a=t[o]).call(a,(function(t,e){return t.center-e.center}))}this.dataChanged=!1}},{key:"_getClusterForItems",value:function(t,e,i,n){var s,r,o=mu(s=i||[]).call(s,(function(t){var e;return{cluster:t,itemsIds:new uu(mu(e=t.data.uiItems).call(e,(function(t){return t.id})))}}));if(o.length){var a=!0,l=!1,h=void 0;try{for(var u,d=function(){var e=u.value;if(e.itemsIds.size===t.length&&kd(t).call(t,(function(t){return e.itemsIds.has(t.id)})))return r=e.cluster,"break"},c=wu(o);!(a=(u=c.next()).done);a=!0){if("break"===d())break}}catch(t){l=!0,h=t}finally{try{a||null==c.return||c.return()}finally{if(l)throw h}}}if(r)return r.setUiItems(t),r.group!==e&&(r.group&&r.group.remove(r),e&&(e.add(r),r.group=e)),r;var f=n.titleTemplate||"",m={toScreen:this.itemSet.body.util.toScreen,toTime:this.itemSet.body.util.toTime},p='<div title="'+g+'">'+t.length+"</div>",g=f.replace(/{count}/,t.length),v=Ru({},n,this.itemSet.options),y={content:p,title:g,group:e,uiItems:t,eventEmitter:this.itemSet.body.emitter,range:this.itemSet.body.range};return r=this.createClusterItem(y,m,v),e&&(e.add(r),r.group=e),r.attach(),r}},{key:"_dropLevelsCache",value:function(){this.cache={},this.cacheLevel=-1,this.cache[this.cacheLevel]=[]}}]),t}(),Ad="__background__",Nd=function(t){function e(t,i){var n;Ds(this,e),(n=Cr(this,Lr(e).call(this))).body=t,n.defaultOptions={type:null,orientation:{item:"bottom"},align:"auto",stack:!0,stackSubgroups:!0,groupOrderSwap:function(t,e,i){var n=e.order;e.order=t.order,t.order=n},groupOrder:"order",selectable:!0,multiselect:!1,itemsAlwaysDraggable:{item:!1,range:!1},editable:{updateTime:!1,updateGroup:!1,add:!1,remove:!1,overrideItems:!1},groupEditable:{order:!1,add:!1,remove:!1},snap:Mh.snap,onDropObjectOnItem:function(t,e,i){i(e)},onAdd:function(t,e){e(t)},onUpdate:function(t,e){e(t)},onMove:function(t,e){e(t)},onRemove:function(t,e){e(t)},onMoving:function(t,e){e(t)},onAddGroup:function(t,e){e(t)},onMoveGroup:function(t,e){e(t)},onRemoveGroup:function(t,e){e(t)},margin:{item:{horizontal:10,vertical:10},axis:20},showTooltips:!0,tooltip:{followMouse:!1,overflowMethod:"flip",delay:500},tooltipOnItemUpdateTime:!1},n.options=to.extend({},n.defaultOptions),n.options.rtl=i.rtl,n.options.onTimeout=i.onTimeout,n.itemOptions={type:{start:"Date",end:"Date"}},n.conversion={toScreen:t.util.toScreen,toTime:t.util.toTime},n.dom={},n.props={},n.hammer=null;var s=Or(n);return n.itemsData=null,n.groupsData=null,n.itemsSettingTime=null,n.initialItemSetDrawn=!1,n.userContinueNotBail=null,n.sequentialSelection=!1,n.itemListeners={add:function(t,e,i){s._onAdd(e.items),s.options.cluster&&s.clusterGenerator.setItems(s.items,{applyOnChangedLevel:!1}),s.redraw()},update:function(t,e,i){s._onUpdate(e.items),s.options.cluster&&s.clusterGenerator.setItems(s.items,{applyOnChangedLevel:!1}),s.redraw()},remove:function(t,e,i){s._onRemove(e.items),s.options.cluster&&s.clusterGenerator.setItems(s.items,{applyOnChangedLevel:!1}),s.redraw()}},n.groupListeners={add:function(t,e,i){if(s._onAddGroups(e.items),s.groupsData&&s.groupsData.length>0){var n,r=s.groupsData.getDataSet();is(n=r.get()).call(n,(function(t){if(t.nestedGroups){var e;0!=t.showNested&&(t.showNested=!0);var n=[];is(e=t.nestedGroups).call(e,(function(e){var i=r.get(e);i&&(i.nestedInGroup=t.id,0==t.showNested&&(i.visible=!1),n=vo(n).call(n,i))})),r.update(n,i)}}))}},update:function(t,e,i){s._onUpdateGroups(e.items)},remove:function(t,e,i){s._onRemoveGroups(e.items)}},n.items={},n.groups={},n.groupIds=[],n.selection=[],n.popup=null,n.popupTimer=null,n.touchParams={},n.groupTouchParams={group:null,isDragging:!1},n._create(),n.setOptions(i),n.clusters=[],n}return jr(e,t),Ts(e,[{key:"_create",value:function(){var t,e,i,n,s,r,o,a,l,h,u,d,c,f,m,p=this,g=document.createElement("div");g.className="vis-itemset",g["vis-itemset"]=this,this.dom.frame=g;var v=document.createElement("div");v.className="vis-background",g.appendChild(v),this.dom.background=v;var y=document.createElement("div");y.className="vis-foreground",g.appendChild(y),this.dom.foreground=y;var _=document.createElement("div");_.className="vis-axis",this.dom.axis=_;var b=document.createElement("div");b.className="vis-labelset",this.dom.labelSet=b,this._updateUngrouped();var w=new cd(Ad,null,this);w.show(),this.groups[Ad]=w,this.hammer=new _h(this.body.dom.centerContainer),this.hammer.on("hammer.input",(function(t){t.isFirst&&p._onTouch(t)})),this.hammer.on("panstart",bs(t=this._onDragStart).call(t,this)),this.hammer.on("panmove",bs(e=this._onDrag).call(e,this)),this.hammer.on("panend",bs(i=this._onDragEnd).call(i,this)),this.hammer.get("pan").set({threshold:5,direction:_h.ALL}),this.hammer.on("tap",bs(n=this._onSelectItem).call(n,this)),this.hammer.on("press",bs(s=this._onMultiSelectItem).call(s,this)),this.hammer.on("doubletap",bs(r=this._onAddItem).call(r,this)),this.options.rtl?this.groupHammer=new _h(this.body.dom.rightContainer):this.groupHammer=new _h(this.body.dom.leftContainer),this.groupHammer.on("tap",bs(o=this._onGroupClick).call(o,this)),this.groupHammer.on("panstart",bs(a=this._onGroupDragStart).call(a,this)),this.groupHammer.on("panmove",bs(l=this._onGroupDrag).call(l,this)),this.groupHammer.on("panend",bs(h=this._onGroupDragEnd).call(h,this)),this.groupHammer.get("pan").set({threshold:5,direction:_h.DIRECTION_VERTICAL}),this.body.dom.centerContainer.addEventListener("mouseover",bs(u=this._onMouseOver).call(u,this)),this.body.dom.centerContainer.addEventListener("mouseout",bs(d=this._onMouseOut).call(d,this)),this.body.dom.centerContainer.addEventListener("mousemove",bs(c=this._onMouseMove).call(c,this)),this.body.dom.centerContainer.addEventListener("contextmenu",bs(f=this._onDragEnd).call(f,this)),this.body.dom.centerContainer.addEventListener("mousewheel",bs(m=this._onMouseWheel).call(m,this)),this.show()}},{key:"setOptions",value:function(t){var e=this;if(t){var i,n;to.selectiveExtend(["type","rtl","align","order","stack","stackSubgroups","selectable","multiselect","sequentialSelection","multiselectPerGroup","groupOrder","dataAttributes","template","groupTemplate","visibleFrameTemplate","hide","snap","groupOrderSwap","showTooltips","tooltip","tooltipOnItemUpdateTime","groupHeightMode","onTimeout"],this.options,t),"itemsAlwaysDraggable"in t&&("boolean"==typeof t.itemsAlwaysDraggable?(this.options.itemsAlwaysDraggable.item=t.itemsAlwaysDraggable,this.options.itemsAlwaysDraggable.range=!1):"object"===Tr(t.itemsAlwaysDraggable)&&(to.selectiveExtend(["item","range"],this.options.itemsAlwaysDraggable,t.itemsAlwaysDraggable),this.options.itemsAlwaysDraggable.item||(this.options.itemsAlwaysDraggable.range=!1))),"sequentialSelection"in t&&"boolean"==typeof t.sequentialSelection&&(this.options.sequentialSelection=t.sequentialSelection),"orientation"in t&&("string"==typeof t.orientation?this.options.orientation.item="top"===t.orientation?"top":"bottom":"object"===Tr(t.orientation)&&"item"in t.orientation&&(this.options.orientation.item=t.orientation.item)),"margin"in t&&("number"==typeof t.margin?(this.options.margin.axis=t.margin,this.options.margin.item.horizontal=t.margin,this.options.margin.item.vertical=t.margin):"object"===Tr(t.margin)&&(to.selectiveExtend(["axis"],this.options.margin,t.margin),"item"in t.margin&&("number"==typeof t.margin.item?(this.options.margin.item.horizontal=t.margin.item,this.options.margin.item.vertical=t.margin.item):"object"===Tr(t.margin.item)&&to.selectiveExtend(["horizontal","vertical"],this.options.margin.item,t.margin.item)))),is(i=["locale","locales"]).call(i,(function(i){i in t&&(e.options[i]=t[i])})),"editable"in t&&("boolean"==typeof t.editable?(this.options.editable.updateTime=t.editable,this.options.editable.updateGroup=t.editable,this.options.editable.add=t.editable,this.options.editable.remove=t.editable,this.options.editable.overrideItems=!1):"object"===Tr(t.editable)&&to.selectiveExtend(["updateTime","updateGroup","add","remove","overrideItems"],this.options.editable,t.editable)),"groupEditable"in t&&("boolean"==typeof t.groupEditable?(this.options.groupEditable.order=t.groupEditable,this.options.groupEditable.add=t.groupEditable,this.options.groupEditable.remove=t.groupEditable):"object"===Tr(t.groupEditable)&&to.selectiveExtend(["order","add","remove"],this.options.groupEditable,t.groupEditable));is(n=["onDropObjectOnItem","onAdd","onUpdate","onRemove","onMove","onMoving","onAddGroup","onMoveGroup","onRemoveGroup"]).call(n,(function(i){var n=t[i];if(n){var s;if("function"!=typeof n)throw new Error(vo(s="option ".concat(i," must be a function ")).call(s,i,"(item, callback)"));e.options[i]=n}})),t.cluster?(Ru(this.options,{cluster:t.cluster}),this.clusterGenerator||(this.clusterGenerator=new Id(this)),this.clusterGenerator.setItems(this.items,{applyOnChangedLevel:!1}),this.markDirty({refreshItems:!0,restackGroups:!0}),this.redraw()):this.clusterGenerator?(this._detachAllClusters(),this.clusters=[],this.clusterGenerator=null,this.options.cluster=void 0,this.markDirty({refreshItems:!0,restackGroups:!0}),this.redraw()):this.markDirty()}}},{key:"markDirty",value:function(t){this.groupIds=[],t&&(t.refreshItems&&is(to).call(to,this.items,(function(t){t.dirty=!0,t.displayed&&t.redraw()})),t.restackGroups&&is(to).call(to,this.groups,(function(t,e){e!==Ad&&(t.stackDirty=!0)})))}},{key:"destroy",value:function(){this.clearPopupTimer(),this.hide(),this.setItems(null),this.setGroups(null),this.hammer&&this.hammer.destroy(),this.groupHammer&&this.groupHammer.destroy(),this.hammer=null,this.body=null,this.conversion=null}},{key:"hide",value:function(){this.dom.frame.parentNode&&this.dom.frame.parentNode.removeChild(this.dom.frame),this.dom.axis.parentNode&&this.dom.axis.parentNode.removeChild(this.dom.axis),this.dom.labelSet.parentNode&&this.dom.labelSet.parentNode.removeChild(this.dom.labelSet)}},{key:"show",value:function(){this.dom.frame.parentNode||this.body.dom.center.appendChild(this.dom.frame),this.dom.axis.parentNode||this.body.dom.backgroundVertical.appendChild(this.dom.axis),this.dom.labelSet.parentNode||(this.options.rtl?this.body.dom.right.appendChild(this.dom.labelSet):this.body.dom.left.appendChild(this.dom.labelSet))}},{key:"setPopupTimer",value:function(t){if(this.clearPopupTimer(),t){var e=this.options.tooltip.delay||"number"==typeof this.options.tooltip.delay?this.options.tooltip.delay:500;this.popupTimer=fs((function(){t.show()}),e)}}},{key:"clearPopupTimer",value:function(){null!=this.popupTimer&&(clearTimeout(this.popupTimer),this.popupTimer=null)}},{key:"setSelection",value:function(t){var e;null==t&&(t=[]),ks(t)||(t=[t]);var i=ls(e=this.selection).call(e,(function(e){return-1===la(t).call(t,e)})),n=!0,s=!1,r=void 0;try{for(var o,a=wu(i);!(n=(o=a.next()).done);n=!0){var l=o.value,h=this.getItemById(l);h&&h.unselect()}}catch(t){s=!0,r=t}finally{try{n||null==a.return||a.return()}finally{if(s)throw r}}this.selection=Iu(t);var u=!0,d=!1,c=void 0;try{for(var f,m=wu(t);!(u=(f=m.next()).done);u=!0){var p=f.value,g=this.getItemById(p);g&&g.select()}}catch(t){d=!0,c=t}finally{try{u||null==m.return||m.return()}finally{if(d)throw c}}}},{key:"getSelection",value:function(){var t;return vo(t=this.selection).call(t,[])}},{key:"getVisibleItems",value:function(){var t,e,i=this.body.range.getRange();this.options.rtl?(t=this.body.util.toScreen(i.start),e=this.body.util.toScreen(i.end)):(e=this.body.util.toScreen(i.start),t=this.body.util.toScreen(i.end));var n=[];for(var s in this.groups)if(this.groups.hasOwnProperty(s)){var r=this.groups[s],o=r.isVisible?r.visibleItems:[],a=!0,l=!1,h=void 0;try{for(var u,d=wu(o);!(a=(u=d.next()).done);a=!0){var c=u.value;this.options.rtl?c.right<e&&c.right+c.width>t&&n.push(c.id):c.left<t&&c.left+c.width>e&&n.push(c.id)}}catch(t){l=!0,h=t}finally{try{a||null==d.return||d.return()}finally{if(l)throw h}}}return n}},{key:"getVisibleGroups",value:function(){var t=[];for(var e in this.groups){if(this.groups.hasOwnProperty(e))this.groups[e].isVisible&&t.push(e)}return t}},{key:"getItemById",value:function(t){var e;return this.items[t]||bu(e=this.clusters).call(e,(function(e){return e.id===t}))}},{key:"_deselect",value:function(t){for(var e=this.selection,i=0,n=e.length;i<n;i++)if(e[i]==t){ea(e).call(e,i,1);break}}},{key:"redraw",value:function(){var t=this,e=this.options.margin,i=this.body.range,n=to.option.asSize,s=this.options,r=s.orientation.item,o=!1,a=this.dom.frame;this.props.top=this.body.domProps.top.height+this.body.domProps.border.top,this.options.rtl?this.props.right=this.body.domProps.right.width+this.body.domProps.border.right:this.props.left=this.body.domProps.left.width+this.body.domProps.border.left,a.className="vis-itemset",this.options.cluster&&this._clusterItems(),o=this._orderGroups()||o;var l=i.end-i.start,h=l!=this.lastVisibleInterval||this.props.width!=this.props.lastWidth,u=i.start!=this.lastRangeStart,d=s.stack!=this.lastStack,c=s.stackSubgroups!=this.lastStackSubgroups,f=h||u||d||c;this.lastVisibleInterval=l,this.lastRangeStart=i.start,this.lastStack=s.stack,this.lastStackSubgroups=s.stackSubgroups,this.props.lastWidth=this.props.width;var m=this._firstGroup(),p={item:e.item,axis:e.axis},g={item:e.item,axis:e.item.vertical/2},v=0,y=e.axis+e.item.vertical;this.groups[Ad].redraw(i,g,f);var _={},b=0;return is(to).call(to,this.groups,(function(t,e){if(e!==Ad){var n=t==m?p:g;_[e]=t.redraw(i,n,f,!0),b=_[e].length}})),b>0&&function(){for(var e={},i=function(t){is(to).call(to,_,(function(i,n){e[n]=i[t]()}))},n=0;n<b;n++)i(n);is(to).call(to,t.groups,(function(t,i){if(i!==Ad){var n=e[i];o=n||o,v+=t.height}})),v=Math.max(v,y)}(),v=Math.max(v,y),a.style.height=n(v),this.props.width=a.offsetWidth,this.props.height=v,this.dom.axis.style.top=n("top"==r?this.body.domProps.top.height+this.body.domProps.border.top:this.body.domProps.top.height+this.body.domProps.centerContainer.height),this.options.rtl?this.dom.axis.style.right="0":this.dom.axis.style.left="0",this.initialItemSetDrawn=!0,o=this._isResized()||o}},{key:"_firstGroup",value:function(){var t="top"==this.options.orientation.item?0:this.groupIds.length-1,e=this.groupIds[t];return this.groups[e]||this.groups.__ungrouped__||null}},{key:"_updateUngrouped",value:function(){var t,e,i=this.groups.__ungrouped__;if(this.groupsData){if(i)for(e in i.hide(),delete this.groups.__ungrouped__,this.items)if(this.items.hasOwnProperty(e)){(t=this.items[e]).parent&&t.parent.remove(t);var n=this.getGroupId(t.data),s=this.groups[n];s&&s.add(t)||t.hide()}}else if(!i){for(e in i=new dd(null,null,this),this.groups.__ungrouped__=i,this.items)this.items.hasOwnProperty(e)&&(t=this.items[e],i.add(t));i.show()}}},{key:"getLabelSet",value:function(){return this.dom.labelSet}},{key:"setItems",value:function(t){this.itemsSettingTime=new Date;var e,i=this,n=this.itemsData;if(t){if(!(t instanceof we||t instanceof ke))throw new TypeError("Data must be an instance of DataSet or DataView");this.itemsData=t}else this.itemsData=null;if(n&&(is(to).call(to,this.itemListeners,(function(t,e){n.off(e,t)})),e=n.getIds(),this._onRemove(e)),this.itemsData){var s=this.id;is(to).call(to,this.itemListeners,(function(t,e){i.itemsData.on(e,t,s)})),e=this.itemsData.getIds(),this._onAdd(e),this._updateUngrouped()}this.body.emitter.emit("_change",{queue:!0})}},{key:"getItems",value:function(){return this.itemsData}},{key:"setGroups",value:function(t){var e,i=this;if(this.groupsData&&(is(to).call(to,this.groupListeners,(function(t,e){i.groupsData.off(e,t)})),e=this.groupsData.getIds(),this.groupsData=null,this._onRemoveGroups(e)),t){if(!(t instanceof we||t instanceof ke))throw new TypeError("Data must be an instance of DataSet or DataView");this.groupsData=t}else this.groupsData=null;if(this.groupsData){var n,s=this.groupsData;this.groupsData instanceof ke&&(s=this.groupsData.getDataSet()),is(n=s.get()).call(n,(function(t){var e;t.nestedGroups&&is(e=t.nestedGroups).call(e,(function(e){var i=s.get(e);i.nestedInGroup=t.id,0==t.showNested&&(i.visible=!1),s.update(i)}))}));var r=this.id;is(to).call(to,this.groupListeners,(function(t,e){i.groupsData.on(e,t,r)})),e=this.groupsData.getIds(),this._onAddGroups(e)}this._updateUngrouped(),this._order(),this.options.cluster&&(this.clusterGenerator.updateData(),this._clusterItems(),this.markDirty({refreshItems:!0,restackGroups:!0})),this.body.emitter.emit("_change",{queue:!0})}},{key:"getGroups",value:function(){return this.groupsData}},{key:"removeItem",value:function(t){var e=this.itemsData.get(t),i=this.itemsData.getDataSet();e&&this.options.onRemove(e,(function(e){e&&i.remove(t)}))}},{key:"_getType",value:function(t){return t.type||this.options.type||(t.end?"range":"box")}},{key:"getGroupId",value:function(t){return"background"==this._getType(t)&&null==t.group?Ad:this.groupsData?t.group:"__ungrouped__"}},{key:"_onUpdate",value:function(t){var i=this,n=this;is(t).call(t,(function(t){var s,r=n.itemsData.get(t,n.itemOptions),o=n.items[t],a=r?n._getType(r):null,l=e.types[a];if(o&&(l&&o instanceof l?n._updateItem(o,r):(s=o.selected,n._removeItem(o),o=null)),!o&&r){if(!l)throw new TypeError('Unknown item type "'.concat(a,'"'));(o=new l(r,n.conversion,n.options)).id=t,n._addItem(o),s&&(i.selection.push(t),o.select())}})),this._order(),this.options.cluster&&(this.clusterGenerator.setItems(this.items,{applyOnChangedLevel:!1}),this._clusterItems()),this.body.emitter.emit("_change",{queue:!0})}},{key:"_onRemove",value:function(t){var e=0,i=this;is(t).call(t,(function(t){var n=i.items[t];n&&(e++,i._removeItem(n))})),e&&(this._order(),this.body.emitter.emit("_change",{queue:!0}))}},{key:"_order",value:function(){is(to).call(to,this.groups,(function(t){t.order()}))}},{key:"_onUpdateGroups",value:function(t){this._onAddGroups(t)}},{key:"_onAddGroups",value:function(t){var e=this;is(t).call(t,(function(t){var i=e.groupsData.get(t),n=e.groups[t];if(n)n.setData(i);else{if("__ungrouped__"==t||t==Ad)throw new Error("Illegal group id. ".concat(t," is a reserved id."));var s=pu(e.options);for(var r in to.extend(s,{height:null}),n=new dd(t,i,e),e.groups[t]=n,e.items)if(e.items.hasOwnProperty(r)){var o=e.items[r];o.data.group==t&&n.add(o)}n.order(),n.show()}})),this.body.emitter.emit("_change",{queue:!0})}},{key:"_onRemoveGroups",value:function(t){var e=this.groups;is(t).call(t,(function(t){var i=e[t];i&&(i.hide(),delete e[t])})),this.options.cluster&&(this.clusterGenerator.updateData(),this._clusterItems()),this.markDirty({restackGroups:!!this.options.cluster}),this.body.emitter.emit("_change",{queue:!0})}},{key:"_orderGroups",value:function(){if(this.groupsData){var t=this.groupsData.getIds({order:this.options.groupOrder});t=this._orderNestedGroups(t);var e=!to.equalArray(t,this.groupIds);if(e){var i=this.groups;is(t).call(t,(function(t){i[t].hide()})),is(t).call(t,(function(t){i[t].show()})),this.groupIds=t}return e}return!1}},{key:"_orderNestedGroups",value:function(t){var e=this;return function t(e,i){var n=[];return is(i).call(i,(function(i){if(n.push(i),e.groupsData.get(i).nestedGroups){var s,r=mu(s=e.groupsData.get({filter:function(t){return t.nestedInGroup==i},order:e.options.groupOrder})).call(s,(function(t){return t.id}));n=vo(n).call(n,t(e,r))}})),n}(this,ls(t).call(t,(function(t){return!e.groupsData.get(t).nestedInGroup})))}},{key:"_addItem",value:function(t){this.items[t.id]=t;var e=this.getGroupId(t.data),i=this.groups[e];i?i&&i.data&&i.data.showNested&&(t.groupShowing=!0):t.groupShowing=!1,i&&i.add(t)}},{key:"_updateItem",value:function(t,e){t.setData(e);var i=this.getGroupId(t.data),n=this.groups[i];n?n&&n.data&&n.data.showNested&&(t.groupShowing=!0):t.groupShowing=!1}},{key:"_removeItem",value:function(t){var e,i;t.hide(),delete this.items[t.id];var n=la(e=this.selection).call(e,t.id);-1!=n&&ea(i=this.selection).call(i,n,1),t.parent&&t.parent.remove(t),null!=this.popup&&this.popup.hide()}},{key:"_constructByEndArray",value:function(t){for(var e=[],i=0;i<t.length;i++)t[i]instanceof gd&&e.push(t[i]);return e}},{key:"_onTouch",value:function(t){this.touchParams.item=this.itemFromTarget(t),this.touchParams.dragLeftItem=t.target.dragLeftItem||!1,this.touchParams.dragRightItem=t.target.dragRightItem||!1,this.touchParams.itemProps=null}},{key:"_getGroupIndex",value:function(t){for(var e=0;e<this.groupIds.length;e++)if(t==this.groupIds[e])return e}},{key:"_onDragStart",value:function(t){var e=this;if(!this.touchParams.itemIsDragging){var i,n=this.touchParams.item||null,s=this;if(n&&(n.selected||this.options.itemsAlwaysDraggable.item)){if(this.options.editable.overrideItems&&!this.options.editable.updateTime&&!this.options.editable.updateGroup)return;if(null!=n.editable&&!n.editable.updateTime&&!n.editable.updateGroup&&!this.options.editable.overrideItems)return;var r=this.touchParams.dragLeftItem,o=this.touchParams.dragRightItem;if(this.touchParams.itemIsDragging=!0,this.touchParams.selectedItem=n,r)i={item:r,initialX:t.center.x,dragLeft:!0,data:this._cloneItemData(n.data)},this.touchParams.itemProps=[i];else if(o)i={item:o,initialX:t.center.x,dragRight:!0,data:this._cloneItemData(n.data)},this.touchParams.itemProps=[i];else if(this.options.editable.add&&(t.srcEvent.ctrlKey||t.srcEvent.metaKey))this._onDragStartAddItem(t);else{this.groupIds.length<1&&this.redraw();var a=this._getGroupIndex(n.data.group),l=this.options.itemsAlwaysDraggable.item&&!n.selected?[n.id]:this.getSelection();this.touchParams.itemProps=mu(l).call(l,(function(i){var n=s.items[i],r=s._getGroupIndex(n.data.group);return{item:n,initialX:t.center.x,groupOffset:a-r,data:e._cloneItemData(n.data)}}))}t.stopPropagation()}else this.options.editable.add&&(t.srcEvent.ctrlKey||t.srcEvent.metaKey)&&this._onDragStartAddItem(t)}}},{key:"_onDragStartAddItem",value:function(t){var e=this.options.snap||null,i=this.dom.frame.getBoundingClientRect(),n=this.options.rtl?i.right-t.center.x+10:t.center.x-i.left-10,s=this.body.util.toTime(n),r=this.body.util.getScale(),o=this.body.util.getStep(),a=e?e(s,r,o):s,l={type:"range",start:a,end:a,content:"new item"},h=to.randomUUID();l[this.itemsData._idProp]=h;var u=this.groupFromTarget(t);u&&(l.group=u.groupId);var d=new gd(l,this.conversion,this.options);d.id=h,d.data=this._cloneItemData(l),this._addItem(d),this.touchParams.selectedItem=d;var c={item:d,initialX:t.center.x,data:d.data};this.options.rtl?c.dragLeft=!0:c.dragRight=!0,this.touchParams.itemProps=[c],t.stopPropagation()}},{key:"_onDrag",value:function(t){var e=this;if(null!=this.popup&&this.options.showTooltips&&!this.popup.hidden){var i=this.body.dom.centerContainer,n=i.getBoundingClientRect();this.popup.setPosition(t.center.x-n.left+i.offsetLeft,t.center.y-n.top+i.offsetTop),this.popup.show()}if(this.touchParams.itemProps){var s;t.stopPropagation();var r=this,o=this.options.snap||null,a=this.body.dom.root.offsetLeft,l=this.options.rtl?a+this.body.domProps.right.width:a+this.body.domProps.left.width,h=this.body.util.getScale(),u=this.body.util.getStep(),d=this.touchParams.selectedItem,c=(this.options.editable.overrideItems||null==d.editable)&&this.options.editable.updateGroup||!this.options.editable.overrideItems&&null!=d.editable&&d.editable.updateGroup,f=null;if(c&&d&&null!=d.data.group){var m=r.groupFromTarget(t);m&&(f=this._getGroupIndex(m.groupId))}is(s=this.touchParams.itemProps).call(s,(function(i){var n,s,a,m,p,g=r.body.util.toTime(t.center.x-l),v=r.body.util.toTime(i.initialX-l);n=e.options.rtl?-(g-v):g-v;var y=e._cloneItemData(i.item.data);if(null==i.item.editable||i.item.editable.updateTime||i.item.editable.updateGroup||r.options.editable.overrideItems){if((e.options.editable.overrideItems||null==d.editable)&&e.options.editable.updateTime||!e.options.editable.overrideItems&&null!=d.editable&&d.editable.updateTime)if(i.dragLeft)e.options.rtl?null!=y.end&&(a=to.convert(i.data.end,"Date"),p=new Date(a.valueOf()+n),y.end=o?o(p,h,u):p):null!=y.start&&(s=to.convert(i.data.start,"Date"),m=new Date(s.valueOf()+n),y.start=o?o(m,h,u):m);else if(i.dragRight)e.options.rtl?null!=y.start&&(s=to.convert(i.data.start,"Date"),m=new Date(s.valueOf()+n),y.start=o?o(m,h,u):m):null!=y.end&&(a=to.convert(i.data.end,"Date"),p=new Date(a.valueOf()+n),y.end=o?o(p,h,u):p);else if(null!=y.start)if(s=to.convert(i.data.start,"Date").valueOf(),m=new Date(s+n),null!=y.end){var _=(a=to.convert(i.data.end,"Date")).valueOf()-s.valueOf();y.start=o?o(m,h,u):m,y.end=new Date(y.start.valueOf()+_)}else y.start=o?o(m,h,u):m;if(c&&!i.dragLeft&&!i.dragRight&&null!=f&&null!=y.group){var b=f-i.groupOffset;b=Math.max(0,b),b=Math.min(r.groupIds.length-1,b),y.group=r.groupIds[b]}y=e._cloneItemData(y),r.options.onMoving(y,(function(t){t&&i.item.setData(e._cloneItemData(t,"Date"))}))}})),this.body.emitter.emit("_change")}}},{key:"_moveToGroup",value:function(t,e){var i=this.groups[e];if(i&&i.groupId!=t.data.group){var n=t.parent;n.remove(t),n.order(),t.data.group=i.groupId,i.add(t),i.order()}}},{key:"_onDragEnd",value:function(t){var e=this;if(this.touchParams.itemIsDragging=!1,this.touchParams.itemProps){t.stopPropagation();var i=this,n=this.itemsData.getDataSet(),s=this.touchParams.itemProps;this.touchParams.itemProps=null,is(s).call(s,(function(t){var s=t.item.id;if(null!=i.itemsData.get(s,i.itemOptions)){var r=e._cloneItemData(t.item.data);i.options.onMove(r,(function(e){e?(e[n._idProp]=s,n.update(e)):(t.item.setData(t.data),i.body.emitter.emit("_change"))}))}else i.options.onAdd(t.item.data,(function(e){i._removeItem(t.item),e&&i.itemsData.getDataSet().add(e),i.body.emitter.emit("_change")}))}))}}},{key:"_onGroupClick",value:function(t){var e=this,i=this.groupFromTarget(t);fs((function(){e.toggleGroupShowNested(i)}),1)}},{key:"toggleGroupShowNested",value:function(t){var e,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0;if(t&&t.nestedGroups){var n=this.groupsData.getDataSet();t.showNested=null!=i?!!i:!t.showNested;var s=n.get(t.groupId);s.showNested=t.showNested;for(var r=t.nestedGroups,o=r;o.length>0;){var a=o;o=[];for(var l=0;l<a.length;l++){var h=n.get(a[l]);h.nestedGroups&&(o=vo(o).call(o,h.nestedGroups))}o.length>0&&(r=vo(r).call(r,o))}var u=mu(e=n.get(r)).call(e,(function(t){return null==t.visible&&(t.visible=!0),t.visible=!!s.showNested,t}));n.update(vo(u).call(u,s)),s.showNested?(to.removeClassName(t.dom.label,"collapsed"),to.addClassName(t.dom.label,"expanded")):(to.removeClassName(t.dom.label,"expanded"),to.addClassName(t.dom.label,"collapsed"))}}},{key:"toggleGroupDragClassName",value:function(t){t.dom.label.classList.toggle("vis-group-is-dragging"),t.dom.foreground.classList.toggle("vis-group-is-dragging")}},{key:"_onGroupDragStart",value:function(t){this.groupTouchParams.isDragging||this.options.groupEditable.order&&(this.groupTouchParams.group=this.groupFromTarget(t),this.groupTouchParams.group&&(t.stopPropagation(),this.groupTouchParams.isDragging=!0,this.toggleGroupDragClassName(this.groupTouchParams.group),this.groupTouchParams.originalOrder=this.groupsData.getIds({order:this.options.groupOrder})))}},{key:"_onGroupDrag",value:function(t){if(this.options.groupEditable.order&&this.groupTouchParams.group){t.stopPropagation();var e=this.groupsData;this.groupsData instanceof ke&&(e=this.groupsData.getDataSet());var i=this.groupFromTarget(t);if(i&&i.height!=this.groupTouchParams.group.height){var n=i.top<this.groupTouchParams.group.top,s=t.center?t.center.y:t.clientY,r=i.dom.foreground.getBoundingClientRect(),o=this.groupTouchParams.group.height;if(n){if(r.top+o<s)return}else{var a=i.height;if(r.top+a-o>s)return}}if(i&&i!=this.groupTouchParams.group){var l=e.get(i.groupId),h=e.get(this.groupTouchParams.group.groupId);h&&l&&(this.options.groupOrderSwap(h,l,e),e.update(h),e.update(l));var u=e.getIds({order:this.options.groupOrder});if(!to.equalArray(u,this.groupTouchParams.originalOrder))for(var d=this.groupTouchParams.originalOrder,c=this.groupTouchParams.group.groupId,f=Math.min(d.length,u.length),m=0,p=0,g=0;m<f;){for(;m+p<f&&m+g<f&&u[m+p]==d[m+g];)m++;if(m+p>=f)break;if(u[m+p]==c)p=1;else if(d[m+g]==c)g=1;else{var v=la(u).call(u,d[m+g]),y=e.get(u[m+p]),_=e.get(d[m+g]);this.options.groupOrderSwap(y,_,e),e.update(y),e.update(_);var b=u[m+p];u[m+p]=d[m+g],u[v]=b,m++}}}}}},{key:"_onGroupDragEnd",value:function(t){if(this.groupTouchParams.isDragging=!1,this.options.groupEditable.order&&this.groupTouchParams.group){t.stopPropagation();var e=this,i=e.groupTouchParams.group.groupId,n=e.groupsData.getDataSet(),s=to.extend({},n.get(i));e.options.onMoveGroup(s,(function(t){if(t)t[n._idProp]=i,n.update(t);else{var s=n.getIds({order:e.options.groupOrder});if(!to.equalArray(s,e.groupTouchParams.originalOrder))for(var r=e.groupTouchParams.originalOrder,o=Math.min(r.length,s.length),a=0;a<o;){for(;a<o&&s[a]==r[a];)a++;if(a>=o)break;var l=la(s).call(s,r[a]),h=n.get(s[a]),u=n.get(r[a]);e.options.groupOrderSwap(h,u,n),n.update(h),n.update(u);var d=s[a];s[a]=r[a],s[l]=d,a++}}})),e.body.emitter.emit("groupDragged",{groupId:i}),this.toggleGroupDragClassName(this.groupTouchParams.group),this.groupTouchParams.group=null}}},{key:"_onSelectItem",value:function(t){if(this.options.selectable){var e=t.srcEvent&&(t.srcEvent.ctrlKey||t.srcEvent.metaKey),i=t.srcEvent&&t.srcEvent.shiftKey;if(e||i)this._onMultiSelectItem(t);else{var n=this.getSelection(),s=this.itemFromTarget(t),r=s&&s.selectable?[s.id]:[];this.setSelection(r);var o=this.getSelection();(o.length>0||n.length>0)&&this.body.emitter.emit("select",{items:o,event:t})}}}},{key:"_onMouseOver",value:function(t){var e=this.itemFromTarget(t);if(e&&e!==this.itemFromRelatedTarget(t)){var i=e.getTitle();if(this.options.showTooltips&&i){null==this.popup&&(this.popup=new yd(this.body.dom.root,this.options.tooltip.overflowMethod||"flip")),this.popup.setText(i);var n=this.body.dom.centerContainer,s=n.getBoundingClientRect();this.popup.setPosition(t.clientX-s.left+n.offsetLeft,t.clientY-s.top+n.offsetTop),this.setPopupTimer(this.popup)}else this.clearPopupTimer(),null!=this.popup&&this.popup.hide();this.body.emitter.emit("itemover",{item:e.id,event:t})}}},{key:"_onMouseOut",value:function(t){var e=this.itemFromTarget(t);e&&(e!==this.itemFromRelatedTarget(t)&&(this.clearPopupTimer(),null!=this.popup&&this.popup.hide(),this.body.emitter.emit("itemout",{item:e.id,event:t})))}},{key:"_onMouseMove",value:function(t){if(this.itemFromTarget(t)&&(null!=this.popupTimer&&this.setPopupTimer(this.popup),this.options.showTooltips&&this.options.tooltip.followMouse&&this.popup&&!this.popup.hidden)){var e=this.body.dom.centerContainer,i=e.getBoundingClientRect();this.popup.setPosition(t.clientX-i.left+e.offsetLeft,t.clientY-i.top+e.offsetTop),this.popup.show()}}},{key:"_onMouseWheel",value:function(t){this.touchParams.itemIsDragging&&this._onDragEnd(t)}},{key:"_onUpdateItem",value:function(t){if(this.options.selectable&&this.options.editable.updateTime&&this.options.editable.updateGroup){var e=this;if(t){var i=e.itemsData.get(t.id);this.options.onUpdate(i,(function(t){t&&e.itemsData.getDataSet().update(t)}))}}}},{key:"_onDropObjectOnItem",value:function(t){var e=this.itemFromTarget(t),i=JSON.parse(t.dataTransfer.getData("text"));this.options.onDropObjectOnItem(i,e)}},{key:"_onAddItem",value:function(t){if(this.options.selectable&&this.options.editable.add){var e,i,n=this,s=this.options.snap||null,r=this.dom.frame.getBoundingClientRect(),o=this.options.rtl?r.right-t.center.x:t.center.x-r.left,a=this.body.util.toTime(o),l=this.body.util.getScale(),h=this.body.util.getStep();"drop"==t.type?((i=JSON.parse(t.dataTransfer.getData("text"))).content=i.content?i.content:"new item",i.start=i.start?i.start:s?s(a,l,h):a,i.type=i.type||"box",i[this.itemsData._idProp]=i.id||to.randomUUID(),"range"!=i.type||i.end||(e=this.body.util.toTime(o+this.props.width/5),i.end=s?s(e,l,h):e)):((i={start:s?s(a,l,h):a,content:"new item"})[this.itemsData._idProp]=to.randomUUID(),"range"===this.options.type&&(e=this.body.util.toTime(o+this.props.width/5),i.end=s?s(e,l,h):e));var u=this.groupFromTarget(t);u&&(i.group=u.groupId),i=this._cloneItemData(i),this.options.onAdd(i,(function(e){e&&(n.itemsData.getDataSet().add(e),"drop"==t.type&&n.setSelection([e.id]))}))}}},{key:"_onMultiSelectItem",value:function(t){var i=this;if(this.options.selectable){var n=this.itemFromTarget(t);if(n){var s=this.options.multiselect?this.getSelection():[];if((t.srcEvent&&t.srcEvent.shiftKey||!1||this.options.sequentialSelection)&&this.options.multiselect){var r=this.itemsData.get(n.id).group,o=void 0;this.options.multiselectPerGroup&&s.length>0&&(o=this.itemsData.get(s[0]).group),this.options.multiselectPerGroup&&null!=o&&o!=r||s.push(n.id);var a=e._getItemRange(this.itemsData.get(s,this.itemOptions));if(!this.options.multiselectPerGroup||o==r)for(var l in s=[],this.items)if(this.items.hasOwnProperty(l)){var h=this.items[l],u=h.data.start,d=void 0!==h.data.end?h.data.end:u;!(u>=a.min&&d<=a.max)||this.options.multiselectPerGroup&&o!=this.itemsData.get(h.id).group||h instanceof vd||s.push(h.id)}}else{var c=la(s).call(s,n.id);-1==c?s.push(n.id):ea(s).call(s,c,1)}var f=ls(s).call(s,(function(t){return i.getItemById(t).selectable}));this.setSelection(f),this.body.emitter.emit("select",{items:this.getSelection(),event:t})}}}},{key:"itemFromElement",value:function(t){for(var e=t;e;){if(e.hasOwnProperty("vis-item"))return e["vis-item"];e=e.parentNode}return null}},{key:"itemFromTarget",value:function(t){return this.itemFromElement(t.target)}},{key:"itemFromRelatedTarget",value:function(t){return this.itemFromElement(t.relatedTarget)}},{key:"groupFromTarget",value:function(t){var e=t.center?t.center.y:t.clientY,i=this.groupIds;i.length<=0&&this.groupsData&&(i=this.groupsData.getIds({order:this.options.groupOrder}));for(var n=0;n<i.length;n++){var s=i[n],r=this.groups[s],o=r.dom.foreground,a=o.getBoundingClientRect();if(e>=a.top&&e<a.top+o.offsetHeight)return r;if("top"===this.options.orientation.item){if(n===this.groupIds.length-1&&e>a.top)return r}else if(0===n&&e<a.top+o.offset)return r}return null}},{key:"_cloneItemData",value:function(t,e){var i=to.extend({},t);return e||(e=this.itemsData.getDataSet()._options.type),null!=i.start&&(i.start=to.convert(i.start,e&&e.start||"Date")),null!=i.end&&(i.end=to.convert(i.end,e&&e.end||"Date")),i}},{key:"_clusterItems",value:function(){if(this.options.cluster){var t=this.body.range.conversion(this.body.domProps.center.width).scale,e=this.clusterGenerator.getClusters(this.clusters,t,this.options.cluster);if(this.clusters!=e){if(this._detachAllClusters(),e){var i=!0,n=!1,s=void 0;try{for(var r,o=wu(e);!(i=(r=o.next()).done);i=!0){r.value.attach()}}catch(t){n=!0,s=t}finally{try{i||null==o.return||o.return()}finally{if(n)throw s}}this.clusters=e}this._updateClusters(e)}}}},{key:"_detachAllClusters",value:function(){if(this.options.cluster&&this.clusters&&this.clusters.length){var t=!0,e=!1,i=void 0;try{for(var n,s=wu(this.clusters);!(t=(n=s.next()).done);t=!0){n.value.detach()}}catch(t){e=!0,i=t}finally{try{t||null==s.return||s.return()}finally{if(e)throw i}}}}},{key:"_updateClusters",value:function(t){if(this.clusters&&this.clusters.length){var e,i=new uu(mu(t).call(t,(function(t){return t.id}))),n=ls(e=this.clusters).call(e,(function(t){return!i.has(t.id)})),s=!1,r=!0,o=!1,a=void 0;try{for(var l,h=wu(n);!(r=(l=h.next()).done);r=!0){var u,d,c=l.value,f=la(u=this.selection).call(u,c.id);if(-1!==f)c.unselect(),ea(d=this.selection).call(d,f,1),s=!0}}catch(t){o=!0,a=t}finally{try{r||null==h.return||h.return()}finally{if(o)throw a}}if(s){var m=this.getSelection();this.body.emitter.emit("select",{items:m,event:event})}}this.clusters=t||[]}}],[{key:"_getItemRange",value:function(t){var e=null,i=null;return is(t).call(t,(function(t){(null==i||t.start<i)&&(i=t.start),null!=t.end?(null==e||t.end>e)&&(e=t.end):(null==e||t.start>e)&&(e=t.start)})),{min:i,max:e}}},{key:"itemSetFromTarget",value:function(t){for(var e=t.target;e;){if(e.hasOwnProperty("vis-itemset"))return e["vis-itemset"];e=e.parentNode}return null}}]),e}(yo);Nd.types={background:vd,box:md,range:gd,point:pd},Nd.prototype._onAdd=Nd.prototype._onUpdate;var Rd,jd=!1,Fd="background: #FFeeee; color: #dd0000",Hd=function(){function t(){Ds(this,t)}return Ts(t,null,[{key:"validate",value:function(e,i,n){jd=!1,Rd=i;var s=i;return void 0!==n&&(s=i[n]),t.parse(e,s,[]),jd}},{key:"parse",value:function(e,i,n){for(var s in e)e.hasOwnProperty(s)&&t.check(s,e,i,n)}},{key:"check",value:function(e,i,n,s){if(void 0!==n[e]||void 0!==n.__any__){var r=e,o=!0;void 0===n[e]&&void 0!==n.__any__&&(r="__any__",o="object"===t.getType(i[e]));var a=n[r];o&&void 0!==a.__type__&&(a=a.__type__),t.checkFields(e,i,n,r,a,s)}else t.getSuggestion(e,n,s)}},{key:"checkFields",value:function(e,i,n,s,r,o){var a=function(i){console.log("%c"+i+t.printLocation(o,e),Fd)},l=t.getType(i[e]),h=r[l];void 0!==h?"array"===t.getType(h)&&-1===la(h).call(h,i[e])?(a('Invalid option detected in "'+e+'". Allowed values are:'+t.print(h)+' not "'+i[e]+'". '),jd=!0):"object"===l&&"__any__"!==s&&(o=to.copyAndExtendArray(o,e),t.parse(i[e],n[s],o)):void 0===r.any&&(a('Invalid type received for "'+e+'". Expected: '+t.print($r(r))+". Received ["+l+'] "'+i[e]+'"'),jd=!0)}},{key:"getType",value:function(t){var e=Tr(t);return"object"===e?null===t?"null":t instanceof Boolean?"boolean":t instanceof Number?"number":t instanceof String?"string":ks(t)?"array":t instanceof Date?"date":void 0!==t.nodeType?"dom":!0===t._isAMomentObject?"moment":"object":"number"===e?"number":"boolean"===e?"boolean":"string"===e?"string":void 0===e?"undefined":e}},{key:"getSuggestion",value:function(e,i,n){var s,r=t.findInOptions(e,i,n,!1),o=t.findInOptions(e,Rd,[],!0);s=void 0!==r.indexMatch?" in "+t.printLocation(r.path,e,"")+'Perhaps it was incomplete? Did you mean: "'+r.indexMatch+'"?\n\n':o.distance<=4&&r.distance>o.distance?" in "+t.printLocation(r.path,e,"")+"Perhaps it was misplaced? Matching option found at: "+t.printLocation(o.path,o.closestMatch,""):r.distance<=8?'. Did you mean "'+r.closestMatch+'"?'+t.printLocation(r.path,e):". Did you mean one of these: "+t.print($r(i))+t.printLocation(n,e),console.log('%cUnknown option detected: "'+e+'"'+s,Fd),jd=!0}},{key:"findInOptions",value:function(e,i,n){var s=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=1e9,o="",a=[],l=e.toLowerCase(),h=void 0;for(var u in i){var d=void 0;if(void 0!==i[u].__type__&&!0===s){var c=t.findInOptions(e,i[u],to.copyAndExtendArray(n,u));r>c.distance&&(o=c.closestMatch,a=c.path,r=c.distance,h=c.indexMatch)}else{var f;-1!==la(f=u.toLowerCase()).call(f,l)&&(h=u),r>(d=t.levenshteinDistance(e,u))&&(o=u,a=to.copyArray(n),r=d)}}return{closestMatch:o,path:a,distance:r,indexMatch:h}}},{key:"printLocation",value:function(t,e){for(var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"Problem value found at: \n",n="\n\n"+i+"options = {\n",s=0;s<t.length;s++){for(var r=0;r<s+1;r++)n+=" ";n+=t[s]+": {\n"}for(var o=0;o<t.length+1;o++)n+=" ";n+=e+"\n";for(var a=0;a<t.length+1;a++){for(var l=0;l<t.length-a;l++)n+=" ";n+="}\n"}return n+"\n\n"}},{key:"print",value:function(t){return mo(t).replace(/(\")|(\[)|(\])|(,"__type__")/g,"").replace(/(\,)/g,", ")}},{key:"levenshteinDistance",value:function(t,e){if(0===t.length)return e.length;if(0===e.length)return t.length;var i,n,s=[];for(i=0;i<=e.length;i++)s[i]=[i];for(n=0;n<=t.length;n++)s[0][n]=n;for(i=1;i<=e.length;i++)for(n=1;n<=t.length;n++)e.charAt(i-1)==t.charAt(n-1)?s[i][n]=s[i-1][n-1]:s[i][n]=Math.min(s[i-1][n-1]+1,Math.min(s[i][n-1]+1,s[i-1][n]+1));return s[e.length][t.length]}}]),t}(),Gd="string",Wd="boolean",zd="number",Ud="object",Vd={configure:{enabled:{boolean:Wd},filter:{boolean:Wd,function:"function"},container:{dom:"dom"},__type__:{object:Ud,boolean:Wd,function:"function"}},align:{string:Gd},alignCurrentTime:{string:Gd,undefined:"undefined"},rtl:{boolean:Wd,undefined:"undefined"},rollingMode:{follow:{boolean:Wd},offset:{number:zd,undefined:"undefined"},__type__:{object:Ud}},onTimeout:{timeoutMs:{number:zd},callback:{function:"function"},__type__:{object:Ud}},verticalScroll:{boolean:Wd,undefined:"undefined"},horizontalScroll:{boolean:Wd,undefined:"undefined"},autoResize:{boolean:Wd},throttleRedraw:{number:zd},clickToUse:{boolean:Wd},dataAttributes:{string:Gd,array:"array"},editable:{add:{boolean:Wd,undefined:"undefined"},remove:{boolean:Wd,undefined:"undefined"},updateGroup:{boolean:Wd,undefined:"undefined"},updateTime:{boolean:Wd,undefined:"undefined"},overrideItems:{boolean:Wd,undefined:"undefined"},__type__:{boolean:Wd,object:Ud}},end:{number:zd,date:"date",string:Gd,moment:"moment"},format:{minorLabels:{millisecond:{string:Gd,undefined:"undefined"},second:{string:Gd,undefined:"undefined"},minute:{string:Gd,undefined:"undefined"},hour:{string:Gd,undefined:"undefined"},weekday:{string:Gd,undefined:"undefined"},day:{string:Gd,undefined:"undefined"},week:{string:Gd,undefined:"undefined"},month:{string:Gd,undefined:"undefined"},year:{string:Gd,undefined:"undefined"},__type__:{object:Ud,function:"function"}},majorLabels:{millisecond:{string:Gd,undefined:"undefined"},second:{string:Gd,undefined:"undefined"},minute:{string:Gd,undefined:"undefined"},hour:{string:Gd,undefined:"undefined"},weekday:{string:Gd,undefined:"undefined"},day:{string:Gd,undefined:"undefined"},week:{string:Gd,undefined:"undefined"},month:{string:Gd,undefined:"undefined"},year:{string:Gd,undefined:"undefined"},__type__:{object:Ud,function:"function"}},__type__:{object:Ud}},moment:{function:"function"},groupHeightMode:{string:Gd},groupOrder:{string:Gd,function:"function"},groupEditable:{add:{boolean:Wd,undefined:"undefined"},remove:{boolean:Wd,undefined:"undefined"},order:{boolean:Wd,undefined:"undefined"},__type__:{boolean:Wd,object:Ud}},groupOrderSwap:{function:"function"},height:{string:Gd,number:zd},hiddenDates:{start:{date:"date",number:zd,string:Gd,moment:"moment"},end:{date:"date",number:zd,string:Gd,moment:"moment"},repeat:{string:Gd},__type__:{object:Ud,array:"array"}},itemsAlwaysDraggable:{item:{boolean:Wd,undefined:"undefined"},range:{boolean:Wd,undefined:"undefined"},__type__:{boolean:Wd,object:Ud}},limitSize:{boolean:Wd},locale:{string:Gd},locales:{__any__:{any:"any"},__type__:{object:Ud}},margin:{axis:{number:zd},item:{horizontal:{number:zd,undefined:"undefined"},vertical:{number:zd,undefined:"undefined"},__type__:{object:Ud,number:zd}},__type__:{object:Ud,number:zd}},max:{date:"date",number:zd,string:Gd,moment:"moment"},maxHeight:{number:zd,string:Gd},maxMinorChars:{number:zd},min:{date:"date",number:zd,string:Gd,moment:"moment"},minHeight:{number:zd,string:Gd},moveable:{boolean:Wd},multiselect:{boolean:Wd},multiselectPerGroup:{boolean:Wd},onAdd:{function:"function"},onDropObjectOnItem:{function:"function"},onUpdate:{function:"function"},onMove:{function:"function"},onMoving:{function:"function"},onRemove:{function:"function"},onAddGroup:{function:"function"},onMoveGroup:{function:"function"},onRemoveGroup:{function:"function"},onInitialDrawComplete:{function:"function"},order:{function:"function"},orientation:{axis:{string:Gd,undefined:"undefined"},item:{string:Gd,undefined:"undefined"},__type__:{string:Gd,object:Ud}},selectable:{boolean:Wd},sequentialSelection:{boolean:Wd},showCurrentTime:{boolean:Wd},showMajorLabels:{boolean:Wd},showMinorLabels:{boolean:Wd},stack:{boolean:Wd},stackSubgroups:{boolean:Wd},cluster:{maxItems:{number:zd,undefined:"undefined"},titleTemplate:{string:Gd,undefined:"undefined"},clusterCriteria:{function:"function",undefined:"undefined"},showStipes:{boolean:Wd,undefined:"undefined"},fitOnDoubleClick:{boolean:Wd,undefined:"undefined"},__type__:{boolean:Wd,object:Ud}},snap:{function:"function",null:"null"},start:{date:"date",number:zd,string:Gd,moment:"moment"},template:{function:"function"},loadingScreenTemplate:{function:"function"},groupTemplate:{function:"function"},visibleFrameTemplate:{string:Gd,function:"function"},showTooltips:{boolean:Wd},tooltip:{followMouse:{boolean:Wd},overflowMethod:{string:["cap","flip","none"]},delay:{number:zd},template:{function:"function"},__type__:{object:Ud}},tooltipOnItemUpdateTime:{template:{function:"function"},__type__:{boolean:Wd,object:Ud}},timeAxis:{scale:{string:Gd,undefined:"undefined"},step:{number:zd,undefined:"undefined"},__type__:{object:Ud}},type:{string:Gd},width:{string:Gd,number:zd},preferZoom:{boolean:Wd},zoomable:{boolean:Wd},zoomKey:{string:["ctrlKey","altKey","shiftKey","metaKey",""]},zoomFriction:{number:zd},zoomMax:{number:zd},zoomMin:{number:zd},__type__:{object:Ud}},Bd={global:{align:["center","left","right"],alignCurrentTime:["none","year","month","quarter","week","isoWeek","day","date","hour","minute","second"],direction:!1,autoResize:!0,clickToUse:!1,editable:{add:!1,remove:!1,updateGroup:!1,updateTime:!1},end:"",format:{minorLabels:{millisecond:"SSS",second:"s",minute:"HH:mm",hour:"HH:mm",weekday:"ddd D",day:"D",week:"w",month:"MMM",year:"YYYY"},majorLabels:{millisecond:"HH:mm:ss",second:"D MMMM HH:mm",minute:"ddd D MMMM",hour:"ddd D MMMM",weekday:"MMMM YYYY",day:"MMMM YYYY",week:"MMMM YYYY",month:"YYYY",year:""}},groupHeightMode:["auto","fixed","fitItems"],groupsDraggable:!1,height:"",locale:"",margin:{axis:[20,0,100,1],item:{horizontal:[10,0,100,1],vertical:[10,0,100,1]}},max:"",maxHeight:"",maxMinorChars:[7,0,20,1],min:"",minHeight:"",moveable:!1,multiselect:!1,multiselectPerGroup:!1,orientation:{axis:["both","bottom","top"],item:["bottom","top"]},preferZoom:!1,selectable:!0,showCurrentTime:!1,showMajorLabels:!0,showMinorLabels:!0,stack:!0,stackSubgroups:!0,cluster:!1,start:"",showTooltips:!0,tooltip:{followMouse:!1,overflowMethod:"flip",delay:[500,0,99999,100]},tooltipOnItemUpdateTime:!1,type:["box","point","range","background"],width:"100%",zoomable:!0,zoomKey:["ctrlKey","altKey","shiftKey","metaKey",""],zoomMax:[31536e10,10,31536e10,1],zoomMin:[10,10,31536e10,1]}};ji({target:"Array",proto:!0},{fill:function(t){for(var e=Fi(this),i=tn(e.length),n=arguments.length,s=sn(n>1?arguments[1]:void 0,i),r=n>2?arguments[2]:void 0,o=void 0===r?i:sn(r,i);o>s;)e[s++]=t;return e}});var Xd=Kn("Array").fill,qd=Array.prototype,Zd=function(t){var e=t.fill;return t===qd||t instanceof Array&&e===qd.fill?Xd:e},$d={black:"#000000",navy:"#000080",darkblue:"#00008B",mediumblue:"#0000CD",blue:"#0000FF",darkgreen:"#006400",green:"#008000",teal:"#008080",darkcyan:"#008B8B",deepskyblue:"#00BFFF",darkturquoise:"#00CED1",mediumspringgreen:"#00FA9A",lime:"#00FF00",springgreen:"#00FF7F",aqua:"#00FFFF",cyan:"#00FFFF",midnightblue:"#191970",dodgerblue:"#1E90FF",lightseagreen:"#20B2AA",forestgreen:"#228B22",seagreen:"#2E8B57",darkslategray:"#2F4F4F",limegreen:"#32CD32",mediumseagreen:"#3CB371",turquoise:"#40E0D0",royalblue:"#4169E1",steelblue:"#4682B4",darkslateblue:"#483D8B",mediumturquoise:"#48D1CC",indigo:"#4B0082",darkolivegreen:"#556B2F",cadetblue:"#5F9EA0",cornflowerblue:"#6495ED",mediumaquamarine:"#66CDAA",dimgray:"#696969",slateblue:"#6A5ACD",olivedrab:"#6B8E23",slategray:"#708090",lightslategray:"#778899",mediumslateblue:"#7B68EE",lawngreen:"#7CFC00",chartreuse:"#7FFF00",aquamarine:"#7FFFD4",maroon:"#800000",purple:"#800080",olive:"#808000",gray:"#808080",skyblue:"#87CEEB",lightskyblue:"#87CEFA",blueviolet:"#8A2BE2",darkred:"#8B0000",darkmagenta:"#8B008B",saddlebrown:"#8B4513",darkseagreen:"#8FBC8F",lightgreen:"#90EE90",mediumpurple:"#9370D8",darkviolet:"#9400D3",palegreen:"#98FB98",darkorchid:"#9932CC",yellowgreen:"#9ACD32",sienna:"#A0522D",brown:"#A52A2A",darkgray:"#A9A9A9",lightblue:"#ADD8E6",greenyellow:"#ADFF2F",paleturquoise:"#AFEEEE",lightsteelblue:"#B0C4DE",powderblue:"#B0E0E6",firebrick:"#B22222",darkgoldenrod:"#B8860B",mediumorchid:"#BA55D3",rosybrown:"#BC8F8F",darkkhaki:"#BDB76B",silver:"#C0C0C0",mediumvioletred:"#C71585",indianred:"#CD5C5C",peru:"#CD853F",chocolate:"#D2691E",tan:"#D2B48C",lightgrey:"#D3D3D3",palevioletred:"#D87093",thistle:"#D8BFD8",orchid:"#DA70D6",goldenrod:"#DAA520",crimson:"#DC143C",gainsboro:"#DCDCDC",plum:"#DDA0DD",burlywood:"#DEB887",lightcyan:"#E0FFFF",lavender:"#E6E6FA",darksalmon:"#E9967A",violet:"#EE82EE",palegoldenrod:"#EEE8AA",lightcoral:"#F08080",khaki:"#F0E68C",aliceblue:"#F0F8FF",honeydew:"#F0FFF0",azure:"#F0FFFF",sandybrown:"#F4A460",wheat:"#F5DEB3",beige:"#F5F5DC",whitesmoke:"#F5F5F5",mintcream:"#F5FFFA",ghostwhite:"#F8F8FF",salmon:"#FA8072",antiquewhite:"#FAEBD7",linen:"#FAF0E6",lightgoldenrodyellow:"#FAFAD2",oldlace:"#FDF5E6",red:"#FF0000",fuchsia:"#FF00FF",magenta:"#FF00FF",deeppink:"#FF1493",orangered:"#FF4500",tomato:"#FF6347",hotpink:"#FF69B4",coral:"#FF7F50",darkorange:"#FF8C00",lightsalmon:"#FFA07A",orange:"#FFA500",lightpink:"#FFB6C1",pink:"#FFC0CB",gold:"#FFD700",peachpuff:"#FFDAB9",navajowhite:"#FFDEAD",moccasin:"#FFE4B5",bisque:"#FFE4C4",mistyrose:"#FFE4E1",blanchedalmond:"#FFEBCD",papayawhip:"#FFEFD5",lavenderblush:"#FFF0F5",seashell:"#FFF5EE",cornsilk:"#FFF8DC",lemonchiffon:"#FFFACD",floralwhite:"#FFFAF0",snow:"#FFFAFA",yellow:"#FFFF00",lightyellow:"#FFFFE0",ivory:"#FFFFF0",white:"#FFFFFF"},Jd=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1;Ds(this,t),this.pixelRatio=e,this.generated=!1,this.centerCoordinates={x:144.5,y:144.5},this.r=289*.49,this.color={r:255,g:255,b:255,a:1},this.hueCircle=void 0,this.initialColor={r:255,g:255,b:255,a:1},this.previousColor=void 0,this.applied=!1,this.updateCallback=function(){},this.closeCallback=function(){},this._create()}return Ts(t,[{key:"insertTo",value:function(t){void 0!==this.hammer&&(this.hammer.destroy(),this.hammer=void 0),this.container=t,this.container.appendChild(this.frame),this._bindHammer(),this._setSize()}},{key:"setUpdateCallback",value:function(t){if("function"!=typeof t)throw new Error("Function attempted to set as colorPicker update callback is not a function.");this.updateCallback=t}},{key:"setCloseCallback",value:function(t){if("function"!=typeof t)throw new Error("Function attempted to set as colorPicker closing callback is not a function.");this.closeCallback=t}},{key:"_isColorString",value:function(t){if("string"==typeof t)return $d[t]}},{key:"setColor",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];if("none"!==t){var i,n=this._isColorString(t);if(void 0!==n&&(t=n),!0===to.isString(t)){if(!0===to.isValidRGB(t)){var s=t.substr(4).substr(0,t.length-5).split(",");i={r:s[0],g:s[1],b:s[2],a:1}}else if(!0===to.isValidRGBA(t)){var r=t.substr(5).substr(0,t.length-6).split(",");i={r:r[0],g:r[1],b:r[2],a:r[3]}}else if(!0===to.isValidHex(t)){var o=to.hexToRGB(t);i={r:o.r,g:o.g,b:o.b,a:1}}}else if(t instanceof Object&&void 0!==t.r&&void 0!==t.g&&void 0!==t.b){var a=void 0!==t.a?t.a:"1.0";i={r:t.r,g:t.g,b:t.b,a:a}}if(void 0===i)throw new Error("Unknown color passed to the colorPicker. Supported are strings: rgb, hex, rgba. Object: rgb ({r:r,g:g,b:b,[a:a]}). Supplied: "+mo(t));this._setColor(i,e)}}},{key:"show",value:function(){void 0!==this.closeCallback&&(this.closeCallback(),this.closeCallback=void 0),this.applied=!1,this.frame.style.display="block",this._generateHueCircle()}},{key:"_hide",value:function(){var t=this,e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];!0===e&&(this.previousColor=to.extend({},this.color)),!0===this.applied&&this.updateCallback(this.initialColor),this.frame.style.display="none",fs((function(){void 0!==t.closeCallback&&(t.closeCallback(),t.closeCallback=void 0)}),0)}},{key:"_save",value:function(){this.updateCallback(this.color),this.applied=!1,this._hide()}},{key:"_apply",value:function(){this.applied=!0,this.updateCallback(this.color),this._updatePicker(this.color)}},{key:"_loadLast",value:function(){void 0!==this.previousColor?this.setColor(this.previousColor,!1):alert("There is no last color to load...")}},{key:"_setColor",value:function(t){var e=!(arguments.length>1&&void 0!==arguments[1])||arguments[1];!0===e&&(this.initialColor=to.extend({},t)),this.color=t;var i=to.RGBToHSV(t.r,t.g,t.b),n=2*Math.PI,s=this.r*i.s,r=this.centerCoordinates.x+s*Math.sin(n*i.h),o=this.centerCoordinates.y+s*Math.cos(n*i.h);this.colorPickerSelector.style.left=r-.5*this.colorPickerSelector.clientWidth+"px",this.colorPickerSelector.style.top=o-.5*this.colorPickerSelector.clientHeight+"px",this._updatePicker(t)}},{key:"_setOpacity",value:function(t){this.color.a=t/100,this._updatePicker(this.color)}},{key:"_setBrightness",value:function(t){var e=to.RGBToHSV(this.color.r,this.color.g,this.color.b);e.v=t/100;var i=to.HSVToRGB(e.h,e.s,e.v);i.a=this.color.a,this.color=i,this._updatePicker()}},{key:"_updatePicker",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.color,e=to.RGBToHSV(t.r,t.g,t.b),i=this.colorPickerCanvas.getContext("2d");void 0===this.pixelRation&&(this.pixelRatio=(window.devicePixelRatio||1)/(i.webkitBackingStorePixelRatio||i.mozBackingStorePixelRatio||i.msBackingStorePixelRatio||i.oBackingStorePixelRatio||i.backingStorePixelRatio||1)),i.setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0);var n=this.colorPickerCanvas.clientWidth,s=this.colorPickerCanvas.clientHeight;i.clearRect(0,0,n,s),i.putImageData(this.hueCircle,0,0),i.fillStyle="rgba(0,0,0,"+(1-e.v)+")",i.circle(this.centerCoordinates.x,this.centerCoordinates.y,this.r),Zd(i).call(i),this.brightnessRange.value=100*e.v,this.opacityRange.value=100*t.a,this.initialColorDiv.style.backgroundColor="rgba("+this.initialColor.r+","+this.initialColor.g+","+this.initialColor.b+","+this.initialColor.a+")",this.newColorDiv.style.backgroundColor="rgba("+this.color.r+","+this.color.g+","+this.color.b+","+this.color.a+")"}},{key:"_setSize",value:function(){this.colorPickerCanvas.style.width="100%",this.colorPickerCanvas.style.height="100%",this.colorPickerCanvas.width=289*this.pixelRatio,this.colorPickerCanvas.height=289*this.pixelRatio}},{key:"_create",value:function(){var t,e,i,n;if(this.frame=document.createElement("div"),this.frame.className="vis-color-picker",this.colorPickerDiv=document.createElement("div"),this.colorPickerSelector=document.createElement("div"),this.colorPickerSelector.className="vis-selector",this.colorPickerDiv.appendChild(this.colorPickerSelector),this.colorPickerCanvas=document.createElement("canvas"),this.colorPickerDiv.appendChild(this.colorPickerCanvas),this.colorPickerCanvas.getContext){var s=this.colorPickerCanvas.getContext("2d");this.pixelRatio=(window.devicePixelRatio||1)/(s.webkitBackingStorePixelRatio||s.mozBackingStorePixelRatio||s.msBackingStorePixelRatio||s.oBackingStorePixelRatio||s.backingStorePixelRatio||1),this.colorPickerCanvas.getContext("2d").setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0)}else{var r=document.createElement("DIV");r.style.color="red",r.style.fontWeight="bold",r.style.padding="10px",r.innerHTML="Error: your browser does not support HTML canvas",this.colorPickerCanvas.appendChild(r)}this.colorPickerDiv.className="vis-color",this.opacityDiv=document.createElement("div"),this.opacityDiv.className="vis-opacity",this.brightnessDiv=document.createElement("div"),this.brightnessDiv.className="vis-brightness",this.arrowDiv=document.createElement("div"),this.arrowDiv.className="vis-arrow",this.opacityRange=document.createElement("input");try{this.opacityRange.type="range",this.opacityRange.min="0",this.opacityRange.max="100"}catch(t){}this.opacityRange.value="100",this.opacityRange.className="vis-range",this.brightnessRange=document.createElement("input");try{this.brightnessRange.type="range",this.brightnessRange.min="0",this.brightnessRange.max="100"}catch(t){}this.brightnessRange.value="100",this.brightnessRange.className="vis-range",this.opacityDiv.appendChild(this.opacityRange),this.brightnessDiv.appendChild(this.brightnessRange);var o=this;this.opacityRange.onchange=function(){o._setOpacity(this.value)},this.opacityRange.oninput=function(){o._setOpacity(this.value)},this.brightnessRange.onchange=function(){o._setBrightness(this.value)},this.brightnessRange.oninput=function(){o._setBrightness(this.value)},this.brightnessLabel=document.createElement("div"),this.brightnessLabel.className="vis-label vis-brightness",this.brightnessLabel.innerHTML="brightness:",this.opacityLabel=document.createElement("div"),this.opacityLabel.className="vis-label vis-opacity",this.opacityLabel.innerHTML="opacity:",this.newColorDiv=document.createElement("div"),this.newColorDiv.className="vis-new-color",this.newColorDiv.innerHTML="new",this.initialColorDiv=document.createElement("div"),this.initialColorDiv.className="vis-initial-color",this.initialColorDiv.innerHTML="initial",this.cancelButton=document.createElement("div"),this.cancelButton.className="vis-button vis-cancel",this.cancelButton.innerHTML="cancel",this.cancelButton.onclick=bs(t=this._hide).call(t,this,!1),this.applyButton=document.createElement("div"),this.applyButton.className="vis-button vis-apply",this.applyButton.innerHTML="apply",this.applyButton.onclick=bs(e=this._apply).call(e,this),this.saveButton=document.createElement("div"),this.saveButton.className="vis-button vis-save",this.saveButton.innerHTML="save",this.saveButton.onclick=bs(i=this._save).call(i,this),this.loadButton=document.createElement("div"),this.loadButton.className="vis-button vis-load",this.loadButton.innerHTML="load last",this.loadButton.onclick=bs(n=this._loadLast).call(n,this),this.frame.appendChild(this.colorPickerDiv),this.frame.appendChild(this.arrowDiv),this.frame.appendChild(this.brightnessLabel),this.frame.appendChild(this.brightnessDiv),this.frame.appendChild(this.opacityLabel),this.frame.appendChild(this.opacityDiv),this.frame.appendChild(this.newColorDiv),this.frame.appendChild(this.initialColorDiv),this.frame.appendChild(this.cancelButton),this.frame.appendChild(this.applyButton),this.frame.appendChild(this.saveButton),this.frame.appendChild(this.loadButton)}},{key:"_bindHammer",value:function(){var t=this;this.drag={},this.pinch={},this.hammer=new _h(this.colorPickerCanvas),this.hammer.get("pinch").set({enable:!0}),bh(this.hammer,(function(e){t._moveSelector(e)})),this.hammer.on("tap",(function(e){t._moveSelector(e)})),this.hammer.on("panstart",(function(e){t._moveSelector(e)})),this.hammer.on("panmove",(function(e){t._moveSelector(e)})),this.hammer.on("panend",(function(e){t._moveSelector(e)}))}},{key:"_generateHueCircle",value:function(){if(!1===this.generated){var t=this.colorPickerCanvas.getContext("2d");void 0===this.pixelRation&&(this.pixelRatio=(window.devicePixelRatio||1)/(t.webkitBackingStorePixelRatio||t.mozBackingStorePixelRatio||t.msBackingStorePixelRatio||t.oBackingStorePixelRatio||t.backingStorePixelRatio||1)),t.setTransform(this.pixelRatio,0,0,this.pixelRatio,0,0);var e,i,n,s,r=this.colorPickerCanvas.clientWidth,o=this.colorPickerCanvas.clientHeight;t.clearRect(0,0,r,o),this.centerCoordinates={x:.5*r,y:.5*o},this.r=.49*r;var a,l=2*Math.PI/360,h=1/this.r;for(n=0;n<360;n++)for(s=0;s<this.r;s++)e=this.centerCoordinates.x+s*Math.sin(l*n),i=this.centerCoordinates.y+s*Math.cos(l*n),a=to.HSVToRGB(n*(1/360),s*h,1),t.fillStyle="rgb("+a.r+","+a.g+","+a.b+")",t.fillRect(e-.5,i-.5,2,2);t.strokeStyle="rgba(0,0,0,1)",t.circle(this.centerCoordinates.x,this.centerCoordinates.y,this.r),t.stroke(),this.hueCircle=t.getImageData(0,0,r,o)}this.generated=!0}},{key:"_moveSelector",value:function(t){var e=this.colorPickerDiv.getBoundingClientRect(),i=t.center.x-e.left,n=t.center.y-e.top,s=.5*this.colorPickerDiv.clientHeight,r=.5*this.colorPickerDiv.clientWidth,o=i-r,a=n-s,l=Math.atan2(o,a),h=.98*Math.min(Math.sqrt(o*o+a*a),r),u=Math.cos(l)*h+s,d=Math.sin(l)*h+r;this.colorPickerSelector.style.top=u-.5*this.colorPickerSelector.clientHeight+"px",this.colorPickerSelector.style.left=d-.5*this.colorPickerSelector.clientWidth+"px";var c=l/(2*Math.PI);c=c<0?c+1:c;var f=h/this.r,m=to.RGBToHSV(this.color.r,this.color.g,this.color.b);m.h=c,m.s=f;var p=to.HSVToRGB(m.h,m.s,m.v);p.a=this.color.a,this.color=p,this.initialColorDiv.style.backgroundColor="rgba("+this.initialColor.r+","+this.initialColor.g+","+this.initialColor.b+","+this.initialColor.a+")",this.newColorDiv.style.backgroundColor="rgba("+this.color.r+","+this.color.g+","+this.color.b+","+this.color.a+")"}}]),t}(),Kd=function(){function t(e,i,n){var s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1;Ds(this,t),this.parent=e,this.changedOptions=[],this.container=i,this.allowCreation=!1,this.options={},this.initialized=!1,this.popupCounter=0,this.defaultOptions={enabled:!1,filter:!0,container:void 0,showButton:!0},to.extend(this.options,this.defaultOptions),this.configureOptions=n,this.moduleOptions={},this.domElements=[],this.popupDiv={},this.popupLimit=5,this.popupHistory={},this.colorPicker=new Jd(s),this.wrapper=void 0}return Ts(t,[{key:"setOptions",value:function(t){if(void 0!==t){this.popupHistory={},this._removePopup();var e=!0;if("string"==typeof t)this.options.filter=t;else if(t instanceof Array)this.options.filter=t.join();else if("object"===Tr(t)){if(null==t)throw new TypeError("options cannot be null");void 0!==t.container&&(this.options.container=t.container),void 0!==ls(t)&&(this.options.filter=ls(t)),void 0!==t.showButton&&(this.options.showButton=t.showButton),void 0!==t.enabled&&(e=t.enabled)}else"boolean"==typeof t?(this.options.filter=!0,e=t):"function"==typeof t&&(this.options.filter=t,e=!0);!1===ls(this.options)&&(e=!1),this.options.enabled=e}this._clean()}},{key:"setModuleOptions",value:function(t){this.moduleOptions=t,!0===this.options.enabled&&(this._clean(),void 0!==this.options.container&&(this.container=this.options.container),this._create())}},{key:"_create",value:function(){this._clean(),this.changedOptions=[];var t=ls(this.options),e=0,i=!1;for(var n in this.configureOptions)this.configureOptions.hasOwnProperty(n)&&(this.allowCreation=!1,i=!1,"function"==typeof t?i=(i=t(n,[]))||this._handleObject(this.configureOptions[n],[n],!0):!0!==t&&-1===la(t).call(t,n)||(i=!0),!1!==i&&(this.allowCreation=!0,e>0&&this._makeItem([]),this._makeHeader(n),this._handleObject(this.configureOptions[n],[n])),e++);this._makeButton(),this._push()}},{key:"_push",value:function(){this.wrapper=document.createElement("div"),this.wrapper.className="vis-configuration-wrapper",this.container.appendChild(this.wrapper);for(var t=0;t<this.domElements.length;t++)this.wrapper.appendChild(this.domElements[t]);this._showPopupIfNeeded()}},{key:"_clean",value:function(){for(var t=0;t<this.domElements.length;t++)this.wrapper.removeChild(this.domElements[t]);void 0!==this.wrapper&&(this.container.removeChild(this.wrapper),this.wrapper=void 0),this.domElements=[],this._removePopup()}},{key:"_getValue",value:function(t){for(var e=this.moduleOptions,i=0;i<t.length;i++){if(void 0===e[t[i]]){e=void 0;break}e=e[t[i]]}return e}},{key:"_makeItem",value:function(t){if(!0===this.allowCreation){var e=document.createElement("div");e.className="vis-configuration vis-config-item vis-config-s"+t.length;for(var i=arguments.length,n=new Array(i>1?i-1:0),s=1;s<i;s++)n[s-1]=arguments[s];return is(n).call(n,(function(t){e.appendChild(t)})),this.domElements.push(e),this.domElements.length}return 0}},{key:"_makeHeader",value:function(t){var e=document.createElement("div");e.className="vis-configuration vis-config-header",e.innerHTML=t,this._makeItem([],e)}},{key:"_makeLabel",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=document.createElement("div");return n.className="vis-configuration vis-config-label vis-config-s"+e.length,n.innerHTML=!0===i?"<i><b>"+t+":</b></i>":t+":",n}},{key:"_makeDropdown",value:function(t,e,i){var n=document.createElement("select");n.className="vis-configuration vis-config-select";var s=0;void 0!==e&&-1!==la(t).call(t,e)&&(s=la(t).call(t,e));for(var r=0;r<t.length;r++){var o=document.createElement("option");o.value=t[r],r===s&&(o.selected="selected"),o.innerHTML=t[r],n.appendChild(o)}var a=this;n.onchange=function(){a._update(this.value,i)};var l=this._makeLabel(i[i.length-1],i);this._makeItem(i,l,n)}},{key:"_makeRange",value:function(t,e,i){var n=t[0],s=t[1],r=t[2],o=t[3],a=document.createElement("input");a.className="vis-configuration vis-config-range";try{a.type="range",a.min=s,a.max=r}catch(t){}a.step=o;var l="",h=0;if(void 0!==e){e<0&&1.2*e<s?(a.min=Math.ceil(1.2*e),h=a.min,l="range increased"):e/1.2<s&&(a.min=Math.ceil(e/1.2),h=a.min,l="range increased"),1.2*e>r&&1!==r&&(a.max=Math.ceil(1.2*e),h=a.max,l="range increased"),a.value=e}else a.value=n;var u=document.createElement("input");u.className="vis-configuration vis-config-rangeinput",u.value=Number(a.value);var d=this;a.onchange=function(){u.value=this.value,d._update(Number(this.value),i)},a.oninput=function(){u.value=this.value};var c=this._makeLabel(i[i.length-1],i),f=this._makeItem(i,c,a,u);""!==l&&this.popupHistory[f]!==h&&(this.popupHistory[f]=h,this._setupPopup(l,f))}},{key:"_makeButton",value:function(){var t=this;if(!0===this.options.showButton){var e=document.createElement("div");e.className="vis-configuration vis-config-button",e.innerHTML="generate options",e.onclick=function(){t._printOptions()},e.onmouseover=function(){e.className="vis-configuration vis-config-button hover"},e.onmouseout=function(){e.className="vis-configuration vis-config-button"},this.optionsContainer=document.createElement("div"),this.optionsContainer.className="vis-configuration vis-config-option-container",this.domElements.push(this.optionsContainer),this.domElements.push(e)}}},{key:"_setupPopup",value:function(t,e){var i=this;if(!0===this.initialized&&!0===this.allowCreation&&this.popupCounter<this.popupLimit){var n=document.createElement("div");n.id="vis-configuration-popup",n.className="vis-configuration-popup",n.innerHTML=t,n.onclick=function(){i._removePopup()},this.popupCounter+=1,this.popupDiv={html:n,index:e}}}},{key:"_removePopup",value:function(){void 0!==this.popupDiv.html&&(this.popupDiv.html.parentNode.removeChild(this.popupDiv.html),clearTimeout(this.popupDiv.hideTimeout),clearTimeout(this.popupDiv.deleteTimeout),this.popupDiv={})}},{key:"_showPopupIfNeeded",value:function(){var t=this;if(void 0!==this.popupDiv.html){var e=this.domElements[this.popupDiv.index].getBoundingClientRect();this.popupDiv.html.style.left=e.left+"px",this.popupDiv.html.style.top=e.top-30+"px",document.body.appendChild(this.popupDiv.html),this.popupDiv.hideTimeout=fs((function(){t.popupDiv.html.style.opacity=0}),1500),this.popupDiv.deleteTimeout=fs((function(){t._removePopup()}),1800)}}},{key:"_makeCheckbox",value:function(t,e,i){var n=document.createElement("input");n.type="checkbox",n.className="vis-configuration vis-config-checkbox",n.checked=t,void 0!==e&&(n.checked=e,e!==t&&("object"===Tr(t)?e!==t.enabled&&this.changedOptions.push({path:i,value:e}):this.changedOptions.push({path:i,value:e})));var s=this;n.onchange=function(){s._update(this.checked,i)};var r=this._makeLabel(i[i.length-1],i);this._makeItem(i,r,n)}},{key:"_makeTextInput",value:function(t,e,i){var n=document.createElement("input");n.type="text",n.className="vis-configuration vis-config-text",n.value=e,e!==t&&this.changedOptions.push({path:i,value:e});var s=this;n.onchange=function(){s._update(this.value,i)};var r=this._makeLabel(i[i.length-1],i);this._makeItem(i,r,n)}},{key:"_makeColorField",value:function(t,e,i){var n=this,s=t[1],r=document.createElement("div");"none"!==(e=void 0===e?s:e)?(r.className="vis-configuration vis-config-colorBlock",r.style.backgroundColor=e):r.className="vis-configuration vis-config-colorBlock none",e=void 0===e?s:e,r.onclick=function(){n._showColorPicker(e,r,i)};var o=this._makeLabel(i[i.length-1],i);this._makeItem(i,o,r)}},{key:"_showColorPicker",value:function(t,e,i){var n=this;e.onclick=function(){},this.colorPicker.insertTo(e),this.colorPicker.show(),this.colorPicker.setColor(t),this.colorPicker.setUpdateCallback((function(t){var s="rgba("+t.r+","+t.g+","+t.b+","+t.a+")";e.style.backgroundColor=s,n._update(s,i)})),this.colorPicker.setCloseCallback((function(){e.onclick=function(){n._showColorPicker(t,e,i)}}))}},{key:"_handleObject",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],n=!1,s=ls(this.options),r=!1;for(var o in t)if(t.hasOwnProperty(o)){n=!0;var a=t[o],l=to.copyAndExtendArray(e,o);if("function"==typeof s&&!1===(n=s(o,e))&&!(a instanceof Array)&&"string"!=typeof a&&"boolean"!=typeof a&&a instanceof Object&&(this.allowCreation=!1,n=this._handleObject(a,l,!0),this.allowCreation=!1===i),!1!==n){r=!0;var h=this._getValue(l);if(a instanceof Array)this._handleArray(a,h,l);else if("string"==typeof a)this._makeTextInput(a,h,l);else if("boolean"==typeof a)this._makeCheckbox(a,h,l);else if(a instanceof Object){var u=!0;if(-1!==la(e).call(e,"physics")&&this.moduleOptions.physics.solver!==o&&(u=!1),!0===u)if(void 0!==a.enabled){var d=to.copyAndExtendArray(l,"enabled"),c=this._getValue(d);if(!0===c){var f=this._makeLabel(o,l,!0);this._makeItem(l,f),r=this._handleObject(a,l)||r}else this._makeCheckbox(a,c,l)}else{var m=this._makeLabel(o,l,!0);this._makeItem(l,m),r=this._handleObject(a,l)||r}}else console.error("dont know how to handle",a,o,l)}}return r}},{key:"_handleArray",value:function(t,e,i){"string"==typeof t[0]&&"color"===t[0]?(this._makeColorField(t,e,i),t[1]!==e&&this.changedOptions.push({path:i,value:e})):"string"==typeof t[0]?(this._makeDropdown(t,e,i),t[0]!==e&&this.changedOptions.push({path:i,value:e})):"number"==typeof t[0]&&(this._makeRange(t,e,i),t[0]!==e&&this.changedOptions.push({path:i,value:Number(e)}))}},{key:"_update",value:function(t,e){var i=this._constructOptions(t,e);this.parent.body&&this.parent.body.emitter&&this.parent.body.emitter.emit&&this.parent.body.emitter.emit("configChange",i),this.initialized=!0,this.parent.setOptions(i)}},{key:"_constructOptions",value:function(t,e){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=i;t="false"!==(t="true"===t||t)&&t;for(var s=0;s<e.length;s++)"global"!==e[s]&&(void 0===n[e[s]]&&(n[e[s]]={}),s!==e.length-1?n=n[e[s]]:n[e[s]]=t);return i}},{key:"_printOptions",value:function(){var t=this.getOptions();this.optionsContainer.innerHTML="<pre>var options = "+mo(t,null,2)+"</pre>"}},{key:"getOptions",value:function(){for(var t={},e=0;e<this.changedOptions.length;e++)this._constructOptions(this.changedOptions[e].value,this.changedOptions[e].path,t);return t}}]),t}(),Qd=function(t){function e(t,i,n,s){var r,o,a,l,h,u,d,c;if(Ds(this,e),(c=Cr(this,Lr(e).call(this))).initTime=new Date,c.itemsDone=!1,!(Or(c)instanceof e))throw new SyntaxError("Constructor must be called with the new operator");if(!(ks(n)||n instanceof we||n instanceof ke)&&n instanceof Object){var f=s;s=n,n=f}s&&s.throttleRedraw&&console.warn('Timeline option "throttleRedraw" is DEPRICATED and no longer supported. It will be removed in the next MAJOR release.');var m=Or(c);if(c.defaultOptions={autoResize:!0,orientation:{axis:"bottom",item:"bottom"},moment:Hr},c.options=to.deepExtend({},c.defaultOptions),c._create(t),!s||s&&void 0===s.rtl){var p;c.dom.root.style.visibility="hidden";for(var g=c.dom.root;!p&&g;)p=window.getComputedStyle(g,null).direction,g=g.parentElement;c.options.rtl=p&&"rtl"==p.toLowerCase()}else c.options.rtl=s.rtl;s&&(s.rollingMode&&(c.options.rollingMode=s.rollingMode),s.onInitialDrawComplete&&(c.options.onInitialDrawComplete=s.onInitialDrawComplete),s.onTimeout&&(c.options.onTimeout=s.onTimeout),s.loadingScreenTemplate&&(c.options.loadingScreenTemplate=s.loadingScreenTemplate));var v=document.createElement("div");if(c.options.loadingScreenTemplate){var y,_=bs(y=c.options.loadingScreenTemplate).call(y,Or(c)),b=_(c.dom.loadingScreen);b instanceof Object&&!(b instanceof Element)?_(v):b instanceof Element?(v.innerHTML="",v.appendChild(b)):null!=b&&(v.innerHTML=b)}return c.dom.loadingScreen.appendChild(v),c.components=[],c.body={dom:c.dom,domProps:c.props,emitter:{on:bs(r=c.on).call(r,Or(c)),off:bs(o=c.off).call(o,Or(c)),emit:bs(a=c.emit).call(a,Or(c))},hiddenDates:[],util:{getScale:function(){return m.timeAxis.step.scale},getStep:function(){return m.timeAxis.step.step},toScreen:bs(l=m._toScreen).call(l,m),toGlobalScreen:bs(h=m._toGlobalScreen).call(h,m),toTime:bs(u=m._toTime).call(u,m),toGlobalTime:bs(d=m._toGlobalTime).call(d,m)}},c.range=new Uo(c.body,c.options),c.components.push(c.range),c.body.range=c.range,c.timeAxis=new Th(c.body,c.options),c.timeAxis2=null,c.components.push(c.timeAxis),c.currentTime=new zh(c.body,c.options),c.components.push(c.currentTime),c.itemSet=new Nd(c.body,c.options),c.components.push(c.itemSet),c.itemsData=null,c.groupsData=null,c.dom.root.onclick=function(t){m.emit("click",m.getEventProperties(t))},c.dom.root.ondblclick=function(t){m.emit("doubleClick",m.getEventProperties(t))},c.dom.root.oncontextmenu=function(t){m.emit("contextmenu",m.getEventProperties(t))},c.dom.root.onmouseover=function(t){m.emit("mouseOver",m.getEventProperties(t))},window.PointerEvent?(c.dom.root.onpointerdown=function(t){m.emit("mouseDown",m.getEventProperties(t))},c.dom.root.onpointermove=function(t){m.emit("mouseMove",m.getEventProperties(t))},c.dom.root.onpointerup=function(t){m.emit("mouseUp",m.getEventProperties(t))}):(c.dom.root.onmousemove=function(t){m.emit("mouseMove",m.getEventProperties(t))},c.dom.root.onmousedown=function(t){m.emit("mouseDown",m.getEventProperties(t))},c.dom.root.onmouseup=function(t){m.emit("mouseUp",m.getEventProperties(t))}),c.initialFitDone=!1,c.on("changed",(function(){if(null!=m.itemsData){if(!m.initialFitDone&&!m.options.rollingMode)if(m.initialFitDone=!0,null!=m.options.start||null!=m.options.end){if(null==m.options.start||null==m.options.end)var t=m.getItemRange();var e=null!=m.options.start?m.options.start:t.min,i=null!=m.options.end?m.options.end:t.max;m.setWindow(e,i,{animation:!1})}else m.fit({animation:!1});m.initialDrawDone||!m.initialRangeChangeDone&&(m.options.start||m.options.end)&&!m.options.rollingMode||(m.initialDrawDone=!0,m.itemSet.initialDrawDone=!0,m.dom.root.style.visibility="visible",m.dom.loadingScreen.parentNode.removeChild(m.dom.loadingScreen),m.options.onInitialDrawComplete&&fs((function(){return m.options.onInitialDrawComplete()}),0))}})),c.on("destroyTimeline",(function(){m.destroy()})),s&&c.setOptions(s),c.body.emitter.on("fit",(function(t){c._onFit(t),c.redraw()})),n&&c.setGroups(n),i&&c.setItems(i),c._redraw(),c}return jr(e,t),Ts(e,[{key:"_createConfigurator",value:function(){return new Kd(this,this.dom.container,Bd)}},{key:"redraw",value:function(){this.itemSet&&this.itemSet.markDirty({refreshItems:!0}),this._redraw()}},{key:"setOptions",value:function(t){if(!0===Hd.validate(t,Vd)&&console.log("%cErrors have been found in the supplied options object.",Fd),Wh.prototype.setOptions.call(this,t),"type"in t&&t.type!==this.options.type){this.options.type=t.type;var e=this.itemsData;if(e){var i=this.getSelection();this.setItems(null),this.setItems(e),this.setSelection(i)}}}},{key:"setItems",value:function(t){var e;this.itemsDone=!1,e=t?t instanceof we||t instanceof ke?t:new we(t,{type:{start:"Date",end:"Date"}}):null,this.itemsData=e,this.itemSet&&this.itemSet.setItems(e)}},{key:"setGroups",value:function(t){var e;if(t){var i=function(t){return!1!==t.visible};e=t instanceof we||t instanceof ke?new ke(t,{filter:i}):new we(ls(t).call(t,i))}else e=null;this.groupsData=e,this.itemSet.setGroups(e)}},{key:"setData",value:function(t){t&&t.groups&&this.setGroups(t.groups),t&&t.items&&this.setItems(t.items)}},{key:"setSelection",value:function(t,e){this.itemSet&&this.itemSet.setSelection(t),e&&e.focus&&this.focus(t,e)}},{key:"getSelection",value:function(){return this.itemSet&&this.itemSet.getSelection()||[]}},{key:"focus",value:function(t,e){if(this.itemsData&&null!=t){var i=ks(t)?t:[t],n=this.itemsData.getDataSet().get(i,{type:{start:"Date",end:"Date"}}),s=null,r=null;if(is(n).call(n,(function(t){var e=t.start.valueOf(),i="end"in t?t.end.valueOf():t.start.valueOf();(null===s||e<s)&&(s=e),(null===r||i>r)&&(r=i)})),null!==s&&null!==r){var o=this,a=this.itemSet.items[i[0]],l=-1*this._getScrollTop(),h=null,u=function(){var t=ic(o,a);t.shouldScroll&&t.itemTop!=h.itemTop&&(o._setScrollTop(-t.scrollOffset),o._redraw())},d=!e||void 0===e.zoom||e.zoom,c=(s+r)/2,f=d?1.1*(r-s):Math.max(this.range.end-this.range.start,1.1*(r-s)),m=!e||void 0===e.animation||e.animation;m||(h={shouldScroll:!1,scrollOffset:-1,itemTop:-1}),this.range.setRange(c-f/2,c+f/2,{animation:m},(function(){u(),fs(u,100)}),(function(t,e,i){var n=ic(o,a);if(!1!==n&&(h||(h=n),h.itemTop!=n.itemTop||h.shouldScroll)){h.itemTop!=n.itemTop&&n.shouldScroll&&(h=n,l=-1*o._getScrollTop());var s=l,r=h.scrollOffset,u=i?r:s+(r-s)*t;o._setScrollTop(-u),e||o._redraw()}}))}}}},{key:"fit",value:function(t,e){var i,n=!t||void 0===t.animation||t.animation,s=this.itemsData&&this.itemsData.getDataSet();1===s.length&&void 0===s.get()[0].end?(i=this.getDataRange(),this.moveTo(i.min.valueOf(),{animation:n},e)):(i=this.getItemRange(),this.range.setRange(i.min,i.max,{animation:n},e))}},{key:"getItemRange",value:function(){var t=this,e=this.getDataRange(),i=null!==e.min?e.min.valueOf():null,n=null!==e.max?e.max.valueOf():null,s=null,r=null;if(null!=i&&null!=n){var o=n-i;o<=0&&(o=10);var a=o/this.props.center.width,l={},h=0;if(is(to).call(to,this.itemSet.items,(function(t,e){if(t.groupShowing){l[e]=t.redraw(!0),h=l[e].length}})),h>0)for(var u=function(t){is(to).call(to,l,(function(e){e[t]()}))},d=0;d<h;d++)u(d);if(is(to).call(to,this.itemSet.items,(function(e){var o,l,h=tc(e),u=ec(e);t.options.rtl?(o=h-(e.getWidthRight()+10)*a,l=u+(e.getWidthLeft()+10)*a):(o=h-(e.getWidthLeft()+10)*a,l=u+(e.getWidthRight()+10)*a),o<i&&(i=o,s=e),l>n&&(n=l,r=e)})),s&&r){var c=s.getWidthLeft()+10,f=r.getWidthRight()+10,m=this.props.center.width-c-f;m>0&&(this.options.rtl?(i=tc(s)-f*o/m,n=ec(r)+c*o/m):(i=tc(s)-c*o/m,n=ec(r)+f*o/m))}}return{min:null!=i?new Date(i):null,max:null!=n?new Date(n):null}}},{key:"getDataRange",value:function(){var t=null,e=null,i=this.itemsData&&this.itemsData.getDataSet();return i&&is(i).call(i,(function(i){var n=to.convert(i.start,"Date").valueOf(),s=to.convert(null!=i.end?i.end:i.start,"Date").valueOf();(null===t||n<t)&&(t=n),(null===e||s>e)&&(e=s)})),{min:null!=t?new Date(t):null,max:null!=e?new Date(e):null}}},{key:"getEventProperties",value:function(t){var e=t.center?t.center.x:t.clientX,i=t.center?t.center.y:t.clientY,n=this.dom.centerContainer.getBoundingClientRect(),s=this.options.rtl?n.right-e:e-n.left,r=i-n.top,o=this.itemSet.itemFromTarget(t),a=this.itemSet.groupFromTarget(t),l=Gh.customTimeFromTarget(t),h=this.itemSet.options.snap||null,u=this.body.util.getScale(),d=this.body.util.getStep(),c=this._toTime(s),f=h?h(c,u,d):c,m=to.getTarget(t),p=null;return null!=o?p="item":null!=l?p="custom-time":to.hasParent(m,this.timeAxis.dom.foreground)?p="axis":this.timeAxis2&&to.hasParent(m,this.timeAxis2.dom.foreground)?p="axis":to.hasParent(m,this.itemSet.dom.labelSet)?p="group-label":to.hasParent(m,this.currentTime.bar)?p="current-time":to.hasParent(m,this.dom.center)&&(p="background"),{event:t,item:o?o.id:null,isCluster:!!o&&!!o.isCluster,items:o?o.items||[]:null,group:a?a.groupId:null,customTime:l?l.options.id:null,what:p,pageX:t.srcEvent?t.srcEvent.pageX:t.pageX,pageY:t.srcEvent?t.srcEvent.pageY:t.pageY,x:s,y:r,time:c,snappedTime:f}}},{key:"toggleRollingMode",value:function(){this.range.rolling?this.range.stopRolling():(null==this.options.rollingMode&&this.setOptions(this.options),this.range.startRolling())}},{key:"_redraw",value:function(){Wh.prototype._redraw.call(this)}},{key:"_onFit",value:function(t){var e=t.start,i=t.end,n=t.animation;i?this.range.setRange(e,i,{animation:n}):this.moveTo(e.valueOf(),{animation:n})}}]),e}(Wh);function tc(t){return to.convert(t.data.start,"Date").valueOf()}function ec(t){var e=null!=t.data.end?t.data.end:t.data.start;return to.convert(e,"Date").valueOf()}function ic(t,e){if(!e.parent)return!1;var i=t.options.rtl?t.props.rightContainer.height:t.props.leftContainer.height,n=t.props.center.height,s=e.parent,r=s.top,o=!0,a=t.timeAxis.options.orientation.axis,l=function(){return"bottom"==a?s.height-e.top-e.height:e.top},h=-1*t._getScrollTop(),u=r+l(),d=e.height;return u<h?r+i<=r+l()+d&&(r+=l()-t.itemSet.options.margin.item.vertical):u+d>h+i?r+=l()+d-i+t.itemSet.options.margin.item.vertical:o=!1,{shouldScroll:o,scrollOffset:r=Math.min(r,n-i),itemTop:u}}var nc=function(){function t(e,i,n,s,r,o){var a=arguments.length>6&&void 0!==arguments[6]&&arguments[6],l=arguments.length>7&&void 0!==arguments[7]&&arguments[7];if(Ds(this,t),this.majorSteps=[1,2,5,10],this.minorSteps=[.25,.5,1,2],this.customLines=null,this.containerHeight=r,this.majorCharHeight=o,this._start=e,this._end=i,this.scale=1,this.minorStepIdx=-1,this.magnitudefactor=1,this.determineScale(),this.zeroAlign=a,this.autoScaleStart=n,this.autoScaleEnd=s,this.formattingFunction=l,n||s){var h=this,u=function(t){var e=t-t%(h.magnitudefactor*h.minorSteps[h.minorStepIdx]);return t%(h.magnitudefactor*h.minorSteps[h.minorStepIdx])>h.magnitudefactor*h.minorSteps[h.minorStepIdx]*.5?e+h.magnitudefactor*h.minorSteps[h.minorStepIdx]:e};n&&(this._start-=2*this.magnitudefactor*this.minorSteps[this.minorStepIdx],this._start=u(this._start)),s&&(this._end+=this.magnitudefactor*this.minorSteps[this.minorStepIdx],this._end=u(this._end)),this.determineScale()}}return Ts(t,[{key:"setCharHeight",value:function(t){this.majorCharHeight=t}},{key:"setHeight",value:function(t){this.containerHeight=t}},{key:"determineScale",value:function(){var t=this._end-this._start;this.scale=this.containerHeight/t;var e=this.majorCharHeight/this.scale,i=t>0?Math.round(Math.log(t)/Math.LN10):0;this.minorStepIdx=-1,this.magnitudefactor=Math.pow(10,i);var n=0;i<0&&(n=i);for(var s=!1,r=n;Math.abs(r)<=Math.abs(i);r++){this.magnitudefactor=Math.pow(10,r);for(var o=0;o<this.minorSteps.length;o++){if(this.magnitudefactor*this.minorSteps[o]>=e){s=!0,this.minorStepIdx=o;break}}if(!0===s)break}}},{key:"is_major",value:function(t){return t%(this.magnitudefactor*this.majorSteps[this.minorStepIdx])==0}},{key:"getStep",value:function(){return this.magnitudefactor*this.minorSteps[this.minorStepIdx]}},{key:"getFirstMajor",value:function(){var t=this.magnitudefactor*this.majorSteps[this.minorStepIdx];return this.convertValue(this._start+(t-this._start%t)%t)}},{key:"formatValue",value:function(t){var e=t.toPrecision(5);return"function"==typeof this.formattingFunction&&(e=this.formattingFunction(t)),"number"==typeof e?"".concat(e):"string"==typeof e?e:t.toPrecision(5)}},{key:"getLines",value:function(){for(var t=[],e=this.getStep(),i=(e-this._start%e)%e,n=this._start+i;this._end-n>1e-5;n+=e)n!=this._start&&t.push({major:this.is_major(n),y:this.convertValue(n),val:this.formatValue(n)});return t}},{key:"followScale",value:function(t){var e=this.minorStepIdx,i=this._start,n=this._end,s=this,r=function(){s.magnitudefactor*=2},o=function(){s.magnitudefactor/=2};t.minorStepIdx<=1&&this.minorStepIdx<=1||t.minorStepIdx>1&&this.minorStepIdx>1||(t.minorStepIdx<this.minorStepIdx?(this.minorStepIdx=1,2==e?r():(r(),r())):(this.minorStepIdx=2,1==e?o():(o(),o())));for(var a=t.convertValue(0),l=t.getStep()*t.scale,h=!1,u=0;!h&&u++<5;){this.scale=l/(this.minorSteps[this.minorStepIdx]*this.magnitudefactor);var d=this.containerHeight/this.scale;this._start=i,this._end=this._start+d;var c=this._end*this.scale,f=this.magnitudefactor*this.majorSteps[this.minorStepIdx],m=this.getFirstMajor()-t.getFirstMajor();if(this.zeroAlign){var p=a-c;this._end+=p/this.scale,this._start=this._end-d}else this.autoScaleStart?(this._start-=m/this.scale,this._end=this._start+d):(this._start+=f-m/this.scale,this._end=this._start+d);if(!this.autoScaleEnd&&this._end>n+1e-5)o(),h=!1;else{if(!this.autoScaleStart&&this._start<i-1e-5){if(!(this.zeroAlign&&i>=0)){o(),h=!1;continue}console.warn("Can't adhere to given 'min' range, due to zeroalign")}this.autoScaleStart&&this.autoScaleEnd&&d<n-i?(r(),h=!1):h=!0}}}},{key:"convertValue",value:function(t){return this.containerHeight-(t-this._start)*this.scale}},{key:"screenToValue",value:function(t){return(this.containerHeight-t)/this.scale+this._start}}]),t}(),sc=function(t){function e(t,i,n,s){var r;Ds(this,e),(r=Cr(this,Lr(e).call(this))).id=to.randomUUID(),r.body=t,r.defaultOptions={orientation:"left",showMinorLabels:!0,showMajorLabels:!0,icons:!1,majorLinesOffset:7,minorLinesOffset:4,labelOffsetX:10,labelOffsetY:2,iconWidth:20,width:"40px",visible:!0,alignZeros:!0,left:{range:{min:void 0,max:void 0},format:function(t){return"".concat(uo(t.toPrecision(3)))},title:{text:void 0,style:void 0}},right:{range:{min:void 0,max:void 0},format:function(t){return"".concat(uo(t.toPrecision(3)))},title:{text:void 0,style:void 0}}},r.linegraphOptions=s,r.linegraphSVG=n,r.props={},r.DOMelements={lines:{},labels:{},title:{}},r.dom={},r.scale=void 0,r.range={start:0,end:0},r.options=to.extend({},r.defaultOptions),r.conversionFactor=1,r.setOptions(i),r.width=Number("".concat(r.options.width).replace("px","")),r.minWidth=r.width,r.height=r.linegraphSVG.getBoundingClientRect().height,r.hidden=!1,r.stepPixels=25,r.zeroCrossing=-1,r.amountOfSteps=-1,r.lineOffset=0,r.master=!0,r.masterAxis=null,r.svgElements={},r.iconsRemoved=!1,r.groups={},r.amountOfGroups=0,r._create(),null==r.scale&&r._redrawLabels(),r.framework={svg:r.svg,svgElements:r.svgElements,options:r.options,groups:r.groups};var o=Or(r);return r.body.emitter.on("verticalDrag",(function(){o.dom.lineContainer.style.top="".concat(o.body.domProps.scrollTop,"px")})),r}return jr(e,t),Ts(e,[{key:"addGroup",value:function(t,e){this.groups.hasOwnProperty(t)||(this.groups[t]=e),this.amountOfGroups+=1}},{key:"updateGroup",value:function(t,e){this.groups.hasOwnProperty(t)||(this.amountOfGroups+=1),this.groups[t]=e}},{key:"removeGroup",value:function(t){this.groups.hasOwnProperty(t)&&(delete this.groups[t],this.amountOfGroups-=1)}},{key:"setOptions",value:function(t){if(t){var e=!1;this.options.orientation!=t.orientation&&void 0!==t.orientation&&(e=!0);to.selectiveDeepExtend(["orientation","showMinorLabels","showMajorLabels","icons","majorLinesOffset","minorLinesOffset","labelOffsetX","labelOffsetY","iconWidth","width","visible","left","right","alignZeros"],this.options,t),this.minWidth=Number("".concat(this.options.width).replace("px","")),!0===e&&this.dom.frame&&(this.hide(),this.show())}}},{key:"_create",value:function(){this.dom.frame=document.createElement("div"),this.dom.frame.style.width=this.options.width,this.dom.frame.style.height=this.height,this.dom.lineContainer=document.createElement("div"),this.dom.lineContainer.style.width="100%",this.dom.lineContainer.style.height=this.height,this.dom.lineContainer.style.position="relative",this.dom.lineContainer.style.visibility="visible",this.dom.lineContainer.style.display="block",this.svg=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.svg.style.position="absolute",this.svg.style.top="0px",this.svg.style.height="100%",this.svg.style.width="100%",this.svg.style.display="block",this.dom.frame.appendChild(this.svg)}},{key:"_redrawGroupIcons",value:function(){var t;xt(this.svgElements);var e=this.options.iconWidth,i=11.5;t="left"===this.options.orientation?4:this.width-e-4;var n=$r(this.groups);Mo(n).call(n,(function(t,e){return t<e?-1:1}));var s=!0,r=!1,o=void 0;try{for(var a,l=wu(n);!(s=(a=l.next()).done);s=!0){var h=a.value;!0!==this.groups[h].visible||void 0!==this.linegraphOptions.visibility[h]&&!0!==this.linegraphOptions.visibility[h]||(this.groups[h].getLegend(e,15,this.framework,t,i),i+=19)}}catch(t){r=!0,o=t}finally{try{s||null==l.return||l.return()}finally{if(r)throw o}}Mt(this.svgElements),this.iconsRemoved=!1}},{key:"_cleanupIcons",value:function(){!1===this.iconsRemoved&&(xt(this.svgElements),Mt(this.svgElements),this.iconsRemoved=!0)}},{key:"show",value:function(){this.hidden=!1,this.dom.frame.parentNode||("left"===this.options.orientation?this.body.dom.left.appendChild(this.dom.frame):this.body.dom.right.appendChild(this.dom.frame)),this.dom.lineContainer.parentNode||this.body.dom.backgroundHorizontal.appendChild(this.dom.lineContainer),this.dom.lineContainer.style.display="block"}},{key:"hide",value:function(){this.hidden=!0,this.dom.frame.parentNode&&this.dom.frame.parentNode.removeChild(this.dom.frame),this.dom.lineContainer.style.display="none"}},{key:"setRange",value:function(t,e){this.range.start=t,this.range.end=e}},{key:"redraw",value:function(){var t=!1,e=0;for(var i in this.dom.lineContainer.style.top="".concat(this.body.domProps.scrollTop,"px"),this.groups)this.groups.hasOwnProperty(i)&&(!0!==this.groups[i].visible||void 0!==this.linegraphOptions.visibility[i]&&!0!==this.linegraphOptions.visibility[i]||e++);if(0===this.amountOfGroups||0===e)this.hide();else{this.show(),this.height=Number(this.linegraphSVG.style.height.replace("px","")),this.dom.lineContainer.style.height="".concat(this.height,"px"),this.width=!0===this.options.visible?Number("".concat(this.options.width).replace("px","")):0;var n=this.props,s=this.dom.frame;s.className="vis-data-axis",this._calculateCharSize();var r=this.options.orientation,o=this.options.showMinorLabels,a=this.options.showMajorLabels,l=this.body.dom.backgroundHorizontal.offsetWidth;n.minorLabelHeight=o?n.minorCharHeight:0,n.majorLabelHeight=a?n.majorCharHeight:0,n.minorLineWidth=l-this.lineOffset-this.width+2*this.options.minorLinesOffset,n.minorLineHeight=1,n.majorLineWidth=l-this.lineOffset-this.width+2*this.options.majorLinesOffset,n.majorLineHeight=1,"left"===r?(s.style.top="0",s.style.left="0",s.style.bottom="",s.style.width="".concat(this.width,"px"),s.style.height="".concat(this.height,"px"),this.props.width=this.body.domProps.left.width,this.props.height=this.body.domProps.left.height):(s.style.top="",s.style.bottom="0",s.style.left="0",s.style.width="".concat(this.width,"px"),s.style.height="".concat(this.height,"px"),this.props.width=this.body.domProps.right.width,this.props.height=this.body.domProps.right.height),t=this._redrawLabels(),t=this._isResized()||t,!0===this.options.icons?this._redrawGroupIcons():this._cleanupIcons(),this._redrawTitle(r)}return t}},{key:"_redrawLabels",value:function(){var t=this,e=!1;xt(this.DOMelements.lines),xt(this.DOMelements.labels);var i=this.options.orientation,n=null!=this.options[i].range?this.options[i].range:{},s=!0;null!=n.max&&(this.range.end=n.max,s=!1);var r=!0;null!=n.min&&(this.range.start=n.min,r=!1),this.scale=new nc(this.range.start,this.range.end,r,s,this.dom.frame.offsetHeight,this.props.majorCharHeight,this.options.alignZeros,this.options[i].format),!1===this.master&&null!=this.masterAxis?(this.scale.followScale(this.masterAxis.scale),this.dom.lineContainer.style.display="none"):this.dom.lineContainer.style.display="block",this.maxLabelSize=0;var o=this.scale.getLines();is(o).call(o,(function(e){var n=e.y,s=e.major;t.options.showMinorLabels&&!1===s&&t._redrawLabel(n-2,e.val,i,"vis-y-axis vis-minor",t.props.minorCharHeight),s&&n>=0&&t._redrawLabel(n-2,e.val,i,"vis-y-axis vis-major",t.props.majorCharHeight),!0===t.master&&(s?t._redrawLine(n,i,"vis-grid vis-horizontal vis-major",t.options.majorLinesOffset,t.props.majorLineWidth):t._redrawLine(n,i,"vis-grid vis-horizontal vis-minor",t.options.minorLinesOffset,t.props.minorLineWidth))}));var a=0;void 0!==this.options[i].title&&void 0!==this.options[i].title.text&&(a=this.props.titleCharHeight);var l=!0===this.options.icons?Math.max(this.options.iconWidth,a)+this.options.labelOffsetX+15:a+this.options.labelOffsetX+15;return this.maxLabelSize>this.width-l&&!0===this.options.visible?(this.width=this.maxLabelSize+l,this.options.width="".concat(this.width,"px"),Mt(this.DOMelements.lines),Mt(this.DOMelements.labels),this.redraw(),e=!0):this.maxLabelSize<this.width-l&&!0===this.options.visible&&this.width>this.minWidth?(this.width=Math.max(this.minWidth,this.maxLabelSize+l),this.options.width="".concat(this.width,"px"),Mt(this.DOMelements.lines),Mt(this.DOMelements.labels),this.redraw(),e=!0):(Mt(this.DOMelements.lines),Mt(this.DOMelements.labels),e=!1),e}},{key:"convertValue",value:function(t){return this.scale.convertValue(t)}},{key:"screenToValue",value:function(t){return this.scale.screenToValue(t)}},{key:"_redrawLabel",value:function(t,e,i,n,s){var r=Ct("div",this.DOMelements.labels,this.dom.frame);r.className=n,r.innerHTML=e,"left"===i?(r.style.left="-".concat(this.options.labelOffsetX,"px"),r.style.textAlign="right"):(r.style.right="-".concat(this.options.labelOffsetX,"px"),r.style.textAlign="left"),r.style.top="".concat(t-.5*s+this.options.labelOffsetY,"px"),e+="";var o=Math.max(this.props.majorCharWidth,this.props.minorCharWidth);this.maxLabelSize<e.length*o&&(this.maxLabelSize=e.length*o)}},{key:"_redrawLine",value:function(t,e,i,n,s){if(!0===this.master){var r=Ct("div",this.DOMelements.lines,this.dom.lineContainer);r.className=i,r.innerHTML="","left"===e?r.style.left="".concat(this.width-n,"px"):r.style.right="".concat(this.width-n,"px"),r.style.width="".concat(s,"px"),r.style.top="".concat(t,"px")}}},{key:"_redrawTitle",value:function(t){if(xt(this.DOMelements.title),void 0!==this.options[t].title&&void 0!==this.options[t].title.text){var e=Ct("div",this.DOMelements.title,this.dom.frame);e.className="vis-y-axis vis-title vis-".concat(t),e.innerHTML=this.options[t].title.text,void 0!==this.options[t].title.style&&to.addCssText(e,this.options[t].title.style),"left"===t?e.style.left="".concat(this.props.titleCharHeight,"px"):e.style.right="".concat(this.props.titleCharHeight,"px"),e.style.width="".concat(this.height,"px")}Mt(this.DOMelements.title)}},{key:"_calculateCharSize",value:function(){if(!("minorCharHeight"in this.props)){var t=document.createTextNode("0"),e=document.createElement("div");e.className="vis-y-axis vis-minor vis-measure",e.appendChild(t),this.dom.frame.appendChild(e),this.props.minorCharHeight=e.clientHeight,this.props.minorCharWidth=e.clientWidth,this.dom.frame.removeChild(e)}if(!("majorCharHeight"in this.props)){var i=document.createTextNode("0"),n=document.createElement("div");n.className="vis-y-axis vis-major vis-measure",n.appendChild(i),this.dom.frame.appendChild(n),this.props.majorCharHeight=n.clientHeight,this.props.majorCharWidth=n.clientWidth,this.dom.frame.removeChild(n)}if(!("titleCharHeight"in this.props)){var s=document.createTextNode("0"),r=document.createElement("div");r.className="vis-y-axis vis-title vis-measure",r.appendChild(s),this.dom.frame.appendChild(r),this.props.titleCharHeight=r.clientHeight,this.props.titleCharWidth=r.clientWidth,this.dom.frame.removeChild(r)}}}]),e}(yo);function rc(t,e){}function oc(t,e){return{style:(e=void 0===e?{}:e).style||t.options.drawPoints.style,styles:e.styles||t.options.drawPoints.styles,size:e.size||t.options.drawPoints.size,className:e.className||t.className}}function ac(t,e){}function lc(t,e){}function hc(t,e,i,n){this.id=e;this.options=to.selectiveBridgeObject(["sampling","style","sort","yAxisOrientation","barChart","drawPoints","shaded","interpolation","zIndex","excludeFromStacking","excludeFromLegend"],i),this.usingDefaultStyle=void 0===t.className,this.groupsUsingDefaultStyles=n,this.zeroPosition=0,this.update(t),1==this.usingDefaultStyle&&(this.groupsUsingDefaultStyles[0]+=1),this.itemsData=[],this.visible=void 0===t.visible||t.visible}function uc(t,e,i,n){this.body=t,this.defaultOptions={enabled:!1,icons:!0,iconSize:20,iconSpacing:6,left:{visible:!0,position:"top-left"},right:{visible:!0,position:"top-right"}},this.side=i,this.options=to.extend({},this.defaultOptions),this.linegraphOptions=n,this.svgElements={},this.dom={},this.groups={},this.amountOfGroups=0,this._create(),this.framework={svg:this.svg,svgElements:this.svgElements,options:this.options,groups:this.groups},this.setOptions(e)}rc.draw=function(t,e,i,n){n=n||0;for(var s=function(t,e){var i=void 0;t.options&&t.options.drawPoints&&t.options.drawPoints.onRender&&"function"==typeof t.options.drawPoints.onRender&&(i=t.options.drawPoints.onRender);e.group.options&&e.group.options.drawPoints&&e.group.options.drawPoints.onRender&&"function"==typeof e.group.options.drawPoints.onRender&&(i=e.group.options.drawPoints.onRender);return i}(i,e),r=0;r<t.length;r++)if(s){var o=s(t[r],e);!0!==o&&"object"!==Tr(o)||Yt(t[r].screen_x+n,t[r].screen_y,oc(e,o),i.svgElements,i.svg,t[r].label)}else Yt(t[r].screen_x+n,t[r].screen_y,oc(e),i.svgElements,i.svg,t[r].label)},rc.drawIcon=function(t,e,i,n,s,r){var o=.5*s,a=Ot("rect",r.svgElements,r.svg);a.setAttributeNS(null,"x",e),a.setAttributeNS(null,"y",i-o),a.setAttributeNS(null,"width",n),a.setAttributeNS(null,"height",2*o),a.setAttributeNS(null,"class","vis-outline"),Yt(e+.5*n,i,oc(t),r.svgElements,r.svg)},ac.drawIcon=function(t,e,i,n,s,r){var o=.5*s,a=Ot("rect",r.svgElements,r.svg);a.setAttributeNS(null,"x",e),a.setAttributeNS(null,"y",i-o),a.setAttributeNS(null,"width",n),a.setAttributeNS(null,"height",2*o),a.setAttributeNS(null,"class","vis-outline");var l=Math.round(.3*n),h=t.options.barChart.width/l,u=Math.round(.4*s),d=Math.round(.75*s),c=Math.round((n-2*l)/3);if(Pt(e+.5*l+c,i+o-u-1,l,u,t.className+" vis-bar",r.svgElements,r.svg,t.style),Pt(e+1.5*l+c+2,i+o-d-1,l,d,t.className+" vis-bar",r.svgElements,r.svg,t.style),1==t.options.drawPoints.enabled){var f={style:t.options.drawPoints.style,styles:t.options.drawPoints.styles,size:t.options.drawPoints.size/h,className:t.className};Yt(e+.5*l+c,i+o-u-1,f,r.svgElements,r.svg),Yt(e+1.5*l+c+2,i+o-d-1,f,r.svgElements,r.svg)}},ac.draw=function(t,e,i){var n,s,r,o,a,l,h=[],u={},d=0;for(a=0;a<t.length;a++)if("bar"===(o=i.groups[t[a]]).options.style&&!0===o.visible&&(void 0===i.options.groups.visibility[t[a]]||!0===i.options.groups.visibility[t[a]]))for(l=0;l<e[t[a]].length;l++)h.push({screen_x:e[t[a]][l].screen_x,screen_end:e[t[a]][l].screen_end,screen_y:e[t[a]][l].screen_y,x:e[t[a]][l].x,end:e[t[a]][l].end,y:e[t[a]][l].y,groupId:t[a],label:e[t[a]][l].label}),d+=1;if(0!==d)for(Mo(h).call(h,(function(t,e){return t.screen_x===e.screen_x?t.groupId<e.groupId?-1:1:t.screen_x-e.screen_x})),ac._getDataIntersections(u,h),a=0;a<h.length;a++){var c=null!=(o=i.groups[h[a].groupId]).options.barChart.minWidth?o.options.barChart.minWidth:.1*o.options.barChart.width,f=0;if(void 0===u[s=h[a].screen_x])a+1<h.length&&(n=Math.abs(h[a+1].screen_x-s)),r=ac._getSafeDrawData(n,o,c);else{var m=a+(u[s].amount-u[s].resolved);m<h.length&&(n=Math.abs(h[m].screen_x-s)),r=ac._getSafeDrawData(n,o,c),u[s].resolved+=1,!0===o.options.stack&&!0!==o.options.excludeFromStacking?h[a].screen_y<o.zeroPosition?(f=u[s].accumulatedNegative,u[s].accumulatedNegative+=o.zeroPosition-h[a].screen_y):(f=u[s].accumulatedPositive,u[s].accumulatedPositive+=o.zeroPosition-h[a].screen_y):!0===o.options.barChart.sideBySide&&(r.width=r.width/u[s].amount,r.offset+=u[s].resolved*r.width-.5*r.width*(u[s].amount+1))}var p=r.width,g=h[a].screen_x;if(null!=h[a].screen_end?g+=.5*(p=h[a].screen_end-h[a].screen_x):g+=r.offset,Pt(g,h[a].screen_y-f,p,o.zeroPosition-h[a].screen_y,o.className+" vis-bar",i.svgElements,i.svg,o.style),!0===o.options.drawPoints.enabled){var v={screen_x:h[a].screen_x,screen_y:h[a].screen_y-f,x:h[a].x,y:h[a].y,groupId:h[a].groupId,label:h[a].label};rc.draw([v],o,i,r.offset)}}},ac._getDataIntersections=function(t,e){for(var i,n=0;n<e.length;n++)n+1<e.length&&(i=Math.abs(e[n+1].screen_x-e[n].screen_x)),n>0&&(i=Math.min(i,Math.abs(e[n-1].screen_x-e[n].screen_x))),0===i&&(void 0===t[e[n].screen_x]&&(t[e[n].screen_x]={amount:0,resolved:0,accumulatedPositive:0,accumulatedNegative:0}),t[e[n].screen_x].amount+=1)},ac._getSafeDrawData=function(t,e,i){var n,s;return t<e.options.barChart.width&&t>0?(n=t<i?i:t,s=0,"left"===e.options.barChart.align?s-=.5*t:"right"===e.options.barChart.align&&(s+=.5*t)):(n=e.options.barChart.width,s=0,"left"===e.options.barChart.align?s-=.5*e.options.barChart.width:"right"===e.options.barChart.align&&(s+=.5*e.options.barChart.width)),{width:n,offset:s}},ac.getStackedYRange=function(t,e,i,n,s){if(t.length>0){Mo(t).call(t,(function(t,e){return t.screen_x===e.screen_x?t.groupId<e.groupId?-1:1:t.screen_x-e.screen_x}));var r={};ac._getDataIntersections(r,t),e[n]=ac._getStackedYRange(r,t),e[n].yAxisOrientation=s,i.push(n)}},ac._getStackedYRange=function(t,e){for(var i,n=e[0].screen_y,s=e[0].screen_y,r=0;r<e.length;r++)void 0===t[i=e[r].screen_x]?(n=n>e[r].screen_y?e[r].screen_y:n,s=s<e[r].screen_y?e[r].screen_y:s):e[r].screen_y<0?t[i].accumulatedNegative+=e[r].screen_y:t[i].accumulatedPositive+=e[r].screen_y;for(var o in t)t.hasOwnProperty(o)&&(n=(n=n>t[o].accumulatedNegative?t[o].accumulatedNegative:n)>t[o].accumulatedPositive?t[o].accumulatedPositive:n,s=(s=s<t[o].accumulatedNegative?t[o].accumulatedNegative:s)<t[o].accumulatedPositive?t[o].accumulatedPositive:s);return{min:n,max:s}},lc.calcPath=function(t,e){if(null!=t&&t.length>0){return 1==e.options.interpolation.enabled?lc._catmullRom(t,e):lc._linear(t)}},lc.drawIcon=function(t,e,i,n,s,r){var o,a,l=.5*s,h=Ot("rect",r.svgElements,r.svg);(h.setAttributeNS(null,"x",e),h.setAttributeNS(null,"y",i-l),h.setAttributeNS(null,"width",n),h.setAttributeNS(null,"height",2*l),h.setAttributeNS(null,"class","vis-outline"),(o=Ot("path",r.svgElements,r.svg)).setAttributeNS(null,"class",t.className),void 0!==t.style&&o.setAttributeNS(null,"style",t.style),o.setAttributeNS(null,"d","M"+e+","+i+" L"+(e+n)+","+i),1==t.options.shaded.enabled&&(a=Ot("path",r.svgElements,r.svg),"top"==t.options.shaded.orientation?a.setAttributeNS(null,"d","M"+e+", "+(i-l)+"L"+e+","+i+" L"+(e+n)+","+i+" L"+(e+n)+","+(i-l)):a.setAttributeNS(null,"d","M"+e+","+i+" L"+e+","+(i+l)+" L"+(e+n)+","+(i+l)+"L"+(e+n)+","+i),a.setAttributeNS(null,"class",t.className+" vis-icon-fill"),void 0!==t.options.shaded.style&&""!==t.options.shaded.style&&a.setAttributeNS(null,"style",t.options.shaded.style)),1==t.options.drawPoints.enabled)&&Yt(e+.5*n,i,{style:t.options.drawPoints.style,styles:t.options.drawPoints.styles,size:t.options.drawPoints.size,className:t.className},r.svgElements,r.svg)},lc.drawShading=function(t,e,i,n){if(1==e.options.shaded.enabled){var s,r=Number(n.svg.style.height.replace("px","")),o=Ot("path",n.svgElements,n.svg),a="L";1==e.options.interpolation.enabled&&(a="C");var l=0;l="top"==e.options.shaded.orientation?0:"bottom"==e.options.shaded.orientation?r:Math.min(Math.max(0,e.zeroPosition),r),s="group"==e.options.shaded.orientation&&null!=i&&null!=i?"M"+t[0][0]+","+t[0][1]+" "+this.serializePath(t,a,!1)+" L"+i[i.length-1][0]+","+i[i.length-1][1]+" "+this.serializePath(i,a,!0)+i[0][0]+","+i[0][1]+" Z":"M"+t[0][0]+","+t[0][1]+" "+this.serializePath(t,a,!1)+" V"+l+" H"+t[0][0]+" Z",o.setAttributeNS(null,"class",e.className+" vis-fill"),void 0!==e.options.shaded.style&&o.setAttributeNS(null,"style",e.options.shaded.style),o.setAttributeNS(null,"d",s)}},lc.draw=function(t,e,i){if(null!=t&&null!=t){var n=Ot("path",i.svgElements,i.svg);n.setAttributeNS(null,"class",e.className),void 0!==e.style&&n.setAttributeNS(null,"style",e.style);var s="L";1==e.options.interpolation.enabled&&(s="C"),n.setAttributeNS(null,"d","M"+t[0][0]+","+t[0][1]+" "+this.serializePath(t,s,!1))}},lc.serializePath=function(t,e,i){if(t.length<2)return"";var n,s=e;if(i)for(n=t.length-2;n>0;n--)s+=t[n][0]+","+t[n][1]+" ";else for(n=1;n<t.length;n++)s+=t[n][0]+","+t[n][1]+" ";return s},lc._catmullRomUniform=function(t){var e,i,n,s,r,o,a=[];a.push([Math.round(t[0].screen_x),Math.round(t[0].screen_y)]);for(var l=t.length,h=0;h<l-1;h++)e=0==h?t[0]:t[h-1],i=t[h],n=t[h+1],s=h+2<l?t[h+2]:n,r={screen_x:(-e.screen_x+6*i.screen_x+n.screen_x)*(1/6),screen_y:(-e.screen_y+6*i.screen_y+n.screen_y)*(1/6)},o={screen_x:(i.screen_x+6*n.screen_x-s.screen_x)*(1/6),screen_y:(i.screen_y+6*n.screen_y-s.screen_y)*(1/6)},a.push([r.screen_x,r.screen_y]),a.push([o.screen_x,o.screen_y]),a.push([n.screen_x,n.screen_y]);return a},lc._catmullRom=function(t,e){var i=e.options.interpolation.alpha;if(0==i||void 0===i)return this._catmullRomUniform(t);var n,s,r,o,a,l,h,u,d,c,f,m,p,g,v,y,_,b,w,k=[];k.push([Math.round(t[0].screen_x),Math.round(t[0].screen_y)]);for(var D=t.length,S=0;S<D-1;S++)n=0==S?t[0]:t[S-1],s=t[S],r=t[S+1],o=S+2<D?t[S+2]:r,h=Math.sqrt(Math.pow(n.screen_x-s.screen_x,2)+Math.pow(n.screen_y-s.screen_y,2)),u=Math.sqrt(Math.pow(s.screen_x-r.screen_x,2)+Math.pow(s.screen_y-r.screen_y,2)),d=Math.sqrt(Math.pow(r.screen_x-o.screen_x,2)+Math.pow(r.screen_y-o.screen_y,2)),g=Math.pow(d,i),y=Math.pow(d,2*i),v=Math.pow(u,i),_=Math.pow(u,2*i),w=Math.pow(h,i),c=2*(b=Math.pow(h,2*i))+3*w*v+_,f=2*y+3*g*v+_,(m=3*w*(w+v))>0&&(m=1/m),(p=3*g*(g+v))>0&&(p=1/p),a={screen_x:(-_*n.screen_x+c*s.screen_x+b*r.screen_x)*m,screen_y:(-_*n.screen_y+c*s.screen_y+b*r.screen_y)*m},l={screen_x:(y*s.screen_x+f*r.screen_x-_*o.screen_x)*p,screen_y:(y*s.screen_y+f*r.screen_y-_*o.screen_y)*p},0==a.screen_x&&0==a.screen_y&&(a=s),0==l.screen_x&&0==l.screen_y&&(l=r),k.push([a.screen_x,a.screen_y]),k.push([l.screen_x,l.screen_y]),k.push([r.screen_x,r.screen_y]);return k},lc._linear=function(t){for(var e=[],i=0;i<t.length;i++)e.push([t[i].screen_x,t[i].screen_y]);return e},hc.prototype.setItems=function(t){null!=t?(this.itemsData=t,1==Mo(this.options)&&to.insertSort(this.itemsData,(function(t,e){return t.x>e.x?1:-1}))):this.itemsData=[]},hc.prototype.getItems=function(){return this.itemsData},hc.prototype.setZeroPosition=function(t){this.zeroPosition=t},hc.prototype.setOptions=function(t){if(void 0!==t){to.selectiveDeepExtend(["sampling","style","sort","yAxisOrientation","barChart","zIndex","excludeFromStacking","excludeFromLegend"],this.options,t),"function"==typeof t.drawPoints&&(t.drawPoints={onRender:t.drawPoints}),to.mergeOptions(this.options,t,"interpolation"),to.mergeOptions(this.options,t,"drawPoints"),to.mergeOptions(this.options,t,"shaded"),t.interpolation&&"object"==Tr(t.interpolation)&&t.interpolation.parametrization&&("uniform"==t.interpolation.parametrization?this.options.interpolation.alpha=0:"chordal"==t.interpolation.parametrization?this.options.interpolation.alpha=1:(this.options.interpolation.parametrization="centripetal",this.options.interpolation.alpha=.5))}},hc.prototype.update=function(t){this.group=t,this.content=t.content||"graph",this.className=t.className||this.className||"vis-graph-group"+this.groupsUsingDefaultStyles[0]%10,this.visible=void 0===t.visible||t.visible,this.style=t.style,this.setOptions(t.options)},hc.prototype.getLegend=function(t,e,i,n,s){null!=i&&null!=i||(i={svg:document.createElementNS("http://www.w3.org/2000/svg","svg"),svgElements:{},options:this.options,groups:[this]});switch(null!=n&&null!=n||(n=0),null!=s&&null!=s||(s=.5*e),this.options.style){case"line":lc.drawIcon(this,n,s,t,e,i);break;case"points":case"point":rc.drawIcon(this,n,s,t,e,i);break;case"bar":ac.drawIcon(this,n,s,t,e,i)}return{icon:i.svg,label:this.content,orientation:this.options.yAxisOrientation}},hc.prototype.getYRange=function(t){for(var e=t[0].y,i=t[0].y,n=0;n<t.length;n++)e=e>t[n].y?t[n].y:e,i=i<t[n].y?t[n].y:i;return{min:e,max:i,yAxisOrientation:this.options.yAxisOrientation}},uc.prototype=new yo,uc.prototype.clear=function(){this.groups={},this.amountOfGroups=0},uc.prototype.addGroup=function(t,e){1!=e.options.excludeFromLegend&&(this.groups.hasOwnProperty(t)||(this.groups[t]=e),this.amountOfGroups+=1)},uc.prototype.updateGroup=function(t,e){this.groups[t]=e},uc.prototype.removeGroup=function(t){this.groups.hasOwnProperty(t)&&(delete this.groups[t],this.amountOfGroups-=1)},uc.prototype._create=function(){this.dom.frame=document.createElement("div"),this.dom.frame.className="vis-legend",this.dom.frame.style.position="absolute",this.dom.frame.style.top="10px",this.dom.frame.style.display="block",this.dom.textArea=document.createElement("div"),this.dom.textArea.className="vis-legend-text",this.dom.textArea.style.position="relative",this.dom.textArea.style.top="0px",this.svg=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.svg.style.position="absolute",this.svg.style.top="0px",this.svg.style.width=this.options.iconSize+5+"px",this.svg.style.height="100%",this.dom.frame.appendChild(this.svg),this.dom.frame.appendChild(this.dom.textArea)},uc.prototype.hide=function(){this.dom.frame.parentNode&&this.dom.frame.parentNode.removeChild(this.dom.frame)},uc.prototype.show=function(){this.dom.frame.parentNode||this.body.dom.center.appendChild(this.dom.frame)},uc.prototype.setOptions=function(t){to.selectiveDeepExtend(["enabled","orientation","icons","left","right"],this.options,t)},uc.prototype.redraw=function(){var t=0,e=$r(this.groups);Mo(e).call(e,(function(t,e){return t<e?-1:1}));for(var i=0;i<e.length;i++){var n=e[i];1!=this.groups[n].visible||void 0!==this.linegraphOptions.visibility[n]&&1!=this.linegraphOptions.visibility[n]||t++}if(0==this.options[this.side].visible||0==this.amountOfGroups||0==this.options.enabled||0==t)this.hide();else{if(this.show(),"top-left"==this.options[this.side].position||"bottom-left"==this.options[this.side].position?(this.dom.frame.style.left="4px",this.dom.frame.style.textAlign="left",this.dom.textArea.style.textAlign="left",this.dom.textArea.style.left=this.options.iconSize+15+"px",this.dom.textArea.style.right="",this.svg.style.left="0px",this.svg.style.right=""):(this.dom.frame.style.right="4px",this.dom.frame.style.textAlign="right",this.dom.textArea.style.textAlign="right",this.dom.textArea.style.right=this.options.iconSize+15+"px",this.dom.textArea.style.left="",this.svg.style.right="0px",this.svg.style.left=""),"top-left"==this.options[this.side].position||"top-right"==this.options[this.side].position)this.dom.frame.style.top=4-Number(this.body.dom.center.style.top.replace("px",""))+"px",this.dom.frame.style.bottom="";else{var s=this.body.domProps.center.height-this.body.domProps.centerContainer.height;this.dom.frame.style.bottom=4+s+Number(this.body.dom.center.style.top.replace("px",""))+"px",this.dom.frame.style.top=""}0==this.options.icons?(this.dom.frame.style.width=this.dom.textArea.offsetWidth+10+"px",this.dom.textArea.style.right="",this.dom.textArea.style.left="",this.svg.style.width="0px"):(this.dom.frame.style.width=this.options.iconSize+15+this.dom.textArea.offsetWidth+10+"px",this.drawLegendIcons());var r="";for(i=0;i<e.length;i++)n=e[i],1!=this.groups[n].visible||void 0!==this.linegraphOptions.visibility[n]&&1!=this.linegraphOptions.visibility[n]||(r+=this.groups[n].content+"<br />");this.dom.textArea.innerHTML=r,this.dom.textArea.style.lineHeight=.75*this.options.iconSize+this.options.iconSpacing+"px"}},uc.prototype.drawLegendIcons=function(){if(this.dom.frame.parentNode){var t=$r(this.groups);Mo(t).call(t,(function(t,e){return t<e?-1:1})),Tt(this.svgElements);var e=window.getComputedStyle(this.dom.frame).paddingTop,i=Number(e.replace("px","")),n=i,s=this.options.iconSize,r=.75*this.options.iconSize,o=i+.5*r+3;this.svg.style.width=s+5+i+"px";for(var a=0;a<t.length;a++){var l=t[a];1!=this.groups[l].visible||void 0!==this.linegraphOptions.visibility[l]&&1!=this.linegraphOptions.visibility[l]||(this.groups[l].getLegend(s,r,this.framework,n,o),o+=r+this.options.iconSpacing)}}};function dc(t,e){this.id=to.randomUUID(),this.body=t,this.defaultOptions={yAxisOrientation:"left",defaultGroup:"default",sort:!0,sampling:!0,stack:!1,graphHeight:"400px",shaded:{enabled:!1,orientation:"bottom"},style:"line",barChart:{width:50,sideBySide:!1,align:"center"},interpolation:{enabled:!0,parametrization:"centripetal",alpha:.5},drawPoints:{enabled:!0,size:6,style:"square"},dataAxis:{},legend:{},groups:{visibility:{}}},this.options=to.extend({},this.defaultOptions),this.dom={},this.props={},this.hammer=null,this.groups={},this.abortedGraphUpdate=!1,this.updateSVGheight=!1,this.updateSVGheightOnResize=!1,this.forceGraphUpdate=!0;var i=this;this.itemsData=null,this.groupsData=null,this.itemListeners={add:function(t,e,n){i._onAdd(e.items)},update:function(t,e,n){i._onUpdate(e.items)},remove:function(t,e,n){i._onRemove(e.items)}},this.groupListeners={add:function(t,e,n){i._onAddGroups(e.items)},update:function(t,e,n){i._onUpdateGroups(e.items)},remove:function(t,e,n){i._onRemoveGroups(e.items)}},this.items={},this.selection=[],this.lastStart=this.body.range.start,this.touchParams={},this.svgElements={},this.setOptions(e),this.groupsUsingDefaultStyles=[0],this.body.emitter.on("rangechanged",(function(){i.lastStart=i.body.range.start,i.svg.style.left=to.option.asSize(-i.props.width),i.forceGraphUpdate=!0,i.redraw.call(i)})),this._create(),this.framework={svg:this.svg,svgElements:this.svgElements,options:this.options,groups:this.groups}}dc.prototype=new yo,dc.prototype._create=function(){var t=document.createElement("div");t.className="vis-line-graph",this.dom.frame=t,this.svg=document.createElementNS("http://www.w3.org/2000/svg","svg"),this.svg.style.position="relative",this.svg.style.height=(""+this.options.graphHeight).replace("px","")+"px",this.svg.style.display="block",t.appendChild(this.svg),this.options.dataAxis.orientation="left",this.yAxisLeft=new sc(this.body,this.options.dataAxis,this.svg,this.options.groups),this.options.dataAxis.orientation="right",this.yAxisRight=new sc(this.body,this.options.dataAxis,this.svg,this.options.groups),delete this.options.dataAxis.orientation,this.legendLeft=new uc(this.body,this.options.legend,"left",this.options.groups),this.legendRight=new uc(this.body,this.options.legend,"right",this.options.groups),this.show()},dc.prototype.setOptions=function(t){if(t){void 0===t.graphHeight&&void 0!==t.height?(this.updateSVGheight=!0,this.updateSVGheightOnResize=!0):void 0!==this.body.domProps.centerContainer.height&&void 0!==t.graphHeight&&xh((t.graphHeight+"").replace("px",""))<this.body.domProps.centerContainer.height&&(this.updateSVGheight=!0),to.selectiveDeepExtend(["sampling","defaultGroup","stack","height","graphHeight","yAxisOrientation","style","barChart","dataAxis","sort","groups"],this.options,t),to.mergeOptions(this.options,t,"interpolation"),to.mergeOptions(this.options,t,"drawPoints"),to.mergeOptions(this.options,t,"shaded"),to.mergeOptions(this.options,t,"legend"),t.interpolation&&"object"==Tr(t.interpolation)&&t.interpolation.parametrization&&("uniform"==t.interpolation.parametrization?this.options.interpolation.alpha=0:"chordal"==t.interpolation.parametrization?this.options.interpolation.alpha=1:(this.options.interpolation.parametrization="centripetal",this.options.interpolation.alpha=.5)),this.yAxisLeft&&void 0!==t.dataAxis&&(this.yAxisLeft.setOptions(this.options.dataAxis),this.yAxisRight.setOptions(this.options.dataAxis)),this.legendLeft&&void 0!==t.legend&&(this.legendLeft.setOptions(this.options.legend),this.legendRight.setOptions(this.options.legend)),this.groups.hasOwnProperty("__ungrouped__")&&this.groups.__ungrouped__.setOptions(t)}this.dom.frame&&(this.forceGraphUpdate=!0,this.body.emitter.emit("_change",{queue:!0}))},dc.prototype.hide=function(){this.dom.frame.parentNode&&this.dom.frame.parentNode.removeChild(this.dom.frame)},dc.prototype.show=function(){this.dom.frame.parentNode||this.body.dom.center.appendChild(this.dom.frame)},dc.prototype.setItems=function(t){var e,i=this,n=this.itemsData;if(t){if(!(t instanceof we||t instanceof ke))throw new TypeError("Data must be an instance of DataSet or DataView");this.itemsData=t}else this.itemsData=null;if(n&&(is(to).call(to,this.itemListeners,(function(t,e){n.off(e,t)})),e=n.getIds(),this._onRemove(e)),this.itemsData){var s=this.id;is(to).call(to,this.itemListeners,(function(t,e){i.itemsData.on(e,t,s)})),e=this.itemsData.getIds(),this._onAdd(e)}},dc.prototype.setGroups=function(t){var e,i=this;if(this.groupsData){is(to).call(to,this.groupListeners,(function(t,e){i.groupsData.off(e,t)})),e=this.groupsData.getIds(),this.groupsData=null;for(var n=0;n<e.length;n++)this._removeGroup(e[n])}if(t){if(!(t instanceof we||t instanceof ke))throw new TypeError("Data must be an instance of DataSet or DataView");this.groupsData=t}else this.groupsData=null;if(this.groupsData){var s=this.id;is(to).call(to,this.groupListeners,(function(t,e){i.groupsData.on(e,t,s)})),e=this.groupsData.getIds(),this._onAddGroups(e)}},dc.prototype._onUpdate=function(t){this._updateAllGroupData(t)},dc.prototype._onAdd=function(t){this._onUpdate(t)},dc.prototype._onRemove=function(t){this._onUpdate(t)},dc.prototype._onUpdateGroups=function(t){this._updateAllGroupData(null,t)},dc.prototype._onAddGroups=function(t){this._onUpdateGroups(t)},dc.prototype._onRemoveGroups=function(t){for(var e=0;e<t.length;e++)this._removeGroup(t[e]);this.forceGraphUpdate=!0,this.body.emitter.emit("_change",{queue:!0})},dc.prototype._removeGroup=function(t){this.groups.hasOwnProperty(t)&&("right"==this.groups[t].options.yAxisOrientation?(this.yAxisRight.removeGroup(t),this.legendRight.removeGroup(t),this.legendRight.redraw()):(this.yAxisLeft.removeGroup(t),this.legendLeft.removeGroup(t),this.legendLeft.redraw()),delete this.groups[t])},dc.prototype._updateGroup=function(t,e){this.groups.hasOwnProperty(e)?(this.groups[e].update(t),"right"==this.groups[e].options.yAxisOrientation?(this.yAxisRight.updateGroup(e,this.groups[e]),this.legendRight.updateGroup(e,this.groups[e]),this.yAxisLeft.removeGroup(e),this.legendLeft.removeGroup(e)):(this.yAxisLeft.updateGroup(e,this.groups[e]),this.legendLeft.updateGroup(e,this.groups[e]),this.yAxisRight.removeGroup(e),this.legendRight.removeGroup(e))):(this.groups[e]=new hc(t,e,this.options,this.groupsUsingDefaultStyles),"right"==this.groups[e].options.yAxisOrientation?(this.yAxisRight.addGroup(e,this.groups[e]),this.legendRight.addGroup(e,this.groups[e])):(this.yAxisLeft.addGroup(e,this.groups[e]),this.legendLeft.addGroup(e,this.groups[e]))),this.legendLeft.redraw(),this.legendRight.redraw()},dc.prototype._updateAllGroupData=function(t,e){if(null!=this.itemsData){var i={},n=this.itemsData.get(),s=this.itemsData._idProp,r={};t&&mu(t).call(t,(function(t){r[t]=t}));for(var o={},a=0;a<n.length;a++){var l=n[a],h=l.group;null==h&&(h="__ungrouped__"),o.hasOwnProperty(h)?o[h]++:o[h]=1}var u={};if(!e&&t)for(h in this.groups)if(this.groups.hasOwnProperty(h)){var d=(p=this.groups[h]).getItems();i[h]=ls(d).call(d,(function(t){return u[t[s]]=t[s],t[s]!==r[t[s]]}));var c=o[h];o[h]-=i[h].length,i[h].length<c&&(i[h][c-1]={})}for(a=0;a<n.length;a++)if(null==(h=(l=n[a]).group)&&(h="__ungrouped__"),e||!t||l[s]===r[l[s]]||!u.hasOwnProperty(l[s])){i.hasOwnProperty(h)||(i[h]=new Array(o[h]));var f=to.bridgeObject(l);f.x=to.convert(l.x,"Date"),f.end=to.convert(l.end,"Date"),f.orginalY=l.y,f.y=Number(l.y),f[s]=l[s];var m=i[h].length-o[h]--;i[h][m]=f}for(h in this.groups)this.groups.hasOwnProperty(h)&&(i.hasOwnProperty(h)||(i[h]=new Array(0)));for(h in i)if(i.hasOwnProperty(h))if(0==i[h].length)this.groups.hasOwnProperty(h)&&this._removeGroup(h);else{var p=void 0;null!=this.groupsData&&(p=this.groupsData.get(h)),null==p&&(p={id:h,content:this.options.defaultGroup+h}),this._updateGroup(p,h),this.groups[h].setItems(i[h])}this.forceGraphUpdate=!0,this.body.emitter.emit("_change",{queue:!0})}},dc.prototype.redraw=function(){var t=!1;this.props.width=this.dom.frame.offsetWidth,this.props.height=this.body.domProps.centerContainer.height-this.body.domProps.border.top-this.body.domProps.border.bottom,t=this._isResized()||t;var e,i=this.body.range.end-this.body.range.start,n=i!=this.lastVisibleInterval;(this.lastVisibleInterval=i,1==t)&&(this.svg.style.width=to.option.asSize(3*this.props.width),this.svg.style.left=to.option.asSize(-this.props.width),-1==la(e=this.options.height+"").call(e,"%")&&1!=this.updateSVGheightOnResize||(this.updateSVGheight=!0));if(1==this.updateSVGheight?(this.options.graphHeight!=this.props.height+"px"&&(this.options.graphHeight=this.props.height+"px",this.svg.style.height=this.props.height+"px"),this.updateSVGheight=!1):this.svg.style.height=(""+this.options.graphHeight).replace("px","")+"px",1==t||1==n||1==this.abortedGraphUpdate||1==this.forceGraphUpdate)t=this._updateGraph()||t,this.forceGraphUpdate=!1;else if(0!=this.lastStart){var s=this.body.range.start-this.lastStart,r=this.body.range.end-this.body.range.start;if(0!=this.props.width){var o=s*(this.props.width/r);this.svg.style.left=-this.props.width-o+"px"}}return this.legendLeft.redraw(),this.legendRight.redraw(),t},dc.prototype._getSortedGroupIds=function(){var t=[];for(var e in this.groups)if(this.groups.hasOwnProperty(e)){var i=this.groups[e];1!=i.visible||void 0!==this.options.groups.visibility[e]&&1!=this.options.groups.visibility[e]||t.push({id:e,zIndex:i.options.zIndex})}to.insertSort(t,(function(t,e){var i=t.zIndex,n=e.zIndex;return void 0===i&&(i=0),void 0===n&&(n=0),i==n?0:i<n?-1:1}));for(var n=new Array(t.length),s=0;s<t.length;s++)n[s]=t[s].id;return n},dc.prototype._updateGraph=function(){if(xt(this.svgElements),0!=this.props.width&&null!=this.itemsData){var t,e,i={},n=this.body.util.toGlobalTime(-this.body.domProps.root.width),s=this.body.util.toGlobalTime(2*this.body.domProps.root.width),r=this._getSortedGroupIds();if(r.length>0){var o={};for(this._getRelevantData(r,o,n,s),this._applySampling(r,o),e=0;e<r.length;e++)this._convertXcoordinates(o[r[e]]);if(this._getYRanges(r,o,i),1==this._updateYAxis(r,i))return Mt(this.svgElements),this.abortedGraphUpdate=!0,!0;this.abortedGraphUpdate=!1;var a=void 0;for(e=0;e<r.length;e++)t=this.groups[r[e]],!0===this.options.stack&&"line"===this.options.style&&(null!=t.options.excludeFromStacking&&t.options.excludeFromStacking||(null!=a&&(this._stack(o[t.id],o[a.id]),1==t.options.shaded.enabled&&"group"!==t.options.shaded.orientation&&("top"==t.options.shaded.orientation&&"group"!==a.options.shaded.orientation?(a.options.shaded.orientation="group",a.options.shaded.groupId=t.id):(t.options.shaded.orientation="group",t.options.shaded.groupId=a.id))),a=t)),this._convertYcoordinates(o[r[e]],t);var l={};for(e=0;e<r.length;e++)if("line"===(t=this.groups[r[e]]).options.style&&1==t.options.shaded.enabled){var h=o[r[e]];if(null==h||0==h.length)continue;if(l.hasOwnProperty(r[e])||(l[r[e]]=lc.calcPath(h,t)),"group"===t.options.shaded.orientation){var u=t.options.shaded.groupId;if(-1===la(r).call(r,u)){console.log(t.id+": Unknown shading group target given:"+u);continue}l.hasOwnProperty(u)||(l[u]=lc.calcPath(o[u],this.groups[u])),lc.drawShading(l[r[e]],t,l[u],this.framework)}else lc.drawShading(l[r[e]],t,void 0,this.framework)}for(ac.draw(r,o,this.framework),e=0;e<r.length;e++)if(t=this.groups[r[e]],o[r[e]].length>0)switch(t.options.style){case"line":l.hasOwnProperty(r[e])||(l[r[e]]=lc.calcPath(o[r[e]],t)),lc.draw(l[r[e]],t,this.framework);case"point":case"points":"point"!=t.options.style&&"points"!=t.options.style&&1!=t.options.drawPoints.enabled||rc.draw(o[r[e]],t,this.framework)}}}return Mt(this.svgElements),!1},dc.prototype._stack=function(t,e){var i,n,s,r,o;i=0;for(var a=0;a<t.length;a++){r=void 0,o=void 0;for(var l=i;l<e.length;l++){if(e[l].x===t[a].x){r=e[l],o=e[l],i=l;break}if(e[l].x>t[a].x){o=e[l],r=0==l?o:e[l-1],i=l;break}}void 0===o&&(r=e[e.length-1],o=e[e.length-1]),n=o.x-r.x,s=o.y-r.y,t[a].y=0==n?t[a].orginalY+o.y:t[a].orginalY+s/n*(t[a].x-r.x)+r.y}},dc.prototype._getRelevantData=function(t,e,i,n){var s,r,o,a;if(t.length>0)for(r=0;r<t.length;r++){var l=(s=this.groups[t[r]]).getItems();if(1==Mo(s.options)){var h=function(t,e){return t.getTime()==e.getTime()?0:t<e?-1:1},u=Math.max(0,to.binarySearchValue(l,i,"x","before",h)),d=Math.min(l.length,to.binarySearchValue(l,n,"x","after",h)+1);d<=0&&(d=l.length);var c=new Array(d-u);for(o=u;o<d;o++)a=s.itemsData[o],c[o-u]=a;e[t[r]]=c}else e[t[r]]=s.itemsData}},dc.prototype._applySampling=function(t,e){if(t.length>0)for(var i=0;i<t.length;i++)if(1==this.groups[t[i]].options.sampling){var n=e[t[i]];if(n.length>0){var s,r=n.length,o=r/(this.body.util.toGlobalScreen(n[n.length-1].x)-this.body.util.toGlobalScreen(n[0].x));s=Math.min(Math.ceil(.2*r),Math.max(1,Math.round(o)));for(var a=new Array(r),l=0;l<r;l+=s){a[Math.round(l/s)]=n[l]}e[t[i]]=ea(a).call(a,0,Math.round(r/s))}}},dc.prototype._getYRanges=function(t,e,i){var n,s,r,o,a=[],l=[];if(t.length>0){for(r=0;r<t.length;r++)n=e[t[r]],o=this.groups[t[r]].options,n.length>0&&(s=this.groups[t[r]],!0===o.stack&&"bar"===o.style?"left"===o.yAxisOrientation?a=vo(a).call(a,n):l=vo(l).call(l,n):i[t[r]]=s.getYRange(n,t[r]));ac.getStackedYRange(a,i,t,"__barStackLeft","left"),ac.getStackedYRange(l,i,t,"__barStackRight","right")}},dc.prototype._updateYAxis=function(t,e){var i,n,s=!1,r=!1,o=!1,a=1e9,l=1e9,h=-1e9,u=-1e9;if(t.length>0){for(var d=0;d<t.length;d++){var c=this.groups[t[d]];c&&"right"!=c.options.yAxisOrientation?(r=!0,a=1e9,h=-1e9):c&&c.options.yAxisOrientation&&(o=!0,l=1e9,u=-1e9)}for(d=0;d<t.length;d++)e.hasOwnProperty(t[d])&&!0!==e[t[d]].ignore&&(i=e[t[d]].min,n=e[t[d]].max,"right"!=e[t[d]].yAxisOrientation?(r=!0,a=a>i?i:a,h=h<n?n:h):(o=!0,l=l>i?i:l,u=u<n?n:u));1==r&&this.yAxisLeft.setRange(a,h),1==o&&this.yAxisRight.setRange(l,u)}s=this._toggleAxisVisiblity(r,this.yAxisLeft)||s,s=this._toggleAxisVisiblity(o,this.yAxisRight)||s,1==o&&1==r?(this.yAxisLeft.drawIcons=!0,this.yAxisRight.drawIcons=!0):(this.yAxisLeft.drawIcons=!1,this.yAxisRight.drawIcons=!1),this.yAxisRight.master=!r,this.yAxisRight.masterAxis=this.yAxisLeft,0==this.yAxisRight.master?(this.yAxisLeft.lineOffset=1==o?this.yAxisRight.width:0,s=this.yAxisLeft.redraw()||s,s=this.yAxisRight.redraw()||s):s=this.yAxisRight.redraw()||s;var f=["__barStackLeft","__barStackRight","__lineStackLeft","__lineStackRight"];for(d=0;d<f.length;d++)-1!=la(t).call(t,f[d])&&ea(t).call(t,la(t).call(t,f[d]),1);return s},dc.prototype._toggleAxisVisiblity=function(t,e){var i=!1;return 0==t?e.dom.frame.parentNode&&0==e.hidden&&(e.hide(),i=!0):e.dom.frame.parentNode||1!=e.hidden||(e.show(),i=!0),i},dc.prototype._convertXcoordinates=function(t){for(var e=this.body.util.toScreen,i=0;i<t.length;i++)t[i].screen_x=e(t[i].x)+this.props.width,t[i].screen_y=t[i].y,null!=t[i].end?t[i].screen_end=e(t[i].end)+this.props.width:t[i].screen_end=void 0},dc.prototype._convertYcoordinates=function(t,e){var i=this.yAxisLeft,n=Number(this.svg.style.height.replace("px",""));"right"==e.options.yAxisOrientation&&(i=this.yAxisRight);for(var s=0;s<t.length;s++)t[s].screen_y=Math.round(i.convertValue(t[s].y));e.setZeroPosition(Math.min(n,i.convertValue(0)))};var cc="boolean",fc={configure:{enabled:{boolean:cc},filter:{boolean:cc,function:"function"},container:{dom:"dom"},__type__:{object:"object",boolean:cc,function:"function"}},alignCurrentTime:{string:"string",undefined:"undefined"},yAxisOrientation:{string:["left","right"]},defaultGroup:{string:"string"},sort:{boolean:cc},sampling:{boolean:cc},stack:{boolean:cc},graphHeight:{string:"string",number:"number"},shaded:{enabled:{boolean:cc},orientation:{string:["bottom","top","zero","group"]},groupId:{object:"object"},__type__:{boolean:cc,object:"object"}},style:{string:["line","bar","points"]},barChart:{width:{number:"number"},minWidth:{number:"number"},sideBySide:{boolean:cc},align:{string:["left","center","right"]},__type__:{object:"object"}},interpolation:{enabled:{boolean:cc},parametrization:{string:["centripetal","chordal","uniform"]},alpha:{number:"number"},__type__:{object:"object",boolean:cc}},drawPoints:{enabled:{boolean:cc},onRender:{function:"function"},size:{number:"number"},style:{string:["square","circle"]},__type__:{object:"object",boolean:cc,function:"function"}},dataAxis:{showMinorLabels:{boolean:cc},showMajorLabels:{boolean:cc},icons:{boolean:cc},width:{string:"string",number:"number"},visible:{boolean:cc},alignZeros:{boolean:cc},left:{range:{min:{number:"number",undefined:"undefined"},max:{number:"number",undefined:"undefined"},__type__:{object:"object"}},format:{function:"function"},title:{text:{string:"string",number:"number",undefined:"undefined"},style:{string:"string",undefined:"undefined"},__type__:{object:"object"}},__type__:{object:"object"}},right:{range:{min:{number:"number",undefined:"undefined"},max:{number:"number",undefined:"undefined"},__type__:{object:"object"}},format:{function:"function"},title:{text:{string:"string",number:"number",undefined:"undefined"},style:{string:"string",undefined:"undefined"},__type__:{object:"object"}},__type__:{object:"object"}},__type__:{object:"object"}},legend:{enabled:{boolean:cc},icons:{boolean:cc},left:{visible:{boolean:cc},position:{string:["top-right","bottom-right","top-left","bottom-left"]},__type__:{object:"object"}},right:{visible:{boolean:cc},position:{string:["top-right","bottom-right","top-left","bottom-left"]},__type__:{object:"object"}},__type__:{object:"object",boolean:cc}},groups:{visibility:{any:"any"},__type__:{object:"object"}},autoResize:{boolean:cc},throttleRedraw:{number:"number"},clickToUse:{boolean:cc},end:{number:"number",date:"date",string:"string",moment:"moment"},format:{minorLabels:{millisecond:{string:"string",undefined:"undefined"},second:{string:"string",undefined:"undefined"},minute:{string:"string",undefined:"undefined"},hour:{string:"string",undefined:"undefined"},weekday:{string:"string",undefined:"undefined"},day:{string:"string",undefined:"undefined"},week:{string:"string",undefined:"undefined"},month:{string:"string",undefined:"undefined"},quarter:{string:"string",undefined:"undefined"},year:{string:"string",undefined:"undefined"},__type__:{object:"object"}},majorLabels:{millisecond:{string:"string",undefined:"undefined"},second:{string:"string",undefined:"undefined"},minute:{string:"string",undefined:"undefined"},hour:{string:"string",undefined:"undefined"},weekday:{string:"string",undefined:"undefined"},day:{string:"string",undefined:"undefined"},week:{string:"string",undefined:"undefined"},month:{string:"string",undefined:"undefined"},quarter:{string:"string",undefined:"undefined"},year:{string:"string",undefined:"undefined"},__type__:{object:"object"}},__type__:{object:"object"}},moment:{function:"function"},height:{string:"string",number:"number"},hiddenDates:{start:{date:"date",number:"number",string:"string",moment:"moment"},end:{date:"date",number:"number",string:"string",moment:"moment"},repeat:{string:"string"},__type__:{object:"object",array:"array"}},locale:{string:"string"},locales:{__any__:{any:"any"},__type__:{object:"object"}},max:{date:"date",number:"number",string:"string",moment:"moment"},maxHeight:{number:"number",string:"string"},maxMinorChars:{number:"number"},min:{date:"date",number:"number",string:"string",moment:"moment"},minHeight:{number:"number",string:"string"},moveable:{boolean:cc},multiselect:{boolean:cc},orientation:{string:"string"},showCurrentTime:{boolean:cc},showMajorLabels:{boolean:cc},showMinorLabels:{boolean:cc},start:{date:"date",number:"number",string:"string",moment:"moment"},timeAxis:{scale:{string:"string",undefined:"undefined"},step:{number:"number",undefined:"undefined"},__type__:{object:"object"}},width:{string:"string",number:"number"},zoomable:{boolean:cc},zoomKey:{string:["ctrlKey","altKey","metaKey",""]},zoomMax:{number:"number"},zoomMin:{number:"number"},zIndex:{number:"number"},__type__:{object:"object"}},mc={global:{alignCurrentTime:["none","year","month","quarter","week","isoWeek","day","date","hour","minute","second"],sort:!0,sampling:!0,stack:!1,shaded:{enabled:!1,orientation:["zero","top","bottom","group"]},style:["line","bar","points"],barChart:{width:[50,5,100,5],minWidth:[50,5,100,5],sideBySide:!1,align:["left","center","right"]},interpolation:{enabled:!0,parametrization:["centripetal","chordal","uniform"]},drawPoints:{enabled:!0,size:[6,2,30,1],style:["square","circle"]},dataAxis:{showMinorLabels:!0,showMajorLabels:!0,icons:!1,width:[40,0,200,1],visible:!0,alignZeros:!0,left:{title:{text:"",style:""}},right:{title:{text:"",style:""}}},legend:{enabled:!1,icons:!0,left:{visible:!0,position:["top-right","bottom-right","top-left","bottom-left"]},right:{visible:!0,position:["top-right","bottom-right","top-left","bottom-left"]}},autoResize:!0,clickToUse:!1,end:"",format:{minorLabels:{millisecond:"SSS",second:"s",minute:"HH:mm",hour:"HH:mm",weekday:"ddd D",day:"D",week:"w",month:"MMM",quarter:"[Q]Q",year:"YYYY"},majorLabels:{millisecond:"HH:mm:ss",second:"D MMMM HH:mm",minute:"ddd D MMMM",hour:"ddd D MMMM",weekday:"MMMM YYYY",day:"MMMM YYYY",week:"MMMM YYYY",month:"YYYY",quarter:"YYYY",year:""}},height:"",locale:"",max:"",maxHeight:"",maxMinorChars:[7,0,20,1],min:"",minHeight:"",moveable:!0,orientation:["both","bottom","top"],showCurrentTime:!1,showMajorLabels:!0,showMinorLabels:!0,start:"",width:"100%",zoomable:!0,zoomKey:["ctrlKey","altKey","metaKey",""],zoomMax:[31536e10,10,31536e10,1],zoomMin:[10,10,31536e10,1],zIndex:0}};function pc(t,e,i,n){var s,r,o,a,l,h,u;if(!(ks(i)||i instanceof we||i instanceof ke)&&i instanceof Object){var d=n;n=i,i=d}n&&n.throttleRedraw&&console.warn('Graph2d option "throttleRedraw" is DEPRICATED and no longer supported. It will be removed in the next MAJOR release.');var c=this;this.defaultOptions={start:null,end:null,autoResize:!0,orientation:{axis:"bottom",item:"bottom"},moment:Hr,width:null,height:null,maxHeight:null,minHeight:null},this.options=to.deepExtend({},this.defaultOptions),this._create(t),this.components=[],this.body={dom:this.dom,domProps:this.props,emitter:{on:bs(s=this.on).call(s,this),off:bs(r=this.off).call(r,this),emit:bs(o=this.emit).call(o,this)},hiddenDates:[],util:{toScreen:bs(a=c._toScreen).call(a,c),toGlobalScreen:bs(l=c._toGlobalScreen).call(l,c),toTime:bs(h=c._toTime).call(h,c),toGlobalTime:bs(u=c._toGlobalTime).call(u,c)}},this.range=new Uo(this.body),this.components.push(this.range),this.body.range=this.range,this.timeAxis=new Th(this.body),this.components.push(this.timeAxis),this.currentTime=new zh(this.body),this.components.push(this.currentTime),this.linegraph=new dc(this.body),this.components.push(this.linegraph),this.itemsData=null,this.groupsData=null,this.on("tap",(function(t){c.emit("click",c.getEventProperties(t))})),this.on("doubletap",(function(t){c.emit("doubleClick",c.getEventProperties(t))})),this.dom.root.oncontextmenu=function(t){c.emit("contextmenu",c.getEventProperties(t))},this.initialFitDone=!1,this.on("changed",(function(){if(null!=c.itemsData){if(!c.initialFitDone&&!c.options.rollingMode)if(c.initialFitDone=!0,null!=c.options.start||null!=c.options.end){if(null==c.options.start||null==c.options.end)var t=c.getItemRange();var e=null!=c.options.start?c.options.start:t.min,i=null!=c.options.end?c.options.end:t.max;c.setWindow(e,i,{animation:!1})}else c.fit({animation:!1});c.initialDrawDone||!c.initialRangeChangeDone&&(c.options.start||c.options.end)&&!c.options.rollingMode||(c.initialDrawDone=!0,c.dom.root.style.visibility="visible",c.dom.loadingScreen.parentNode.removeChild(c.dom.loadingScreen),c.options.onInitialDrawComplete&&fs((function(){return c.options.onInitialDrawComplete()}),0))}})),n&&this.setOptions(n),i&&this.setGroups(i),e&&this.setItems(e),this._redraw()}pc.prototype=new Wh,pc.prototype.setOptions=function(t){!0===Hd.validate(t,fc)&&console.log("%cErrors have been found in the supplied options object.",Fd),Wh.prototype.setOptions.call(this,t)},pc.prototype.setItems=function(t){var e,i=null==this.itemsData;if(e=t?t instanceof we||t instanceof ke?t:new we(t,{type:{start:"Date",end:"Date"}}):null,this.itemsData=e,this.linegraph&&this.linegraph.setItems(e),i)if(null!=this.options.start||null!=this.options.end){var n=null!=this.options.start?this.options.start:null,s=null!=this.options.end?this.options.end:null;this.setWindow(n,s,{animation:!1})}else this.fit({animation:!1})},pc.prototype.setGroups=function(t){var e;e=t?t instanceof we||t instanceof ke?t:new we(t):null,this.groupsData=e,this.linegraph.setGroups(e)},pc.prototype.getLegend=function(t,e,i){return void 0===e&&(e=15),void 0===i&&(i=15),void 0!==this.linegraph.groups[t]?this.linegraph.groups[t].getLegend(e,i):"cannot find group:'"+t+"'"},pc.prototype.isGroupVisible=function(t){return void 0!==this.linegraph.groups[t]&&(this.linegraph.groups[t].visible&&(void 0===this.linegraph.options.groups.visibility[t]||1==this.linegraph.options.groups.visibility[t]))},pc.prototype.getDataRange=function(){var t=null,e=null;for(var i in this.linegraph.groups)if(this.linegraph.groups.hasOwnProperty(i)&&1==this.linegraph.groups[i].visible)for(var n=0;n<this.linegraph.groups[i].itemsData.length;n++){var s=this.linegraph.groups[i].itemsData[n],r=to.convert(s.x,"Date").valueOf();t=null==t?r:t>r?r:t,e=null==e?r:e<r?r:e}return{min:null!=t?new Date(t):null,max:null!=e?new Date(e):null}},pc.prototype.getEventProperties=function(t){var e=t.center?t.center.x:t.clientX,i=t.center?t.center.y:t.clientY,n=e-to.getAbsoluteLeft(this.dom.centerContainer),s=i-to.getAbsoluteTop(this.dom.centerContainer),r=this._toTime(n),o=Gh.customTimeFromTarget(t),a=to.getTarget(t),l=null;to.hasParent(a,this.timeAxis.dom.foreground)?l="axis":this.timeAxis2&&to.hasParent(a,this.timeAxis2.dom.foreground)?l="axis":to.hasParent(a,this.linegraph.yAxisLeft.dom.frame)?l="data-axis":to.hasParent(a,this.linegraph.yAxisRight.dom.frame)?l="data-axis":to.hasParent(a,this.linegraph.legendLeft.dom.frame)?l="legend":to.hasParent(a,this.linegraph.legendRight.dom.frame)?l="legend":null!=o?l="custom-time":to.hasParent(a,this.currentTime.bar)?l="current-time":to.hasParent(a,this.dom.center)&&(l="background");var h=[],u=this.linegraph.yAxisLeft,d=this.linegraph.yAxisRight;return!u.hidden&&this.itemsData.length>0&&h.push(u.screenToValue(s)),!d.hidden&&this.itemsData.length>0&&h.push(d.screenToValue(s)),{event:t,customTime:o?o.options.id:null,what:l,pageX:t.srcEvent?t.srcEvent.pageX:t.pageX,pageY:t.srcEvent?t.srcEvent.pageY:t.pageY,x:n,y:s,time:r,value:h}},pc.prototype._createConfigurator=function(){return new Kd(this,this.dom.container,mc)};var gc=Et();Hr.locale(gc);var vc={Core:Wh,DateUtil:zo,Range:Uo,stack:hd,TimeStep:Mh,components:{items:{Item:fd,BackgroundItem:vd,BoxItem:md,PointItem:pd,RangeItem:gd},BackgroundGroup:cd,Component:yo,CurrentTime:zh,CustomTime:Gh,DataAxis:sc,DataScale:nc,GraphGroup:hc,Group:dd,ItemSet:Nd,Legend:uc,LineGraph:dc,TimeAxis:Th}},yc={util:Dt,DOMutil:Lt,DataSet:we,DataView:ke,Queue:me,Timeline:Qd,Graph2d:pc,timeline:vc,moment:Hr,Hammer:_h,keycharm:Ch};t.DOMutil=Lt,t.DataSet=we,t.DataView=ke,t.Graph2d=pc,t.Hammer=_h,t.Queue=me,t.Timeline=Qd,t.default=yc,t.keycharm=Ch,t.moment=Hr,t.timeline=vc,t.util=Dt,Object.defineProperty(t,"__esModule",{value:!0})}));
|