Du kannst nicht mehr als 25 Themen auswählen Themen müssen entweder mit einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.
 
 
 
 

36 Zeilen
1.0 MiB

(window.webpackJsonp=window.webpackJsonp||[]).push([[0],[,,,function(e,t,n){(function(e){e.exports=function(){"use strict";var t,o;function r(){return t.apply(null,arguments)}function i(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function a(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function s(e,t){var n,o=[];for(n=0;n<e.length;++n)o.push(t(e[n],n));return o}function l(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function u(e,t){for(var n in t)l(t,n)&&(e[n]=t[n]);return l(t,"toString")&&(e.toString=t.toString),l(t,"valueOf")&&(e.valueOf=t.valueOf),e}function c(e,t,n,o){return ht(e,t,n,o,!0).utc()}function d(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],meridiem:null}),e._pf}function h(e){if(null==e._isValid){var t=d(e),n=o.call(t.parsedDateParts,function(e){return null!=e});e._isValid=!isNaN(e._d.getTime())&&t.overflow<0&&!t.empty&&!t.invalidMonth&&!t.invalidWeekday&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n),e._strict&&(e._isValid=e._isValid&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour)}return e._isValid}function f(e){var t=c(NaN);return null!=e?u(d(t),e):d(t).userInvalidated=!0,t}function p(e){return void 0===e}o=Array.prototype.some?Array.prototype.some:function(e){for(var t=Object(this),n=t.length>>>0,o=0;o<n;o++)if(o in t&&e.call(this,t[o],o,t))return!0;return!1};var m=r.momentProperties=[];function g(e,t){var n,o,r;if(p(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),p(t._i)||(e._i=t._i),p(t._f)||(e._f=t._f),p(t._l)||(e._l=t._l),p(t._strict)||(e._strict=t._strict),p(t._tzm)||(e._tzm=t._tzm),p(t._isUTC)||(e._isUTC=t._isUTC),p(t._offset)||(e._offset=t._offset),p(t._pf)||(e._pf=d(t)),p(t._locale)||(e._locale=t._locale),m.length>0)for(n in m)p(r=t[o=m[n]])||(e[o]=r);return e}var v=!1;function y(e){g(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),!1===v&&(v=!0,r.updateOffset(this),v=!1)}function _(e){return e instanceof y||null!=e&&null!=e._isAMomentObject}function w(e){return e<0?Math.ceil(e):Math.floor(e)}function b(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=w(t)),n}function C(e,t,n){var o,r=Math.min(e.length,t.length),i=Math.abs(e.length-t.length),a=0;for(o=0;o<r;o++)(n&&e[o]!==t[o]||!n&&b(e[o])!==b(t[o]))&&a++;return a+i}function M(e){!1===r.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function k(e,t){var n=!0;return u(function(){return null!=r.deprecationHandler&&r.deprecationHandler(null,e),n&&(M(e+"\nArguments: "+Array.prototype.slice.call(arguments).join(", ")+"\n"+(new Error).stack),n=!1),t.apply(this,arguments)},t)}var S,T={};function L(e,t){null!=r.deprecationHandler&&r.deprecationHandler(e,t),T[e]||(M(t),T[e]=!0)}function x(e){return e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function D(e){return"[object Object]"===Object.prototype.toString.call(e)}function O(e,t){var n,o=u({},e);for(n in t)l(t,n)&&(D(e[n])&&D(t[n])?(o[n]={},u(o[n],e[n]),u(o[n],t[n])):null!=t[n]?o[n]=t[n]:delete o[n]);return o}function E(e){null!=e&&this.set(e)}r.suppressDeprecationWarnings=!1,r.deprecationHandler=null,S=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)l(e,t)&&n.push(t);return n};var R,A={};function H(e){return e?e.toLowerCase().replace("_","-"):e}function Y(t){var o=null;if(!A[t]&&void 0!==e&&e&&e.exports)try{o=R._abbr,n(407)("./"+t),P(o)}catch(e){}return A[t]}function P(e,t){var n;return e&&(n=p(t)?I(e):N(e,t))&&(R=n),R._abbr}function N(e,t){return null!==t?(t.abbr=e,null!=A[e]?(L("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale"),t=O(A[e]._config,t)):null!=t.parentLocale&&(null!=A[t.parentLocale]?t=O(A[t.parentLocale]._config,t):L("parentLocaleUndefined","specified parentLocale is not defined yet")),A[e]=new E(t),P(e),A[e]):(delete A[e],null)}function I(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return R;if(!i(e)){if(t=Y(e))return t;e=[e]}return function(e){for(var t,n,o,r,i=0;i<e.length;){for(t=(r=H(e[i]).split("-")).length,n=(n=H(e[i+1]))?n.split("-"):null;t>0;){if(o=Y(r.slice(0,t).join("-")))return o;if(n&&n.length>=t&&C(r,n,!0)>=t-1)break;t--}i++}return null}(e)}var W={};function j(e,t){var n=e.toLowerCase();W[n]=W[n+"s"]=W[t]=e}function F(e){return"string"==typeof e?W[e]||W[e.toLowerCase()]:void 0}function z(e){var t,n,o={};for(n in e)l(e,n)&&(t=F(n))&&(o[t]=e[n]);return o}function B(e,t){return function(n){return null!=n?(U(this,e,n),r.updateOffset(this,t),this):V(this,e)}}function V(e,t){return e.isValid()?e._d["get"+(e._isUTC?"UTC":"")+t]():NaN}function U(e,t,n){e.isValid()&&e._d["set"+(e._isUTC?"UTC":"")+t](n)}function K(e,t){var n;if("object"==typeof e)for(n in e)this.set(n,e[n]);else if(x(this[e=F(e)]))return this[e](t);return this}function G(e,t,n){var o=""+Math.abs(e),r=t-o.length;return(e>=0?n?"+":"":"-")+Math.pow(10,Math.max(0,r)).toString().substr(1)+o}var X=/(\[[^\[]*\])|(\\)?([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,J=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,q={},Q={};function $(e,t,n,o){var r=o;"string"==typeof o&&(r=function(){return this[o]()}),e&&(Q[e]=r),t&&(Q[t[0]]=function(){return G(r.apply(this,arguments),t[1],t[2])}),n&&(Q[n]=function(){return this.localeData().ordinal(r.apply(this,arguments),e)})}function Z(e,t){return e.isValid()?(t=ee(t,e.localeData()),q[t]=q[t]||function(e){var t,n,o,r=e.match(X);for(t=0,n=r.length;t<n;t++)Q[r[t]]?r[t]=Q[r[t]]:r[t]=(o=r[t]).match(/\[[\s\S]/)?o.replace(/^\[|\]$/g,""):o.replace(/\\/g,"");return function(t){var o,i="";for(o=0;o<n;o++)i+=r[o]instanceof Function?r[o].call(t,e):r[o];return i}}(t),q[t](e)):e.localeData().invalidDate()}function ee(e,t){var n=5;function o(e){return t.longDateFormat(e)||e}for(J.lastIndex=0;n>=0&&J.test(e);)e=e.replace(J,o),J.lastIndex=0,n-=1;return e}var te=/\d/,ne=/\d\d/,oe=/\d{3}/,re=/\d{4}/,ie=/[+-]?\d{6}/,ae=/\d\d?/,se=/\d\d\d\d?/,le=/\d\d\d\d\d\d?/,ue=/\d{1,3}/,ce=/\d{1,4}/,de=/[+-]?\d{1,6}/,he=/\d+/,fe=/[+-]?\d+/,pe=/Z|[+-]\d\d:?\d\d/gi,me=/Z|[+-]\d\d(?::?\d\d)?/gi,ge=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF\/]+(\s*?[\u0600-\u06FF]+){1,2}/i,ve={};function ye(e,t,n){ve[e]=x(t)?t:function(e,o){return e&&n?n:t}}function _e(e,t){return l(ve,e)?ve[e](t._strict,t._locale):new RegExp(we(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,function(e,t,n,o,r){return t||n||o||r})))}function we(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}var be={};function Ce(e,t){var n,o=t;for("string"==typeof e&&(e=[e]),"number"==typeof t&&(o=function(e,n){n[t]=b(e)}),n=0;n<e.length;n++)be[e[n]]=o}function Me(e,t){Ce(e,function(e,n,o,r){o._w=o._w||{},t(e,o._w,o,r)})}function ke(e,t,n){null!=t&&l(be,e)&&be[e](t,n._a,n,e)}var Se,Te=0,Le=1,xe=2,De=3,Oe=4,Ee=5,Re=6,Ae=7,He=8;function Ye(e,t){return new Date(Date.UTC(e,t+1,0)).getUTCDate()}Se=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},$("M",["MM",2],"Mo",function(){return this.month()+1}),$("MMM",0,0,function(e){return this.localeData().monthsShort(this,e)}),$("MMMM",0,0,function(e){return this.localeData().months(this,e)}),j("month","M"),ye("M",ae),ye("MM",ae,ne),ye("MMM",function(e,t){return t.monthsShortRegex(e)}),ye("MMMM",function(e,t){return t.monthsRegex(e)}),Ce(["M","MM"],function(e,t){t[Le]=b(e)-1}),Ce(["MMM","MMMM"],function(e,t,n,o){var r=n._locale.monthsParse(e,o,n._strict);null!=r?t[Le]=r:d(n).invalidMonth=e});var Pe=/D[oD]?(\[[^\[\]]*\]|\s+)+MMMM?/,Ne="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),Ie="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_");function We(e,t,n){var o,r,i,a=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],o=0;o<12;++o)i=c([2e3,o]),this._shortMonthsParse[o]=this.monthsShort(i,"").toLocaleLowerCase(),this._longMonthsParse[o]=this.months(i,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(r=Se.call(this._shortMonthsParse,a))?r:null:-1!==(r=Se.call(this._longMonthsParse,a))?r:null:"MMM"===t?-1!==(r=Se.call(this._shortMonthsParse,a))?r:-1!==(r=Se.call(this._longMonthsParse,a))?r:null:-1!==(r=Se.call(this._longMonthsParse,a))?r:-1!==(r=Se.call(this._shortMonthsParse,a))?r:null}function je(e,t){var n;if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=b(t);else if("number"!=typeof(t=e.localeData().monthsParse(t)))return e;return n=Math.min(e.date(),Ye(e.year(),t)),e._d["set"+(e._isUTC?"UTC":"")+"Month"](t,n),e}function Fe(e){return null!=e?(je(this,e),r.updateOffset(this,!0),this):V(this,"Month")}var ze=ge,Be=ge;function Ve(){function e(e,t){return t.length-e.length}var t,n,o=[],r=[],i=[];for(t=0;t<12;t++)n=c([2e3,t]),o.push(this.monthsShort(n,"")),r.push(this.months(n,"")),i.push(this.months(n,"")),i.push(this.monthsShort(n,""));for(o.sort(e),r.sort(e),i.sort(e),t=0;t<12;t++)o[t]=we(o[t]),r[t]=we(r[t]),i[t]=we(i[t]);this._monthsRegex=new RegExp("^("+i.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+r.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+o.join("|")+")","i")}function Ue(e){var t,n=e._a;return n&&-2===d(e).overflow&&(t=n[Le]<0||n[Le]>11?Le:n[xe]<1||n[xe]>Ye(n[Te],n[Le])?xe:n[De]<0||n[De]>24||24===n[De]&&(0!==n[Oe]||0!==n[Ee]||0!==n[Re])?De:n[Oe]<0||n[Oe]>59?Oe:n[Ee]<0||n[Ee]>59?Ee:n[Re]<0||n[Re]>999?Re:-1,d(e)._overflowDayOfYear&&(t<Te||t>xe)&&(t=xe),d(e)._overflowWeeks&&-1===t&&(t=Ae),d(e)._overflowWeekday&&-1===t&&(t=He),d(e).overflow=t),e}var Ke=/^\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)?)?/,Ge=/^\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)?)?/,Xe=/Z|[+-]\d\d(?::?\d\d)?/,Je=[["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}/]],qe=[["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/]],Qe=/^\/?Date\((\-?\d+)/i;function $e(e){var t,n,o,r,i,a,s=e._i,l=Ke.exec(s)||Ge.exec(s);if(l){for(d(e).iso=!0,t=0,n=Je.length;t<n;t++)if(Je[t][1].exec(l[1])){r=Je[t][0],o=!1!==Je[t][2];break}if(null==r)return void(e._isValid=!1);if(l[3]){for(t=0,n=qe.length;t<n;t++)if(qe[t][1].exec(l[3])){i=(l[2]||" ")+qe[t][0];break}if(null==i)return void(e._isValid=!1)}if(!o&&null!=i)return void(e._isValid=!1);if(l[4]){if(!Xe.exec(l[4]))return void(e._isValid=!1);a="Z"}e._f=r+(i||"")+(a||""),ct(e)}else e._isValid=!1}function Ze(e,t,n,o,r,i,a){var s=new Date(e,t,n,o,r,i,a);return e<100&&e>=0&&isFinite(s.getFullYear())&&s.setFullYear(e),s}function et(e){var t=new Date(Date.UTC.apply(null,arguments));return e<100&&e>=0&&isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e),t}function tt(e){return nt(e)?366:365}function nt(e){return e%4==0&&e%100!=0||e%400==0}r.createFromInputFallback=k("moment construction falls back to js Date. This is discouraged and will be removed in upcoming major release. Please refer to https://github.com/moment/moment/issues/1407 for more info.",function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))}),$("Y",0,0,function(){var e=this.year();return e<=9999?""+e:"+"+e}),$(0,["YY",2],0,function(){return this.year()%100}),$(0,["YYYY",4],0,"year"),$(0,["YYYYY",5],0,"year"),$(0,["YYYYYY",6,!0],0,"year"),j("year","y"),ye("Y",fe),ye("YY",ae,ne),ye("YYYY",ce,re),ye("YYYYY",de,ie),ye("YYYYYY",de,ie),Ce(["YYYYY","YYYYYY"],Te),Ce("YYYY",function(e,t){t[Te]=2===e.length?r.parseTwoDigitYear(e):b(e)}),Ce("YY",function(e,t){t[Te]=r.parseTwoDigitYear(e)}),Ce("Y",function(e,t){t[Te]=parseInt(e,10)}),r.parseTwoDigitYear=function(e){return b(e)+(b(e)>68?1900:2e3)};var ot=B("FullYear",!0);function rt(e,t,n){var o=7+t-n;return-(7+et(e,0,o).getUTCDay()-t)%7+o-1}function it(e,t,n,o,r){var i,a,s=1+7*(t-1)+(7+n-o)%7+rt(e,o,r);return s<=0?a=tt(i=e-1)+s:s>tt(e)?(i=e+1,a=s-tt(e)):(i=e,a=s),{year:i,dayOfYear:a}}function at(e,t,n){var o,r,i=rt(e.year(),t,n),a=Math.floor((e.dayOfYear()-i-1)/7)+1;return a<1?o=a+st(r=e.year()-1,t,n):a>st(e.year(),t,n)?(o=a-st(e.year(),t,n),r=e.year()+1):(r=e.year(),o=a),{week:o,year:r}}function st(e,t,n){var o=rt(e,t,n),r=rt(e+1,t,n);return(tt(e)-o+r)/7}function lt(e,t,n){return null!=e?e:null!=t?t:n}function ut(e){var t,n,o,i,a=[];if(!e._d){for(o=function(e){var t=new Date(r.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}(e),e._w&&null==e._a[xe]&&null==e._a[Le]&&function(e){var t,n,o,r,i,a,s,l;null!=(t=e._w).GG||null!=t.W||null!=t.E?(i=1,a=4,n=lt(t.GG,e._a[Te],at(ft(),1,4).year),o=lt(t.W,1),((r=lt(t.E,1))<1||r>7)&&(l=!0)):(i=e._locale._week.dow,a=e._locale._week.doy,n=lt(t.gg,e._a[Te],at(ft(),i,a).year),o=lt(t.w,1),null!=t.d?((r=t.d)<0||r>6)&&(l=!0):null!=t.e?(r=t.e+i,(t.e<0||t.e>6)&&(l=!0)):r=i),o<1||o>st(n,i,a)?d(e)._overflowWeeks=!0:null!=l?d(e)._overflowWeekday=!0:(s=it(n,o,r,i,a),e._a[Te]=s.year,e._dayOfYear=s.dayOfYear)}(e),e._dayOfYear&&(i=lt(e._a[Te],o[Te]),e._dayOfYear>tt(i)&&(d(e)._overflowDayOfYear=!0),n=et(i,0,e._dayOfYear),e._a[Le]=n.getUTCMonth(),e._a[xe]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=a[t]=o[t];for(;t<7;t++)e._a[t]=a[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[De]&&0===e._a[Oe]&&0===e._a[Ee]&&0===e._a[Re]&&(e._nextDay=!0,e._a[De]=0),e._d=(e._useUTC?et:Ze).apply(null,a),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[De]=24)}}function ct(e){if(e._f!==r.ISO_8601){e._a=[],d(e).empty=!0;var t,n,o,i,a,s=""+e._i,l=s.length,u=0;for(o=ee(e._f,e._locale).match(X)||[],t=0;t<o.length;t++)i=o[t],(n=(s.match(_e(i,e))||[])[0])&&((a=s.substr(0,s.indexOf(n))).length>0&&d(e).unusedInput.push(a),s=s.slice(s.indexOf(n)+n.length),u+=n.length),Q[i]?(n?d(e).empty=!1:d(e).unusedTokens.push(i),ke(i,n,e)):e._strict&&!n&&d(e).unusedTokens.push(i);d(e).charsLeftOver=l-u,s.length>0&&d(e).unusedInput.push(s),!0===d(e).bigHour&&e._a[De]<=12&&e._a[De]>0&&(d(e).bigHour=void 0),d(e).parsedDateParts=e._a.slice(0),d(e).meridiem=e._meridiem,e._a[De]=function(e,t,n){var o;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((o=e.isPM(n))&&t<12&&(t+=12),o||12!==t||(t=0),t):t}(e._locale,e._a[De],e._meridiem),ut(e),Ue(e)}else $e(e)}function dt(e){var t=e._i,n=e._f;return e._locale=e._locale||I(e._l),null===t||void 0===n&&""===t?f({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),_(t)?new y(Ue(t)):(i(n)?function(e){var t,n,o,r,i;if(0===e._f.length)return d(e).invalidFormat=!0,void(e._d=new Date(NaN));for(r=0;r<e._f.length;r++)i=0,t=g({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[r],ct(t),h(t)&&(i+=d(t).charsLeftOver,i+=10*d(t).unusedTokens.length,d(t).score=i,(null==o||i<o)&&(o=i,n=t));u(e,n||t)}(e):n?ct(e):a(t)?e._d=t:function(e){var t=e._i;void 0===t?e._d=new Date(r.now()):a(t)?e._d=new Date(t.valueOf()):"string"==typeof t?function(e){var t=Qe.exec(e._i);null===t?($e(e),!1===e._isValid&&(delete e._isValid,r.createFromInputFallback(e))):e._d=new Date(+t[1])}(e):i(t)?(e._a=s(t.slice(0),function(e){return parseInt(e,10)}),ut(e)):"object"==typeof t?function(e){if(!e._d){var t=z(e._i);e._a=s([t.year,t.month,t.day||t.date,t.hour,t.minute,t.second,t.millisecond],function(e){return e&&parseInt(e,10)}),ut(e)}}(e):"number"==typeof t?e._d=new Date(t):r.createFromInputFallback(e)}(e),h(e)||(e._d=null),e))}function ht(e,t,n,o,r){var i,a={};return"boolean"==typeof n&&(o=n,n=void 0),a._isAMomentObject=!0,a._useUTC=a._isUTC=r,a._l=n,a._i=e,a._f=t,a._strict=o,(i=new y(Ue(dt(a))))._nextDay&&(i.add(1,"d"),i._nextDay=void 0),i}function ft(e,t,n,o){return ht(e,t,n,o,!1)}r.ISO_8601=function(){};var pt=k("moment().min is deprecated, use moment.max instead. https://github.com/moment/moment/issues/1548",function(){var e=ft.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:f()}),mt=k("moment().max is deprecated, use moment.min instead. https://github.com/moment/moment/issues/1548",function(){var e=ft.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:f()});function gt(e,t){var n,o;if(1===t.length&&i(t[0])&&(t=t[0]),!t.length)return ft();for(n=t[0],o=1;o<t.length;++o)t[o].isValid()&&!t[o][e](n)||(n=t[o]);return n}function vt(e){var t=z(e),n=t.year||0,o=t.quarter||0,r=t.month||0,i=t.week||0,a=t.day||0,s=t.hour||0,l=t.minute||0,u=t.second||0,c=t.millisecond||0;this._milliseconds=+c+1e3*u+6e4*l+1e3*s*60*60,this._days=+a+7*i,this._months=+r+3*o+12*n,this._data={},this._locale=I(),this._bubble()}function yt(e){return e instanceof vt}function _t(e,t){$(e,0,0,function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+G(~~(e/60),2)+t+G(~~e%60,2)})}_t("Z",":"),_t("ZZ",""),ye("Z",me),ye("ZZ",me),Ce(["Z","ZZ"],function(e,t,n){n._useUTC=!0,n._tzm=bt(me,e)});var wt=/([\+\-]|\d\d)/gi;function bt(e,t){var n=(t||"").match(e)||[],o=((n[n.length-1]||[])+"").match(wt)||["-",0,0],r=60*o[1]+b(o[2]);return"+"===o[0]?r:-r}function Ct(e,t){var n,o;return t._isUTC?(n=t.clone(),o=(_(e)||a(e)?e.valueOf():ft(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+o),r.updateOffset(n,!1),n):ft(e).local()}function Mt(e){return 15*-Math.round(e._d.getTimezoneOffset()/15)}function kt(){return!!this.isValid()&&this._isUTC&&0===this._offset}r.updateOffset=function(){};var St=/^(\-)?(?:(\d*)[. ])?(\d+)\:(\d+)(?:\:(\d+)\.?(\d{3})?\d*)?$/,Tt=/^(-)?P(?:(-?[0-9,.]*)Y)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)W)?(?:(-?[0-9,.]*)D)?(?:T(?:(-?[0-9,.]*)H)?(?:(-?[0-9,.]*)M)?(?:(-?[0-9,.]*)S)?)?$/;function Lt(e,t){var n,o,r,i,a,s,u=e,c=null;return yt(e)?u={ms:e._milliseconds,d:e._days,M:e._months}:"number"==typeof e?(u={},t?u[t]=e:u.milliseconds=e):(c=St.exec(e))?(n="-"===c[1]?-1:1,u={y:0,d:b(c[xe])*n,h:b(c[De])*n,m:b(c[Oe])*n,s:b(c[Ee])*n,ms:b(c[Re])*n}):(c=Tt.exec(e))?(n="-"===c[1]?-1:1,u={y:xt(c[2],n),M:xt(c[3],n),w:xt(c[4],n),d:xt(c[5],n),h:xt(c[6],n),m:xt(c[7],n),s:xt(c[8],n)}):null==u?u={}:"object"==typeof u&&("from"in u||"to"in u)&&(i=ft(u.from),a=ft(u.to),r=i.isValid()&&a.isValid()?(a=Ct(a,i),i.isBefore(a)?s=Dt(i,a):((s=Dt(a,i)).milliseconds=-s.milliseconds,s.months=-s.months),s):{milliseconds:0,months:0},(u={}).ms=r.milliseconds,u.M=r.months),o=new vt(u),yt(e)&&l(e,"_locale")&&(o._locale=e._locale),o}function xt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Dt(e,t){var n={milliseconds:0,months:0};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function Ot(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function Et(e,t){return function(n,o){var r;return null===o||isNaN(+o)||(L(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period)."),r=n,n=o,o=r),Rt(this,Lt(n="string"==typeof n?+n:n,o),e),this}}function Rt(e,t,n,o){var i=t._milliseconds,a=Ot(t._days),s=Ot(t._months);e.isValid()&&(o=null==o||o,i&&e._d.setTime(e._d.valueOf()+i*n),a&&U(e,"Date",V(e,"Date")+a*n),s&&je(e,V(e,"Month")+s*n),o&&r.updateOffset(e,a||s))}Lt.fn=vt.prototype;var At=Et(1,"add"),Ht=Et(-1,"subtract");function Yt(e){var t;return void 0===e?this._locale._abbr:(null!=(t=I(e))&&(this._locale=t),this)}r.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",r.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var Pt=k("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",function(e){return void 0===e?this.localeData():this.locale(e)});function Nt(){return this._locale}function It(e,t){$(0,[e,e.length],0,t)}function Wt(e,t,n,o,r){var i;return null==e?at(this,o,r).year:(t>(i=st(e,o,r))&&(t=i),jt.call(this,e,t,n,o,r))}function jt(e,t,n,o,r){var i=it(e,t,n,o,r),a=et(i.year,0,i.dayOfYear);return this.year(a.getUTCFullYear()),this.month(a.getUTCMonth()),this.date(a.getUTCDate()),this}$(0,["gg",2],0,function(){return this.weekYear()%100}),$(0,["GG",2],0,function(){return this.isoWeekYear()%100}),It("gggg","weekYear"),It("ggggg","weekYear"),It("GGGG","isoWeekYear"),It("GGGGG","isoWeekYear"),j("weekYear","gg"),j("isoWeekYear","GG"),ye("G",fe),ye("g",fe),ye("GG",ae,ne),ye("gg",ae,ne),ye("GGGG",ce,re),ye("gggg",ce,re),ye("GGGGG",de,ie),ye("ggggg",de,ie),Me(["gggg","ggggg","GGGG","GGGGG"],function(e,t,n,o){t[o.substr(0,2)]=b(e)}),Me(["gg","GG"],function(e,t,n,o){t[o]=r.parseTwoDigitYear(e)}),$("Q",0,"Qo","quarter"),j("quarter","Q"),ye("Q",te),Ce("Q",function(e,t){t[Le]=3*(b(e)-1)}),$("w",["ww",2],"wo","week"),$("W",["WW",2],"Wo","isoWeek"),j("week","w"),j("isoWeek","W"),ye("w",ae),ye("ww",ae,ne),ye("W",ae),ye("WW",ae,ne),Me(["w","ww","W","WW"],function(e,t,n,o){t[o.substr(0,1)]=b(e)}),$("D",["DD",2],"Do","date"),j("date","D"),ye("D",ae),ye("DD",ae,ne),ye("Do",function(e,t){return e?t._ordinalParse:t._ordinalParseLenient}),Ce(["D","DD"],xe),Ce("Do",function(e,t){t[xe]=b(e.match(ae)[0])});var Ft=B("Date",!0);$("d",0,"do","day"),$("dd",0,0,function(e){return this.localeData().weekdaysMin(this,e)}),$("ddd",0,0,function(e){return this.localeData().weekdaysShort(this,e)}),$("dddd",0,0,function(e){return this.localeData().weekdays(this,e)}),$("e",0,0,"weekday"),$("E",0,0,"isoWeekday"),j("day","d"),j("weekday","e"),j("isoWeekday","E"),ye("d",ae),ye("e",ae),ye("E",ae),ye("dd",function(e,t){return t.weekdaysMinRegex(e)}),ye("ddd",function(e,t){return t.weekdaysShortRegex(e)}),ye("dddd",function(e,t){return t.weekdaysRegex(e)}),Me(["dd","ddd","dddd"],function(e,t,n,o){var r=n._locale.weekdaysParse(e,o,n._strict);null!=r?t.d=r:d(n).invalidWeekday=e}),Me(["d","e","E"],function(e,t,n,o){t[o]=b(e)});var zt="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Bt="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Vt="Su_Mo_Tu_We_Th_Fr_Sa".split("_");function Ut(e,t,n){var o,r,i,a=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],o=0;o<7;++o)i=c([2e3,1]).day(o),this._minWeekdaysParse[o]=this.weekdaysMin(i,"").toLocaleLowerCase(),this._shortWeekdaysParse[o]=this.weekdaysShort(i,"").toLocaleLowerCase(),this._weekdaysParse[o]=this.weekdays(i,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(r=Se.call(this._weekdaysParse,a))?r:null:"ddd"===t?-1!==(r=Se.call(this._shortWeekdaysParse,a))?r:null:-1!==(r=Se.call(this._minWeekdaysParse,a))?r:null:"dddd"===t?-1!==(r=Se.call(this._weekdaysParse,a))?r:-1!==(r=Se.call(this._shortWeekdaysParse,a))?r:-1!==(r=Se.call(this._minWeekdaysParse,a))?r:null:"ddd"===t?-1!==(r=Se.call(this._shortWeekdaysParse,a))?r:-1!==(r=Se.call(this._weekdaysParse,a))?r:-1!==(r=Se.call(this._minWeekdaysParse,a))?r:null:-1!==(r=Se.call(this._minWeekdaysParse,a))?r:-1!==(r=Se.call(this._weekdaysParse,a))?r:-1!==(r=Se.call(this._shortWeekdaysParse,a))?r:null}var Kt=ge,Gt=ge,Xt=ge;function Jt(){function e(e,t){return t.length-e.length}var t,n,o,r,i,a=[],s=[],l=[],u=[];for(t=0;t<7;t++)n=c([2e3,1]).day(t),o=this.weekdaysMin(n,""),r=this.weekdaysShort(n,""),i=this.weekdays(n,""),a.push(o),s.push(r),l.push(i),u.push(o),u.push(r),u.push(i);for(a.sort(e),s.sort(e),l.sort(e),u.sort(e),t=0;t<7;t++)s[t]=we(s[t]),l[t]=we(l[t]),u[t]=we(u[t]);this._weekdaysRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+l.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+a.join("|")+")","i")}function qt(){return this.hours()%12||12}function Qt(e,t){$(e,0,0,function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)})}function $t(e,t){return t._meridiemParse}$("DDD",["DDDD",3],"DDDo","dayOfYear"),j("dayOfYear","DDD"),ye("DDD",ue),ye("DDDD",oe),Ce(["DDD","DDDD"],function(e,t,n){n._dayOfYear=b(e)}),$("H",["HH",2],0,"hour"),$("h",["hh",2],0,qt),$("k",["kk",2],0,function(){return this.hours()||24}),$("hmm",0,0,function(){return""+qt.apply(this)+G(this.minutes(),2)}),$("hmmss",0,0,function(){return""+qt.apply(this)+G(this.minutes(),2)+G(this.seconds(),2)}),$("Hmm",0,0,function(){return""+this.hours()+G(this.minutes(),2)}),$("Hmmss",0,0,function(){return""+this.hours()+G(this.minutes(),2)+G(this.seconds(),2)}),Qt("a",!0),Qt("A",!1),j("hour","h"),ye("a",$t),ye("A",$t),ye("H",ae),ye("h",ae),ye("HH",ae,ne),ye("hh",ae,ne),ye("hmm",se),ye("hmmss",le),ye("Hmm",se),ye("Hmmss",le),Ce(["H","HH"],De),Ce(["a","A"],function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e}),Ce(["h","hh"],function(e,t,n){t[De]=b(e),d(n).bigHour=!0}),Ce("hmm",function(e,t,n){var o=e.length-2;t[De]=b(e.substr(0,o)),t[Oe]=b(e.substr(o)),d(n).bigHour=!0}),Ce("hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[De]=b(e.substr(0,o)),t[Oe]=b(e.substr(o,2)),t[Ee]=b(e.substr(r)),d(n).bigHour=!0}),Ce("Hmm",function(e,t,n){var o=e.length-2;t[De]=b(e.substr(0,o)),t[Oe]=b(e.substr(o))}),Ce("Hmmss",function(e,t,n){var o=e.length-4,r=e.length-2;t[De]=b(e.substr(0,o)),t[Oe]=b(e.substr(o,2)),t[Ee]=b(e.substr(r))});var Zt=B("Hours",!0);$("m",["mm",2],0,"minute"),j("minute","m"),ye("m",ae),ye("mm",ae,ne),Ce(["m","mm"],Oe);var en=B("Minutes",!1);$("s",["ss",2],0,"second"),j("second","s"),ye("s",ae),ye("ss",ae,ne),Ce(["s","ss"],Ee);var tn,nn=B("Seconds",!1);for($("S",0,0,function(){return~~(this.millisecond()/100)}),$(0,["SS",2],0,function(){return~~(this.millisecond()/10)}),$(0,["SSS",3],0,"millisecond"),$(0,["SSSS",4],0,function(){return 10*this.millisecond()}),$(0,["SSSSS",5],0,function(){return 100*this.millisecond()}),$(0,["SSSSSS",6],0,function(){return 1e3*this.millisecond()}),$(0,["SSSSSSS",7],0,function(){return 1e4*this.millisecond()}),$(0,["SSSSSSSS",8],0,function(){return 1e5*this.millisecond()}),$(0,["SSSSSSSSS",9],0,function(){return 1e6*this.millisecond()}),j("millisecond","ms"),ye("S",ue,te),ye("SS",ue,ne),ye("SSS",ue,oe),tn="SSSS";tn.length<=9;tn+="S")ye(tn,he);function on(e,t){t[Re]=b(1e3*("0."+e))}for(tn="S";tn.length<=9;tn+="S")Ce(tn,on);var rn=B("Milliseconds",!1);$("z",0,0,"zoneAbbr"),$("zz",0,0,"zoneName");var an=y.prototype;an.add=At,an.calendar=function(e,t){var n=e||ft(),o=Ct(n,this).startOf("day"),r=this.diff(o,"days",!0),i=r<-6?"sameElse":r<-1?"lastWeek":r<0?"lastDay":r<1?"sameDay":r<2?"nextDay":r<7?"nextWeek":"sameElse",a=t&&(x(t[i])?t[i]():t[i]);return this.format(a||this.localeData().calendar(i,this,ft(n)))},an.clone=function(){return new y(this)},an.diff=function(e,t,n){var o,r,i,a,s,l,u,c,d,h;return this.isValid()&&(o=Ct(e,this)).isValid()?(r=6e4*(o.utcOffset()-this.utcOffset()),"year"===(t=F(t))||"month"===t||"quarter"===t?(s=this,d=12*((l=o).year()-s.year())+(l.month()-s.month()),h=s.clone().add(d,"months"),l-h<0?(u=s.clone().add(d-1,"months"),c=(l-h)/(h-u)):(u=s.clone().add(d+1,"months"),c=(l-h)/(u-h)),a=-(d+c)||0,"quarter"===t?a/=3:"year"===t&&(a/=12)):(i=this-o,a="second"===t?i/1e3:"minute"===t?i/6e4:"hour"===t?i/36e5:"day"===t?(i-r)/864e5:"week"===t?(i-r)/6048e5:i),n?a:w(a)):NaN},an.endOf=function(e){return void 0===(e=F(e))||"millisecond"===e?this:("date"===e&&(e="day"),this.startOf(e).add(1,"isoWeek"===e?"week":e).subtract(1,"ms"))},an.format=function(e){e||(e=this.isUtc()?r.defaultFormatUtc:r.defaultFormat);var t=Z(this,e);return this.localeData().postformat(t)},an.from=function(e,t){return this.isValid()&&(_(e)&&e.isValid()||ft(e).isValid())?Lt({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},an.fromNow=function(e){return this.from(ft(),e)},an.to=function(e,t){return this.isValid()&&(_(e)&&e.isValid()||ft(e).isValid())?Lt({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},an.toNow=function(e){return this.to(ft(),e)},an.get=K,an.invalidAt=function(){return d(this).overflow},an.isAfter=function(e,t){var n=_(e)?e:ft(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=F(p(t)?"millisecond":t))?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},an.isBefore=function(e,t){var n=_(e)?e:ft(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=F(p(t)?"millisecond":t))?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},an.isBetween=function(e,t,n,o){return("("===(o=o||"()")[0]?this.isAfter(e,n):!this.isBefore(e,n))&&(")"===o[1]?this.isBefore(t,n):!this.isAfter(t,n))},an.isSame=function(e,t){var n,o=_(e)?e:ft(e);return!(!this.isValid()||!o.isValid())&&("millisecond"===(t=F(t||"millisecond"))?this.valueOf()===o.valueOf():(n=o.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},an.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},an.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},an.isValid=function(){return h(this)},an.lang=Pt,an.locale=Yt,an.localeData=Nt,an.max=mt,an.min=pt,an.parsingFlags=function(){return u({},d(this))},an.set=K,an.startOf=function(e){switch(e=F(e)){case"year":this.month(0);case"quarter":case"month":this.date(1);case"week":case"isoWeek":case"day":case"date":this.hours(0);case"hour":this.minutes(0);case"minute":this.seconds(0);case"second":this.milliseconds(0)}return"week"===e&&this.weekday(0),"isoWeek"===e&&this.isoWeekday(1),"quarter"===e&&this.month(3*Math.floor(this.month()/3)),this},an.subtract=Ht,an.toArray=function(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]},an.toObject=function(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}},an.toDate=function(){return this._offset?new Date(this.valueOf()):this._d},an.toISOString=function(){var e=this.clone().utc();return 0<e.year()&&e.year()<=9999?x(Date.prototype.toISOString)?this.toDate().toISOString():Z(e,"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]"):Z(e,"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]")},an.toJSON=function(){return this.isValid()?this.toISOString():null},an.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},an.unix=function(){return Math.floor(this.valueOf()/1e3)},an.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},an.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},an.year=ot,an.isLeapYear=function(){return nt(this.year())},an.weekYear=function(e){return Wt.call(this,e,this.week(),this.weekday(),this.localeData()._week.dow,this.localeData()._week.doy)},an.isoWeekYear=function(e){return Wt.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},an.quarter=an.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},an.month=Fe,an.daysInMonth=function(){return Ye(this.year(),this.month())},an.week=an.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},an.isoWeek=an.isoWeeks=function(e){var t=at(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},an.weeksInYear=function(){var e=this.localeData()._week;return st(this.year(),e.dow,e.doy)},an.isoWeeksInYear=function(){return st(this.year(),1,4)},an.date=Ft,an.day=an.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t=this._isUTC?this._d.getUTCDay():this._d.getDay();return null!=e?(e=function(e,t){return"string"!=typeof e?e:isNaN(e)?"number"==typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}(e,this.localeData()),this.add(e-t,"d")):t},an.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},an.isoWeekday=function(e){return this.isValid()?null==e?this.day()||7:this.day(this.day()%7?e:e-7):null!=e?this:NaN},an.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},an.hour=an.hours=Zt,an.minute=an.minutes=en,an.second=an.seconds=nn,an.millisecond=an.milliseconds=rn,an.utcOffset=function(e,t){var n,o=this._offset||0;return this.isValid()?null!=e?("string"==typeof e?e=bt(me,e):Math.abs(e)<16&&(e*=60),!this._isUTC&&t&&(n=Mt(this)),this._offset=e,this._isUTC=!0,null!=n&&this.add(n,"m"),o!==e&&(!t||this._changeInProgress?Rt(this,Lt(e-o,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,r.updateOffset(this,!0),this._changeInProgress=null)),this):this._isUTC?o:Mt(this):null!=e?this:NaN},an.utc=function(e){return this.utcOffset(0,e)},an.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(Mt(this),"m")),this},an.parseZone=function(){return this._tzm?this.utcOffset(this._tzm):"string"==typeof this._i&&this.utcOffset(bt(pe,this._i)),this},an.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?ft(e).utcOffset():0,(this.utcOffset()-e)%60==0)},an.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},an.isDSTShifted=function(){if(!p(this._isDSTShifted))return this._isDSTShifted;var e={};if(g(e,this),(e=dt(e))._a){var t=e._isUTC?c(e._a):ft(e._a);this._isDSTShifted=this.isValid()&&C(e._a,t.toArray())>0}else this._isDSTShifted=!1;return this._isDSTShifted},an.isLocal=function(){return!!this.isValid()&&!this._isUTC},an.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},an.isUtc=kt,an.isUTC=kt,an.zoneAbbr=function(){return this._isUTC?"UTC":""},an.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},an.dates=k("dates accessor is deprecated. Use date instead.",Ft),an.months=k("months accessor is deprecated. Use month instead",Fe),an.years=k("years accessor is deprecated. Use year instead",ot),an.zone=k("moment().zone is deprecated, use moment().utcOffset instead. https://github.com/moment/moment/issues/1779",function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()});var sn=an;function ln(e){return e}var un=E.prototype;function cn(e,t,n,o){var r=I(),i=c().set(o,t);return r[n](i,e)}function dn(e,t,n){if("number"==typeof e&&(t=e,e=void 0),e=e||"",null!=t)return cn(e,t,n,"month");var o,r=[];for(o=0;o<12;o++)r[o]=cn(e,o,n,"month");return r}function hn(e,t,n,o){"boolean"==typeof e?("number"==typeof t&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,"number"==typeof t&&(n=t,t=void 0),t=t||"");var r,i=I(),a=e?i._week.dow:0;if(null!=n)return cn(t,(n+a)%7,o,"day");var s=[];for(r=0;r<7;r++)s[r]=cn(t,(r+a)%7,o,"day");return s}un._calendar={sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},un.calendar=function(e,t,n){var o=this._calendar[e];return x(o)?o.call(t,n):o},un._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"},un.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.replace(/MMMM|MM|DD|dddd/g,function(e){return e.slice(1)}),this._longDateFormat[e])},un._invalidDate="Invalid date",un.invalidDate=function(){return this._invalidDate},un._ordinal="%d",un.ordinal=function(e){return this._ordinal.replace("%d",e)},un._ordinalParse=/\d{1,2}/,un.preparse=ln,un.postformat=ln,un._relativeTime={future:"in %s",past:"%s ago",s:"a few 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"},un.relativeTime=function(e,t,n,o){var r=this._relativeTime[n];return x(r)?r(e,t,n,o):r.replace(/%d/i,e)},un.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return x(n)?n(t):n.replace(/%s/i,t)},un.set=function(e){var t,n;for(n in e)x(t=e[n])?this[n]=t:this["_"+n]=t;this._config=e,this._ordinalParseLenient=new RegExp(this._ordinalParse.source+"|"+/\d{1,2}/.source)},un.months=function(e,t){return i(this._months)?this._months[e.month()]:this._months[Pe.test(t)?"format":"standalone"][e.month()]},un._months=Ne,un.monthsShort=function(e,t){return i(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[Pe.test(t)?"format":"standalone"][e.month()]},un._monthsShort=Ie,un.monthsParse=function(e,t,n){var o,r,i;if(this._monthsParseExact)return We.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),o=0;o<12;o++){if(r=c([2e3,o]),n&&!this._longMonthsParse[o]&&(this._longMonthsParse[o]=new RegExp("^"+this.months(r,"").replace(".","")+"$","i"),this._shortMonthsParse[o]=new RegExp("^"+this.monthsShort(r,"").replace(".","")+"$","i")),n||this._monthsParse[o]||(i="^"+this.months(r,"")+"|^"+this.monthsShort(r,""),this._monthsParse[o]=new RegExp(i.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[o].test(e))return o;if(n&&"MMM"===t&&this._shortMonthsParse[o].test(e))return o;if(!n&&this._monthsParse[o].test(e))return o}},un._monthsRegex=Be,un.monthsRegex=function(e){return this._monthsParseExact?(l(this,"_monthsRegex")||Ve.call(this),e?this._monthsStrictRegex:this._monthsRegex):this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex},un._monthsShortRegex=ze,un.monthsShortRegex=function(e){return this._monthsParseExact?(l(this,"_monthsRegex")||Ve.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex},un.week=function(e){return at(e,this._week.dow,this._week.doy).week},un._week={dow:0,doy:6},un.firstDayOfYear=function(){return this._week.doy},un.firstDayOfWeek=function(){return this._week.dow},un.weekdays=function(e,t){return i(this._weekdays)?this._weekdays[e.day()]:this._weekdays[this._weekdays.isFormat.test(t)?"format":"standalone"][e.day()]},un._weekdays=zt,un.weekdaysMin=function(e){return this._weekdaysMin[e.day()]},un._weekdaysMin=Vt,un.weekdaysShort=function(e){return this._weekdaysShort[e.day()]},un._weekdaysShort=Bt,un.weekdaysParse=function(e,t,n){var o,r,i;if(this._weekdaysParseExact)return Ut.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),o=0;o<7;o++){if(r=c([2e3,1]).day(o),n&&!this._fullWeekdaysParse[o]&&(this._fullWeekdaysParse[o]=new RegExp("^"+this.weekdays(r,"").replace(".",".?")+"$","i"),this._shortWeekdaysParse[o]=new RegExp("^"+this.weekdaysShort(r,"").replace(".",".?")+"$","i"),this._minWeekdaysParse[o]=new RegExp("^"+this.weekdaysMin(r,"").replace(".",".?")+"$","i")),this._weekdaysParse[o]||(i="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[o]=new RegExp(i.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[o].test(e))return o;if(n&&"ddd"===t&&this._shortWeekdaysParse[o].test(e))return o;if(n&&"dd"===t&&this._minWeekdaysParse[o].test(e))return o;if(!n&&this._weekdaysParse[o].test(e))return o}},un._weekdaysRegex=Kt,un.weekdaysRegex=function(e){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Jt.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex},un._weekdaysShortRegex=Gt,un.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Jt.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex},un._weekdaysMinRegex=Xt,un.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(l(this,"_weekdaysRegex")||Jt.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex},un.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},un._meridiemParse=/[ap]\.?m?\.?/i,un.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},P("en",{ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===b(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),r.lang=k("moment.lang is deprecated. Use moment.locale instead.",P),r.langData=k("moment.langData is deprecated. Use moment.localeData instead.",I);var fn=Math.abs;function pn(e,t,n,o){var r=Lt(t,n);return e._milliseconds+=o*r._milliseconds,e._days+=o*r._days,e._months+=o*r._months,e._bubble()}function mn(e){return e<0?Math.floor(e):Math.ceil(e)}function gn(e){return 4800*e/146097}function vn(e){return 146097*e/4800}function yn(e){return function(){return this.as(e)}}var _n=yn("ms"),wn=yn("s"),bn=yn("m"),Cn=yn("h"),Mn=yn("d"),kn=yn("w"),Sn=yn("M"),Tn=yn("y");function Ln(e){return function(){return this._data[e]}}var xn=Ln("milliseconds"),Dn=Ln("seconds"),On=Ln("minutes"),En=Ln("hours"),Rn=Ln("days"),An=Ln("months"),Hn=Ln("years"),Yn=Math.round,Pn={s:45,m:45,h:22,d:26,M:11};function Nn(e,t,n,o,r){return r.relativeTime(t||1,!!n,e,o)}var In=Math.abs;function Wn(){var e,t,n=In(this._milliseconds)/1e3,o=In(this._days),r=In(this._months);e=w(n/60),t=w(e/60),n%=60,e%=60;var i=w(r/12),a=r%=12,s=o,l=t,u=e,c=n,d=this.asSeconds();return d?(d<0?"-":"")+"P"+(i?i+"Y":"")+(a?a+"M":"")+(s?s+"D":"")+(l||u||c?"T":"")+(l?l+"H":"")+(u?u+"M":"")+(c?c+"S":""):"P0D"}var jn=vt.prototype;return jn.abs=function(){var e=this._data;return this._milliseconds=fn(this._milliseconds),this._days=fn(this._days),this._months=fn(this._months),e.milliseconds=fn(e.milliseconds),e.seconds=fn(e.seconds),e.minutes=fn(e.minutes),e.hours=fn(e.hours),e.months=fn(e.months),e.years=fn(e.years),this},jn.add=function(e,t){return pn(this,e,t,1)},jn.subtract=function(e,t){return pn(this,e,t,-1)},jn.as=function(e){var t,n,o=this._milliseconds;if("month"===(e=F(e))||"year"===e)return t=this._days+o/864e5,n=this._months+gn(t),"month"===e?n:n/12;switch(t=this._days+Math.round(vn(this._months)),e){case"week":return t/7+o/6048e5;case"day":return t+o/864e5;case"hour":return 24*t+o/36e5;case"minute":return 1440*t+o/6e4;case"second":return 86400*t+o/1e3;case"millisecond":return Math.floor(864e5*t)+o;default:throw new Error("Unknown unit "+e)}},jn.asMilliseconds=_n,jn.asSeconds=wn,jn.asMinutes=bn,jn.asHours=Cn,jn.asDays=Mn,jn.asWeeks=kn,jn.asMonths=Sn,jn.asYears=Tn,jn.valueOf=function(){return this._milliseconds+864e5*this._days+this._months%12*2592e6+31536e6*b(this._months/12)},jn._bubble=function(){var e,t,n,o,r,i=this._milliseconds,a=this._days,s=this._months,l=this._data;return i>=0&&a>=0&&s>=0||i<=0&&a<=0&&s<=0||(i+=864e5*mn(vn(s)+a),a=0,s=0),l.milliseconds=i%1e3,e=w(i/1e3),l.seconds=e%60,t=w(e/60),l.minutes=t%60,n=w(t/60),l.hours=n%24,a+=w(n/24),r=w(gn(a)),s+=r,a-=mn(vn(r)),o=w(s/12),s%=12,l.days=a,l.months=s,l.years=o,this},jn.get=function(e){return this[(e=F(e))+"s"]()},jn.milliseconds=xn,jn.seconds=Dn,jn.minutes=On,jn.hours=En,jn.days=Rn,jn.weeks=function(){return w(this.days()/7)},jn.months=An,jn.years=Hn,jn.humanize=function(e){var t=this.localeData(),n=function(e,t,n){var o=Lt(e).abs(),r=Yn(o.as("s")),i=Yn(o.as("m")),a=Yn(o.as("h")),s=Yn(o.as("d")),l=Yn(o.as("M")),u=Yn(o.as("y")),c=r<Pn.s&&["s",r]||i<=1&&["m"]||i<Pn.m&&["mm",i]||a<=1&&["h"]||a<Pn.h&&["hh",a]||s<=1&&["d"]||s<Pn.d&&["dd",s]||l<=1&&["M"]||l<Pn.M&&["MM",l]||u<=1&&["y"]||["yy",u];return c[2]=t,c[3]=+e>0,c[4]=n,Nn.apply(null,c)}(this,!e,t);return e&&(n=t.pastFuture(+this,n)),t.postformat(n)},jn.toISOString=Wn,jn.toString=Wn,jn.toJSON=Wn,jn.locale=Yt,jn.localeData=Nt,jn.toIsoString=k("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",Wn),jn.lang=Pt,$("X",0,0,"unix"),$("x",0,0,"valueOf"),ye("x",fe),ye("X",/[+-]?\d+(\.\d{1,3})?/),Ce("X",function(e,t,n){n._d=new Date(1e3*parseFloat(e,10))}),Ce("x",function(e,t,n){n._d=new Date(b(e))}),r.version="2.13.0",t=ft,r.fn=sn,r.min=function(){return gt("isBefore",[].slice.call(arguments,0))},r.max=function(){return gt("isAfter",[].slice.call(arguments,0))},r.now=function(){return Date.now?Date.now():+new Date},r.utc=c,r.unix=function(e){return ft(1e3*e)},r.months=function(e,t){return dn(e,t,"months")},r.isDate=a,r.locale=P,r.invalid=f,r.duration=Lt,r.isMoment=_,r.weekdays=function(e,t,n){return hn(e,t,n,"weekdays")},r.parseZone=function(){return ft.apply(null,arguments).parseZone()},r.localeData=I,r.isDuration=yt,r.monthsShort=function(e,t){return dn(e,t,"monthsShort")},r.weekdaysMin=function(e,t,n){return hn(e,t,n,"weekdaysMin")},r.defineLocale=N,r.updateLocale=function(e,t){var n;null!=t?(null!=A[e]&&(t=O(A[e]._config,t)),(n=new E(t)).parentLocale=A[e],A[e]=n,P(e)):null!=A[e]&&(null!=A[e].parentLocale?A[e]=A[e].parentLocale:null!=A[e]&&delete A[e]);return A[e]},r.locales=function(){return S(A)},r.weekdaysShort=function(e,t,n){return hn(e,t,n,"weekdaysShort")},r.normalizeUnits=F,r.relativeTimeThreshold=function(e,t){return void 0!==Pn[e]&&(void 0===t?Pn[e]:(Pn[e]=t,!0))},r.prototype=sn,r}()}).call(this,n(45)(e))},,,function(e,t,n){"use strict";e.exports=n(36),e.exports.easing=n(362),e.exports.canvas=n(363),e.exports.options=n(364)},function(e,t,n){
/*!
* (The MIT License)
*
* Copyright (c) 2012-2014 Marcin Warpechowski
* Copyright (c) 2015 Handsoncode sp. z o.o. <hello@handsoncode.net>
*
* Permission is hereby granted, free of charge, to any person obtaining
* a copy of this software and associated documentation files (the
* 'Software'), to deal in the Software without restriction, including
* without limitation the rights to use, copy, modify, merge, publish,
* distribute, sublicense, and/or sell copies of the Software, and to
* permit persons to whom the Software is furnished to do so, subject to
* the following conditions:
*
* The above copyright notice and this permission notice shall be
* included in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
*
* Version: 0.32.0
* Date: Tue May 30 2017 12:18:32 GMT+0200 (CEST)
*/
var o;o=function(e,t,n,o){return function(e){var t={};function n(o){if(t[o])return t[o].exports;var r=t[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:o})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=209)}([function(e,t,n){"use strict";t.__esModule=!0,t.HTML_CHARACTERS=void 0,t.getParent=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=-1,o=null;null!=e;){if(n===t){o=e;break}e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e=e.host:(n++,e=e.parentNode)}return o},t.closest=u,t.closestDown=function(e,t,n){for(var o=[];e&&(e=u(e,t,n))&&(!n||n.contains(e));)o.push(e),e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode;var r=o.length;return r?o[r-1]:null},t.isChildOf=function(e,t){var n=e.parentNode,o=[];for("string"==typeof t?o=Array.prototype.slice.call(document.querySelectorAll(t),0):o.push(t);null!=n;){if(o.indexOf(n)>-1)return!0;n=n.parentNode}return!1},t.isChildOfWebComponentTable=function(e){var t,n="hot-table",o=!1;function r(e){return e.nodeType===Node.ELEMENT_NODE&&e.nodeName===n.toUpperCase()}for(t=c(e);null!=t;){if(r(t)){o=!0;break}if(t.host&&t.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(o=r(t.host))break;t=t.host}t=t.parentNode}return o},t.polymerWrap=c,t.polymerUnwrap=d,t.index=function(e){var t=0;if(e.previousSibling)for(;e=e.previousSibling;)++t;return t},t.overlayContainsElement=function(e,t){var n=document.querySelector(".ht_clone_"+e);return n?n.contains(t):null},t.hasClass=function(e,t){return o(e,t)},t.addClass=function(e,t){return r(e,t)},t.removeClass=function(e,t){return i(e,t)},t.removeTextNodes=function e(t,n){if(3===t.nodeType)n.removeChild(t);else if(["TABLE","THEAD","TBODY","TFOOT","TR"].indexOf(t.nodeName)>-1)for(var o=t.childNodes,r=o.length-1;r>=0;r--)e(o[r],t)},t.empty=m,t.fastInnerHTML=function(e,t){v.test(t)?e.innerHTML=t:_(e,t)},t.fastInnerText=_,t.isVisible=function e(t){for(var n=t;d(n)!==document.documentElement;){if(null===n)return!1;if(n.nodeType===Node.DOCUMENT_FRAGMENT_NODE){if(n.host){if(n.host.impl)return e(n.host.impl);if(n.host)return e(n.host);throw new Error("Lost in Web Components world")}return!1}if("none"===n.style.display)return!1;n=n.parentNode}return!0},t.offset=function(e){var t,n,o,r,i;if(r=document.documentElement,(0,l.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName)return{top:(i=e.getBoundingClientRect()).top+(window.pageYOffset||r.scrollTop)-(r.clientTop||0),left:i.left+(window.pageXOffset||r.scrollLeft)-(r.clientLeft||0)};for(t=e.offsetLeft,n=e.offsetTop,o=e;(e=e.offsetParent)&&e!==document.body;)t+=e.offsetLeft,n+=e.offsetTop,o=e;return o&&"fixed"===o.style.position&&(t+=window.pageXOffset||r.scrollLeft,n+=window.pageYOffset||r.scrollTop),{left:t,top:n}},t.getWindowScrollTop=w,t.getWindowScrollLeft=b,t.getScrollTop=function(e){return e===window?w():e.scrollTop},t.getScrollLeft=function(e){return e===window?b():e.scrollLeft},t.getScrollableElement=function(e){for(var t,n,o,r=e.parentNode,i=["auto","scroll"],a="",s="",l="",u="";r&&r.style&&document.body!==r;){if(t=r.style.overflow,n=r.style.overflowX,o=r.style.overflowY,"scroll"==t||"scroll"==n||"scroll"==o)return r;if(window.getComputedStyle&&(a=window.getComputedStyle(r),s=a.getPropertyValue("overflow"),l=a.getPropertyValue("overflow-y"),u=a.getPropertyValue("overflow-x"),"scroll"===s||"scroll"===u||"scroll"===l))return r;if(r.clientHeight<=r.scrollHeight&&(-1!==i.indexOf(o)||-1!==i.indexOf(t)||-1!==i.indexOf(s)||-1!==i.indexOf(l)))return r;if(r.clientWidth<=r.scrollWidth&&(-1!==i.indexOf(n)||-1!==i.indexOf(t)||-1!==i.indexOf(s)||-1!==i.indexOf(u)))return r;r=r.parentNode}return window},t.getTrimmingContainer=function(e){for(var t=e.parentNode;t&&t.style&&document.body!==t;){if("visible"!==t.style.overflow&&""!==t.style.overflow)return t;if(window.getComputedStyle){var n=window.getComputedStyle(t);if("visible"!==n.getPropertyValue("overflow")&&""!==n.getPropertyValue("overflow"))return t}t=t.parentNode}return window},t.getStyle=function(e,t){if(e){if(e===window)return"width"===t?window.innerWidth+"px":"height"===t?window.innerHeight+"px":void 0;var n,o=e.style[t];return""!==o&&void 0!==o?o:""!==(n=C(e))[t]&&void 0!==n[t]?n[t]:void 0}},t.getComputedStyle=C,t.outerWidth=function(e){return e.offsetWidth},t.outerHeight=function(e){return(0,l.hasCaptionProblem)()&&e.firstChild&&"CAPTION"===e.firstChild.nodeName?e.offsetHeight+e.firstChild.offsetHeight:e.offsetHeight},t.innerHeight=function(e){return e.clientHeight||e.innerHeight},t.innerWidth=function(e){return e.clientWidth||e.innerWidth},t.addEvent=function(e,t,n){window.addEventListener?e.addEventListener(t,n,!1):e.attachEvent("on"+t,n)},t.removeEvent=function(e,t,n){window.removeEventListener?e.removeEventListener(t,n,!1):e.detachEvent("on"+t,n)},t.getCaretPosition=function(e){if(e.selectionStart)return e.selectionStart;if(document.selection){e.focus();var t=document.selection.createRange();if(null==t)return 0;var n=e.createTextRange(),o=n.duplicate();return n.moveToBookmark(t.getBookmark()),o.setEndPoint("EndToStart",n),o.text.length}return 0},t.getSelectionEndPosition=function(e){if(e.selectionEnd)return e.selectionEnd;if(document.selection){var t=document.selection.createRange();return null==t?0:e.createTextRange().text.indexOf(t.text)+t.text.length}return 0},t.getSelectionText=function(){var e="";return window.getSelection?e=window.getSelection().toString():document.selection&&"Control"!==document.selection.type&&(e=document.selection.createRange().text),e},t.setCaretPosition=function(e,t,n){if(void 0===n&&(n=t),e.setSelectionRange){e.focus();try{e.setSelectionRange(t,n)}catch(i){var o=e.parentNode,r=o.style.display;o.style.display="block",e.setSelectionRange(t,n),o.style.display=r}}else if(e.createTextRange){var i=e.createTextRange();i.collapse(!0),i.moveEnd("character",n),i.moveStart("character",t),i.select()}},t.getScrollbarWidth=function(){return void 0===g&&(g=function(){var e=document.createElement("div");e.style.height="200px",e.style.width="100%";var t=document.createElement("div");t.style.boxSizing="content-box",t.style.height="150px",t.style.left="0px",t.style.overflow="hidden",t.style.position="absolute",t.style.top="0px",t.style.width="200px",t.style.visibility="hidden",t.appendChild(e),(document.body||document.documentElement).appendChild(t);var n=e.offsetWidth;t.style.overflow="scroll";var o=e.offsetWidth;return n==o&&(o=t.clientWidth),(document.body||document.documentElement).removeChild(t),n-o}()),g},t.hasVerticalScrollbar=function(e){return e.offsetWidth!==e.clientWidth},t.hasHorizontalScrollbar=function(e){return e.offsetHeight!==e.clientHeight},t.setOverlayPosition=function(e,t,n){(0,s.isIE8)()||(0,s.isIE9)()?(e.style.top=n,e.style.left=t):(0,s.isSafari)()?e.style["-webkit-transform"]="translate3d("+t+","+n+",0)":e.style.transform="translate3d("+t+","+n+",0)"},t.getCssTransform=function(e){var t;return e.style.transform&&""!==(t=e.style.transform)?["transform",t]:e.style["-webkit-transform"]&&""!==(t=e.style["-webkit-transform"])?["-webkit-transform",t]:-1},t.resetCssTransform=function(e){e.style.transform&&""!==e.style.transform?e.style.transform="":e.style["-webkit-transform"]&&""!==e.style["-webkit-transform"]&&(e.style["-webkit-transform"]="")},t.isInput=M,t.isOutsideInput=function(e){return M(e)&&-1==e.className.indexOf("handsontableInput")&&-1==e.className.indexOf("copyPaste")};var o,r,i,a,s=n(25),l=n(34);function u(e,t,n){for(;null!=e&&e!==n;){if(e.nodeType===Node.ELEMENT_NODE&&(t.indexOf(e.nodeName)>-1||t.indexOf(e)>-1))return e;e=e.host&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE?e.host:e.parentNode}return null}function c(e){return"undefined"!=typeof Polymer&&"function"==typeof wrap?wrap(e):e}function d(e){return"undefined"!=typeof Polymer&&"function"==typeof unwrap?unwrap(e):e}function h(e){var t=0,n=[];if(!e||!e.length)return n;for(;e[t];)n.push(e[t]),t++;return n}if(document.documentElement.classList){var f=((a=document.createElement("div")).classList.add("test","test2"),a.classList.contains("test2"));o=function(e,t){return""!==t&&e.classList.contains(t)},r=function(e,t){var n=0;if("string"==typeof t&&(t=t.split(" ")),t=h(t),f)e.classList.add.apply(e.classList,t);else for(;t&&t[n];)e.classList.add(t[n]),n++},i=function(e,t){var n=0;if("string"==typeof t&&(t=t.split(" ")),t=h(t),f)e.classList.remove.apply(e.classList,t);else for(;t&&t[n];)e.classList.remove(t[n]),n++}}else{var p=function(e){return new RegExp("(\\s|^)"+e+"(\\s|$)")};o=function(e,t){return!!e.className.match(p(t))},r=function(e,t){var n=0,o=e.className;if("string"==typeof t&&(t=t.split(" ")),""===o)o=t.join(" ");else for(;t&&t[n];)p(t[n]).test(o)||(o+=" "+t[n]),n++;e.className=o},i=function(e,t){var n=0,o=e.className;for("string"==typeof t&&(t=t.split(" "));t&&t[n];)o=o.replace(p(t[n])," ").trim(),n++;e.className!==o&&(e.className=o)}}function m(e){for(var t;t=e.lastChild;)e.removeChild(t)}var g,v=t.HTML_CHARACTERS=/(<(.*)>|&(.*);)/,y=!!document.createTextNode("test").textContent;function _(e,t){var n=e.firstChild;n&&3===n.nodeType&&null===n.nextSibling?y?n.textContent=t:n.data=t:(m(e),e.appendChild(document.createTextNode(t)))}function w(){var e=window.scrollY;return void 0===e&&(e=document.documentElement.scrollTop),e}function b(){var e=window.scrollX;return void 0===e&&(e=document.documentElement.scrollLeft),e}function C(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}function M(e){return e&&(["INPUT","SELECT","TEXTAREA"].indexOf(e.nodeName)>-1||"true"===e.contentEditable)}},function(e,t,n){"use strict";function o(e,t,n,o){var r=-1,i=e.length;for(o&&i&&(n=e[++r]);++r<i;)n=t(n,e[r],r,e);return n}function r(e,t){for(var n=-1,o=e.length;++n<o&&!1!==t(e[n],n,e););return e}function i(e){return o(e,function(e,t){return e+t},0)}t.__esModule=!0,t.to2dArray=function(e){for(var t=0,n=e.length;t<n;)e[t]=[e[t]],t++},t.extendArray=function(e,t){for(var n=0,o=t.length;n<o;)e.push(t[n]),n++},t.pivot=function(e){var t=[];if(!e||0===e.length||!e[0]||0===e[0].length)return t;for(var n=e.length,o=e[0].length,r=0;r<n;r++)for(var i=0;i<o;i++)t[i]||(t[i]=[]),t[i][r]=e[r][i];return t},t.arrayReduce=o,t.arrayFilter=function(e,t){for(var n=-1,o=e.length,r=-1,i=[];++n<o;){var a=e[n];t(a,n,e)&&(i[++r]=a)}return i},t.arrayMap=function(e,t){for(var n=-1,o=e.length,r=-1,i=[];++n<o;){var a=e[n];i[++r]=t(a,n,e)}return i},t.arrayEach=r,t.arraySum=i,t.arrayMax=function(e){return o(e,function(e,t){return e>t?e:t},Array.isArray(e)?e[0]:void 0)},t.arrayMin=function(e){return o(e,function(e,t){return e<t?e:t},Array.isArray(e)?e[0]:void 0)},t.arrayAvg=function(e){return e.length?i(e)/e.length:0},t.arrayFlatten=function e(t){return o(t,function(t,n){return t.concat(Array.isArray(n)?e(n):n)},[])},t.arrayUnique=function(e){var t=[];return r(e,function(e){-1===t.indexOf(e)&&t.push(e)}),t}},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.duckSchema=function e(t){var n;return Array.isArray(t)?n=[]:(n={},l(t,function(t,r){"__children"!==r&&(t&&"object"===(void 0===t?"undefined":o(t))&&!Array.isArray(t)?n[r]=e(t):Array.isArray(t)?t.length&&"object"===o(t[0])&&!Array.isArray(t[0])?n[r]=[e(t[0])]:n[r]=[]:n[r]=null)})),n},t.inherit=function(e,t){return t.prototype.constructor=t,e.prototype=new t,e.prototype.constructor=e,e},t.extend=function(e,t){return l(t,function(t,n){e[n]=t}),e},t.deepExtend=function e(t,n){l(n,function(r,i){n[i]&&"object"===o(n[i])?(t[i]||(Array.isArray(n[i])?t[i]=[]:"[object Date]"===Object.prototype.toString.call(n[i])?t[i]=n[i]:t[i]={}),e(t[i],n[i])):t[i]=n[i]})},t.deepClone=a,t.clone=function(e){var t={};return l(e,function(e,n){t[n]=e}),t},t.mixin=function(e){e.MIXINS||(e.MIXINS=[]);for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return(0,r.arrayEach)(n,function(t){e.MIXINS.push(t.MIXIN_NAME),l(t,function(t,n){if(void 0!==e.prototype[n])throw new Error("Mixin conflict. Property '"+n+"' already exist and cannot be overwritten.");var o;"function"==typeof t?e.prototype[n]=t:Object.defineProperty(e.prototype,n,{get:function(e,t){return e="_"+e,function(){return void 0===this[e]&&(this[e]=function(e){return(Array.isArray(e)||s(e))&&(e=a(e)),e}(t)),this[e]}}(n,t),set:(o=n,o="_"+o,function(e){this[o]=e}),configurable:!0})})}),e},t.isObjectEquals=function(e,t){return JSON.stringify(e)===JSON.stringify(t)},t.isObject=s,t.defineGetter=function(e,t,n,o){o.value=n,o.writable=!1!==o.writable,o.enumerable=!1!==o.enumerable,o.configurable=!1!==o.configurable,Object.defineProperty(e,t,o)},t.objectEach=l,t.getProperty=function(e,t){var n=t.split("."),o=e;return l(n,function(e){if(void 0===(o=o[e]))return o=void 0,!1}),o},t.deepObjectSize=function(e){return s(e)?function e(t){var n=0;return s(t)?l(t,function(t){n+=e(t)}):n++,n}(e):0},t.createObjectPropListener=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"value",o="_"+n,r=(i(t={_touched:!1},o,e),i(t,"isTouched",function(){return this._touched}),t);return Object.defineProperty(r,n,{get:function(){return this[o]},set:function(e){this._touched=!0,this[o]=e},enumerable:!0,configurable:!0}),r},t.hasOwnProperty=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)};var r=n(1);function i(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e){return"object"===(void 0===e?"undefined":o(e))?JSON.parse(JSON.stringify(e)):e}function s(e){return"[object Object]"==Object.prototype.toString.call(e)}function l(e,t){for(var n in e)if((!e.hasOwnProperty||e.hasOwnProperty&&Object.prototype.hasOwnProperty.call(e,n))&&!1===t(e[n],n,e))break;return e}},function(e,t,n){var o=n(13),r=n(44),i=n(32),a=n(33),s=n(29),l=function(e,t,n){var u,c,d,h,f=e&l.F,p=e&l.G,m=e&l.S,g=e&l.P,v=e&l.B,y=p?o:m?o[t]||(o[t]={}):(o[t]||{}).prototype,_=p?r:r[t]||(r[t]={}),w=_.prototype||(_.prototype={});for(u in p&&(n=t),n)d=((c=!f&&y&&void 0!==y[u])?y:n)[u],h=v&&c?s(d,o):g&&"function"==typeof d?s(Function.call,d):d,y&&a(y,u,d,e&l.U),_[u]!=d&&i(_,u,h),g&&w[u]!=d&&(w[u]=d)};o.core=r,l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,e.exports=l},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.getListenersCounter=function(){return s};var r=n(0),i=n(34),a=n(7),s=0,l=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.context=t||this,this.context.eventListeners||(this.context.eventListeners=[])}return o(e,[{key:"addEventListener",value:function(e,t,n){var o=this,r=this.context;function i(e){e=u(r,e),n.call(this,e)}return this.context.eventListeners.push({element:e,event:t,callback:n,callbackProxy:i}),window.addEventListener?e.addEventListener(t,i,!1):e.attachEvent("on"+t,i),s++,function(){o.removeEventListener(e,t,n)}}},{key:"removeEventListener",value:function(e,t,n){for(var o=this.context.eventListeners.length,r=void 0;o--;)if((r=this.context.eventListeners[o]).event==t&&r.element==e){if(n&&n!=r.callback)continue;this.context.eventListeners.splice(o,1),r.element.removeEventListener?r.element.removeEventListener(r.event,r.callbackProxy,!1):r.element.detachEvent("on"+r.event,r.callbackProxy),s--}}},{key:"clearEvents",value:function(){if(this.context)for(var e=this.context.eventListeners.length;e--;){var t=this.context.eventListeners[e];t&&this.removeEventListener(t.element,t.event,t.callback)}}},{key:"clear",value:function(){this.clearEvents()}},{key:"destroy",value:function(){this.clearEvents(),this.context=null}},{key:"fireEvent",value:function(e,t){var n,o={bubbles:!0,cancelable:"mousemove"!==t,view:window,detail:0,screenX:0,screenY:0,clientX:1,clientY:1,ctrlKey:!1,altKey:!1,shiftKey:!1,metaKey:!1,button:0,relatedTarget:void 0};document.createEvent?(n=document.createEvent("MouseEvents")).initMouseEvent(t,o.bubbles,o.cancelable,o.view,o.detail,o.screenX,o.screenY,o.clientX,o.clientY,o.ctrlKey,o.altKey,o.shiftKey,o.metaKey,o.button,o.relatedTarget||document.body.parentNode):n=document.createEventObject(),e.dispatchEvent?e.dispatchEvent(n):e.fireEvent("on"+t,n)}}]),e}();function u(e,t){var n=void 0,o=void 0,s=void 0,u=void 0,c=void 0,d=void 0;if(t.isTargetWebComponent=!1,t.realTarget=t.target,d=t.stopImmediatePropagation,t.stopImmediatePropagation=function(){d.apply(this),(0,a.stopImmediatePropagation)(this)},!l.isHotTableEnv)return t;for(c=(t=(0,r.polymerWrap)(t)).path?t.path.length:0;c--;){if("HOT-TABLE"===t.path[c].nodeName)n=!0;else if(n&&t.path[c].shadowRoot){u=t.path[c];break}0!==c||u||(u=t.path[c])}return u||(u=t.target),t.isTargetWebComponent=!0,(0,i.isWebComponentSupportedNatively)()?t.realTarget=t.srcElement||t.toElement:(e instanceof Core||e instanceof Walkontable)&&(e instanceof Core?o=e.view?e.view.wt.wtTable.TABLE:null:e instanceof Walkontable&&(o=e.wtTable.TABLE.parentNode.parentNode),s=(0,r.closest)(t.target,["HOT-TABLE"],o),t.realTarget=s&&o.querySelector("HOT-TABLE")||t.target),Object.defineProperty(t,"target",{get:function(){return(0,r.polymerWrap)(u)},enumerable:!0,configurable:!0}),t}t.default=l},function(e,t,n){"use strict";t.__esModule=!0,t.getPluginName=t.getRegistredPluginNames=t.getPlugin=t.registerPlugin=void 0;var o,r=n(8),i=(o=r)&&o.__esModule?o:{default:o},a=n(2),s=n(27),l=new WeakMap;t.registerPlugin=function(e,t){e=(0,s.toUpperCaseFirst)(e),i.default.getSingleton().add("construct",function(){var n=void 0;l.has(this)||l.set(this,{}),(n=l.get(this))[e]||(n[e]=new t(this))}),i.default.getSingleton().add("afterDestroy",function(){if(l.has(this)){var e=l.get(this);(0,a.objectEach)(e,function(e){return e.destroy()}),l.delete(this)}})},t.getPlugin=function(e,t){if("string"!=typeof t)throw Error('Only strings can be passed as "plugin" parameter');var n=(0,s.toUpperCaseFirst)(t);if(l.has(e)&&l.get(e)[n])return l.get(e)[n]},t.getRegistredPluginNames=function(e){return l.has(e)?Object.keys(l.get(e)):[]},t.getPluginName=function(e,t){var n=null;return l.has(e)&&(0,a.objectEach)(l.get(e),function(e,o){e===t&&(n=o)}),n}},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.isNumeric=function(e){var t=void 0===e?"undefined":o(e);return"number"==t?!isNaN(e)&&isFinite(e):"string"==t?!!e.length&&(1==e.length?/\d/.test(e):/^\s*[+-]?\s*(?:(?:\d+(?:\.\d+)?(?:e[+-]?\d+)?)|(?:0x[a-f\d]+))\s*$/i.test(e)):"object"==t&&!(!e||"number"!=typeof e.valueOf()||e instanceof Date)},t.rangeEach=function(e,t,n){var o=-1;for("function"==typeof t?(n=t,t=e):o=e-1;++o<=t&&!1!==n(o););},t.rangeEachReverse=function(e,t,n){var o=e+1;for("function"==typeof t&&(n=t,t=0);--o>=t&&!1!==n(o););},t.valueAccordingPercent=function(e,t){return t=parseInt(t.toString().replace("%",""),10),t=parseInt(e*t/100,10)}},function(e,t,n){"use strict";t.__esModule=!0,t.stopImmediatePropagation=function(e){e.isImmediatePropagationEnabled=!1,e.cancelBubble=!0},t.isImmediatePropagationStopped=function(e){return!1===e.isImmediatePropagationEnabled},t.stopPropagation=function(e){"function"==typeof e.stopPropagation?e.stopPropagation():e.cancelBubble=!0},t.pageX=function(e){return e.pageX?e.pageX:e.clientX+(0,o.getWindowScrollLeft)()},t.pageY=function(e){return e.pageY?e.pageY:e.clientY+(0,o.getWindowScrollTop)()},t.isRightClick=function(e){return 2===e.button},t.isLeftClick=function(e){return 0===e.button};var o=n(0)},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(1),i=n(2),a=["afterCellMetaReset","afterChange","afterChangesObserved","afterContextMenuDefaultOptions","beforeContextMenuSetItems","afterDropdownMenuDefaultOptions","beforeDropdownMenuSetItems","afterContextMenuHide","afterContextMenuShow","afterCopyLimit","beforeCreateCol","afterCreateCol","beforeCreateRow","afterCreateRow","afterDeselect","afterDestroy","afterDocumentKeyDown","afterGetCellMeta","afterGetColHeader","afterGetRowHeader","afterInit","afterLoadData","afterMomentumScroll","afterOnCellCornerMouseDown","afterOnCellCornerDblClick","afterOnCellMouseDown","afterOnCellMouseOver","afterOnCellMouseOut","afterRemoveCol","afterRemoveRow","afterRender","beforeRenderer","afterRenderer","afterScrollHorizontally","afterScrollVertically","afterSelection","afterSelectionByProp","afterSelectionEnd","afterSelectionEndByProp","afterSetCellMeta","afterSetDataAtCell","afterSetDataAtRowProp","afterUpdateSettings","afterValidate","beforeAutofill","beforeCellAlignment","beforeChange","beforeChangeRender","beforeDrawBorders","beforeGetCellMeta","beforeInit","beforeInitWalkontable","beforeKeyDown","beforeOnCellMouseDown","beforeOnCellMouseOver","beforeOnCellMouseOut","beforeRemoveCol","beforeRemoveRow","beforeRender","beforeSetRangeStart","beforeSetRangeEnd","beforeTouchScroll","beforeValidate","beforeValueRender","construct","init","modifyCol","unmodifyCol","unmodifyRow","modifyColHeader","modifyColWidth","modifyRow","modifyRowHeader","modifyRowHeight","modifyData","modifyRowData","persistentStateLoad","persistentStateReset","persistentStateSave","beforeColumnSort","afterColumnSort","modifyAutofillRange","modifyCopyableRange","beforeCut","afterCut","beforeCopy","afterCopy","beforePaste","afterPaste","beforeColumnMove","afterColumnMove","beforeRowMove","afterRowMove","beforeColumnResize","afterColumnResize","beforeRowResize","afterRowResize","afterGetColumnHeaderRenderers","afterGetRowHeaderRenderers","beforeStretchingColumnWidth","beforeFilter","afterFilter","modifyColumnHeaderHeight","beforeUndo","afterUndo","beforeRedo","afterRedo","modifyRowHeaderWidth","beforeAutofillInsidePopulate","modifyTransformStart","modifyTransformEnd","afterModifyTransformStart","afterModifyTransformEnd","beforeValueRender","afterViewportRowCalculatorOverride","afterViewportColumnCalculatorOverride","afterPluginsInitialized","manualRowHeights","skipLengthCache","afterTrimRow","afterUntrimRow","afterDropdownMenuShow","afterDropdownMenuHide","hiddenRow","hiddenColumn","beforeAddChild","afterAddChild","beforeDetachChild","afterDetachChild","afterBeginEditing"],s=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.globalBucket=this.createEmptyBucket()}return o(e,null,[{key:"getSingleton",value:function(){return l}}]),o(e,[{key:"createEmptyBucket",value:function(){var e=Object.create(null);return(0,r.arrayEach)(a,function(t){return e[t]=[]}),e}},{key:"getBucket",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return e?(e.pluginHookBucket||(e.pluginHookBucket=this.createEmptyBucket()),e.pluginHookBucket):this.globalBucket}},{key:"add",value:function(e,t){var n=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(Array.isArray(t))(0,r.arrayEach)(t,function(t){return n.add(e,t,o)});else{var i=this.getBucket(o);if(void 0===i[e]&&(this.register(e),i[e]=[]),t.skip=!1,-1===i[e].indexOf(t)){var a=!1;t.initialHook&&(0,r.arrayEach)(i[e],function(n,o){if(n.initialHook)return i[e][o]=t,a=!0,!1}),a||i[e].push(t)}}return this}},{key:"once",value:function(e,t){var n=this,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;Array.isArray(t)?(0,r.arrayEach)(t,function(t){return n.once(e,t,o)}):(t.runOnce=!0,this.add(e,t,o))}},{key:"remove",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=this.getBucket(n);return void 0!==o[e]&&o[e].indexOf(t)>=0&&(t.skip=!0,!0)}},{key:"has",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=this.getBucket(t);return!(void 0===n[e]||!n[e].length)}},{key:"run",value:function(e,t,n,o,r,i,a,s){var l=this.globalBucket[t],u=-1,c=l?l.length:0;if(c)for(;++u<c;)if(l[u]&&!l[u].skip){var d=l[u].call(e,n,o,r,i,a,s);void 0!==d&&(n=d),l[u]&&l[u].runOnce&&this.remove(t,l[u])}var h=this.getBucket(e)[t],f=-1,p=h?h.length:0;if(p)for(;++f<p;)if(h[f]&&!h[f].skip){var m=h[f].call(e,n,o,r,i,a,s);void 0!==m&&(n=m),h[f]&&h[f].runOnce&&this.remove(t,h[f],e)}return n}},{key:"destroy",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;(0,i.objectEach)(this.getBucket(e),function(e,t,n){return n[t].length=0})}},{key:"register",value:function(e){this.isRegistered(e)||a.push(e)}},{key:"deregister",value:function(e){this.isRegistered(e)&&a.splice(a.indexOf(e),1)}},{key:"isRegistered",value:function(e){return a.indexOf(e)>=0}},{key:"getRegistered",value:function(){return a}}]),e}(),l=new s;t.default=s},function(e,t,n){"use strict";t.__esModule=!0,t.getRegisteredRenderers=t.getRegisteredRendererNames=t.hasRenderer=t.getRenderer=t.registerRenderer=void 0;var o=d(n(51)),r=d(n(260)),i=d(n(261)),a=d(n(262)),s=d(n(263)),l=d(n(264)),u=d(n(265)),c=d(n(266));function d(e){return e&&e.__esModule?e:{default:e}}var h=(0,o.default)("renderers"),f=h.register,p=h.getItem,m=h.hasItem,g=h.getNames,v=h.getValues;f("base",r.default),f("autocomplete",i.default),f("checkbox",a.default),f("html",s.default),f("numeric",l.default),f("password",u.default),f("text",c.default),t.registerRenderer=f,t.getRenderer=function(e){if("function"==typeof e)return e;if(!m(e))throw Error('No registered renderer found under "'+e+'" name');return p(e)},t.hasRenderer=m,t.getRegisteredRendererNames=g,t.getRegisteredRenderers=v},function(e,t,n){var o=n(82)("wks"),r=n(49),i=n(13).Symbol,a="function"==typeof i;(e.exports=function(e){return o[e]||(o[e]=a&&i[e]||(a?i:r)("Symbol."+e))}).store=o},function(e,t,n){"use strict";t.__esModule=!0,t.Viewport=t.TableRenderer=t.Table=t.Settings=t.Selection=t.Scroll=t.Overlays=t.Event=t.Core=t.default=t.Border=t.TopLeftCornerOverlay=t.TopOverlay=t.LeftOverlay=t.DebugOverlay=t.RowFilter=t.ColumnFilter=t.CellRange=t.CellCoords=t.ViewportRowsCalculator=t.ViewportColumnsCalculator=void 0,n(96),n(113),n(122),n(123),n(107),n(121),n(104),n(105),n(106),n(95),n(118),n(116),n(114),n(119),n(120),n(115),n(117),n(108),n(109),n(110),n(112),n(111),n(93),n(94),n(89),n(92),n(91),n(90),n(68),n(98),n(99),n(101),n(100),n(97),n(103),n(102),n(124),n(127),n(125),n(126),n(129),n(128),n(131),n(130);var o=M(n(135)),r=M(n(136)),i=M(n(42)),a=M(n(69)),s=M(n(139)),l=M(n(140)),u=M(n(185)),c=M(n(186)),d=M(n(187)),h=M(n(188)),f=M(n(134)),p=M(n(137)),m=M(n(138)),g=M(n(141)),v=M(n(142)),y=M(n(189)),_=M(n(143)),w=M(n(144)),b=M(n(145)),C=M(n(146));function M(e){return e&&e.__esModule?e:{default:e}}t.ViewportColumnsCalculator=o.default,t.ViewportRowsCalculator=r.default,t.CellCoords=i.default,t.CellRange=a.default,t.ColumnFilter=s.default,t.RowFilter=l.default,t.DebugOverlay=u.default,t.LeftOverlay=c.default,t.TopOverlay=d.default,t.TopLeftCornerOverlay=h.default,t.Border=f.default,t.default=p.default,t.Core=p.default,t.Event=m.default,t.Overlays=g.default,t.Scroll=v.default,t.Selection=y.default,t.Settings=_.default,t.Table=w.default,t.TableRenderer=b.default,t.Viewport=C.default},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(2),i=n(1),a=n(153),s=n(5),l=new WeakMap,u=null,c=function(){function e(t){var n=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),(0,r.defineGetter)(this,"hot",t,{writable:!1}),(0,r.defineGetter)(this,"t",(0,a.getTranslator)(t),{writable:!1}),l.set(this,{hooks:{}}),u=null,this.pluginName=null,this.pluginsInitializedCallbacks=[],this.isPluginsReady=!1,this.enabled=!1,this.initialized=!1,this.hot.addHook("afterPluginsInitialized",function(){return n.onAfterPluginsInitialized()}),this.hot.addHook("afterUpdateSettings",function(){return n.onUpdateSettings()}),this.hot.addHook("beforeInit",function(){return n.init()})}return o(e,[{key:"init",value:function(){this.pluginName=(0,s.getPluginName)(this.hot,this),this.isEnabled&&this.isEnabled()&&this.enablePlugin(),u||(u=(0,s.getRegistredPluginNames)(this.hot)),u.indexOf(this.pluginName)>=0&&u.splice(u.indexOf(this.pluginName),1),u.length||this.hot.runHooks("afterPluginsInitialized"),this.initialized=!0}},{key:"enablePlugin",value:function(){this.enabled=!0}},{key:"disablePlugin",value:function(){this.eventManager&&this.eventManager.clear(),this.clearHooks(),this.enabled=!1}},{key:"addHook",value:function(e,t){l.get(this).hooks[e]=l.get(this).hooks[e]||[];var n=l.get(this).hooks[e];this.hot.addHook(e,t),n.push(t),l.get(this).hooks[e]=n}},{key:"removeHooks",value:function(e){var t=this;(0,i.arrayEach)(l.get(this).hooks[e]||[],function(n){t.hot.removeHook(e,n)})}},{key:"clearHooks",value:function(){var e=this,t=l.get(this).hooks;(0,r.objectEach)(t,function(t,n){return e.removeHooks(n)}),t.length=0}},{key:"callOnPluginsReady",value:function(e){this.isPluginsReady?e():this.pluginsInitializedCallbacks.push(e)}},{key:"onAfterPluginsInitialized",value:function(){(0,i.arrayEach)(this.pluginsInitializedCallbacks,function(e){return e()}),this.pluginsInitializedCallbacks.length=0,this.isPluginsReady=!0}},{key:"onUpdateSettings",value:function(){this.isEnabled&&(this.enabled&&!this.isEnabled()&&this.disablePlugin(),!this.enabled&&this.isEnabled()&&this.enablePlugin(),this.enabled&&this.isEnabled()&&this.updatePlugin())}},{key:"updatePlugin",value:function(){}},{key:"destroy",value:function(){var e=this;this.eventManager&&this.eventManager.destroy(),this.clearHooks(),(0,r.objectEach)(this,function(t,n){"hot"!==n&&"t"!==n&&(e[n]=null)}),delete this.t,delete this.hot}}]),e}();t.default=c},function(e,t){var n=e.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(e,t,n){"use strict";t.__esModule=!0,t.getRegisteredEditors=t.getRegisteredEditorNames=t.hasEditor=t.getEditorInstance=t.getEditor=t.registerEditor=void 0,t.RegisteredEditor=k,t._getEditorInstance=S;var o=g(n(51)),r=g(n(8)),i=g(n(36)),a=g(n(147)),s=g(n(202)),l=g(n(203)),u=g(n(204)),c=g(n(148)),d=g(n(205)),h=g(n(206)),f=g(n(207)),p=g(n(208)),m=g(n(43));function g(e){return e&&e.__esModule?e:{default:e}}var v=new WeakMap,y=(0,o.default)("editors"),_=y.register,w=y.getItem,b=y.hasItem,C=y.getNames,M=y.getValues;function k(e){var t={},n=e;this.getConstructor=function(){return e},this.getInstance=function(e){return e.guid in t||(t[e.guid]=new n(e)),t[e.guid]},r.default.getSingleton().add("afterDestroy",function(){t={}})}function S(e,t){var n=void 0;if("function"==typeof e)v.get(e)||T(null,e),n=v.get(e);else{if("string"!=typeof e)throw Error('Only strings and functions can be passed as "editor" parameter');n=w(e)}if(!n)throw Error('No editor registered under name "'+e+'"');return n.getInstance(t)}function T(e,t){var n=new k(t);"string"==typeof e&&_(e,n),v.set(t,n)}T("base",i.default),T("autocomplete",a.default),T("checkbox",s.default),T("date",l.default),T("dropdown",u.default),T("handsontable",c.default),T("mobile",d.default),T("numeric",h.default),T("password",f.default),T("select",p.default),T("text",m.default),t.registerEditor=T,t.getEditor=function(e){if(!b(e))throw Error('No registered editor found under "'+e+'" name');return w(e).getConstructor()},t.getEditorInstance=S,t.hasEditor=b,t.getRegisteredEditorNames=C,t.getRegisteredEditors=M},function(e,t){e.exports=function(e){return"object"==typeof e?null!==e:"function"==typeof e}},function(e,t,n){"use strict";t.__esModule=!0,t.KEY_CODES=void 0,t.isPrintableChar=function(e){return 32==e||e>=48&&e<=57||e>=96&&e<=111||e>=186&&e<=192||e>=219&&e<=222||e>=226||e>=65&&e<=90},t.isMetaKey=function(e){return-1!==[r.ARROW_DOWN,r.ARROW_UP,r.ARROW_LEFT,r.ARROW_RIGHT,r.HOME,r.END,r.DELETE,r.BACKSPACE,r.F1,r.F2,r.F3,r.F4,r.F5,r.F6,r.F7,r.F8,r.F9,r.F10,r.F11,r.F12,r.TAB,r.PAGE_DOWN,r.PAGE_UP,r.ENTER,r.ESCAPE,r.SHIFT,r.CAPS_LOCK,r.ALT].indexOf(e)},t.isCtrlKey=function(e){return-1!==[r.CONTROL_LEFT,224,r.COMMAND_LEFT,r.COMMAND_RIGHT].indexOf(e)},t.isKey=function(e,t){var n=t.split("|"),i=!1;return(0,o.arrayEach)(n,function(t){if(e===r[t])return i=!0,!1}),i};var o=n(1),r=t.KEY_CODES={MOUSE_LEFT:1,MOUSE_RIGHT:3,MOUSE_MIDDLE:2,BACKSPACE:8,COMMA:188,INSERT:45,DELETE:46,END:35,ENTER:13,ESCAPE:27,CONTROL_LEFT:91,COMMAND_LEFT:17,COMMAND_RIGHT:93,ALT:18,HOME:36,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,SPACE:32,SHIFT:16,CAPS_LOCK:20,TAB:9,ARROW_RIGHT:39,ARROW_LEFT:37,ARROW_UP:38,ARROW_DOWN:40,F1:112,F2:113,F3:114,F4:115,F5:116,F6:117,F7:118,F8:119,F9:120,F10:121,F11:122,F12:123,A:65,X:88,C:67,V:86}},function(e,t,n){"use strict";t.__esModule=!0,t.normalizeSelection=function(e){return{start:e.getTopLeftCorner(),end:e.getBottomRightCorner()}},t.isSeparator=function(e){return(0,r.hasClass)(e,"htSeparator")},t.hasSubMenu=function(e){return(0,r.hasClass)(e,"htSubmenu")},t.isDisabled=function(e){return(0,r.hasClass)(e,"htDisabled")},t.isSelectionDisabled=function(e){return(0,r.hasClass)(e,"htSelectionDisabled")},t.getValidSelection=function(e){var t=e.getSelected();return t?t[0]<0?null:t:null},t.prepareVerticalAlignClass=a,t.prepareHorizontalAlignClass=s,t.getAlignmentClasses=function(e,t){for(var n={},o=e.from.row;o<=e.to.row;o++)for(var r=e.from.col;r<=e.to.col;r++)n[o]||(n[o]=[]),n[o][r]=t(o,r);return n},t.align=function(e,t,n,o,r){if(e.from.row==e.to.row&&e.from.col==e.to.col)l(e.from.row,e.from.col,t,n,o,r);else for(var i=e.from.row;i<=e.to.row;i++)for(var a=e.from.col;a<=e.to.col;a++)l(i,a,t,n,o,r)},t.checkSelectionConsistency=function(e,t){var n=!1;return e&&e.forAll(function(e,o){if(t(e,o))return n=!0,!1}),n},t.markLabelAsSelected=function(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e},t.isItemHidden=function(e,t){return!e.hidden||!("function"==typeof e.hidden&&e.hidden.call(t))},t.filterSeparators=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:i.KEY,n=e.slice(0);return n=function(e){var t=[];return(0,o.arrayEach)(e,function(e,n){n>0?t[t.length-1].name!==e.name&&t.push(e):t.push(e)}),t}(n=function(e,t){var n=e.slice(0);return n.reverse(),(n=u(n,t)).reverse(),n}(n=u(n,t),t))};var o=n(1),r=n(0),i=n(70);function a(e,t){return-1!=e.indexOf(t)?e:(e=e.replace("htTop","").replace("htMiddle","").replace("htBottom","").replace(" ",""),e+=" "+t)}function s(e,t){return-1!=e.indexOf(t)?e:(e=e.replace("htLeft","").replace("htCenter","").replace("htRight","").replace("htJustify","").replace(" ",""),e+=" "+t)}function l(e,t,n,o,r,i){var l=r(e,t),u=o;l.className&&(u="vertical"===n?a(l.className,o):s(l.className,o)),i(e,t,"className",u)}function u(e,t){for(var n=e.slice(0);0<n.length&&n[0].name===t;)n.shift();return n}},function(e,t,n){var o=n(15);e.exports=function(e){if(!o(e))throw TypeError(e+" is not an object!");return e}},function(e,t,n){var o=n(18),r=n(160),i=n(85),a=Object.defineProperty;t.f=n(21)?Object.defineProperty:function(e,t,n){if(o(e),t=i(t,!0),o(n),r)try{return a(e,t,n)}catch(e){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(e[t]=n.value),e}},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};function r(e){return void 0===e}t.stringify=function(e){var t=void 0;switch(void 0===e?"undefined":o(e)){case"string":case"number":t=""+e;break;case"object":t=null===e?"":e.toString();break;case"undefined":t="";break;default:t=e.toString()}return t},t.isDefined=function(e){return void 0!==e},t.isUndefined=r,t.isEmpty=function(e){return null===e||""===e||r(e)},t.isRegExp=function(e){return"[object RegExp]"===Object.prototype.toString.call(e)}},function(e,t,n){e.exports=!n(31)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(e,t){var n={}.hasOwnProperty;e.exports=function(e,t){return n.call(e,t)}},function(e,t,n){var o=n(76),r=n(30);e.exports=function(e){return o(r(e))}},function(e,t,n){var o=n(61),r=Math.min;e.exports=function(e){return e>0?r(o(e),9007199254740991):0}},function(e,t,n){"use strict";t.__esModule=!0,t.isIE8=function(){return o},t.isIE9=function(){return r},t.isSafari=function(){return i},t.isChrome=function(){return a},t.isMobileBrowser=function(e){return e||(e=navigator.userAgent),/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)};var o=!document.createTextNode("test").textContent,r=!!document.documentMode,i=/Safari/.test(navigator.userAgent)&&/Apple Computer/.test(navigator.vendor),a=/Chrome/.test(navigator.userAgent)&&/Google/.test(navigator.vendor)},function(e,t,n){"use strict";t.__esModule=!0,t.getRegisteredValidators=t.getRegisteredValidatorNames=t.hasValidator=t.getValidator=t.registerValidator=void 0;var o=l(n(51)),r=l(n(271)),i=l(n(272)),a=l(n(273)),s=l(n(274));function l(e){return e&&e.__esModule?e:{default:e}}var u=(0,o.default)("validators"),c=u.register,d=u.getItem,h=u.hasItem,f=u.getNames,p=u.getValues;c("autocomplete",r.default),c("date",i.default),c("numeric",a.default),c("time",s.default),t.registerValidator=c,t.getValidator=function(e){if("function"==typeof e)return e;if(!h(e))throw Error('No registered validator found under "'+e+'" name');return d(e)},t.hasValidator=h,t.getRegisteredValidatorNames=f,t.getRegisteredValidators=p},function(e,t,n){"use strict";t.__esModule=!0,t.toUpperCaseFirst=function(e){return e[0].toUpperCase()+e.substr(1)},t.equalsIgnoreCase=function(){for(var e=[],t=arguments.length,n=Array(t),r=0;r<t;r++)n[r]=arguments[r];for(var i=n.length;i--;){var a=(0,o.stringify)(n[i]).toLowerCase();-1===e.indexOf(a)&&e.push(a)}return 1===e.length},t.randomString=function(){function e(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)}return e()+e()+e()+e()},t.isPercentValue=function(e){return/^([0-9][0-9]?%$)|(^100%$)/.test(e)},t.substitute=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return(""+e).replace(/(?:\\)?\[([^[\]]+)]/g,function(e,n){return"\\"===e.charAt(0)?e.substr(1,e.length-1):void 0===t[n]?"":t[n]})},t.stripTags=function(e){return(e+="").replace(r,"")};var o=n(20);n(6);var r=/<\/?\w+\/?>|<\w+[\s|\/][^>]*>/gi},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(2),a=n(1),s=u(n(4)),l=u(n(137));function u(e){return e&&e.__esModule?e:{default:e}}var c={},d=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),(0,i.defineGetter)(this,"wot",t,{writable:!1}),this.instance=this.wot,this.type="",this.mainTableScrollableElement=null,this.TABLE=this.wot.wtTable.TABLE,this.hider=this.wot.wtTable.hider,this.spreader=this.wot.wtTable.spreader,this.holder=this.wot.wtTable.holder,this.wtRootElement=this.wot.wtTable.wtRootElement,this.trimmingContainer=(0,r.getTrimmingContainer)(this.hider.parentNode.parentNode),this.areElementSizesAdjusted=!1,this.updateStateOfRendering()}return o(e,null,[{key:"registerOverlay",value:function(t,n){if(-1===e.CLONE_TYPES.indexOf(t))throw new Error("Unsupported overlay ("+t+").");c[t]=n}},{key:"createOverlay",value:function(e,t){return new c[e](t)}},{key:"hasOverlay",value:function(e){return void 0!==c[e]}},{key:"isOverlayTypeOf",value:function(e,t){return!(!e||!c[t])&&e instanceof c[t]}},{key:"CLONE_TOP",get:function(){return"top"}},{key:"CLONE_BOTTOM",get:function(){return"bottom"}},{key:"CLONE_LEFT",get:function(){return"left"}},{key:"CLONE_TOP_LEFT_CORNER",get:function(){return"top_left_corner"}},{key:"CLONE_BOTTOM_LEFT_CORNER",get:function(){return"bottom_left_corner"}},{key:"CLONE_DEBUG",get:function(){return"debug"}},{key:"CLONE_TYPES",get:function(){return[e.CLONE_TOP,e.CLONE_BOTTOM,e.CLONE_LEFT,e.CLONE_TOP_LEFT_CORNER,e.CLONE_BOTTOM_LEFT_CORNER,e.CLONE_DEBUG]}}]),o(e,[{key:"updateStateOfRendering",value:function(){var e=this.needFullRender;this.needFullRender=this.shouldBeRendered();var t=e!==this.needFullRender;return t&&!this.needFullRender&&this.reset(),t}},{key:"shouldBeRendered",value:function(){return!0}},{key:"updateTrimmingContainer",value:function(){this.trimmingContainer=(0,r.getTrimmingContainer)(this.hider.parentNode.parentNode)}},{key:"updateMainScrollableElement",value:function(){this.mainTableScrollableElement=(0,r.getScrollableElement)(this.wot.wtTable.TABLE)}},{key:"makeClone",value:function(t){if(-1===e.CLONE_TYPES.indexOf(t))throw new Error('Clone type "'+t+'" is not supported.');var n=document.createElement("DIV"),o=document.createElement("TABLE");n.className="ht_clone_"+t+" handsontable",n.style.position="absolute",n.style.top=0,n.style.left=0,n.style.overflow="hidden",o.className=this.wot.wtTable.TABLE.className,n.appendChild(o),this.type=t,this.wot.wtTable.wtRootElement.parentNode.appendChild(n);var i=this.wot.getSetting("preventOverflow");return!0===i||"horizontal"===i&&this.type===e.CLONE_TOP||"vertical"===i&&this.type===e.CLONE_LEFT?this.mainTableScrollableElement=window:this.mainTableScrollableElement=(0,r.getScrollableElement)(this.wot.wtTable.TABLE),new l.default({cloneSource:this.wot,cloneOverlay:this,table:o})}},{key:"refresh",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.shouldBeRendered();this.clone&&(this.needFullRender||t)&&this.clone.draw(e),this.needFullRender=t}},{key:"reset",value:function(){if(this.clone){var e=this.clone.wtTable.holder,t=this.clone.wtTable.hider,n=e.style,o=t.style,r=e.parentNode.style;(0,a.arrayEach)([n,o,r],function(e){e.width="",e.height=""})}}},{key:"destroy",value:function(){new s.default(this.clone).destroy()}}]),e}();t.default=d},function(e,t,n){var o=n(71);e.exports=function(e,t,n){if(o(e),void 0===t)return e;switch(n){case 1:return function(n){return e.call(t,n)};case 2:return function(n,o){return e.call(t,n,o)};case 3:return function(n,o,r){return e.call(t,n,o,r)}}return function(){return e.apply(t,arguments)}}},function(e,t){e.exports=function(e){if(null==e)throw TypeError("Can't call method on "+e);return e}},function(e,t){e.exports=function(e){try{return!!e()}catch(e){return!0}}},function(e,t,n){var o=n(19),r=n(40);e.exports=n(21)?function(e,t,n){return o.f(e,t,r(1,n))}:function(e,t,n){return e[t]=n,e}},function(e,t,n){var o=n(13),r=n(32),i=n(22),a=n(49)("src"),s=Function.toString,l=(""+s).split("toString");n(44).inspectSource=function(e){return s.call(e)},(e.exports=function(e,t,n,s){var u="function"==typeof n;u&&(i(n,"name")||r(n,"name",t)),e[t]!==n&&(u&&(i(n,a)||r(n,a,e[t]?""+e[t]:l.join(String(t)))),e===o?e[t]=n:s?e[t]?e[t]=n:r(e,t,n):(delete e[t],r(e,t,n)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[a]||s.call(this)})},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.requestAnimationFrame=function(e){return s.call(window,e)},t.cancelAnimationFrame=function(e){l.call(window,e)},t.isTouchSupported=function(){return"ontouchstart"in window},t.isWebComponentSupportedNatively=function(){var e=document.createElement("div");return!(!e.createShadowRoot||!e.createShadowRoot.toString().match(/\[native code\]/))},t.hasCaptionProblem=function(){return void 0===r&&function(){var e=document.createElement("TABLE");e.style.borderSpacing=0,e.style.borderWidth=0,e.style.padding=0;var t=document.createElement("TBODY");e.appendChild(t),t.appendChild(document.createElement("TR")),t.firstChild.appendChild(document.createElement("TD")),t.firstChild.firstChild.innerHTML="<tr><td>t<br>t</td></tr>";var n=document.createElement("CAPTION");n.innerHTML="c<br>c<br>c<br>c",n.style.padding=0,n.style.margin=0,e.insertBefore(n,t),document.body.appendChild(e),r=e.offsetHeight<2*e.lastChild.offsetHeight,document.body.removeChild(e)}(),r},t.getComparisonFunction=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return c||(c="object"===("undefined"==typeof Intl?"undefined":o(Intl))?new Intl.Collator(e,t).compare:"function"==typeof String.prototype.localeCompare?function(e,t){return(""+e).localeCompare(t)}:function(e,t){return e===t?0:e>t?-1:1})};for(var r,i=0,a=["ms","moz","webkit","o"],s=window.requestAnimationFrame,l=window.cancelAnimationFrame,u=0;u<a.length&&!s;++u)s=window[a[u]+"RequestAnimationFrame"],l=window[a[u]+"CancelAnimationFrame"]||window[a[u]+"CancelRequestAnimationFrame"];s||(s=function(e){var t=(new Date).getTime(),n=Math.max(0,16-(t-i)),o=window.setTimeout(function(){e(t+n)},n);return i=t+n,o}),l||(l=function(e){clearTimeout(e)});var c=void 0},function(e,t,n){"use strict";t.__esModule=!0,t.isFunction=function(e){return"function"==typeof e},t.throttle=r,t.throttleAfterHits=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:10,o=r(e,t),i=n;function a(){return i?(i--,e.apply(this,arguments)):o.apply(this,arguments)}return a.clearHits=function(){i=n},a},t.debounce=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=null,o=void 0;return function(){var r=this,i=arguments;return n&&clearTimeout(n),n=setTimeout(function(){o=e.apply(r,i)},t),o}},t.pipe=function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];var r=t[0],i=t.slice(1);return function(){return(0,o.arrayReduce)(i,function(e,t){return t(e)},r.apply(this,arguments))}},t.partial=function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),o=1;o<t;o++)n[o-1]=arguments[o];return function(){for(var t=arguments.length,o=Array(t),r=0;r<t;r++)o[r]=arguments[r];return e.apply(this,n.concat(o))}},t.curry=function(e){var t=e.length;return function n(o){return function(){for(var r=arguments.length,i=Array(r),a=0;a<r;a++)i[a]=arguments[a];var s=o.concat(i);return s.length>=t?e.apply(this,s):n(s)}}([])},t.curryRight=function(e){var t=e.length;return function n(o){return function(){for(var r=arguments.length,i=Array(r),a=0;a<r;a++)i[a]=arguments[a];var s=o.concat(i.reverse());return s.length>=t?e.apply(this,s):n(s)}}([])};var o=n(1);function r(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:200,n=0,o={lastCallThrottled:!0},r=null;return function(){var i=this,a=arguments,s=Date.now(),l=!1;o.lastCallThrottled=!0,n||(n=s,l=!0);var u=t-(s-n);return l?(o.lastCallThrottled=!1,e.apply(this,a)):(r&&clearTimeout(r),r=setTimeout(function(){o.lastCallThrottled=!1,e.apply(i,a),n=0,r=void 0},u)),o}}},function(e,t,n){"use strict";t.__esModule=!0,t.EditorState=void 0;var o=n(11),r=n(20),i=t.EditorState={VIRGIN:"STATE_VIRGIN",EDITING:"STATE_EDITING",WAITING:"STATE_WAITING",FINISHED:"STATE_FINISHED"};function a(e){this.instance=e,this.state=i.VIRGIN,this._opened=!1,this._fullEditMode=!1,this._closeCallback=null,this.init()}a.prototype._fireCallbacks=function(e){this._closeCallback&&(this._closeCallback(e),this._closeCallback=null)},a.prototype.init=function(){},a.prototype.getValue=function(){throw Error("Editor getValue() method unimplemented")},a.prototype.setValue=function(e){throw Error("Editor setValue() method unimplemented")},a.prototype.open=function(){throw Error("Editor open() method unimplemented")},a.prototype.close=function(){throw Error("Editor close() method unimplemented")},a.prototype.prepare=function(e,t,n,o,r,a){this.TD=o,this.row=e,this.col=t,this.prop=n,this.originalValue=r,this.cellProperties=a;var s=!document.activeElement||document.activeElement&&void 0===document.activeElement.nodeName;this.instance.view.isMouseDown()&&document.activeElement&&document.activeElement!==document.body&&!s?document.activeElement.blur():s&&document.body.focus(),this.state=i.VIRGIN},a.prototype.extend=function(){var e=this.constructor;return function(e,t){function n(){}return n.prototype=t.prototype,e.prototype=new n,e.prototype.constructor=e,e}(function(){e.apply(this,arguments)},e)},a.prototype.saveValue=function(e,t){var n=void 0,o=void 0;t?((n=this.instance.getSelected())[0]>n[2]&&(o=n[0],n[0]=n[2],n[2]=o),n[1]>n[3]&&(o=n[1],n[1]=n[3],n[3]=o)):n=[this.row,this.col,null,null],this.instance.populateFromArray(n[0],n[1],e,n[2],n[3],"edit")},a.prototype.beginEditing=function(e,t){this.state==i.VIRGIN&&(this.instance.view.scrollViewport(new o.CellCoords(this.row,this.col)),this.instance.view.render(),this.state=i.EDITING,e="string"==typeof e?e:this.originalValue,this.setValue((0,r.stringify)(e)),this.open(t),this._opened=!0,this.focus(),this.instance.view.render(),this.instance.runHooks("afterBeginEditing",this.row,this.col))},a.prototype.finishEditing=function(e,t,n){var o,r=this;if(n){var a=this._closeCallback;this._closeCallback=function(e){a&&a(e),n(e),r.instance.view.render()}}if(!this.isWaiting())if(this.state!=i.VIRGIN){if(this.state==i.EDITING){if(e)return this.cancelChanges(),void this.instance.view.render();var s=this.getValue();o=this.instance.getSettings().trimWhitespace?[["string"==typeof s?String.prototype.trim.call(s||""):s]]:[[s]],this.state=i.WAITING,this.saveValue(o,t),this.instance.getCellValidator(this.cellProperties)?this.instance.addHookOnce("postAfterValidate",function(e){r.state=i.FINISHED,r.discardEditor(e)}):(this.state=i.FINISHED,this.discardEditor(!0))}}else this.instance._registerTimeout(setTimeout(function(){r._fireCallbacks(!0)},0))},a.prototype.cancelChanges=function(){this.state=i.FINISHED,this.discardEditor()},a.prototype.discardEditor=function(e){this.state===i.FINISHED&&(!1===e&&!0!==this.cellProperties.allowInvalid?(this.instance.selectCell(this.row,this.col),this.focus(),this.state=i.EDITING,this._fireCallbacks(!1)):(this.close(),this._opened=!1,this._fullEditMode=!1,this.state=i.VIRGIN,this._fireCallbacks(!0)))},a.prototype.enableFullEditMode=function(){this._fullEditMode=!0},a.prototype.isInFullEditMode=function(){return this._fullEditMode},a.prototype.isOpened=function(){return this._opened},a.prototype.isWaiting=function(){return this.state===i.WAITING},a.prototype.checkEditorSection=function(){var e=this.instance.countRows(),t="";return this.row<this.instance.getSettings().fixedRowsTop?t=this.col<this.instance.getSettings().fixedColumnsLeft?"top-left-corner":"top":this.instance.getSettings().fixedRowsBottom&&this.row>=e-this.instance.getSettings().fixedRowsBottom?t=this.col<this.instance.getSettings().fixedColumnsLeft?"bottom-left-corner":"bottom":this.col<this.instance.getSettings().fixedColumnsLeft&&(t="left"),t},t.default=a},function(e,t,n){var o=n(10)("unscopables"),r=Array.prototype;null==r[o]&&n(32)(r,o,{}),e.exports=function(e){r[o][e]=!0}},function(e,t){var n={}.toString;e.exports=function(e){return n.call(e).slice(8,-1)}},function(e,t,n){var o=n(169),r=n(74);e.exports=Object.keys||function(e){return o(e,r)}},function(e,t){e.exports=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}}},function(e,t,n){var o=n(30);e.exports=function(e){return Object(o(e))}},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),void 0!==t&&void 0!==n?(this.row=t,this.col=n):(this.row=null,this.col=null)}return o(e,[{key:"isValid",value:function(e){return!(this.row<0||this.col<0||this.row>=e.getSetting("totalRows")||this.col>=e.getSetting("totalColumns"))}},{key:"isEqual",value:function(e){return e===this||this.row===e.row&&this.col===e.col}},{key:"isSouthEastOf",value:function(e){return this.row>=e.row&&this.col>=e.col}},{key:"isNorthWestOf",value:function(e){return this.row<=e.row&&this.col<=e.col}},{key:"isSouthWestOf",value:function(e){return this.row>=e.row&&this.col<=e.col}},{key:"isNorthEastOf",value:function(e){return this.row<=e.row&&this.col>=e.col}}]),e}();t.default=r},function(e,t,n){"use strict";t.__esModule=!0;var o=n(0),r=c(n(183)),i=n(36),a=c(i),s=c(n(4)),l=n(16),u=n(7);function c(e){return e&&e.__esModule?e:{default:e}}var d=a.default.prototype.extend();d.prototype.init=function(){var e=this;this.createElements(),this.eventManager=new s.default(this),this.bindEvents(),this.autoResize=(0,r.default)(),this.instance.addHook("afterDestroy",function(){e.destroy()})},d.prototype.getValue=function(){return this.TEXTAREA.value},d.prototype.setValue=function(e){this.TEXTAREA.value=e};var h=function(e){var t,n=this.getActiveEditor();if(t=(e.ctrlKey||e.metaKey)&&!e.altKey,e.target===n.TEXTAREA&&!(0,u.isImmediatePropagationStopped)(e))if(17!==e.keyCode&&224!==e.keyCode&&91!==e.keyCode&&93!==e.keyCode){switch(e.keyCode){case l.KEY_CODES.ARROW_RIGHT:case l.KEY_CODES.ARROW_LEFT:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&(0,u.stopImmediatePropagation)(e);break;case l.KEY_CODES.ARROW_UP:case l.KEY_CODES.ARROW_DOWN:n.isInFullEditMode()&&(!n.isWaiting()&&!n.allowKeyEventPropagation||!n.isWaiting()&&n.allowKeyEventPropagation&&!n.allowKeyEventPropagation(e.keyCode))&&(0,u.stopImmediatePropagation)(e);break;case l.KEY_CODES.ENTER:var r=n.instance.getSelected(),i=!(r[0]===r[2]&&r[1]===r[3]);if(t&&!i||e.altKey){if(n.isOpened()){var a=(0,o.getCaretPosition)(n.TEXTAREA),s=n.getValue(),c=s.slice(0,a)+"\n"+s.slice(a);n.setValue(c),(0,o.setCaretPosition)(n.TEXTAREA,a+1)}else n.beginEditing(n.originalValue+"\n");(0,u.stopImmediatePropagation)(e)}e.preventDefault();break;case l.KEY_CODES.A:case l.KEY_CODES.X:case l.KEY_CODES.C:case l.KEY_CODES.V:t&&(0,u.stopImmediatePropagation)(e);break;case l.KEY_CODES.BACKSPACE:case l.KEY_CODES.DELETE:case l.KEY_CODES.HOME:case l.KEY_CODES.END:(0,u.stopImmediatePropagation)(e)}-1===[l.KEY_CODES.ARROW_UP,l.KEY_CODES.ARROW_RIGHT,l.KEY_CODES.ARROW_DOWN,l.KEY_CODES.ARROW_LEFT].indexOf(e.keyCode)&&n.autoResize.resize(String.fromCharCode(e.keyCode))}else(0,u.stopImmediatePropagation)(e)};d.prototype.open=function(){this.refreshDimensions(),this.instance.addHook("beforeKeyDown",h)},d.prototype.close=function(e){this.textareaParentStyle.display="none",this.autoResize.unObserve(),document.activeElement===this.TEXTAREA&&this.instance.listen(),this.instance.removeHook("beforeKeyDown",h)},d.prototype.focus=function(){this.TEXTAREA.focus(),(0,o.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length)},d.prototype.createElements=function(){this.TEXTAREA=document.createElement("TEXTAREA"),(0,o.addClass)(this.TEXTAREA,"handsontableInput"),this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,this.TEXTAREA_PARENT=document.createElement("DIV"),(0,o.addClass)(this.TEXTAREA_PARENT,"handsontableInputHolder"),this.textareaParentStyle=this.TEXTAREA_PARENT.style,this.textareaParentStyle.top=0,this.textareaParentStyle.left=0,this.textareaParentStyle.display="none",this.TEXTAREA_PARENT.appendChild(this.TEXTAREA),this.instance.rootElement.appendChild(this.TEXTAREA_PARENT);var e=this;this.instance._registerTimeout(setTimeout(function(){e.refreshDimensions()},0))},d.prototype.getEditedCell=function(){var e;switch(this.checkEditorSection()){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=101;break;case"top-left-corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"bottom-left-corner":e=this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;case"bottom":e=this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.textareaParentStyle.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.textareaParentStyle.zIndex=""}return-1!=e&&-2!=e?e:void 0},d.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},d.prototype.refreshDimensions=function(){if(this.state===i.EditorState.EDITING)if(this.TD=this.getEditedCell(),this.TD){var e,t=(0,o.offset)(this.TD),n=(0,o.offset)(this.instance.rootElement),r=(0,o.getScrollableElement)(this.TD),a=this.instance.countRows(),s=t.top===n.top?0:1,l=t.top-n.top-s-(r.scrollTop||0),u=t.left-n.left-1-(r.scrollLeft||0),c=this.instance.getSettings(),d=(this.instance.hasRowHeaders(),this.instance.hasColHeaders()),h=this.checkEditorSection(),f=this.TD.style.backgroundColor;switch(h){case"top":e=(0,o.getCssTransform)(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=(0,o.getCssTransform)(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=(0,o.getCssTransform)(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=(0,o.getCssTransform)(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=(0,o.getCssTransform)(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}(d&&0===this.instance.getSelected()[0]||c.fixedRowsBottom&&this.instance.getSelected()[0]===a-c.fixedRowsBottom)&&(l+=1),0===this.instance.getSelected()[1]&&(u+=1),e&&-1!=e?this.textareaParentStyle[e[0]]=e[1]:(0,o.resetCssTransform)(this.TEXTAREA_PARENT),this.textareaParentStyle.top=l+"px",this.textareaParentStyle.left=u+"px";var p=this.instance.view.wt.wtViewport.rowsRenderCalculator.startPosition,m=this.instance.view.wt.wtViewport.columnsRenderCalculator.startPosition,g=this.instance.view.wt.wtOverlays.leftOverlay.getScrollPosition(),v=this.instance.view.wt.wtOverlays.topOverlay.getScrollPosition(),y=(0,o.getScrollbarWidth)(),_=this.TD.offsetTop+p-v,w=this.TD.offsetLeft+m-g,b=(0,o.innerWidth)(this.TD)-8,C=(0,o.hasVerticalScrollbar)(r)?y:0,M=(0,o.hasHorizontalScrollbar)(r)?y:0,k=this.instance.view.maximumVisibleElementWidth(w)-9-C,S=this.TD.scrollHeight+1,T=Math.max(this.instance.view.maximumVisibleElementHeight(_)-M,23),L=(0,o.getComputedStyle)(this.TD);this.TEXTAREA.style.fontSize=L.fontSize,this.TEXTAREA.style.fontFamily=L.fontFamily,this.TEXTAREA.style.backgroundColor="",this.TEXTAREA.style.backgroundColor=f||(0,o.getComputedStyle)(this.TEXTAREA).backgroundColor,this.autoResize.init(this.TEXTAREA,{minHeight:Math.min(S,T),maxHeight:T,minWidth:Math.min(b,k),maxWidth:k},!0),this.textareaParentStyle.display="block"}else this.close(!0)},d.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.TEXTAREA,"cut",function(e){(0,u.stopPropagation)(e)}),this.eventManager.addEventListener(this.TEXTAREA,"paste",function(e){(0,u.stopPropagation)(e)}),this.instance.addHook("afterScrollHorizontally",function(){e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterRowResize",function(){e.refreshDimensions(),e.focus()}),this.instance.addHook("afterDestroy",function(){e.eventManager.destroy()})},d.prototype.destroy=function(){this.eventManager.destroy()},t.default=d},function(e,t){var n=e.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(e,t){e.exports={}},function(e,t,n){var o=n(49)("meta"),r=n(15),i=n(22),a=n(19).f,s=0,l=Object.isExtensible||function(){return!0},u=!n(31)(function(){return l(Object.preventExtensions({}))}),c=function(e){a(e,o,{value:{i:"O"+ ++s,w:{}}})},d=e.exports={KEY:o,NEED:!1,fastKey:function(e,t){if(!r(e))return"symbol"==typeof e?e:("string"==typeof e?"S":"P")+e;if(!i(e,o)){if(!l(e))return"F";if(!t)return"E";c(e)}return e[o].i},getWeak:function(e,t){if(!i(e,o)){if(!l(e))return!0;if(!t)return!1;c(e)}return e[o].w},onFreeze:function(e){return u&&d.NEED&&l(e)&&!i(e,o)&&c(e),e}}},function(e,t){t.f={}.propertyIsEnumerable},function(e,t,n){var o=n(19).f,r=n(22),i=n(10)("toStringTag");e.exports=function(e,t,n){e&&!r(e=n?e:e.prototype,i)&&o(e,i,{configurable:!0,value:t})}},function(e,t){var n=0,o=Math.random();e.exports=function(e){return"Symbol(".concat(void 0===e?"":e,")_",(++n+o).toString(36))}},function(e,t,n){"use strict";var o;t.__esModule=!0,t.ITEMS=t.UNDO=t.SEPARATOR=t.ROW_BELOW=t.ROW_ABOVE=t.REMOVE_ROW=t.REMOVE_COLUMN=t.REDO=t.READ_ONLY=t.COLUMN_RIGHT=t.COLUMN_LEFT=t.CLEAR_COLUMN=t.ALIGNMENT=void 0;var r=n(223);Object.defineProperty(t,"ALIGNMENT",{enumerable:!0,get:function(){return r.KEY}});var i=n(224);Object.defineProperty(t,"CLEAR_COLUMN",{enumerable:!0,get:function(){return i.KEY}});var a=n(225);Object.defineProperty(t,"COLUMN_LEFT",{enumerable:!0,get:function(){return a.KEY}});var s=n(226);Object.defineProperty(t,"COLUMN_RIGHT",{enumerable:!0,get:function(){return s.KEY}});var l=n(227);Object.defineProperty(t,"READ_ONLY",{enumerable:!0,get:function(){return l.KEY}});var u=n(228);Object.defineProperty(t,"REDO",{enumerable:!0,get:function(){return u.KEY}});var c=n(229);Object.defineProperty(t,"REMOVE_COLUMN",{enumerable:!0,get:function(){return c.KEY}});var d=n(230);Object.defineProperty(t,"REMOVE_ROW",{enumerable:!0,get:function(){return d.KEY}});var h=n(231);Object.defineProperty(t,"ROW_ABOVE",{enumerable:!0,get:function(){return h.KEY}});var f=n(232);Object.defineProperty(t,"ROW_BELOW",{enumerable:!0,get:function(){return f.KEY}});var p=n(70);Object.defineProperty(t,"SEPARATOR",{enumerable:!0,get:function(){return p.KEY}});var m=n(233);Object.defineProperty(t,"UNDO",{enumerable:!0,get:function(){return m.KEY}}),t.predefinedItems=function(){var e={};return(0,g.objectEach)(R,function(t,n){e[n]=t()}),e},t.addItem=function(e,t){-1===E.indexOf(e)&&(R[e]=t)};var g=n(2),v=D(r),y=D(i),_=D(a),w=D(s),b=D(l),C=D(u),M=D(c),k=D(d),S=D(h),T=D(f),L=D(p),x=D(m);function D(e){return e&&e.__esModule?e:{default:e}}function O(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var E=t.ITEMS=[h.KEY,f.KEY,a.KEY,s.KEY,i.KEY,d.KEY,c.KEY,m.KEY,u.KEY,l.KEY,r.KEY,p.KEY],R=(O(o={},p.KEY,L.default),O(o,h.KEY,S.default),O(o,f.KEY,T.default),O(o,a.KEY,_.default),O(o,s.KEY,w.default),O(o,i.KEY,y.default),O(o,d.KEY,k.default),O(o,c.KEY,M.default),O(o,m.KEY,x.default),O(o,u.KEY,C.default),O(o,l.KEY,b.default),O(o,r.KEY,v.default),o)},function(e,t,n){"use strict";function o(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}t.__esModule=!0,t.default=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"common";r.has(e)||r.set(e,new Map);var t=r.get(e);return{register:function(e,n){t.set(e,n)},getItem:function(e){return t.get(e)},hasItem:function(e){return t.has(e)},getNames:function(){return[].concat(o(t.keys()))},getValues:function(){return[].concat(o(t.values()))}}};var r=t.collection=new Map},function(e,t){e.exports=function(e,t,n,o){if(!(e instanceof t)||void 0!==o&&o in e)throw TypeError(n+": incorrect invocation!");return e}},function(e,t,n){var o=n(29),r=n(76),i=n(41),a=n(24),s=n(278);e.exports=function(e,t){var n=1==e,l=2==e,u=3==e,c=4==e,d=6==e,h=5==e||d,f=t||s;return function(t,s,p){for(var m,g,v=i(t),y=r(v),_=o(s,p,3),w=a(y.length),b=0,C=n?f(t,w):l?f(t,0):void 0;w>b;b++)if((h||b in y)&&(g=_(m=y[b],b,v),e))if(n)C[b]=g;else if(g)switch(e){case 3:return!0;case 5:return m;case 6:return b;case 2:C.push(m)}else if(c)return!1;return d?-1:u||c?c:C}}},function(e,t,n){"use strict";var o=n(13),r=n(3),i=n(33),a=n(59),s=n(46),l=n(56),u=n(52),c=n(15),d=n(31),h=n(77),f=n(48),p=n(281);e.exports=function(e,t,n,m,g,v){var y=o[e],_=y,w=g?"set":"add",b=_&&_.prototype,C={},M=function(e){var t=b[e];i(b,e,"delete"==e?function(e){return!(v&&!c(e))&&t.call(this,0===e?0:e)}:"has"==e?function(e){return!(v&&!c(e))&&t.call(this,0===e?0:e)}:"get"==e?function(e){return v&&!c(e)?void 0:t.call(this,0===e?0:e)}:"add"==e?function(e){return t.call(this,0===e?0:e),this}:function(e,n){return t.call(this,0===e?0:e,n),this})};if("function"==typeof _&&(v||b.forEach&&!d(function(){(new _).entries().next()}))){var k=new _,S=k[w](v?{}:-0,1)!=k,T=d(function(){k.has(1)}),L=h(function(e){new _(e)}),x=!v&&d(function(){for(var e=new _,t=5;t--;)e[w](t,t);return!e.has(-0)});L||((_=t(function(t,n){u(t,_,e);var o=p(new y,t,_);return null!=n&&l(n,g,o[w],o),o})).prototype=b,b.constructor=_),(T||x)&&(M("delete"),M("has"),g&&M("get")),(x||S)&&M(w),v&&b.clear&&delete b.clear}else _=m.getConstructor(t,e,g,w),a(_.prototype,n),s.NEED=!0;return f(_,e),C[e]=_,r(r.G+r.W+r.F*(_!=y),C),v||m.setStrong(_,e,g),_}},function(e,t,n){"use strict";var o=n(32),r=n(33),i=n(31),a=n(30),s=n(10);e.exports=function(e,t,n){var l=s(e),u=n(a,l,""[e]),c=u[0],d=u[1];i(function(){var t={};return t[l]=function(){return 7},7!=""[e](t)})&&(r(String.prototype,e,c),o(RegExp.prototype,l,2==t?function(e,t){return d.call(e,this,t)}:function(e){return d.call(e,this)}))}},function(e,t,n){var o=n(29),r=n(165),i=n(161),a=n(18),s=n(24),l=n(176),u={},c={};(t=e.exports=function(e,t,n,d,h){var f,p,m,g,v=h?function(){return e}:l(e),y=o(n,d,t?2:1),_=0;if("function"!=typeof v)throw TypeError(e+" is not iterable!");if(i(v)){for(f=s(e.length);f>_;_++)if((g=t?y(a(p=e[_])[0],p[1]):y(e[_]))===u||g===c)return g}else for(m=v.call(e);!(p=m.next()).done;)if((g=r(m,y,p.value,t))===u||g===c)return g}).BREAK=u,t.RETURN=c},function(e,t){e.exports=!1},function(e,t){t.f=Object.getOwnPropertySymbols},function(e,t,n){var o=n(33);e.exports=function(e,t,n){for(var r in t)o(e,r,t[r],n);return e}},function(e,t,n){var o=n(61),r=Math.max,i=Math.min;e.exports=function(e,t){return(e=o(e))<0?r(e+t,0):i(e,t)}},function(e,t){var n=Math.ceil,o=Math.floor;e.exports=function(e){return isNaN(e=+e)?0:(e>0?o:n)(e)}},function(t,n){t.exports=e},function(e,t,n){"use strict";t.__esModule=!0,t.getRegisteredCellTypes=t.getRegisteredCellTypeNames=t.hasCellType=t.getCellType=t.registerCellType=void 0;var o=g(n(51)),r=n(14),i=n(9),a=n(26),s=g(n(190)),l=g(n(191)),u=g(n(192)),c=g(n(193)),d=g(n(194)),h=g(n(195)),f=g(n(196)),p=g(n(197)),m=g(n(198));function g(e){return e&&e.__esModule?e:{default:e}}var v=(0,o.default)("cellTypes"),y=v.register,_=v.getItem,w=v.hasItem,b=v.getNames,C=v.getValues;function M(e,t){var n=t.editor,o=t.renderer,s=t.validator;n&&(0,r.registerEditor)(e,n),o&&(0,i.registerRenderer)(e,o),s&&(0,a.registerValidator)(e,s),y(e,t)}M("autocomplete",s.default),M("checkbox",l.default),M("date",u.default),M("dropdown",c.default),M("handsontable",d.default),M("numeric",h.default),M("password",f.default),M("text",p.default),M("time",m.default),t.registerCellType=M,t.getCellType=function(e){if(!w(e))throw Error('You declared cell type "'+e+'" as a string that is not mapped to a known object.\n Cell type must be an object or a string mapped to an object registered by "Handsontable.cellTypes.registerCellType" method');return _(e)},t.hasCellType=w,t.getRegisteredCellTypeNames=b,t.getRegisteredCellTypes=C},function(e,t,n){"use strict";t.__esModule=!0;var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(o=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&s.return&&s.return()}finally{if(r)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.default=function(e,t){var n,D,R,A,H,Y,P=this,N=function(){},I=new f.default(P);(0,p.extend)(N.prototype,L.default.prototype),(0,p.extend)(N.prototype,t),(0,p.extend)(N.prototype,V(t)),this.rootElement=e,this.isHotTableEnv=(0,a.isChildOfWebComponentTable)(this.rootElement),f.default.isHotTableEnv=this.isHotTableEnv,this.container=document.createElement("DIV"),this.renderCall=!1,e.insertBefore(this.container,e.firstChild),this.guid="ht_"+(0,_.randomString)();var W=(0,k.getTranslator)(P);function j(){var e=!1;return{validatorsInQueue:0,valid:!0,addValidatorToQueue:function(){this.validatorsInQueue++,e=!1},removeValidatorFormQueue:function(){this.validatorsInQueue=this.validatorsInQueue-1<0?0:this.validatorsInQueue-1,this.checkIfQueueIsEmpty()},onQueueEmpty:function(e){},checkIfQueueIsEmpty:function(){0==this.validatorsInQueue&&0==e&&(e=!0,this.onQueueEmpty(this.valid))}}}function F(e,t,n){var o=new j;o.onQueueEmpty=function(){var o;e.length&&(o=P.runHooks("beforeChange",e,t),(0,l.isFunction)(o)?console.warn("Your beforeChange callback returns a function. It's not supported since Handsontable 0.12.1 (and the returned function will not be executed)."):!1===o&&e.splice(0,e.length)),n()};for(var r=e.length-1;r>=0;r--)if(null===e[r])e.splice(r,1);else{var s=e[r][0],c=D.propToCol(e[r][1]),d=P.getCellMeta(s,c);if("numeric"===d.type&&"string"==typeof e[r][3]&&e[r][3].length>0&&(/^-?[\d\s]*(\.|,)?\d*$/.test(e[r][3])||d.format)){var h=e[r][3].length;(0,u.isUndefined)(d.language)?i.default.culture("en-US"):e[r][3].indexOf(".")===h-3&&-1===e[r][3].indexOf(",")?i.default.culture("en-US"):i.default.culture(d.language),i.default.cultureData(i.default.culture()).delimiters,i.default.validate(e[r][3])&&!isNaN(e[r][3])?e[r][3]=parseFloat(e[r][3]):e[r][3]=(0,i.default)().unformat(e[r][3])||e[r][3]}P.getCellValidator(d)&&(o.addValidatorToQueue(),P.validateCell(e[r][3],d,function(t,n){return function(r){if("boolean"!=typeof r)throw new Error("Validation error: result is not boolean");if(!1===r&&!1===n.allowInvalid){e.splice(t,1),n.valid=!0;var i=P.getCell(n.row,n.col);(0,a.removeClass)(i,P.getSettings().invalidCellClassName),--t}o.removeValidatorFormQueue()}}(r,d),t))}o.checkIfQueueIsEmpty()}function z(e,t){var o=e.length-1;if(!(o<0)){for(;o>=0;o--){var r=!1;if(null!==e[o]){if(null!=e[o][2]||null!=e[o][3]){if(n.settings.allowInsertRow)for(;e[o][0]>P.countRows()-1;)if(0===D.createRow(void 0,void 0,t)){r=!0;break}if(!r){if("array"===P.dataType&&(!n.settings.columns||0===n.settings.columns.length)&&n.settings.allowInsertColumn)for(;D.propToCol(e[o][1])>P.countCols()-1;)D.createCol(void 0,void 0,t);D.set(e[o][0],e[o][1],e[o][3])}}}else e.splice(o,1)}P.forceFullRender=!0,A.adjustRowsAndCols(),P.runHooks("beforeChangeRender",e,t),H.refreshBorders(null,!0),P.view.wt.wtOverlays.adjustElementsSize(),P.runHooks("afterChange",e,t||"edit");var i=P.getActiveEditor();i&&(0,u.isDefined)(i.refreshValue)&&i.refreshValue()}}function B(e,t,n){return"object"===(void 0===e?"undefined":r(e))?e:[[e,t,n]]}function V(e){if((0,p.hasOwnProperty)(e,"type")){var t,n={};for(var o in"object"===r(e.type)?t=e.type:"string"==typeof e.type&&(t=(0,x.getCellType)(e.type)),t)(0,p.hasOwnProperty)(t,o)&&!(0,p.hasOwnProperty)(e,o)&&(n[o]=t[o]);return n}}R=new C.default(P),this.rootElement.id&&"ht_"!==this.rootElement.id.substring(0,3)||(this.rootElement.id=this.guid),n={cellSettings:[],columnSettings:[],columnsSettingConflicts:["data","width"],settings:new N,selRange:null,isPopulated:null,scrollable:null,firstRun:!0},A={alter:function(e,t,o,r,i){var a;function s(e,t,n,o){var r=(0,m.arrayMap)(new Array(n),function(){return e=void 0,"array"===o?e=[]:"object"===o&&(e={}),e;var e});r.unshift(t,0),e.splice.apply(e,O(r))}switch(o=o||1,e){case"insert_row":var l=P.countSourceRows();if(P.getSettings().maxRows===l)return;t=(0,u.isDefined)(t)?t:l,a=D.createRow(t,o,r),s(n.cellSettings,t,o,"array"),a&&(H.isSelected()&&n.selRange.from.row>=t?(n.selRange.from.row+=a,H.transformEnd(a,0)):H.refreshBorders());break;case"insert_col":a=D.createCol(t,o,r);for(var c=0,d=P.countSourceRows();c<d;c++)n.cellSettings[c]&&s(n.cellSettings[c],t,o);if(a){if(Array.isArray(P.getSettings().colHeaders)){var h=[t,0];h.length+=a,Array.prototype.splice.apply(P.getSettings().colHeaders,h)}H.isSelected()&&n.selRange.from.col>=t?(n.selRange.from.col+=a,H.transformEnd(0,a)):H.refreshBorders()}break;case"remove_row":D.removeRow(t,o,r),n.cellSettings.splice(t,o);var f=P.countRows(),p=P.getSettings().fixedRowsTop;p>=t+1&&(P.getSettings().fixedRowsTop-=Math.min(o,p-t));var g=P.getSettings().fixedRowsBottom;g&&t>=f-g&&(P.getSettings().fixedRowsBottom-=Math.min(o,g)),A.adjustRowsAndCols(),H.refreshBorders();break;case"remove_col":var v=W.toPhysicalColumn(t);D.removeCol(t,o,r);for(var y=0,_=P.countSourceRows();y<_;y++)n.cellSettings[y]&&n.cellSettings[y].splice(v,o);var w=P.getSettings().fixedColumnsLeft;w>=t+1&&(P.getSettings().fixedColumnsLeft-=Math.min(o,w-t)),Array.isArray(P.getSettings().colHeaders)&&(void 0===v&&(v=-1),P.getSettings().colHeaders.splice(v,o)),A.adjustRowsAndCols(),H.refreshBorders();break;default:throw new Error('There is no such action "'+e+'"')}i||A.adjustRowsAndCols()},adjustRowsAndCols:function(){if(n.settings.minRows){var e=P.countRows();if(e<n.settings.minRows)for(var t=0,o=n.settings.minRows;t<o-e;t++)D.createRow(P.countRows(),1,"auto")}if(n.settings.minSpareRows){var r=P.countEmptyRows(!0);if(r<n.settings.minSpareRows)for(;r<n.settings.minSpareRows&&P.countSourceRows()<n.settings.maxRows;r++)D.createRow(P.countRows(),1,"auto")}var i=void 0;if((n.settings.minCols||n.settings.minSpareCols)&&(i=P.countEmptyCols(!0)),n.settings.minCols&&!n.settings.columns&&P.countCols()<n.settings.minCols)for(;P.countCols()<n.settings.minCols;i++)D.createCol(P.countCols(),1,"auto");if(n.settings.minSpareCols&&!n.settings.columns&&"array"===P.dataType&&i<n.settings.minSpareCols)for(;i<n.settings.minSpareCols&&P.countCols()<n.settings.maxCols;i++)D.createCol(P.countCols(),1,"auto");var a=P.countRows(),s=P.countCols();if(0!==a&&0!==s||H.deselect(),H.isSelected()){var l=!1,u=n.selRange.from.row,c=n.selRange.from.col,d=n.selRange.to.row,h=n.selRange.to.col;u>a-1?(l=!0,d>(u=a-1)&&(d=u)):d>a-1&&(l=!0,u>(d=a-1)&&(u=d)),c>s-1?(l=!0,h>(c=s-1)&&(h=c)):h>s-1&&(l=!0,c>(h=s-1)&&(c=h)),l&&P.selectCell(u,c,d,h)}P.view&&P.view.wt.wtOverlays.adjustElementsSize()},populateFromArray:function(e,t,o,i,a,s,l){var c,d,h,f,m,g,v,y,_=[],w={};if(0===(d=t.length))return!1;switch(null===o||o.row,null===o||o.col,a){case"shift_down":for(m=o?o.col-e.col+1:0,g=o?o.row-e.row+1:0,h=0,f=(t=(0,M.translateRowsToColumns)(t)).length,v=Math.max(f,m);h<v;h++)if(h<f){var b;for(c=0,d=t[h].length;c<g-d;c++)t[h].push(t[h][c%d]);t[h].unshift(e.col+h,e.row,0),(b=P).spliceCol.apply(b,O(t[h]))}else{var C;t[h%f][0]=e.col+h,(C=P).spliceCol.apply(C,O(t[h%f]))}break;case"shift_right":for(m=o?o.col-e.col+1:0,g=o?o.row-e.row+1:0,c=0,d=t.length,y=Math.max(d,g);c<y;c++)if(c<d){var k;for(h=0,f=t[c].length;h<m-f;h++)t[c].push(t[c][h%f]);t[c].unshift(e.row+c,e.col,0),(k=P).spliceRow.apply(k,O(t[c]))}else{var S;t[c%d][0]=e.row+c,(S=P).spliceRow.apply(S,O(t[c%d]))}break;case"overwrite":default:w.row=e.row,w.col=e.col;var T={row:o&&e?o.row-e.row+1:1,col:o&&e?o.col-e.col+1:1},L=0,x=0,D=!0,E=void 0,R=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,o=t[e%t.length];return null!==n?o[n%o.length]:o},A=t.length,H=o?o.row-e.row+1:0;for(d=o?H:Math.max(A,H),c=0;c<d&&!(o&&w.row>o.row&&H>A||!n.settings.allowInsertRow&&w.row>P.countRows()-1||w.row>=n.settings.maxRows);c++){var Y=c-L,N=R(Y).length,I=o?o.col-e.col+1:0;if(f=o?I:Math.max(N,I),w.col=e.col,E=P.getCellMeta(w.row,w.col),"CopyPaste.paste"!==i&&"Autofill.autofill"!==i||!E.skipRowOnPaste){for(x=0,h=0;h<f&&!(o&&w.col>o.col&&I>N||!n.settings.allowInsertColumn&&w.col>P.countCols()-1||w.col>=n.settings.maxCols);h++)if(E=P.getCellMeta(w.row,w.col),"CopyPaste.paste"!==i&&"Autofill.fill"!==i||!E.skipColumnOnPaste)if(E.readOnly)w.col++;else{var W=h-x,j=R(Y,W),F=P.getDataAtCell(w.row,w.col),z={row:Y,col:W};if("Autofill.fill"===i){var B=P.runHooks("beforeAutofillInsidePopulate",z,s,t,l,{},T);B&&(j=(0,u.isUndefined)(B.value)?j:B.value)}if(null!==j&&"object"===(void 0===j?"undefined":r(j)))if(null===F||"object"!==(void 0===F?"undefined":r(F)))D=!1;else{var V=(0,p.duckSchema)(F[0]||F),U=(0,p.duckSchema)(j[0]||j);(0,p.isObjectEquals)(V,U)?j=(0,p.deepClone)(j):D=!1}else null!==F&&"object"===(void 0===F?"undefined":r(F))&&(D=!1);D&&_.push([w.row,w.col,j]),D=!0,w.col++}else x++,w.col++,f++;w.row++}else L++,w.row++,d++}P.setDataAtCell(_,null,null,i||"populateFromArray")}}},this.selection=H={inProgress:!1,selectedHeader:{cols:!1,rows:!1},setSelectedHeaders:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];P.selection.selectedHeader.rows=e,P.selection.selectedHeader.cols=t,P.selection.selectedHeader.corner=n},begin:function(){P.selection.inProgress=!0},finish:function(){var e=P.getSelected();P.runHooks("afterSelectionEnd",e[0],e[1],e[2],e[3]),P.runHooks("afterSelectionEndByProp",e[0],P.colToProp(e[1]),e[2],P.colToProp(e[3])),P.selection.inProgress=!1},isInProgress:function(){return P.selection.inProgress},setRangeStart:function(e,t){P.runHooks("beforeSetRangeStart",e),n.selRange=new S.CellRange(e,e,e),H.setRangeEnd(e,null,t)},setRangeStartOnly:function(e){P.runHooks("beforeSetRangeStartOnly",e),n.selRange=new S.CellRange(e,e,e)},setRangeEnd:function(e,t,o){if(null!==n.selRange){var r,i=!1,s=!0,l=P.view.wt.wtTable.getFirstVisibleRow(),u=P.view.wt.wtTable.getFirstVisibleColumn(),c={row:null,col:null};P.runHooks("beforeSetRangeEnd",e),P.selection.begin(),c.row=e.row<0?l:e.row,c.col=e.col<0?u:e.col,n.selRange.to=new S.CellCoords(c.row,c.col),n.settings.multiSelect||(n.selRange.from=e),P.view.wt.selections.current.clear(),"string"==typeof(r=P.getCellMeta(n.selRange.highlight.row,n.selRange.highlight.col).disableVisualSelection)&&(r=[r]),(!1===r||Array.isArray(r)&&-1===r.indexOf("current"))&&P.view.wt.selections.current.add(n.selRange.highlight),P.view.wt.selections.area.clear(),(!1===r||Array.isArray(r)&&-1===r.indexOf("area"))&&H.isMultiple()&&(P.view.wt.selections.area.add(n.selRange.from),P.view.wt.selections.area.add(n.selRange.to)),(n.settings.currentHeaderClassName||n.settings.currentRowClassName||n.settings.currentColClassName)&&(P.view.wt.selections.highlight.clear(),P.view.wt.selections.highlight.add(n.selRange.from),P.view.wt.selections.highlight.add(n.selRange.to));var d=(0,p.createObjectPropListener)("value");P.runHooks("afterSelection",n.selRange.from.row,n.selRange.from.col,n.selRange.to.row,n.selRange.to.col,d),P.runHooks("afterSelectionByProp",n.selRange.from.row,D.colToProp(n.selRange.from.col),n.selRange.to.row,D.colToProp(n.selRange.to.col),d),(0===n.selRange.from.row&&n.selRange.to.row===P.countRows()-1&&P.countRows()>1||0===n.selRange.from.col&&n.selRange.to.col===P.countCols()-1&&P.countCols()>1)&&(i=!0),(e.row<0||e.col<0)&&(s=!1),d.isTouched()&&(t=!d.value),!1!==t&&!i&&s&&(n.selRange.from&&!H.isMultiple()?P.view.scrollViewport(n.selRange.from):P.view.scrollViewport(e)),H.selectedHeader.rows&&H.selectedHeader.cols?(0,a.addClass)(P.rootElement,["ht__selection--rows","ht__selection--columns"]):H.selectedHeader.rows?((0,a.removeClass)(P.rootElement,"ht__selection--columns"),(0,a.addClass)(P.rootElement,"ht__selection--rows")):H.selectedHeader.cols?((0,a.removeClass)(P.rootElement,"ht__selection--rows"),(0,a.addClass)(P.rootElement,"ht__selection--columns")):(0,a.removeClass)(P.rootElement,["ht__selection--rows","ht__selection--columns"]),H.refreshBorders(null,o)}},refreshBorders:function(e,t){t||Y.destroyEditor(e),P.view.render(),H.isSelected()&&!t&&Y.prepareEditor()},isMultiple:function(){var e=!(n.selRange.to.col===n.selRange.from.col&&n.selRange.to.row===n.selRange.from.row),t=P.runHooks("afterIsMultipleSelection",e);if(e)return t},transformStart:function(e,t,o,r){var i,a,s,l,u=new S.CellCoords(e,t),c=0,d=0;P.runHooks("modifyTransformStart",u),i=P.countRows(),a=P.countCols(),l=P.getSettings().fixedRowsBottom,n.selRange.highlight.row+e>i-1?o&&n.settings.minSpareRows>0&&!(l&&n.selRange.highlight.row>=i-l-1)?(P.alter("insert_row",i),i=P.countRows()):n.settings.autoWrapCol&&(u.row=1-i,u.col=n.selRange.highlight.col+u.col==a-1?1-a:1):n.settings.autoWrapCol&&n.selRange.highlight.row+u.row<0&&n.selRange.highlight.col+u.col>=0&&(u.row=i-1,u.col=n.selRange.highlight.col+u.col==0?a-1:-1),n.selRange.highlight.col+u.col>a-1?o&&n.settings.minSpareCols>0?(P.alter("insert_col",a),a=P.countCols()):n.settings.autoWrapRow&&(u.row=n.selRange.highlight.row+u.row==i-1?1-i:1,u.col=1-a):n.settings.autoWrapRow&&n.selRange.highlight.col+u.col<0&&n.selRange.highlight.row+u.row>=0&&(u.row=n.selRange.highlight.row+u.row==0?i-1:-1,u.col=a-1),(s=new S.CellCoords(n.selRange.highlight.row+u.row,n.selRange.highlight.col+u.col)).row<0?(c=-1,s.row=0):s.row>0&&s.row>=i&&(c=1,s.row=i-1),s.col<0?(d=-1,s.col=0):s.col>0&&s.col>=a&&(d=1,s.col=a-1),P.runHooks("afterModifyTransformStart",s,c,d),H.setRangeStart(s,r)},transformEnd:function(e,t){var o,r,i,a=new S.CellCoords(e,t),s=0,l=0;P.runHooks("modifyTransformEnd",a),o=P.countRows(),r=P.countCols(),(i=new S.CellCoords(n.selRange.to.row+a.row,n.selRange.to.col+a.col)).row<0?(s=-1,i.row=0):i.row>0&&i.row>=o&&(s=1,i.row=o-1),i.col<0?(l=-1,i.col=0):i.col>0&&i.col>=r&&(l=1,i.col=r-1),P.runHooks("afterModifyTransformEnd",i,s,l),H.setRangeEnd(i,!0)},isSelected:function(){return null!==n.selRange},inInSelection:function(e){return!!H.isSelected()&&n.selRange.includes(e)},deselect:function(){H.isSelected()&&(P.selection.inProgress=!1,n.selRange=null,P.view.wt.selections.current.clear(),P.view.wt.selections.area.clear(),(n.settings.currentHeaderClassName||n.settings.currentRowClassName||n.settings.currentColClassName)&&P.view.wt.selections.highlight.clear(),Y.destroyEditor(),H.refreshBorders(),(0,a.removeClass)(P.rootElement,["ht__selection--rows","ht__selection--columns"]),P.runHooks("afterDeselect"))},selectAll:function(){n.settings.multiSelect&&(H.setSelectedHeaders(!0,!0,!0),H.setRangeStart(new S.CellCoords(0,0)),H.setRangeEnd(new S.CellCoords(P.countRows()-1,P.countCols()-1),!1))},empty:function(){if(H.isSelected()){var e,t,o=n.selRange.getTopLeftCorner(),r=n.selRange.getBottomRightCorner(),i=[];for(e=o.row;e<=r.row;e++)for(t=o.col;t<=r.col;t++)P.getCellMeta(e,t).readOnly||i.push([e,t,""]);P.setDataAtCell(i)}}},this.init=function(){R.setData(n.settings.data),P.runHooks("beforeInit"),(0,c.isMobileBrowser)()&&(0,a.addClass)(P.rootElement,"mobile"),this.updateSettings(n.settings,!0),this.view=new b.default(this),Y=new h.default(P,n,H,D),this.forceFullRender=!0,P.runHooks("init"),this.view.render(),"object"===r(n.firstRun)&&(P.runHooks("afterChange",n.firstRun[0],n.firstRun[1]),n.firstRun=!1),P.runHooks("afterInit")},this.validateCell=function(e,t,n,o){var r=P.getCellValidator(t);function i(e){var o=t.visualCol,r=t.visualRow,i=P.getCell(r,o,!0);i&&"TH"!=i.nodeName&&P.view.wt.wtSettings.settings.cellRenderer(r,o,i),n(e)}(0,u.isRegExp)(r)&&(r=function(e){return function(t,n){n(e.test(t))}}(r)),(0,l.isFunction)(r)?(e=P.runHooks("beforeValidate",e,t.visualRow,t.prop,o),P._registerTimeout(setTimeout(function(){r.call(t,e,function(n){n=P.runHooks("afterValidate",n,e,t.visualRow,t.prop,o),t.valid=n,i(n),P.runHooks("postAfterValidate",n,e,t.visualRow,t.prop,o)})},0))):P._registerTimeout(setTimeout(function(){t.valid=!0,i(t.valid)},0))},this.setDataAtCell=function(e,t,n,o){var i,a,s,l=B(e,t,n),u=[];for(i=0,a=l.length;i<a;i++){if("object"!==r(l[i]))throw new Error("Method `setDataAtCell` accepts row number or changes array of arrays as its first parameter");if("number"!=typeof l[i][1])throw new Error("Method `setDataAtCell` accepts row and column number as its parameters. If you want to use object property name, use method `setDataAtRowProp`");s=D.colToProp(l[i][1]),u.push([l[i][0],s,R.getAtCell(W.toPhysicalRow(l[i][0]),l[i][1]),l[i][2]])}o||"object"!==(void 0===e?"undefined":r(e))||(o=t),P.runHooks("afterSetDataAtCell",u,o),F(u,o,function(){z(u,o)})},this.setDataAtRowProp=function(e,t,n,o){var i,a,s=B(e,t,n),l=[];for(i=0,a=s.length;i<a;i++)l.push([s[i][0],s[i][1],R.getAtCell(W.toPhysicalRow(s[i][0]),s[i][1]),s[i][2]]);o||"object"!==(void 0===e?"undefined":r(e))||(o=t),P.runHooks("afterSetDataAtRowProp",l,o),F(l,o,function(){z(l,o)})},this.listen=function(){E=P.guid},this.unlisten=function(){E=null},this.isListening=function(){return E===P.guid},this.destroyEditor=function(e){H.refreshBorders(e)},this.populateFromArray=function(e,t,n,o,i,a,s,l,u){var c;if("object"!==(void 0===n?"undefined":r(n))||"object"!==r(n[0]))throw new Error("populateFromArray parameter `input` must be an array of arrays");return c="number"==typeof o?new S.CellCoords(o,i):null,A.populateFromArray(new S.CellCoords(e,t),n,c,a,s,l,u)},this.spliceCol=function(e,t,n){var o;return(o=D).spliceCol.apply(o,arguments)},this.spliceRow=function(e,t,n){var o;return(o=D).spliceRow.apply(o,arguments)},this.getSelected=function(){if(H.isSelected())return[n.selRange.from.row,n.selRange.from.col,n.selRange.to.row,n.selRange.to.col]},this.getSelectedRange=function(){if(H.isSelected())return n.selRange},this.render=function(){P.view&&(P.renderCall=!0,P.forceFullRender=!0,H.refreshBorders(null,!0))},this.loadData=function(e){if(Array.isArray(n.settings.dataSchema)?P.dataType="array":(0,l.isFunction)(n.settings.dataSchema)?P.dataType="function":P.dataType="object",D&&D.destroy(),D=new d.default(P,n,N),"object"===(void 0===e?"undefined":r(e))&&null!==e)e.push&&e.splice||(e=[e]);else{if(null!==e)throw new Error("loadData only accepts array of objects or array of arrays ("+(void 0===e?"undefined":r(e))+" given)");var t;e=[];var o,i=0,a=D.getSchema();for(i=0,o=n.settings.startRows;i<o;i++)if("object"!==P.dataType&&"function"!==P.dataType||!n.settings.dataSchema)if("array"===P.dataType)t=(0,p.deepClone)(a[0]),e.push(t);else{t=[];for(var s=0,u=n.settings.startCols;s<u;s++)t.push(null);e.push(t)}else t=(0,p.deepClone)(a),e.push(t)}n.isPopulated=!1,N.prototype.data=e,Array.isArray(e[0])&&(P.dataType="array"),D.dataSource=e,R.data=e,R.dataType=P.dataType,R.colToProp=D.colToProp.bind(D),R.propToCol=D.propToCol.bind(D),n.cellSettings.length=0,A.adjustRowsAndCols(),P.runHooks("afterLoadData",n.firstRun),n.firstRun?n.firstRun=[null,"loadData"]:(P.runHooks("afterChange",null,"loadData"),P.render()),n.isPopulated=!0},this.getData=function(e,t,n,o){return(0,u.isUndefined)(e)?D.getAll():D.getRange(new S.CellCoords(e,t),new S.CellCoords(n,o),D.DESTINATION_RENDERER)},this.getCopyableText=function(e,t,n,o){return D.getCopyableText(new S.CellCoords(e,t),new S.CellCoords(n,o))},this.getCopyableData=function(e,t){return D.getCopyable(e,D.colToProp(t))},this.getSchema=function(){return D.getSchema()},this.updateSettings=function(e,t){var o=!1,r=void 0,i=void 0,c=void 0;if((0,u.isDefined)(e.rows))throw new Error('"rows" setting is no longer supported. do you mean startRows, minRows or maxRows?');if((0,u.isDefined)(e.cols))throw new Error('"cols" setting is no longer supported. do you mean startCols, minCols or maxCols?');for(r in e)"data"!==r&&(T.default.getSingleton().getRegistered().indexOf(r)>-1?((0,l.isFunction)(e[r])||Array.isArray(e[r]))&&(e[r].initialHook=!0,P.addHook(r,e[r])):!t&&(0,p.hasOwnProperty)(e,r)&&(N.prototype[r]=e[r]));void 0===e.data&&void 0===n.settings.data?P.loadData(null):void 0!==e.data?P.loadData(e.data):void 0!==e.columns&&D.createMap(),c=P.countCols();var d=e.columns||N.prototype.columns;if(d&&(0,l.isFunction)(d)&&(c=P.countSourceCols(),o=!0),void 0===e.cell&&void 0===e.cells&&void 0===e.columns||(n.cellSettings.length=0),c>0){var h=void 0,f=void 0;for(r=0,i=0;r<c;r++)o&&!d(r)||(n.columnSettings[i]=(0,s.columnFactory)(N,n.columnsSettingConflicts),h=n.columnSettings[i].prototype,d&&(f=o?d(r):d[i])&&((0,p.extend)(h,f),(0,p.extend)(h,V(f))),i++)}if((0,u.isDefined)(e.cell))for(var m in e.cell)if((0,p.hasOwnProperty)(e.cell,m)){var g=e.cell[m];P.setCellMetaObject(g.row,g.col,g)}P.runHooks("afterCellMetaReset"),(0,u.isDefined)(e.className)&&(N.prototype.className&&(0,a.removeClass)(P.rootElement,N.prototype.className),e.className&&(0,a.addClass)(P.rootElement,e.className));var v=P.rootElement.style.height;""!==v&&(v=parseInt(P.rootElement.style.height,10));var y=e.height;if((0,l.isFunction)(y)&&(y=y()),t&&P.rootElement.getAttribute("style")&&P.rootElement.setAttribute("data-initialstyle",P.rootElement.getAttribute("style")),null===y){var _=P.rootElement.getAttribute("data-initialstyle");_&&(_.indexOf("height")>-1||_.indexOf("overflow")>-1)?P.rootElement.setAttribute("style",_):(P.rootElement.style.height="",P.rootElement.style.overflow="")}else void 0!==y&&(P.rootElement.style.height=y+"px",P.rootElement.style.overflow="hidden");if(void 0!==e.width){var w=e.width;(0,l.isFunction)(w)&&(w=w()),P.rootElement.style.width=w+"px"}t||(D.clearLengthCache(),P.view&&P.view.wt.wtViewport.resetHasOversizedColumnHeadersMarked(),P.runHooks("afterUpdateSettings")),A.adjustRowsAndCols(),P.view&&!n.firstRun&&(P.forceFullRender=!0,H.refreshBorders(null,!0)),t||!P.view||""!==v&&""!==y&&void 0!==y||v===y||P.view.wt.wtOverlays.updateMainScrollableElements()},this.getValue=function(){var e=P.getSelected();if(N.prototype.getValue){if((0,l.isFunction)(N.prototype.getValue))return N.prototype.getValue.call(P);if(e)return P.getData()[e[0]][N.prototype.getValue]}else if(e)return P.getDataAtCell(e[0],e[1])},this.getSettings=function(){return n.settings},this.clear=function(){H.selectAll(),H.empty()},this.alter=function(e,t,n,o,r){A.alter(e,t,n,o,r)},this.getCell=function(e,t,n){return P.view.getCellAtCoords(new S.CellCoords(e,t),n)},this.getCoords=function(e){return this.view.wt.wtTable.getCoords.call(this.view.wt.wtTable,e)},this.colToProp=function(e){return D.colToProp(e)},this.propToCol=function(e){return D.propToCol(e)},this.toVisualRow=function(e){return W.toVisualRow(e)},this.toVisualColumn=function(e){return W.toVisualColumn(e)},this.toPhysicalRow=function(e){return W.toPhysicalRow(e)},this.toPhysicalColumn=function(e){return W.toPhysicalColumn(e)},this.getDataAtCell=function(e,t){return D.get(e,D.colToProp(t))},this.getDataAtRowProp=function(e,t){return D.get(e,t)},this.getDataAtCol=function(e){var t=[];return t.concat.apply(t,O(D.getRange(new S.CellCoords(0,e),new S.CellCoords(n.settings.data.length-1,e),D.DESTINATION_RENDERER)))},this.getDataAtProp=function(e){var t,o=[];return t=D.getRange(new S.CellCoords(0,D.propToCol(e)),new S.CellCoords(n.settings.data.length-1,D.propToCol(e)),D.DESTINATION_RENDERER),o.concat.apply(o,O(t))},this.getSourceData=function(e,t,n,o){return void 0===e?R.getData():R.getByRange(new S.CellCoords(e,t),new S.CellCoords(n,o))},this.getSourceDataArray=function(e,t,n,o){return void 0===e?R.getData(!0):R.getByRange(new S.CellCoords(e,t),new S.CellCoords(n,o),!0)},this.getSourceDataAtCol=function(e){return R.getAtColumn(e)},this.getSourceDataAtRow=function(e){return R.getAtRow(e)},this.getSourceDataAtCell=function(e,t){return R.getAtCell(e,t)},this.getDataAtRow=function(e){return D.getRange(new S.CellCoords(e,0),new S.CellCoords(e,this.countCols()-1),D.DESTINATION_RENDERER)[0]||[]},this.getDataType=function(e,t,n,o){var r=this,i=null,a=null;void 0===e&&(e=0,n=this.countRows(),t=0,o=this.countCols()),void 0===n&&(n=e),void 0===o&&(o=t);var s="mixed";return(0,w.rangeEach)(Math.min(e,n),Math.max(e,n),function(e){var n=!0;return(0,w.rangeEach)(Math.min(t,o),Math.max(t,o),function(t){var o=r.getCellMeta(e,t);return a=o.type,i?n=i===a:i=a,n}),s=n?a:"mixed",n}),s},this.removeCellMeta=function(e,t,o){null!=P.getCellMeta(e,t)[o]&&delete n.cellSettings[e][t][o]},this.spliceCellsMeta=function(e,t){for(var o,r=arguments.length,i=Array(r>2?r-2:0),a=2;a<r;a++)i[a-2]=arguments[a];(o=n.cellSettings).splice.apply(o,[e,t].concat(i))},this.setCellMetaObject=function(e,t,n){if("object"===(void 0===n?"undefined":r(n)))for(var o in n)if((0,p.hasOwnProperty)(n,o)){var i=n[o];this.setCellMeta(e,t,o,i)}},this.setCellMeta=function(e,t,r,i){var a=W.toPhysical(e,t),l=o(a,2);e=l[0],t=l[1],n.columnSettings[t]||(n.columnSettings[t]=(0,s.columnFactory)(N,n.columnsSettingConflicts)),n.cellSettings[e]||(n.cellSettings[e]=[]),n.cellSettings[e][t]||(n.cellSettings[e][t]=new n.columnSettings[t]),n.cellSettings[e][t][r]=i,P.runHooks("afterSetCellMeta",e,t,r,i)},this.getCellsMeta=function(){return(0,m.arrayFlatten)(n.cellSettings)},this.getCellMeta=function(e,t){var r,i=D.colToProp(t),a=e,l=t,u=W.toPhysical(e,t),c=o(u,2);if(e=c[0],t=c[1],n.columnSettings[t]||(n.columnSettings[t]=(0,s.columnFactory)(N,n.columnsSettingConflicts)),n.cellSettings[e]||(n.cellSettings[e]=[]),n.cellSettings[e][t]||(n.cellSettings[e][t]=new n.columnSettings[t]),(r=n.cellSettings[e][t]).row=e,r.col=t,r.visualRow=a,r.visualCol=l,r.prop=i,r.instance=P,P.runHooks("beforeGetCellMeta",e,t,r),(0,p.extend)(r,V(r)),r.cells){var d=r.cells.call(r,e,t,i);d&&((0,p.extend)(r,d),(0,p.extend)(r,V(d)))}return P.runHooks("afterGetCellMeta",e,t,r),r},this.getCellMetaAtRow=function(e){return n.cellSettings[e]},this.isColumnModificationAllowed=function(){return!("object"===P.dataType||P.getSettings().columns)};var U=(0,M.cellMethodLookupFactory)("renderer");this.getCellRenderer=function(e,t){return(0,v.getRenderer)(U.call(this,e,t))},this.getCellEditor=(0,M.cellMethodLookupFactory)("editor");var K=(0,M.cellMethodLookupFactory)("validator");function G(){throw new Error("This method cannot be called because this Handsontable instance has been destroyed")}this.getCellValidator=function(e,t){var n=K.call(this,e,t);return"string"==typeof n&&(n=(0,y.getValidator)(n)),n},this.validateCells=function(e){var t=new j;e&&(t.onQueueEmpty=e);for(var n=P.countRows()-1;n>=0;){for(var o=P.countCols()-1;o>=0;)t.addValidatorToQueue(),P.validateCell(P.getDataAtCell(n,o),P.getCellMeta(n,o),function(e){if("boolean"!=typeof e)throw new Error("Validation error: result is not boolean");!1===e&&(t.valid=!1),t.removeValidatorFormQueue()},"validateCells"),o--;n--}t.checkIfQueueIsEmpty()},this.getRowHeader=function(e){var t=n.settings.rowHeaders;return void 0!==e&&(e=P.runHooks("modifyRowHeader",e)),void 0===e?(t=[],(0,w.rangeEach)(P.countRows()-1,function(e){t.push(P.getRowHeader(e))})):Array.isArray(t)&&void 0!==t[e]?t=t[e]:(0,l.isFunction)(t)?t=t(e):t&&"string"!=typeof t&&"number"!=typeof t&&(t=e+1),t},this.hasRowHeaders=function(){return!!n.settings.rowHeaders},this.hasColHeaders=function(){if(void 0!==n.settings.colHeaders&&null!==n.settings.colHeaders)return!!n.settings.colHeaders;for(var e=0,t=P.countCols();e<t;e++)if(P.getColHeader(e))return!0;return!1},this.getColHeader=function(e){var t=n.settings.columns&&(0,l.isFunction)(n.settings.columns),o=n.settings.colHeaders;if(void 0===(e=P.runHooks("modifyColHeader",e))){for(var r=[],i=t?P.countSourceCols():P.countCols(),a=0;a<i;a++)r.push(P.getColHeader(a));o=r}else{var s=e,u=function(e){for(var t=[],n=P.countSourceCols(),o=0;o<n;o++)(0,l.isFunction)(P.getSettings().columns)&&P.getSettings().columns(o)&&t.push(o);return t[e]}(e=P.runHooks("modifyCol",e));n.settings.columns&&(0,l.isFunction)(n.settings.columns)&&n.settings.columns(u)&&n.settings.columns(u).title?o=n.settings.columns(u).title:n.settings.columns&&n.settings.columns[e]&&n.settings.columns[e].title?o=n.settings.columns[e].title:Array.isArray(n.settings.colHeaders)&&void 0!==n.settings.colHeaders[e]?o=n.settings.colHeaders[e]:(0,l.isFunction)(n.settings.colHeaders)?o=n.settings.colHeaders(e):n.settings.colHeaders&&"string"!=typeof n.settings.colHeaders&&"number"!=typeof n.settings.colHeaders&&(o=(0,M.spreadsheetColumnLabel)(s))}return o},this._getColWidthFromSettings=function(e){var t=P.getCellMeta(0,e),o=t.width;if(void 0!==o&&o!==n.settings.width||(o=t.colWidths),null!=o){switch(void 0===o?"undefined":r(o)){case"object":o=o[e];break;case"function":o=o(e)}"string"==typeof o&&(o=parseInt(o,10))}return o},this.getColWidth=function(e){var t=P._getColWidthFromSettings(e);return void 0===(t=P.runHooks("modifyColWidth",t,e))&&(t=S.ViewportColumnsCalculator.DEFAULT_WIDTH),t},this._getRowHeightFromSettings=function(e){var t=n.settings.rowHeights;if(null!=t){switch(void 0===t?"undefined":r(t)){case"object":t=t[e];break;case"function":t=t(e)}"string"==typeof t&&(t=parseInt(t,10))}return t},this.getRowHeight=function(e){var t=P._getRowHeightFromSettings(e);return t=P.runHooks("modifyRowHeight",t,e)},this.countSourceRows=function(){return P.runHooks("modifySourceLength")||(P.getSourceData()?P.getSourceData().length:0)},this.countSourceCols=function(){var e=P.getSourceData()&&P.getSourceData()[0]?P.getSourceData()[0]:[];return(0,p.isObject)(e)?(0,p.deepObjectSize)(e):e.length||0},this.countRows=function(){return D.getLength()},this.countCols=function(){var e=this.getSettings().maxCols,t=!1,o=0;if("array"===P.dataType&&(t=n.settings.data&&n.settings.data[0]&&n.settings.data[0].length),t&&(o=n.settings.data[0].length),n.settings.columns)if((0,l.isFunction)(n.settings.columns))if("array"===P.dataType){for(var r=0,i=0;i<o;i++)n.settings.columns(i)&&r++;o=r}else"object"!==P.dataType&&"function"!==P.dataType||(o=D.colToPropCache.length);else o=n.settings.columns.length;else"object"!==P.dataType&&"function"!==P.dataType||(o=D.colToPropCache.length);return Math.min(e,o)},this.rowOffset=function(){return P.view.wt.wtTable.getFirstRenderedRow()},this.colOffset=function(){return P.view.wt.wtTable.getFirstRenderedColumn()},this.countRenderedRows=function(){return P.view.wt.drawn?P.view.wt.wtTable.getRenderedRowsCount():-1},this.countVisibleRows=function(){return P.view.wt.drawn?P.view.wt.wtTable.getVisibleRowsCount():-1},this.countRenderedCols=function(){return P.view.wt.drawn?P.view.wt.wtTable.getRenderedColumnsCount():-1},this.countVisibleCols=function(){return P.view.wt.drawn?P.view.wt.wtTable.getVisibleColumnsCount():-1},this.countEmptyRows=function(e){for(var t,n=P.countRows()-1,o=0;n>=0;){if(t=P.runHooks("modifyRow",n),P.isEmptyRow(t))o++;else if(e)break;n--}return o},this.countEmptyCols=function(e){if(P.countRows()<1)return 0;for(var t=P.countCols()-1,n=0;t>=0;){if(P.isEmptyCol(t))n++;else if(e)break;t--}return n},this.isEmptyRow=function(e){return n.settings.isEmptyRow.call(P,e)},this.isEmptyCol=function(e){return n.settings.isEmptyCol.call(P,e)},this.selectCell=function(e,t,o,r,i,a){var s;if(a=(0,u.isUndefined)(a)||!0===a,"number"!=typeof e||e<0||e>=P.countRows())return!1;if("number"!=typeof t||t<0||t>=P.countCols())return!1;if((0,u.isDefined)(o)){if("number"!=typeof o||o<0||o>=P.countRows())return!1;if("number"!=typeof r||r<0||r>=P.countCols())return!1}return s=new S.CellCoords(e,t),n.selRange=new S.CellRange(s,s,s),a&&P.listen(),(0,u.isUndefined)(o)?H.setRangeEnd(n.selRange.from,i):H.setRangeEnd(new S.CellCoords(o,r),i),P.selection.finish(),!0},this.selectCellByProp=function(e,t,n,o,r){var i;return arguments[1]=D.propToCol(arguments[1]),(0,u.isDefined)(arguments[3])&&(arguments[3]=D.propToCol(arguments[3])),(i=P).selectCell.apply(i,arguments)},this.deselectCell=function(){H.deselect()},this.scrollViewportTo=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(void 0!==e&&(e<0||e>=P.countRows()))return!1;if(void 0!==t&&(t<0||t>=P.countCols()))return!1;var r=!1;return void 0!==e&&void 0!==t&&(P.view.wt.wtOverlays.topOverlay.scrollTo(e,n),P.view.wt.wtOverlays.leftOverlay.scrollTo(t,o),r=!0),"number"==typeof e&&"number"!=typeof t&&(P.view.wt.wtOverlays.topOverlay.scrollTo(e,n),r=!0),"number"==typeof t&&"number"!=typeof e&&(P.view.wt.wtOverlays.leftOverlay.scrollTo(t,o),r=!0),r},this.destroy=function(){for(var e in P._clearTimeouts(),P.view&&P.view.destroy(),R&&R.destroy(),R=null,(0,a.empty)(P.rootElement),I.destroy(),P.runHooks("afterDestroy"),T.default.getSingleton().destroy(P),P)(0,p.hasOwnProperty)(P,e)&&((0,l.isFunction)(P[e])?P[e]=G:"guid"!==e&&(P[e]=null));D&&D.destroy(),D=null,n=null,A=null,H=null,Y=null,P=null,N=null},this.getActiveEditor=function(){return Y.getActiveEditor()},this.getPlugin=function(e){return(0,g.getPlugin)(this,e)},this.getInstance=function(){return P},this.addHook=function(e,t){T.default.getSingleton().add(e,t,P)},this.hasHook=function(e){return T.default.getSingleton().has(e,P)},this.addHookOnce=function(e,t){T.default.getSingleton().once(e,t,P)},this.removeHook=function(e,t){T.default.getSingleton().remove(e,t,P)},this.runHooks=function(e,t,n,o,r,i,a){return T.default.getSingleton().run(P,e,t,n,o,r,i,a)},this.timeouts=[],this._registerTimeout=function(e){this.timeouts.push(e)},this._clearTimeouts=function(){for(var e=0,t=this.timeouts.length;e<t;e++)clearTimeout(this.timeouts[e])},T.default.getSingleton().run(P,"construct")};var i=D(n(86)),a=n(0),s=n(66),l=n(35),u=n(20),c=n(25),d=D(n(199)),h=D(n(201)),f=D(n(4)),p=n(2),m=n(1),g=n(5),v=n(9),y=n(26),_=n(27),w=n(6),b=D(n(267)),C=D(n(200)),M=n(65),k=n(153),S=n(11),T=D(n(8)),L=D(n(87)),x=n(63);function D(e){return e&&e.__esModule?e:{default:e}}function O(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}var E=null},function(e,t,n){"use strict";t.__esModule=!0,t.spreadsheetColumnLabel=s,t.spreadsheetColumnIndex=function(e){var t=0;if(e)for(var n=0,o=e.length-1;n<e.length;n+=1,o-=1)t+=Math.pow(a,o)*(i.indexOf(e[n])+1);return--t},t.createSpreadsheetData=function(){var e,t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4,r=[];for(e=0;e<n;e++){var i=[];for(t=0;t<o;t++)i.push(s(t)+(e+1));r.push(i)}return r},t.createSpreadsheetObjectData=function(){var e,t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:100,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:4,r=[];for(e=0;e<n;e++){var i={};for(t=0;t<o;t++)i["prop"+t]=s(t)+(e+1);r.push(i)}return r},t.createEmptySpreadsheetData=function(e,t){for(var n=[],o=void 0,r=0;r<e;r++){o=[];for(var i=0;i<t;i++)o.push("");n.push(o)}return n},t.translateRowsToColumns=function(e){var t,n,o,r,i=[],a=0;for(t=0,n=e.length;t<n;t++)for(o=0,r=e[t].length;o<r;o++)o==a&&(i.push([]),a++),i[o].push(e[t][o]);return i},t.cellMethodLookupFactory=function(e,t){return t=void 0===t||t,function(n,i){return function n(i){if(i){if((0,r.hasOwnProperty)(i,e)&&void 0!==i[e])return i[e];if((0,r.hasOwnProperty)(i,"type")&&i.type){var a;if("string"!=typeof i.type)throw new Error("Cell type must be a string ");if(a=(0,o.getCellType)(i.type),(0,r.hasOwnProperty)(a,e))return a[e];if(t)return}return n(Object.getPrototypeOf(i))}}("number"==typeof n?this.getCellMeta(n,i):n)}};var o=n(63),r=n(2),i="ABCDEFGHIJKLMNOPQRSTUVWXYZ",a=i.length;function s(e){for(var t=e+1,n="",o=void 0;t>0;)o=(t-1)%a,n=String.fromCharCode(65+o)+n,t=parseInt((t-o)/a,10);return n}},function(e,t,n){"use strict";t.__esModule=!0,t.columnFactory=function(e,t){function n(){}(0,o.inherit)(n,e);for(var r=0,i=t.length;r<i;r++)n.prototype[t[r]]=void 0;return n};var o=n(2)},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(1),a=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this.container=null,this.injected=!1,this.rows=[],this.columns=[],this.samples=null,this.settings={useHeaders:!0}}return o(e,[{key:"addRow",value:function(e,t){if(this.columns.length)throw new Error("Doesn't support multi-dimensional table");this.rows.length||(this.container=this.createContainer(this.hot.rootElement.className));var n={row:e};this.rows.push(n),this.samples=t,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tr.appendChild(this.createRow(e)),this.container.container.appendChild(this.table.fragment),n.table=this.table.table}},{key:"addColumnHeadersRow",value:function(e){if(null!=this.hot.getColHeader(0)){var t={row:-1};this.rows.push(t),this.container=this.createContainer(this.hot.rootElement.className),this.samples=e,this.table=this.createTable(this.hot.table.className),this.table.colGroup.appendChild(this.createColGroupsCol()),this.table.tHead.appendChild(this.createColumnHeadersRow()),this.container.container.appendChild(this.table.fragment),t.table=this.table.table}}},{key:"addColumn",value:function(e,t){if(this.rows.length)throw new Error("Doesn't support multi-dimensional table");this.columns.length||(this.container=this.createContainer(this.hot.rootElement.className));var n={col:e};this.columns.push(n),this.samples=t,this.table=this.createTable(this.hot.table.className),this.getSetting("useHeaders")&&null!==this.hot.getColHeader(e)&&this.hot.view.appendColHeader(e,this.table.th),this.table.tBody.appendChild(this.createCol(e)),this.container.container.appendChild(this.table.fragment),n.table=this.table.table}},{key:"getHeights",value:function(e){this.injected||this.injectTable(),(0,i.arrayEach)(this.rows,function(t){e(t.row,(0,r.outerHeight)(t.table)-1)})}},{key:"getWidths",value:function(e){this.injected||this.injectTable(),(0,i.arrayEach)(this.columns,function(t){e(t.col,(0,r.outerWidth)(t.table))})}},{key:"setSettings",value:function(e){this.settings=e}},{key:"setSetting",value:function(e,t){this.settings||(this.settings={}),this.settings[e]=t}},{key:"getSettings",value:function(){return this.settings}},{key:"getSetting",value:function(e){return this.settings?this.settings[e]:null}},{key:"createColGroupsCol",value:function(){var e=this,t=document.createDocumentFragment();return this.hot.hasRowHeaders()&&t.appendChild(this.createColElement(-1)),this.samples.forEach(function(n){(0,i.arrayEach)(n.strings,function(n){t.appendChild(e.createColElement(n.col))})}),t}},{key:"createRow",value:function(e){var t=this,n=document,o=n.createDocumentFragment(),r=n.createElement("th");return this.hot.hasRowHeaders()&&(this.hot.view.appendRowHeader(e,r),o.appendChild(r)),this.samples.forEach(function(r){(0,i.arrayEach)(r.strings,function(r){var i=r.col,a=t.hot.getCellMeta(e,i);a.col=i,a.row=e;var s=t.hot.getCellRenderer(a),l=n.createElement("td");s(t.hot,l,e,i,t.hot.colToProp(i),r.value,a),o.appendChild(l)})}),o}},{key:"createColumnHeadersRow",value:function(){var e=this,t=document,n=t.createDocumentFragment();if(this.hot.hasRowHeaders()){var o=t.createElement("th");this.hot.view.appendColHeader(-1,o),n.appendChild(o)}return this.samples.forEach(function(o){(0,i.arrayEach)(o.strings,function(o){var r=o.col,i=t.createElement("th");e.hot.view.appendColHeader(r,i),n.appendChild(i)})}),n}},{key:"createCol",value:function(e){var t=this,n=document,o=n.createDocumentFragment();return this.samples.forEach(function(r){(0,i.arrayEach)(r.strings,function(r){var i=r.row,a=t.hot.getCellMeta(i,e);a.col=e,a.row=i;var s=t.hot.getCellRenderer(a),l=n.createElement("td"),u=n.createElement("tr");s(t.hot,l,i,e,t.hot.colToProp(e),r.value,a),u.appendChild(l),o.appendChild(u)})}),o}},{key:"clean",value:function(){this.rows.length=0,this.rows[-1]=void 0,this.columns.length=0,this.samples&&this.samples.clear(),this.samples=null,this.removeTable()}},{key:"injectTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.injected||((e||this.hot.rootElement).appendChild(this.container.fragment),this.injected=!0)}},{key:"removeTable",value:function(){this.injected&&this.container.container.parentNode&&(this.container.container.parentNode.removeChild(this.container.container),this.container=null,this.injected=!1)}},{key:"createColElement",value:function(e){var t=document.createElement("col");return t.style.width=this.hot.view.wt.wtTable.getStretchedColumnWidth(e)+"px",t}},{key:"createTable",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,n=t.createDocumentFragment(),o=t.createElement("table"),i=t.createElement("thead"),a=t.createElement("tbody"),s=t.createElement("colgroup"),l=t.createElement("tr"),u=t.createElement("th");return this.isVertical()&&o.appendChild(s),this.isHorizontal()&&(l.appendChild(u),i.appendChild(l),o.style.tableLayout="auto",o.style.width="auto"),o.appendChild(i),this.isVertical()&&a.appendChild(l),o.appendChild(a),(0,r.addClass)(o,e),n.appendChild(o),{fragment:n,table:o,tHead:i,tBody:a,colGroup:s,tr:l,th:u}}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=document,n=t.createDocumentFragment(),o=t.createElement("div");return e="htGhostTable htAutoSize "+e.trim(),(0,r.addClass)(o,e),n.appendChild(o),{fragment:n,container:o}}},{key:"isVertical",value:function(){return!(!this.rows.length||this.columns.length)}},{key:"isHorizontal",value:function(){return!(!this.columns.length||this.rows.length)}}]),e}();t.default=a},function(e,t,n){"use strict";var o=n(37),r=n(167),i=n(45),a=n(23);e.exports=n(166)(Array,"Array",function(e,t){this._t=a(e),this._i=0,this._k=t},function(){var e=this._t,t=this._k,n=this._i++;return!e||n>=e.length?(this._t=void 0,r(1)):r(0,"keys"==t?n:"values"==t?e[n]:[n,e[n]])},"values"),i.Arguments=i.Array,o("keys"),o("values"),o("entries")},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(42),a=(o=i)&&o.__esModule?o:{default:o},s=function(){function e(t,n,o){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.highlight=t,this.from=n,this.to=o}return r(e,[{key:"isValid",value:function(e){return this.from.isValid(e)&&this.to.isValid(e)}},{key:"isSingle",value:function(){return this.from.row===this.to.row&&this.from.col===this.to.col}},{key:"getHeight",value:function(){return Math.max(this.from.row,this.to.row)-Math.min(this.from.row,this.to.row)+1}},{key:"getWidth",value:function(){return Math.max(this.from.col,this.to.col)-Math.min(this.from.col,this.to.col)+1}},{key:"includes",value:function(e){var t=e.row,n=e.col,o=this.getTopLeftCorner(),r=this.getBottomRightCorner();return o.row<=t&&r.row>=t&&o.col<=n&&r.col>=n}},{key:"includesRange",value:function(e){return this.includes(e.getTopLeftCorner())&&this.includes(e.getBottomRightCorner())}},{key:"isEqual",value:function(e){return Math.min(this.from.row,this.to.row)==Math.min(e.from.row,e.to.row)&&Math.max(this.from.row,this.to.row)==Math.max(e.from.row,e.to.row)&&Math.min(this.from.col,this.to.col)==Math.min(e.from.col,e.to.col)&&Math.max(this.from.col,this.to.col)==Math.max(e.from.col,e.to.col)}},{key:"overlaps",value:function(e){return e.isSouthEastOf(this.getTopLeftCorner())&&e.isNorthWestOf(this.getBottomRightCorner())}},{key:"isSouthEastOf",value:function(e){return this.getTopLeftCorner().isSouthEastOf(e)||this.getBottomRightCorner().isSouthEastOf(e)}},{key:"isNorthWestOf",value:function(e){return this.getTopLeftCorner().isNorthWestOf(e)||this.getBottomRightCorner().isNorthWestOf(e)}},{key:"expand",value:function(e){var t=this.getTopLeftCorner(),n=this.getBottomRightCorner();return(e.row<t.row||e.col<t.col||e.row>n.row||e.col>n.col)&&(this.from=new a.default(Math.min(t.row,e.row),Math.min(t.col,e.col)),this.to=new a.default(Math.max(n.row,e.row),Math.max(n.col,e.col)),!0)}},{key:"expandByRange",value:function(t){if(this.includesRange(t)||!this.overlaps(t))return!1;var n=this.getTopLeftCorner(),o=this.getBottomRightCorner(),r=(this.getTopRightCorner(),this.getBottomLeftCorner(),t.getTopLeftCorner()),i=t.getBottomRightCorner(),s=Math.min(n.row,r.row),l=Math.min(n.col,r.col),u=Math.max(o.row,i.row),c=Math.max(o.col,i.col),d=new a.default(s,l),h=new a.default(u,c),f=new e(d,d,h).isCorner(this.from,t),p=t.isEqual(new e(d,d,h));return f&&!p&&(this.from.col>d.col&&(d.col=c,h.col=l),this.from.row>d.row&&(d.row=u,h.row=s)),this.from=d,this.to=h,!0}},{key:"getDirection",value:function(){return this.from.isNorthWestOf(this.to)?"NW-SE":this.from.isNorthEastOf(this.to)?"NE-SW":this.from.isSouthEastOf(this.to)?"SE-NW":this.from.isSouthWestOf(this.to)?"SW-NE":void 0}},{key:"setDirection",value:function(e){switch(e){case"NW-SE":var t=[this.getTopLeftCorner(),this.getBottomRightCorner()];this.from=t[0],this.to=t[1];break;case"NE-SW":var n=[this.getTopRightCorner(),this.getBottomLeftCorner()];this.from=n[0],this.to=n[1];break;case"SE-NW":var o=[this.getBottomRightCorner(),this.getTopLeftCorner()];this.from=o[0],this.to=o[1];break;case"SW-NE":var r=[this.getBottomLeftCorner(),this.getTopRightCorner()];this.from=r[0],this.to=r[1]}}},{key:"getTopLeftCorner",value:function(){return new a.default(Math.min(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))}},{key:"getBottomRightCorner",value:function(){return new a.default(Math.max(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))}},{key:"getTopRightCorner",value:function(){return new a.default(Math.min(this.from.row,this.to.row),Math.max(this.from.col,this.to.col))}},{key:"getBottomLeftCorner",value:function(){return new a.default(Math.max(this.from.row,this.to.row),Math.min(this.from.col,this.to.col))}},{key:"isCorner",value:function(e,t){return!!(t&&t.includes(e)&&(this.getTopLeftCorner().isEqual(new a.default(t.from.row,t.from.col))||this.getTopRightCorner().isEqual(new a.default(t.from.row,t.to.col))||this.getBottomLeftCorner().isEqual(new a.default(t.to.row,t.from.col))||this.getBottomRightCorner().isEqual(new a.default(t.to.row,t.to.col))))||e.isEqual(this.getTopLeftCorner())||e.isEqual(this.getTopRightCorner())||e.isEqual(this.getBottomLeftCorner())||e.isEqual(this.getBottomRightCorner())}},{key:"getOppositeCorner",value:function(e,t){if(!(e instanceof a.default))return!1;if(t&&t.includes(e)){if(this.getTopLeftCorner().isEqual(new a.default(t.from.row,t.from.col)))return this.getBottomRightCorner();if(this.getTopRightCorner().isEqual(new a.default(t.from.row,t.to.col)))return this.getBottomLeftCorner();if(this.getBottomLeftCorner().isEqual(new a.default(t.to.row,t.from.col)))return this.getTopRightCorner();if(this.getBottomRightCorner().isEqual(new a.default(t.to.row,t.to.col)))return this.getTopLeftCorner()}return e.isEqual(this.getBottomRightCorner())?this.getTopLeftCorner():e.isEqual(this.getTopLeftCorner())?this.getBottomRightCorner():e.isEqual(this.getTopRightCorner())?this.getBottomLeftCorner():e.isEqual(this.getBottomLeftCorner())?this.getTopRightCorner():void 0}},{key:"getBordersSharedWith",value:function(e){if(!this.includesRange(e))return[];var t=Math.min(this.from.row,this.to.row),n=Math.max(this.from.row,this.to.row),o=Math.min(this.from.col,this.to.col),r=Math.max(this.from.col,this.to.col),i=Math.min(e.from.row,e.to.row),a=Math.max(e.from.row,e.to.row),s=Math.min(e.from.col,e.to.col),l=Math.max(e.from.col,e.to.col),u=[];return t==i&&u.push("top"),r==l&&u.push("right"),n==a&&u.push("bottom"),o==s&&u.push("left"),u}},{key:"getInner",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),n=[],o=e.row;o<=t.row;o++)for(var r=e.col;r<=t.col;r++)this.from.row===o&&this.from.col===r||this.to.row===o&&this.to.col===r||n.push(new a.default(o,r));return n}},{key:"getAll",value:function(){for(var e=this.getTopLeftCorner(),t=this.getBottomRightCorner(),n=[],o=e.row;o<=t.row;o++)for(var r=e.col;r<=t.col;r++)e.row===o&&e.col===r?n.push(e):t.row===o&&t.col===r?n.push(t):n.push(new a.default(o,r));return n}},{key:"forAll",value:function(e){for(var t=this.getTopLeftCorner(),n=this.getBottomRightCorner(),o=t.row;o<=n.row;o++)for(var r=t.col;r<=n.col;r++)if(!1===e(o,r))return}}]),e}();t.default=s},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(){return{name:o}};var o=t.KEY="---------"},function(e,t){e.exports=function(e){if("function"!=typeof e)throw TypeError(e+" is not a function!");return e}},function(e,t,n){"use strict";var o=n(19),r=n(40);e.exports=function(e,t,n){t in e?o.f(e,t,r(0,n)):e[t]=n}},function(e,t,n){var o=n(15),r=n(13).document,i=o(r)&&o(r.createElement);e.exports=function(e){return i?r.createElement(e):{}}},function(e,t){e.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(e,t,n){var o=n(10)("match");e.exports=function(e){var t=/./;try{"/./"[e](t)}catch(n){try{return t[o]=!1,!"/./"[e](t)}catch(e){}}return!0}},function(e,t,n){var o=n(38);e.exports=Object("z").propertyIsEnumerable(0)?Object:function(e){return"String"==o(e)?e.split(""):Object(e)}},function(e,t,n){var o=n(10)("iterator"),r=!1;try{var i=[7][o]();i.return=function(){r=!0},Array.from(i,function(){throw 2})}catch(e){}e.exports=function(e,t){if(!t&&!r)return!1;var n=!1;try{var i=[7],a=i[o]();a.next=function(){return{done:n=!0}},i[o]=function(){return a},e(i)}catch(e){}return n}},function(e,t,n){var o=n(18),r=n(286),i=n(74),a=n(81)("IE_PROTO"),s=function(){},l=function(){var e,t=n(73)("iframe"),o=i.length;for(t.style.display="none",n(159).appendChild(t),t.src="javascript:",(e=t.contentWindow.document).open(),e.write("<script>document.F=Object<\/script>"),e.close(),l=e.F;o--;)delete l.prototype[i[o]];return l()};e.exports=Object.create||function(e,t){var n;return null!==e?(s.prototype=o(e),n=new s,s.prototype=null,n[a]=e):n=l(),void 0===t?n:r(n,t)}},function(e,t,n){var o=n(47),r=n(40),i=n(23),a=n(85),s=n(22),l=n(160),u=Object.getOwnPropertyDescriptor;t.f=n(21)?u:function(e,t){if(e=i(e),t=a(t,!0),l)try{return u(e,t)}catch(e){}if(s(e,t))return r(!o.f.call(e,t),e[t])}},function(e,t,n){var o=n(169),r=n(74).concat("length","prototype");t.f=Object.getOwnPropertyNames||function(e){return o(e,r)}},function(e,t,n){var o=n(82)("keys"),r=n(49);e.exports=function(e){return o[e]||(o[e]=r(e))}},function(e,t,n){var o=n(13),r=o["__core-js_shared__"]||(o["__core-js_shared__"]={});e.exports=function(e){return r[e]||(r[e]={})}},function(e,t,n){var o=n(164),r=n(30);e.exports=function(e,t,n){if(o(t))throw TypeError("String#"+n+" doesn't accept regex!");return String(r(e))}},function(e,t,n){var o,r,i,a=n(29),s=n(282),l=n(159),u=n(73),c=n(13),d=c.process,h=c.setImmediate,f=c.clearImmediate,p=c.MessageChannel,m=0,g={},v=function(){var e=+this;if(g.hasOwnProperty(e)){var t=g[e];delete g[e],t()}},y=function(e){v.call(e.data)};h&&f||(h=function(e){for(var t=[],n=1;arguments.length>n;)t.push(arguments[n++]);return g[++m]=function(){s("function"==typeof e?e:Function(e),t)},o(m),m},f=function(e){delete g[e]},"process"==n(38)(d)?o=function(e){d.nextTick(a(v,e,1))}:p?(i=(r=new p).port2,r.port1.onmessage=y,o=a(i.postMessage,i,1)):c.addEventListener&&"function"==typeof postMessage&&!c.importScripts?(o=function(e){c.postMessage(e+"","*")},c.addEventListener("message",y,!1)):o="onreadystatechange"in u("script")?function(e){l.appendChild(u("script")).onreadystatechange=function(){l.removeChild(this),v.call(e)}}:function(e){setTimeout(a(v,e,1),0)}),e.exports={set:h,clear:f}},function(e,t,n){var o=n(15);e.exports=function(e,t){if(!o(e))return e;var n,r;if(t&&"function"==typeof(n=e.toString)&&!o(r=n.call(e)))return r;if("function"==typeof(n=e.valueOf)&&!o(r=n.call(e)))return r;if(!t&&"function"==typeof(n=e.toString)&&!o(r=n.call(e)))return r;throw TypeError("Can't convert object to primitive value")}},function(e,n){e.exports=t},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=n(20);function i(){}i.prototype={data:void 0,dataSchema:void 0,width:void 0,height:void 0,startRows:5,startCols:5,rowHeaders:void 0,colHeaders:null,colWidths:void 0,rowHeights:void 0,columns:void 0,cells:void 0,cell:[],comments:!1,customBorders:!1,minRows:0,minCols:0,maxRows:1/0,maxCols:1/0,minSpareRows:0,minSpareCols:0,allowInsertRow:!0,allowInsertColumn:!0,allowRemoveRow:!0,allowRemoveColumn:!0,multiSelect:!0,fillHandle:!0,fixedRowsTop:0,fixedRowsBottom:0,fixedColumnsLeft:0,outsideClickDeselects:!0,enterBeginsEditing:!0,enterMoves:{row:1,col:0},tabMoves:{row:0,col:1},autoWrapRow:!1,autoWrapCol:!1,copyRowsLimit:1e3,copyColsLimit:1e3,pasteMode:"overwrite",persistentState:void 0,currentRowClassName:void 0,currentColClassName:void 0,currentHeaderClassName:"ht__highlight",className:void 0,tableClassName:void 0,stretchH:"none",isEmptyRow:function(e){var t,n,i,a;for(t=0,n=this.countCols();t<n;t++)if(""!==(i=this.getDataAtCell(e,t))&&null!==i&&(0,r.isDefined)(i))return"object"===(void 0===i?"undefined":o(i))&&(a=this.getCellMeta(e,t),isObjectEquals(this.getSchema()[a.prop],i));return!0},isEmptyCol:function(e){var t,n,o;for(t=0,n=this.countRows();t<n;t++)if(""!==(o=this.getDataAtCell(t,e))&&null!==o&&(0,r.isDefined)(o))return!1;return!0},observeDOMVisibility:!0,allowInvalid:!0,allowEmpty:!0,invalidCellClassName:"htInvalid",placeholder:!1,placeholderCellClassName:"htPlaceholder",readOnlyCellClassName:"htDimmed",renderer:void 0,commentedCellClassName:"htCommentCell",fragmentSelection:!1,readOnly:!1,skipColumnOnPaste:!1,search:!1,type:"text",copyable:!0,editor:void 0,autoComplete:void 0,visibleRows:10,trimDropdown:!0,debug:!1,wordWrap:!0,noWordWrapClassName:"htNoWrap",contextMenu:void 0,contextMenuCopyPaste:void 0,copyPaste:void 0,undo:void 0,columnSorting:void 0,manualColumnMove:void 0,manualColumnResize:void 0,manualRowMove:void 0,manualRowResize:void 0,mergeCells:!1,viewportRowRenderingOffset:"auto",viewportColumnRenderingOffset:"auto",validator:void 0,disableVisualSelection:!1,sortIndicator:void 0,manualColumnFreeze:void 0,trimWhitespace:!0,settings:void 0,source:void 0,title:void 0,checkedTemplate:void 0,uncheckedTemplate:void 0,label:void 0,format:void 0,language:void 0,selectOptions:void 0,autoColumnSize:void 0,autoRowSize:void 0,dateFormat:void 0,correctFormat:!1,defaultDate:void 0,strict:void 0,allowHtml:!1,renderAllRows:void 0,preventOverflow:!1,bindRowsWithHeaders:void 0,collapsibleColumns:void 0,columnSummary:void 0,dropdownMenu:void 0,filters:void 0,formulas:void 0,ganttChart:void 0,headerTooltips:void 0,hiddenColumns:void 0,hiddenRows:void 0,nestedHeaders:void 0,trimRows:void 0,rowHeaderWidth:void 0,columnHeaderHeight:void 0,observeChanges:void 0,sortFunction:void 0,sortByRelevance:!0,filter:!0,filteringCaseSensitive:!1},t.default=i},function(e,t,n){"use strict";t.__esModule=!0,t.getNormalizedDate=function(e){var t=new Date(e);return isNaN(new Date(e+"T00:00").getDate())?t:new Date(t.getTime()+6e4*t.getTimezoneOffset())}},function(e,t,n){var o=n(3);o(o.P,"Array",{copyWithin:n(275)}),n(37)("copyWithin")},function(e,t,n){var o=n(3);o(o.P,"Array",{fill:n(276)}),n(37)("fill")},function(e,t,n){"use strict";var o=n(3),r=n(53)(6),i="findIndex",a=!0;i in[]&&Array(1)[i](function(){a=!1}),o(o.P+o.F*a,"Array",{findIndex:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),n(37)(i)},function(e,t,n){"use strict";var o=n(3),r=n(53)(5),i=!0;"find"in[]&&Array(1).find(function(){i=!1}),o(o.P+o.F*i,"Array",{find:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),n(37)("find")},function(e,t,n){"use strict";var o=n(29),r=n(3),i=n(41),a=n(165),s=n(161),l=n(24),u=n(72),c=n(176);r(r.S+r.F*!n(77)(function(e){Array.from(e)}),"Array",{from:function(e){var t,n,r,d,h=i(e),f="function"==typeof this?this:Array,p=arguments.length,m=p>1?arguments[1]:void 0,g=void 0!==m,v=0,y=c(h);if(g&&(m=o(m,p>2?arguments[2]:void 0,2)),null==y||f==Array&&s(y))for(n=new f(t=l(h.length));t>v;v++)u(n,v,g?m(h[v],v):h[v]);else for(d=y.call(h),n=new f;!(r=d.next()).done;v++)u(n,v,g?a(d,m,[r.value,v],!0):r.value);return n.length=v,n}})},function(e,t,n){"use strict";var o=n(3),r=n(72);o(o.S+o.F*n(31)(function(){function e(){}return!(Array.of.call(e)instanceof e)}),"Array",{of:function(){for(var e=0,t=arguments.length,n=new("function"==typeof this?this:Array)(t);t>e;)r(n,e,arguments[e++]);return n.length=t,n}})},function(e,t,n){var o=n(19).f,r=n(40),i=n(22),a=Function.prototype,s=/^\s*function ([^ (]*)/,l=Object.isExtensible||function(){return!0};"name"in a||n(21)&&o(a,"name",{configurable:!0,get:function(){try{var e=(""+this).match(s)[1];return i(this,"name")||!l(this)||o(this,"name",r(5,e)),e}catch(e){return""}}})},function(e,t,n){"use strict";var o=n(157);e.exports=n(54)("Map",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{get:function(e){var t=o.getEntry(this,e);return t&&t.v},set:function(e,t){return o.def(this,0===e?0:e,t)}},o,!0)},function(e,t,n){var o=n(3);o(o.S,"Number",{EPSILON:Math.pow(2,-52)})},function(e,t,n){var o=n(3),r=n(13).isFinite;o(o.S,"Number",{isFinite:function(e){return"number"==typeof e&&r(e)}})},function(e,t,n){var o=n(3);o(o.S,"Number",{isInteger:n(163)})},function(e,t,n){var o=n(3);o(o.S,"Number",{isNaN:function(e){return e!=e}})},function(e,t,n){var o=n(3),r=n(163),i=Math.abs;o(o.S,"Number",{isSafeInteger:function(e){return r(e)&&i(e)<=9007199254740991}})},function(e,t,n){var o=n(3);o(o.S,"Number",{MAX_SAFE_INTEGER:9007199254740991})},function(e,t,n){var o=n(3);o(o.S,"Number",{MIN_SAFE_INTEGER:-9007199254740991})},function(e,t,n){var o=n(3);o(o.S+o.F,"Object",{assign:n(168)})},function(e,t,n){var o=n(3);o(o.S,"Object",{is:n(290)})},function(e,t,n){var o=n(3);o(o.S,"Object",{setPrototypeOf:n(171).set})},function(e,t,n){"use strict";var o,r,i,a=n(57),s=n(13),l=n(29),u=n(156),c=n(3),d=n(15),h=n(71),f=n(52),p=n(56),m=n(291),g=n(84).set,v=n(285)(),y=s.TypeError,_=s.process,w=s.Promise,b="process"==u(_=s.process),C=function(){},M=!!function(){try{var e=w.resolve(1),t=(e.constructor={})[n(10)("species")]=function(e){e(C,C)};return(b||"function"==typeof PromiseRejectionEvent)&&e.then(C)instanceof t}catch(e){}}(),k=function(e,t){return e===t||e===w&&t===i},S=function(e){var t;return!(!d(e)||"function"!=typeof(t=e.then))&&t},T=function(e){return k(w,e)?new L(e):new r(e)},L=r=function(e){var t,n;this.promise=new e(function(e,o){if(void 0!==t||void 0!==n)throw y("Bad Promise constructor");t=e,n=o}),this.resolve=h(t),this.reject=h(n)},x=function(e){try{e()}catch(e){return{error:e}}},D=function(e,t){if(!e._n){e._n=!0;var n=e._c;v(function(){for(var o=e._v,r=1==e._s,i=0,a=function(t){var n,i,a=r?t.ok:t.fail,s=t.resolve,l=t.reject,u=t.domain;try{a?(r||(2==e._h&&R(e),e._h=1),!0===a?n=o:(u&&u.enter(),n=a(o),u&&u.exit()),n===t.promise?l(y("Promise-chain cycle")):(i=S(n))?i.call(n,s,l):s(n)):l(o)}catch(e){l(e)}};n.length>i;)a(n[i++]);e._c=[],e._n=!1,t&&!e._h&&O(e)})}},O=function(e){g.call(s,function(){var t,n,o,r=e._v;if(E(e)&&(t=x(function(){b?_.emit("unhandledRejection",r,e):(n=s.onunhandledrejection)?n({promise:e,reason:r}):(o=s.console)&&o.error&&o.error("Unhandled promise rejection",r)}),e._h=b||E(e)?2:1),e._a=void 0,t)throw t.error})},E=function(e){if(1==e._h)return!1;for(var t,n=e._a||e._c,o=0;n.length>o;)if((t=n[o++]).fail||!E(t.promise))return!1;return!0},R=function(e){g.call(s,function(){var t;b?_.emit("rejectionHandled",e):(t=s.onrejectionhandled)&&t({promise:e,reason:e._v})})},A=function(e){var t=this;t._d||(t._d=!0,(t=t._w||t)._v=e,t._s=2,t._a||(t._a=t._c.slice()),D(t,!0))},H=function(e){var t,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===e)throw y("Promise can't be resolved itself");(t=S(e))?v(function(){var o={_w:n,_d:!1};try{t.call(e,l(H,o,1),l(A,o,1))}catch(e){A.call(o,e)}}):(n._v=e,n._s=1,D(n,!1))}catch(e){A.call({_w:n,_d:!1},e)}}};M||(w=function(e){f(this,w,"Promise","_h"),h(e),o.call(this);try{e(l(H,this,1),l(A,this,1))}catch(e){A.call(this,e)}},(o=function(e){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1}).prototype=n(59)(w.prototype,{then:function(e,t){var n=T(m(this,w));return n.ok="function"!=typeof e||e,n.fail="function"==typeof t&&t,n.domain=b?_.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&D(this,!1),n.promise},catch:function(e){return this.then(void 0,e)}}),L=function(){var e=new o;this.promise=e,this.resolve=l(H,e,1),this.reject=l(A,e,1)}),c(c.G+c.W+c.F*!M,{Promise:w}),n(48)(w,"Promise"),n(172)("Promise"),i=n(44).Promise,c(c.S+c.F*!M,"Promise",{reject:function(e){var t=T(this);return(0,t.reject)(e),t.promise}}),c(c.S+c.F*(a||!M),"Promise",{resolve:function(e){if(e instanceof w&&k(e.constructor,this))return e;var t=T(this);return(0,t.resolve)(e),t.promise}}),c(c.S+c.F*!(M&&n(77)(function(e){w.all(e).catch(C)})),"Promise",{all:function(e){var t=this,n=T(t),o=n.resolve,r=n.reject,i=x(function(){var n=[],i=0,a=1;p(e,!1,function(e){var s=i++,l=!1;n.push(void 0),a++,t.resolve(e).then(function(e){l||(l=!0,n[s]=e,--a||o(n))},r)}),--a||o(n)});return i&&r(i.error),n.promise},race:function(e){var t=this,n=T(t),o=n.reject,r=x(function(){p(e,!1,function(e){t.resolve(e).then(n.resolve,o)})});return r&&o(r.error),n.promise}})},function(e,t,n){n(21)&&"g"!=/./g.flags&&n(19).f(RegExp.prototype,"flags",{configurable:!0,get:n(280)})},function(e,t,n){n(55)("match",1,function(e,t,n){return[function(n){"use strict";var o=e(this),r=null==n?void 0:n[t];return void 0!==r?r.call(n,o):new RegExp(n)[t](String(o))},n]})},function(e,t,n){n(55)("replace",2,function(e,t,n){return[function(o,r){"use strict";var i=e(this),a=null==o?void 0:o[t];return void 0!==a?a.call(o,i,r):n.call(String(i),o,r)},n]})},function(e,t,n){n(55)("search",1,function(e,t,n){return[function(n){"use strict";var o=e(this),r=null==n?void 0:n[t];return void 0!==r?r.call(n,o):new RegExp(n)[t](String(o))},n]})},function(e,t,n){n(55)("split",2,function(e,t,o){"use strict";var r=n(164),i=o,a=[].push;if("c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length){var s=void 0===/()??/.exec("")[1];o=function(e,t){var n=String(this);if(void 0===e&&0===t)return[];if(!r(e))return i.call(n,e,t);var o,l,u,c,d,h=[],f=(e.ignoreCase?"i":"")+(e.multiline?"m":"")+(e.unicode?"u":"")+(e.sticky?"y":""),p=0,m=void 0===t?4294967295:t>>>0,g=new RegExp(e.source,f+"g");for(s||(o=new RegExp("^"+g.source+"$(?!\\s)",f));(l=g.exec(n))&&!((u=l.index+l[0].length)>p&&(h.push(n.slice(p,l.index)),!s&&l.length>1&&l[0].replace(o,function(){for(d=1;d<arguments.length-2;d++)void 0===arguments[d]&&(l[d]=void 0)}),l.length>1&&l.index<n.length&&a.apply(h,l.slice(1)),c=l[0].length,p=u,h.length>=m));)g.lastIndex===l.index&&g.lastIndex++;return p===n.length?!c&&g.test("")||h.push(""):h.push(n.slice(p)),h.length>m?h.slice(0,m):h}}else"0".split(void 0,0).length&&(o=function(e,t){return void 0===e&&0===t?[]:i.call(this,e,t)});return[function(n,r){var i=e(this),a=null==n?void 0:n[t];return void 0!==a?a.call(n,i,r):o.call(String(i),n,r)},o]})},function(e,t,n){"use strict";var o=n(157);e.exports=n(54)("Set",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return o.def(this,e=0===e?0:e,e)}},o)},function(e,t,n){"use strict";var o=n(3),r=n(292)(!1);o(o.P,"String",{codePointAt:function(e){return r(this,e)}})},function(e,t,n){"use strict";var o=n(3),r=n(24),i=n(83),a="".endsWith;o(o.P+o.F*n(75)("endsWith"),"String",{endsWith:function(e){var t=i(this,e,"endsWith"),n=arguments.length>1?arguments[1]:void 0,o=r(t.length),s=void 0===n?o:Math.min(r(n),o),l=String(e);return a?a.call(t,l,s):t.slice(s-l.length,s)===l}})},function(e,t,n){var o=n(3),r=n(60),i=String.fromCharCode,a=String.fromCodePoint;o(o.S+o.F*(!!a&&1!=a.length),"String",{fromCodePoint:function(e){for(var t,n=[],o=arguments.length,a=0;o>a;){if(t=+arguments[a++],r(t,1114111)!==t)throw RangeError(t+" is not a valid code point");n.push(t<65536?i(t):i(55296+((t-=65536)>>10),t%1024+56320))}return n.join("")}})},function(e,t,n){"use strict";var o=n(3),r=n(83);o(o.P+o.F*n(75)("includes"),"String",{includes:function(e){return!!~r(this,e,"includes").indexOf(e,arguments.length>1?arguments[1]:void 0)}})},function(e,t,n){var o=n(3),r=n(23),i=n(24);o(o.S,"String",{raw:function(e){for(var t=r(e.raw),n=i(t.length),o=arguments.length,a=[],s=0;n>s;)a.push(String(t[s++])),s<o&&a.push(String(arguments[s]));return a.join("")}})},function(e,t,n){var o=n(3);o(o.P,"String",{repeat:n(174)})},function(e,t,n){"use strict";var o=n(3),r=n(24),i=n(83),a="".startsWith;o(o.P+o.F*n(75)("startsWith"),"String",{startsWith:function(e){var t=i(this,e,"startsWith"),n=r(Math.min(arguments.length>1?arguments[1]:void 0,t.length)),o=String(e);return a?a.call(t,o,n):t.slice(n,n+o.length)===o}})},function(e,t,n){"use strict";var o=n(13),r=n(22),i=n(21),a=n(3),s=n(33),l=n(46).KEY,u=n(31),c=n(82),d=n(48),h=n(49),f=n(10),p=n(175),m=n(293),g=n(284),v=n(279),y=n(162),_=n(18),w=n(23),b=n(85),C=n(40),M=n(78),k=n(287),S=n(79),T=n(19),L=n(39),x=S.f,D=T.f,O=k.f,E=o.Symbol,R=o.JSON,A=R&&R.stringify,H=f("_hidden"),Y=f("toPrimitive"),P={}.propertyIsEnumerable,N=c("symbol-registry"),I=c("symbols"),W=c("op-symbols"),j=Object.prototype,F="function"==typeof E,z=o.QObject,B=!z||!z.prototype||!z.prototype.findChild,V=i&&u(function(){return 7!=M(D({},"a",{get:function(){return D(this,"a",{value:7}).a}})).a})?function(e,t,n){var o=x(j,t);o&&delete j[t],D(e,t,n),o&&e!==j&&D(j,t,o)}:D,U=function(e){var t=I[e]=M(E.prototype);return t._k=e,t},K=F&&"symbol"==typeof E.iterator?function(e){return"symbol"==typeof e}:function(e){return e instanceof E},G=function(e,t,n){return e===j&&G(W,t,n),_(e),t=b(t,!0),_(n),r(I,t)?(n.enumerable?(r(e,H)&&e[H][t]&&(e[H][t]=!1),n=M(n,{enumerable:C(0,!1)})):(r(e,H)||D(e,H,C(1,{})),e[H][t]=!0),V(e,t,n)):D(e,t,n)},X=function(e,t){_(e);for(var n,o=v(t=w(t)),r=0,i=o.length;i>r;)G(e,n=o[r++],t[n]);return e},J=function(e){var t=P.call(this,e=b(e,!0));return!(this===j&&r(I,e)&&!r(W,e))&&(!(t||!r(this,e)||!r(I,e)||r(this,H)&&this[H][e])||t)},q=function(e,t){if(e=w(e),t=b(t,!0),e!==j||!r(I,t)||r(W,t)){var n=x(e,t);return!n||!r(I,t)||r(e,H)&&e[H][t]||(n.enumerable=!0),n}},Q=function(e){for(var t,n=O(w(e)),o=[],i=0;n.length>i;)r(I,t=n[i++])||t==H||t==l||o.push(t);return o},$=function(e){for(var t,n=e===j,o=O(n?W:w(e)),i=[],a=0;o.length>a;)!r(I,t=o[a++])||n&&!r(j,t)||i.push(I[t]);return i};F||(s((E=function(){if(this instanceof E)throw TypeError("Symbol is not a constructor!");var e=h(arguments.length>0?arguments[0]:void 0),t=function(n){this===j&&t.call(W,n),r(this,H)&&r(this[H],e)&&(this[H][e]=!1),V(this,e,C(1,n))};return i&&B&&V(j,e,{configurable:!0,set:t}),U(e)}).prototype,"toString",function(){return this._k}),S.f=q,T.f=G,n(80).f=k.f=Q,n(47).f=J,n(58).f=$,i&&!n(57)&&s(j,"propertyIsEnumerable",J,!0),p.f=function(e){return U(f(e))}),a(a.G+a.W+a.F*!F,{Symbol:E});for(var Z="hasInstance,isConcatSpreadable,iterator,match,replace,search,species,split,toPrimitive,toStringTag,unscopables".split(","),ee=0;Z.length>ee;)f(Z[ee++]);for(Z=L(f.store),ee=0;Z.length>ee;)m(Z[ee++]);a(a.S+a.F*!F,"Symbol",{for:function(e){return r(N,e+="")?N[e]:N[e]=E(e)},keyFor:function(e){if(K(e))return g(N,e);throw TypeError(e+" is not a symbol!")},useSetter:function(){B=!0},useSimple:function(){B=!1}}),a(a.S+a.F*!F,"Object",{create:function(e,t){return void 0===t?M(e):X(M(e),t)},defineProperty:G,defineProperties:X,getOwnPropertyDescriptor:q,getOwnPropertyNames:Q,getOwnPropertySymbols:$}),R&&a(a.S+a.F*(!F||u(function(){var e=E();return"[null]"!=A([e])||"{}"!=A({a:e})||"{}"!=A(Object(e))})),"JSON",{stringify:function(e){if(void 0!==e&&!K(e)){for(var t,n,o=[e],r=1;arguments.length>r;)o.push(arguments[r++]);return"function"==typeof(t=o[1])&&(n=t),!n&&y(t)||(t=function(e,t){if(n&&(t=n.call(this,e,t)),!K(t))return t}),o[1]=t,A.apply(R,o)}}}),E.prototype[Y]||n(32)(E.prototype,Y,E.prototype.valueOf),d(E,"Symbol"),d(Math,"Math",!0),d(o.JSON,"JSON",!0)},function(e,t,n){"use strict";var o,r=n(53)(0),i=n(33),a=n(46),s=n(168),l=n(158),u=n(15),c=a.getWeak,d=Object.isExtensible,h=l.ufstore,f={},p=function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},m={get:function(e){if(u(e)){var t=c(e);return!0===t?h(this).get(e):t?t[this._i]:void 0}},set:function(e,t){return l.def(this,e,t)}},g=e.exports=n(54)("WeakMap",p,m,l,!0,!0);7!=(new g).set((Object.freeze||Object)(f),7).get(f)&&(s((o=l.getConstructor(p)).prototype,m),a.NEED=!0,r(["delete","has","get","set"],function(e){var t=g.prototype,n=t[e];i(t,e,function(t,r){if(u(t)&&!d(t)){this._f||(this._f=new o);var i=this._f[e](t,r);return"set"==e?this:i}return n.call(this,t,r)})}))},function(e,t,n){"use strict";var o=n(158);n(54)("WeakSet",function(e){return function(){return e(this,arguments.length>0?arguments[0]:void 0)}},{add:function(e){return o.def(this,e,!0)}},o,!1,!0)},function(e,t,n){"use strict";var o=n(3),r=n(155)(!0);o(o.P,"Array",{includes:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0)}}),n(37)("includes")},function(e,t,n){var o=n(3),r=n(170)(!0);o(o.S,"Object",{entries:function(e){return r(e)}})},function(e,t,n){var o=n(3),r=n(289),i=n(23),a=n(79),s=n(72);o(o.S,"Object",{getOwnPropertyDescriptors:function(e){for(var t,n=i(e),o=a.f,l=r(n),u={},c=0;l.length>c;)s(u,t=l[c++],o(n,t));return u}})},function(e,t,n){var o=n(3),r=n(170)(!1);o(o.S,"Object",{values:function(e){return r(e)}})},function(e,t,n){"use strict";var o=n(3),r=n(173);o(o.P,"String",{padEnd:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!1)}})},function(e,t,n){"use strict";var o=n(3),r=n(173);o(o.P,"String",{padStart:function(e){return r(this,e,arguments.length>1?arguments[1]:void 0,!0)}})},function(e,t,n){for(var o=n(68),r=n(33),i=n(13),a=n(32),s=n(45),l=n(10),u=l("iterator"),c=l("toStringTag"),d=s.Array,h=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],f=0;f<5;f++){var p,m=h[f],g=i[m],v=g&&g.prototype;if(v)for(p in v[u]||a(v,u,d),v[c]||a(v,c,m),s[m]=d,o)v[p]||r(v,p,o[p],!0)}},function(e,t,n){var o=n(3),r=n(84);o(o.G+o.B,{setImmediate:r.set,clearImmediate:r.clear})},function(e,t,n){"use strict";!function(e){function n(e){return e.split('"').length-1}var o=function(e){var t,o,r,i,a,s,l,u=[],c=0;for((r=e.split("\n")).length>1&&""===r[r.length-1]&&r.pop(),t=0,o=r.length;t<o;t+=1){for(r[t]=r[t].split("\t"),i=0,a=r[t].length;i<a;i+=1)u[c]||(u[c]=[]),s&&0===i?(l=u[c].length-1,u[c][l]=u[c][l]+"\n"+r[t][0],s&&1&n(r[t][0])&&(s=!1,u[c][l]=u[c][l].substring(0,u[c][l].length-1).replace(/""/g,'"'))):i===a-1&&0===r[t][i].indexOf('"')&&1&n(r[t][i])?(u[c].push(r[t][i].substring(1).replace(/""/g,'"')),s=!0):(u[c].push(r[t][i].replace(/""/g,'"')),s=!1);s||(c+=1)}return u},r=function(e){var t,n,o,r,i,a="";for(t=0,n=e.length;t<n;t+=1){for(r=e[t].length,o=0;o<r;o+=1)o>0&&(a+="\t"),"string"==typeof(i=e[t][o])?i.indexOf("\n")>-1?a+='"'+i.replace(/"/g,'""')+'"':a+=i:a+=null==i?"":i;t!==n-1&&(a+="\n")}return a};t.parse=o,t.stringify=r}(window)},function(e,t,n){"use strict";var o,r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);function o(){this.constructor=e}e.prototype=null===t?Object.create(t):(o.prototype=t.prototype,new o)},a=Error;
/*!
* https://github.com/Starcounter-Jack/JSON-Patch
* json-patch-duplex.js version: 0.5.7
* (c) 2013 Joachim Wester
* MIT license
*/!function(e){var t=function(e){if(u(e)){for(var t=new Array(e.length),n=0;n<t.length;n++)t[n]=""+n;return t}if(Object.keys)return Object.keys(e);for(var o in t=[],e)e.hasOwnProperty(o)&&t.push(o);return t},n={add:function(e,t){return e[t]=this.value,!0},remove:function(e,t){return delete e[t],!0},replace:function(e,t){return e[t]=this.value,!0},move:function(e,t,n){var o={op:"_get",path:this.from};return v(n,[o]),v(n,[{op:"remove",path:this.from}]),v(n,[{op:"add",path:this.path,value:o.value}]),!0},copy:function(e,t,n){var o={op:"_get",path:this.from};return v(n,[o]),v(n,[{op:"add",path:this.path,value:o.value}]),!0},test:function(e,n){return function e(n,o){switch(void 0===n?"undefined":r(n)){case"undefined":case"boolean":case"string":case"number":return n===o;case"object":if(null===n)return null===o;if(u(n)){if(!u(o)||n.length!==o.length)return!1;for(var i=0,a=n.length;i<a;i++)if(!e(n[i],o[i]))return!1;return!0}var s=t(o).length;if(t(n).length!==s)return!1;for(i=0;i<s;i++)if(!e(n[i],o[i]))return!1;return!0;default:return!1}}(e[n],this.value)},_get:function(e,t){this.value=e[t]}},o={add:function(e,t){return e.splice(t,0,this.value),!0},remove:function(e,t){return e.splice(t,1),!0},replace:function(e,t){return e[t]=this.value,!0},move:n.move,copy:n.copy,test:n.test,_get:n._get},s={add:function(e){for(var t in s.remove.call(this,e),this.value)this.value.hasOwnProperty(t)&&(e[t]=this.value[t]);return!0},remove:function(e){for(var t in e)e.hasOwnProperty(t)&&n.remove.call(this,e,t);return!0},replace:function(e){return v(e,[{op:"remove",path:this.path}]),v(e,[{op:"add",path:this.path,value:this.value}]),!0},move:n.move,copy:n.copy,test:function(e){return JSON.stringify(e)===JSON.stringify(this.value)},_get:function(e){this.value=e}};function l(e){return-1===e.indexOf("/")&&-1===e.indexOf("~")?e:e.replace(/~/g,"~0").replace(/\//g,"~1")}var u,c=[],d=function(e){this.observers=[],this.obj=e},h=function(e,t){this.callback=e,this.observer=t};function f(e){return"object"===(void 0===e?"undefined":r(e))?JSON.parse(JSON.stringify(e)):e}function p(e){for(var t,n=0,o=c.length;n<o;n++)if(c[n].obj===e.object){t=c[n];break}m(t.value,e.object,e.patches,""),e.patches.length&&v(t.value,e.patches);var r=e.patches;return r.length>0&&(e.patches=[],e.callback&&e.callback(r)),r}function m(e,n,o,i){for(var a=t(n),s=t(e),u=!1,c=s.length-1;c>=0;c--){var d=e[p=s[c]];if(n.hasOwnProperty(p)){var h=n[p];"object"==(void 0===d?"undefined":r(d))&&null!=d&&"object"==(void 0===h?"undefined":r(h))&&null!=h?m(d,h,o,i+"/"+l(p)):d!=h&&o.push({op:"replace",path:i+"/"+l(p),value:f(h)})}else o.push({op:"remove",path:i+"/"+l(p)}),u=!0}if(u||a.length!=s.length)for(c=0;c<a.length;c++){var p=a[c];e.hasOwnProperty(p)||o.push({op:"add",path:i+"/"+l(p),value:f(n[p])})}}function g(e){for(var t,n=0,o=e.length;n<o;){if(!((t=e.charCodeAt(n))>=48&&t<=57))return!1;n++}return!0}function v(e,t,r){for(var i,a,l=!1,c=0,d=t.length;c<d;){i=t[c],c++;for(var h=(i.path||"").split("/"),f=e,p=1,m=h.length,v=void 0;;){if(a=h[p],r&&void 0===v&&(void 0===f[a]?v=h.slice(0,p).join("/"):p==m-1&&(v=i.path),void 0!==v&&this.validator(i,c-1,e,v)),p++,void 0===a&&p>=m){l=s[i.op].call(i,f,a,e);break}if(u(f)){if("-"===a)a=f.length;else{if(r&&!g(a))throw new y("Expected an unsigned base-10 integer value, making the new referenced value the array element with the zero-based index","OPERATION_PATH_ILLEGAL_ARRAY_INDEX",c-1,i.path,i);a=parseInt(a,10)}if(p>=m){if(r&&"add"===i.op&&a>f.length)throw new y("The specified index MUST NOT be greater than the number of elements in the array","OPERATION_VALUE_OUT_OF_BOUNDS",c-1,i.path,i);l=o[i.op].call(i,f,a,e);break}}else if(a&&-1!=a.indexOf("~")&&(a=a.replace(/~1/g,"/").replace(/~0/g,"~")),p>=m){l=n[i.op].call(i,f,a,e);break}f=f[a]}}return l}e.unobserve=function(e,t){t.unobserve()},e.observe=function(e,t){var n,o=function(e){for(var t=0,n=c.length;t<n;t++)if(c[t].obj===e)return c[t]}(e);if(o?n=function(e,t){for(var n=0,o=e.observers.length;n<o;n++)if(e.observers[n].callback===t)return e.observers[n].observer}(o,t):(o=new d(e),c.push(o)),n)return n;if(n={},o.value=f(e),t){n.callback=t,n.next=null;var r=this.intervals||[100,1e3,1e4,6e4];if(void 0===r.push)throw new a("jsonpatch.intervals must be an array");var i=0,s=function(){p(n)},l=function(){clearTimeout(n.next),n.next=setTimeout(function(){s(),i=0,n.next=setTimeout(u,r[i++])},0)},u=function e(){s(),i==r.length&&(i=r.length-1),n.next=setTimeout(e,r[i++])};"undefined"!=typeof window&&(window.addEventListener?(window.addEventListener("mousedown",l),window.addEventListener("mouseup",l),window.addEventListener("keydown",l)):(document.documentElement.attachEvent("onmousedown",l),document.documentElement.attachEvent("onmouseup",l),document.documentElement.attachEvent("onkeydown",l))),n.next=setTimeout(u,r[i++])}return n.patches=[],n.object=e,n.unobserve=function(){p(n),clearTimeout(n.next),function(e,t){for(var n=0,o=e.observers.length;n<o;n++)if(e.observers[n].observer===t)return void e.observers.splice(n,1)}(o,n),"undefined"!=typeof window&&(window.removeEventListener?(window.removeEventListener("mousedown",l),window.removeEventListener("mouseup",l),window.removeEventListener("keydown",l)):(document.documentElement.detachEvent("onmousedown",l),document.documentElement.detachEvent("onmouseup",l),document.documentElement.detachEvent("onkeydown",l)))},o.observers.push(new h(t,n)),n},e.generate=p,u=Array.isArray?Array.isArray:function(e){return e.push&&"number"==typeof e.length},e.apply=v,e.compare=function(e,t){var n=[];return m(e,t,n,""),n};var y=function(e){function t(t,n,o,r,i){e.call(this,t),this.message=t,this.name=n,this.index=o,this.operation=r,this.tree=i}return i(t,e),t}(a);e.JsonPatchError=y,e.Error=y,e.validator=function(t,o,i,a){if("object"!==(void 0===t?"undefined":r(t))||null===t||u(t))throw new y("Operation is not an object","OPERATION_NOT_AN_OBJECT",o,t,i);if(!n[t.op])throw new y("Operation `op` property is not one of operations defined in RFC-6902","OPERATION_OP_INVALID",o,t,i);if("string"!=typeof t.path)throw new y("Operation `path` property is not a string","OPERATION_PATH_INVALID",o,t,i);if(("move"===t.op||"copy"===t.op)&&"string"!=typeof t.from)throw new y("Operation `from` property is not present (applicable in `move` and `copy` operations)","OPERATION_FROM_REQUIRED",o,t,i);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&void 0===t.value)throw new y("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_REQUIRED",o,t,i);if(("add"===t.op||"replace"===t.op||"test"===t.op)&&function e(t){if(void 0===t)return!0;if("array"==typeof t||"object"==(void 0===t?"undefined":r(t)))for(var n in t)if(e(t[n]))return!0;return!1}(t.value))throw new y("Operation `value` property is not present (applicable in `add`, `replace` and `test` operations)","OPERATION_VALUE_CANNOT_CONTAIN_UNDEFINED",o,t,i);if(i)if("add"==t.op){var s=t.path.split("/").length,l=a.split("/").length;if(s!==l+1&&s!==l)throw new y("Cannot perform an `add` operation at the desired path","OPERATION_PATH_CANNOT_ADD",o,t,i)}else if("replace"===t.op||"remove"===t.op||"_get"===t.op){if(t.path!==a)throw new y("Cannot perform the operation at a path that does not exist","OPERATION_PATH_UNRESOLVABLE",o,t,i)}else if("move"===t.op||"copy"===t.op){var c={op:"_get",path:t.from,value:void 0},d=e.validate([c],i);if(d&&"OPERATION_PATH_UNRESOLVABLE"===d.name)throw new y("Cannot perform the operation from a path that does not exist","OPERATION_FROM_UNRESOLVABLE",o,t,i)}},e.validate=function(e,t){try{if(!u(e))throw new y("Patch sequence must be an array","SEQUENCE_NOT_AN_ARRAY");if(t)t=JSON.parse(JSON.stringify(t)),v.call(this,t,e,!0);else for(var n=0;n<e.length;n++)this.validator(e[n],n)}catch(e){if(e instanceof y)return e;throw e}}}(o||(o={})),t.apply=o.apply,t.observe=o.observe,t.unobserve=o.unobserve,t.generate=o.generate,t.compare=o.compare,t.validate=o.validate,t.validator=o.validator,t.JsonPatchError=o.JsonPatchError,t.Error=o.Error},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(7),a=n(2),s=n(25),l=c(n(4)),u=c(n(42));function c(e){return e&&e.__esModule?e:{default:e}}c(n(28));var d=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),n&&(this.eventManager=new l.default(t),this.instance=t,this.wot=t,this.settings=n,this.mouseDown=!1,this.main=null,this.top=null,this.left=null,this.bottom=null,this.right=null,this.topStyle=null,this.leftStyle=null,this.bottomStyle=null,this.rightStyle=null,this.cornerDefaultStyle={width:"5px",height:"5px",borderWidth:"2px",borderStyle:"solid",borderColor:"#FFF"},this.corner=null,this.cornerStyle=null,this.createBorders(n),this.registerListeners())}return o(e,[{key:"registerListeners",value:function(){var e=this;this.eventManager.addEventListener(document.body,"mousedown",function(){return e.onMouseDown()}),this.eventManager.addEventListener(document.body,"mouseup",function(){return e.onMouseUp()});for(var t=function(t,n){e.eventManager.addEventListener(e.main.childNodes[t],"mouseenter",function(n){return e.onMouseEnter(n,e.main.childNodes[t])})},n=0,o=this.main.childNodes.length;n<o;n++)t(n)}},{key:"onMouseDown",value:function(){this.mouseDown=!0}},{key:"onMouseUp",value:function(){this.mouseDown=!1}},{key:"onMouseEnter",value:function(e,t){if(this.mouseDown&&this.wot.getSetting("hideBorderOnMouseDownOver")){e.preventDefault(),(0,i.stopImmediatePropagation)(e);var n=this,o=t.getBoundingClientRect();t.style.display="none",this.eventManager.addEventListener(document.body,"mousemove",function e(r){(function(e){return e.clientY<Math.floor(o.top)||e.clientY>Math.ceil(o.top+o.height)||e.clientX<Math.floor(o.left)||e.clientX>Math.ceil(o.left+o.width)||void 0})(r)&&(n.eventManager.removeEventListener(document.body,"mousemove",e),t.style.display="block")})}}},{key:"createBorders",value:function(e){this.main=document.createElement("div");var t=["top","left","bottom","right","corner"],n=this.main.style;n.position="absolute",n.top=0,n.left=0;for(var o=0;o<5;o++){var r=t[o],i=document.createElement("div");i.className="wtBorder "+(this.settings.className||""),this.settings[r]&&this.settings[r].hide&&(i.className+=" hidden"),(n=i.style).backgroundColor=this.settings[r]&&this.settings[r].color?this.settings[r].color:e.border.color,n.height=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",n.width=this.settings[r]&&this.settings[r].width?this.settings[r].width+"px":e.border.width+"px",this.main.appendChild(i)}this.top=this.main.childNodes[0],this.left=this.main.childNodes[1],this.bottom=this.main.childNodes[2],this.right=this.main.childNodes[3],this.topStyle=this.top.style,this.leftStyle=this.left.style,this.bottomStyle=this.bottom.style,this.rightStyle=this.right.style,this.corner=this.main.childNodes[4],this.corner.className+=" corner",this.cornerStyle=this.corner.style,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.height=this.cornerDefaultStyle.height,this.cornerStyle.border=[this.cornerDefaultStyle.borderWidth,this.cornerDefaultStyle.borderStyle,this.cornerDefaultStyle.borderColor].join(" "),(0,s.isMobileBrowser)()&&this.createMultipleSelectorHandles(),this.disappear(),this.wot.wtTable.bordersHolder||(this.wot.wtTable.bordersHolder=document.createElement("div"),this.wot.wtTable.bordersHolder.className="htBorders",this.wot.wtTable.spreader.appendChild(this.wot.wtTable.bordersHolder)),this.wot.wtTable.bordersHolder.insertBefore(this.main,this.wot.wtTable.bordersHolder.firstChild)}},{key:"createMultipleSelectorHandles",value:function(){this.selectionHandles={topLeft:document.createElement("DIV"),topLeftHitArea:document.createElement("DIV"),bottomRight:document.createElement("DIV"),bottomRightHitArea:document.createElement("DIV")},this.selectionHandles.topLeft.className="topLeftSelectionHandle",this.selectionHandles.topLeftHitArea.className="topLeftSelectionHandle-HitArea",this.selectionHandles.bottomRight.className="bottomRightSelectionHandle",this.selectionHandles.bottomRightHitArea.className="bottomRightSelectionHandle-HitArea",this.selectionHandles.styles={topLeft:this.selectionHandles.topLeft.style,topLeftHitArea:this.selectionHandles.topLeftHitArea.style,bottomRight:this.selectionHandles.bottomRight.style,bottomRightHitArea:this.selectionHandles.bottomRightHitArea.style};var e={position:"absolute",height:"40px",width:"40px","border-radius":parseInt(40/1.5,10)+"px"};for(var t in e)(0,a.hasOwnProperty)(e,t)&&(this.selectionHandles.styles.bottomRightHitArea[t]=e[t],this.selectionHandles.styles.topLeftHitArea[t]=e[t]);var n={position:"absolute",height:"10px",width:"10px","border-radius":parseInt(10/1.5,10)+"px",background:"#F5F5FF",border:"1px solid #4285c8"};for(var o in n)(0,a.hasOwnProperty)(n,o)&&(this.selectionHandles.styles.bottomRight[o]=n[o],this.selectionHandles.styles.topLeft[o]=n[o]);this.main.appendChild(this.selectionHandles.topLeft),this.main.appendChild(this.selectionHandles.bottomRight),this.main.appendChild(this.selectionHandles.topLeftHitArea),this.main.appendChild(this.selectionHandles.bottomRightHitArea)}},{key:"isPartRange",value:function(e,t){return!(!this.wot.selections.area.cellRange||e==this.wot.selections.area.cellRange.to.row&&t==this.wot.selections.area.cellRange.to.col)}},{key:"updateMultipleSelectionHandlesPosition",value:function(e,t,n,o,r,i){var a=parseInt(this.selectionHandles.styles.topLeft.width,10),s=parseInt(this.selectionHandles.styles.topLeftHitArea.width,10);this.selectionHandles.styles.topLeft.top=parseInt(n-a,10)+"px",this.selectionHandles.styles.topLeft.left=parseInt(o-a,10)+"px",this.selectionHandles.styles.topLeftHitArea.top=parseInt(n-s/4*3,10)+"px",this.selectionHandles.styles.topLeftHitArea.left=parseInt(o-s/4*3,10)+"px",this.selectionHandles.styles.bottomRight.top=parseInt(n+i,10)+"px",this.selectionHandles.styles.bottomRight.left=parseInt(o+r,10)+"px",this.selectionHandles.styles.bottomRightHitArea.top=parseInt(n+i-s/4,10)+"px",this.selectionHandles.styles.bottomRightHitArea.left=parseInt(o+r-s/4,10)+"px",this.settings.border.multipleSelectionHandlesVisible&&this.settings.border.multipleSelectionHandlesVisible()?(this.selectionHandles.styles.topLeft.display="block",this.selectionHandles.styles.topLeftHitArea.display="block",this.isPartRange(e,t)?(this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"):(this.selectionHandles.styles.bottomRight.display="block",this.selectionHandles.styles.bottomRightHitArea.display="block")):(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none",this.selectionHandles.styles.topLeftHitArea.display="none",this.selectionHandles.styles.bottomRightHitArea.display="none"),e==this.wot.wtSettings.getSetting("fixedRowsTop")||t==this.wot.wtSettings.getSetting("fixedColumnsLeft")?(this.selectionHandles.styles.topLeft.zIndex="9999",this.selectionHandles.styles.topLeftHitArea.zIndex="9999"):(this.selectionHandles.styles.topLeft.zIndex="",this.selectionHandles.styles.topLeftHitArea.zIndex="")}},{key:"appear",value:function(e){if(!this.disabled){var t,n,o,i,a,l,c,d,h,f,p,m,g,v,y,_,w,b;b=this.wot.wtTable.getRenderedRowsCount();for(var C=0;C<b;C++){var M=this.wot.wtTable.rowFilter.renderedToSource(C);if(M>=e[0]&&M<=e[2]){g=M;break}}for(var k=b-1;k>=0;k--){var S=this.wot.wtTable.rowFilter.renderedToSource(k);if(S>=e[0]&&S<=e[2]){y=S;break}}b=this.wot.wtTable.getRenderedColumnsCount();for(var T=0;T<b;T++){var L=this.wot.wtTable.columnFilter.renderedToSource(T);if(L>=e[1]&&L<=e[3]){v=L;break}}for(var x=b-1;x>=0;x--){var D=this.wot.wtTable.columnFilter.renderedToSource(x);if(D>=e[1]&&D<=e[3]){_=D;break}}if(void 0!==g&&void 0!==v){t=g!==y||v!==_,n=this.wot.wtTable.getCell(new u.default(g,v)),o=t?this.wot.wtTable.getCell(new u.default(y,_)):n,i=(0,r.offset)(n),a=t?(0,r.offset)(o):i,l=(0,r.offset)(this.wot.wtTable.TABLE),d=i.top,p=a.top+(0,r.outerHeight)(o)-d,f=i.left,m=a.left+(0,r.outerWidth)(o)-f,c=d-l.top-1,h=f-l.left-1;var O=(0,r.getComputedStyle)(n);parseInt(O.borderTopWidth,10)>0&&(c+=1,p=p>0?p-1:0),parseInt(O.borderLeftWidth,10)>0&&(h+=1,m=m>0?m-1:0),this.topStyle.top=c+"px",this.topStyle.left=h+"px",this.topStyle.width=m+"px",this.topStyle.display="block",this.leftStyle.top=c+"px",this.leftStyle.left=h+"px",this.leftStyle.height=p+"px",this.leftStyle.display="block";var E=Math.floor(this.settings.border.width/2);this.bottomStyle.top=c+p-E+"px",this.bottomStyle.left=h+"px",this.bottomStyle.width=m+"px",this.bottomStyle.display="block",this.rightStyle.top=c+"px",this.rightStyle.left=h+m-E+"px",this.rightStyle.height=p+1+"px",this.rightStyle.display="block",(0,s.isMobileBrowser)()||!this.hasSetting(this.settings.border.cornerVisible)||this.isPartRange(y,_)?this.cornerStyle.display="none":(this.cornerStyle.top=c+p-4+"px",this.cornerStyle.left=h+m-4+"px",this.cornerStyle.borderRightWidth=this.cornerDefaultStyle.borderWidth,this.cornerStyle.width=this.cornerDefaultStyle.width,this.cornerStyle.display="none",w=(0,r.getTrimmingContainer)(this.wot.wtTable.TABLE),_===this.wot.getSetting("totalColumns")-1&&o.offsetLeft+(0,r.outerWidth)(o)+parseInt(this.cornerDefaultStyle.width,10)/2>=(0,r.innerWidth)(w)&&(this.cornerStyle.left=Math.floor(h+m-3-parseInt(this.cornerDefaultStyle.width,10)/2)+"px",this.cornerStyle.borderRightWidth=0),y===this.wot.getSetting("totalRows")-1&&o.offsetTop+(0,r.outerHeight)(o)+parseInt(this.cornerDefaultStyle.height,10)/2>=(0,r.innerHeight)(w)&&(this.cornerStyle.top=Math.floor(c+p-3-parseInt(this.cornerDefaultStyle.height,10)/2)+"px",this.cornerStyle.borderBottomWidth=0),this.cornerStyle.display="block"),(0,s.isMobileBrowser)()&&this.updateMultipleSelectionHandlesPosition(g,v,c,h,m,p)}else this.disappear()}}},{key:"disappear",value:function(){this.topStyle.display="none",this.leftStyle.display="none",this.bottomStyle.display="none",this.rightStyle.display="none",this.cornerStyle.display="none",(0,s.isMobileBrowser)()&&(this.selectionHandles.styles.topLeft.display="none",this.selectionHandles.styles.bottomRight.display="none")}},{key:"hasSetting",value:function(e){return"function"==typeof e?e():!!e}}]),e}();t.default=d},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=new WeakMap,i=function(){function e(t,n,o,i,a,s,l){var u=arguments.length>7&&void 0!==arguments[7]?arguments[7]:function(e){return e};!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),r.set(this,{viewportWidth:t,scrollOffset:n,totalColumns:o,columnWidthFn:i,overrideFn:a,onlyFullyVisible:s,stretchingColumnWidthFn:u}),this.count=0,this.startColumn=null,this.endColumn=null,this.startPosition=null,this.stretchAllRatio=0,this.stretchLastWidth=0,this.stretch=l,this.totalTargetWidth=0,this.needVerifyLastColumnWidth=!0,this.stretchAllColumnsWidth=[],this.calculate()}return o(e,null,[{key:"DEFAULT_WIDTH",get:function(){return 50}}]),o(e,[{key:"calculate",value:function(){for(var e=0,t=!0,n=[],o=void 0,i=r.get(this),a=i.onlyFullyVisible,s=i.overrideFn,l=i.scrollOffset,u=i.totalColumns,c=i.viewportWidth,d=0;d<u;d++)if(o=this._getColumnWidth(d),e<=l&&!a&&(this.startColumn=d),e>=l&&e+o<=l+(l>0?c+1:c)&&(null==this.startColumn&&(this.startColumn=d),this.endColumn=d),n.push(e),e+=o,a||(this.endColumn=d),e>=l+c){t=!1;break}if(this.endColumn===u-1&&t)for(this.startColumn=this.endColumn;this.startColumn>0;){var h=n[this.endColumn]+o-n[this.startColumn-1];if((h<=c||!a)&&this.startColumn--,h>c)break}null!==this.startColumn&&s&&s(this),this.startPosition=n[this.startColumn],null==this.startPosition&&(this.startPosition=null),null!==this.startColumn&&(this.count=this.endColumn-this.startColumn+1)}},{key:"refreshStretching",value:function(e){if("none"!==this.stretch){this.totalTargetWidth=e;for(var t=r.get(this),n=t.totalColumns,o=0,i=0;i<n;i++){var a=this._getColumnWidth(i),s=t.stretchingColumnWidthFn(void 0,i);"number"==typeof s?e-=s:o+=a}var l=e-o;if("all"===this.stretch&&l>0)this.stretchAllRatio=e/o,this.stretchAllColumnsWidth=[],this.needVerifyLastColumnWidth=!0;else if("last"===this.stretch&&e!==1/0){var u=this._getColumnWidth(n-1),c=l+u;this.stretchLastWidth=c>=0?c:u}}}},{key:"getStretchedColumnWidth",value:function(e,t){var n=null;return"all"===this.stretch&&0!==this.stretchAllRatio?n=this._getStretchedAllColumnWidth(e,t):"last"===this.stretch&&0!==this.stretchLastWidth&&(n=this._getStretchedLastColumnWidth(e)),n}},{key:"_getStretchedAllColumnWidth",value:function(e,t){var n=0,o=r.get(this),i=o.totalColumns;if(!this.stretchAllColumnsWidth[e]){var a=Math.round(t*this.stretchAllRatio),s=o.stretchingColumnWidthFn(a,e);this.stretchAllColumnsWidth[e]=void 0===s?a:isNaN(s)?this._getColumnWidth(e):s}if(this.stretchAllColumnsWidth.length===i&&this.needVerifyLastColumnWidth){this.needVerifyLastColumnWidth=!1;for(var l=0;l<this.stretchAllColumnsWidth.length;l++)n+=this.stretchAllColumnsWidth[l];n!==this.totalTargetWidth&&(this.stretchAllColumnsWidth[this.stretchAllColumnsWidth.length-1]+=this.totalTargetWidth-n)}return this.stretchAllColumnsWidth[e]}},{key:"_getStretchedLastColumnWidth",value:function(e){return e===r.get(this).totalColumns-1?this.stretchLastWidth:null}},{key:"_getColumnWidth",value:function(t){var n=r.get(this).columnWidthFn(t);return void 0===n&&(n=e.DEFAULT_WIDTH),n}}]),e}();t.default=i},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=new WeakMap,i=function(){function e(t,n,o,i,a,s,l){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),r.set(this,{viewportHeight:t,scrollOffset:n,totalRows:o,rowHeightFn:i,overrideFn:a,onlyFullyVisible:s,horizontalScrollbarHeight:l}),this.count=0,this.startRow=null,this.endRow=null,this.startPosition=null,this.calculate()}return o(e,null,[{key:"DEFAULT_HEIGHT",get:function(){return 23}}]),o(e,[{key:"calculate",value:function(){for(var t=0,n=!0,o=[],i=r.get(this),a=i.onlyFullyVisible,s=i.overrideFn,l=i.rowHeightFn,u=i.scrollOffset,c=i.totalRows,d=i.viewportHeight,h=i.horizontalScrollbarHeight||0,f=void 0,p=0;p<c;p++)if(void 0===(f=l(p))&&(f=e.DEFAULT_HEIGHT),t<=u&&!a&&(this.startRow=p),t>=u&&t+f<=u+d-h&&(null===this.startRow&&(this.startRow=p),this.endRow=p),o.push(t),t+=f,a||(this.endRow=p),t>=u+d-h){n=!1;break}if(this.endRow===c-1&&n)for(this.startRow=this.endRow;this.startRow>0;){var m=o[this.endRow]+f-o[this.startRow-1];if((m<=d-h||!a)&&this.startRow--,m>=d-h)break}null!==this.startRow&&s&&s(this),this.startPosition=o[this.startRow],null==this.startPosition&&(this.startPosition=null),null!==this.startRow&&(this.count=this.endRow-this.startRow+1)}}]),e}();t.default=i},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(2),a=n(27),s=f(n(138)),l=f(n(141)),u=f(n(142)),c=f(n(143)),d=f(n(144)),h=f(n(146));function f(e){return e&&e.__esModule?e:{default:e}}var p=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n=[];if(this.guid="wt_"+(0,a.randomString)(),t.cloneSource?(this.cloneSource=t.cloneSource,this.cloneOverlay=t.cloneOverlay,this.wtSettings=t.cloneSource.wtSettings,this.wtTable=new d.default(this,t.table,t.wtRootElement),this.wtScroll=new u.default(this),this.wtViewport=t.cloneSource.wtViewport,this.wtEvent=new s.default(this),this.selections=this.cloneSource.selections):(this.wtSettings=new c.default(this,t),this.wtTable=new d.default(this,t.table),this.wtScroll=new u.default(this),this.wtViewport=new h.default(this),this.wtEvent=new s.default(this),this.selections=this.getSetting("selections"),this.wtOverlays=new l.default(this),this.exportSettingsAsClassNames()),this.wtTable.THEAD.childNodes.length&&this.wtTable.THEAD.childNodes[0].childNodes.length){for(var o=0,i=this.wtTable.THEAD.childNodes[0].childNodes.length;o<i;o++)n.push(this.wtTable.THEAD.childNodes[0].childNodes[o].innerHTML);this.getSetting("columnHeaders").length||this.update("columnHeaders",[function(e,t){(0,r.fastInnerText)(t,n[e])}])}this.drawn=!1,this.drawInterrupted=!1}return o(e,[{key:"draw",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return this.drawInterrupted=!1,e||(0,r.isVisible)(this.wtTable.TABLE)?this.wtTable.draw(e):this.drawInterrupted=!0,this}},{key:"getCell",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(!t)return this.wtTable.getCell(e);var n=this.wtSettings.getSetting("totalRows"),o=this.wtSettings.getSetting("fixedRowsTop"),r=this.wtSettings.getSetting("fixedRowsBottom"),i=this.wtSettings.getSetting("fixedColumnsLeft");if(e.row<o&&e.col<i)return this.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell(e);if(e.row<o)return this.wtOverlays.topOverlay.clone.wtTable.getCell(e);if(e.col<i&&e.row>=n-r){if(this.wtOverlays.bottomLeftCornerOverlay&&this.wtOverlays.bottomLeftCornerOverlay.clone)return this.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.getCell(e)}else{if(e.col<i)return this.wtOverlays.leftOverlay.clone.wtTable.getCell(e);if(e.row<n&&e.row>n-r&&this.wtOverlays.bottomOverlay&&this.wtOverlays.bottomOverlay.clone)return this.wtOverlays.bottomOverlay.clone.wtTable.getCell(e)}return this.wtTable.getCell(e)}},{key:"update",value:function(e,t){return this.wtSettings.update(e,t)}},{key:"scrollVertical",value:function(e){return this.wtOverlays.topOverlay.scrollTo(e),this.getSetting("onScrollVertically"),this}},{key:"scrollHorizontal",value:function(e){return this.wtOverlays.leftOverlay.scrollTo(e),this.getSetting("onScrollHorizontally"),this}},{key:"scrollViewport",value:function(e){return this.wtScroll.scrollViewport(e),this}},{key:"getViewport",value:function(){return[this.wtTable.getFirstVisibleRow(),this.wtTable.getFirstVisibleColumn(),this.wtTable.getLastVisibleRow(),this.wtTable.getLastVisibleColumn()]}},{key:"getOverlayName",value:function(){return this.cloneOverlay?this.cloneOverlay.type:"master"}},{key:"isOverlayName",value:function(e){return!!this.cloneOverlay&&this.cloneOverlay.type===e}},{key:"exportSettingsAsClassNames",value:function(){var e=this,t=[],n=[];(0,i.objectEach)({rowHeaders:["array"],columnHeaders:["array"]},function(o,r){o.indexOf("array")>-1&&e.getSetting(r).length&&n.push("ht"+(0,a.toUpperCaseFirst)(r)),t.push("ht"+(0,a.toUpperCaseFirst)(r))}),(0,r.removeClass)(this.wtTable.wtRootElement.parentNode,t),(0,r.addClass)(this.wtTable.wtRootElement.parentNode,n)}},{key:"getSetting",value:function(e,t,n,o,r){return this.wtSettings.getSetting(e,t,n,o,r)}},{key:"hasSetting",value:function(e){return this.wtSettings.has(e)}},{key:"destroy",value:function(){this.wtOverlays.destroy(),this.wtEvent.destroy()}}]),e}();t.default=p},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(0),i=n(35),a=n(25),s=n(4),l=(o=s)&&o.__esModule?o:{default:o};function u(e){var t=this,n=new l.default(e);this.instance=e;var o=[null,null];this.dblClickTimeout=[null,null];var s=function(e){var n=document.activeElement,a=(0,i.partial)(r.getParent,e.realTarget),s=e.realTarget;if(s!==n&&a(0)!==n&&a(1)!==n){var l=t.parentCell(s);(0,r.hasClass)(s,"corner")?t.instance.getSetting("onCellCornerMouseDown",e,s):l.TD&&t.instance.hasSetting("onCellMouseDown")&&t.instance.getSetting("onCellMouseDown",e,l.coords,l.TD,t.instance),2!==e.button&&l.TD&&(o[0]=l.TD,clearTimeout(t.dblClickTimeout[0]),t.dblClickTimeout[0]=setTimeout(function(){o[0]=null},1e3))}},u=function(e){t.instance.touchMoving=!0},c=function(e){n.addEventListener(this,"touchmove",u),t.checkIfTouchMove=setTimeout(function(){!0===t.instance.touchMoving&&(t.instance.touchMoving=void 0,n.removeEventListener("touchmove",u,!1)),s(e)},30)},d=function(e){if(2!==e.button){var n=t.parentCell(e.realTarget);n.TD===o[0]&&n.TD===o[1]?((0,r.hasClass)(e.realTarget,"corner")?t.instance.getSetting("onCellCornerDblClick",e,n.coords,n.TD,t.instance):t.instance.getSetting("onCellDblClick",e,n.coords,n.TD,t.instance),o[0]=null,o[1]=null):n.TD===o[0]?(t.instance.getSetting("onCellMouseUp",e,n.coords,n.TD,t.instance),o[1]=n.TD,clearTimeout(t.dblClickTimeout[1]),t.dblClickTimeout[1]=setTimeout(function(){o[1]=null},500)):n.TD&&t.instance.hasSetting("onCellMouseUp")&&t.instance.getSetting("onCellMouseUp",e,n.coords,n.TD,t.instance)}},h=function(e){clearTimeout(void 0),e.preventDefault(),d(e)};if(n.addEventListener(this.instance.wtTable.holder,"mousedown",s),n.addEventListener(this.instance.wtTable.TABLE,"mouseover",function(e){var n,o,i;t.instance.hasSetting("onCellMouseOver")&&(n=t.instance.wtTable.TABLE,o=(0,r.closestDown)(e.realTarget,["TD","TH"],n),i=t.instance.cloneSource||t.instance,o&&o!==i.lastMouseOver&&(0,r.isChildOf)(o,n)&&(i.lastMouseOver=o,t.instance.getSetting("onCellMouseOver",e,t.instance.wtTable.getCoords(o),o,t.instance)))}),n.addEventListener(this.instance.wtTable.TABLE,"mouseout",function(e){var n=void 0,o=void 0,i=void 0;t.instance.hasSetting("onCellMouseOut")&&(n=t.instance.wtTable.TABLE,o=(0,r.closestDown)(e.realTarget,["TD","TH"],n),i=(0,r.closestDown)(e.relatedTarget,["TD","TH"],n),o&&o!==i&&(0,r.isChildOf)(o,n)&&t.instance.getSetting("onCellMouseOut",e,t.instance.wtTable.getCoords(o),o,t.instance))}),n.addEventListener(this.instance.wtTable.holder,"mouseup",d),this.instance.wtTable.holder.parentNode.parentNode&&(0,a.isMobileBrowser)()&&!t.instance.wtTable.isWorkingOnClone()){var f="."+this.instance.wtTable.holder.parentNode.className.split(" ").join(".");n.addEventListener(this.instance.wtTable.holder,"touchstart",function(e){t.instance.touchApplied=!0,(0,r.isChildOf)(e.target,f)&&c.call(e.target,e)}),n.addEventListener(this.instance.wtTable.holder,"touchend",function(e){t.instance.touchApplied=!1,(0,r.isChildOf)(e.target,f)&&h.call(e.target,e)}),t.instance.momentumScrolling||(t.instance.momentumScrolling={}),n.addEventListener(this.instance.wtTable.holder,"scroll",function(e){clearTimeout(t.instance.momentumScrolling._timeout),t.instance.momentumScrolling.ongoing||t.instance.getSetting("onBeforeTouchScroll"),t.instance.momentumScrolling.ongoing=!0,t.instance.momentumScrolling._timeout=setTimeout(function(){t.instance.touchApplied||(t.instance.momentumScrolling.ongoing=!1,t.instance.getSetting("onAfterMomentumScroll"))},200)})}n.addEventListener(window,"resize",function(){"none"!==t.instance.getSetting("stretchH")&&t.instance.draw()}),this.destroy=function(){clearTimeout(this.dblClickTimeout[0]),clearTimeout(this.dblClickTimeout[1]),n.destroy()}}u.prototype.parentCell=function(e){var t={},n=this.instance.wtTable.TABLE,o=(0,r.closestDown)(e,["TD","TH"],n);return o?(t.coords=this.instance.wtTable.getCoords(o),t.TD=o):(0,r.hasClass)(e,"wtBorder")&&(0,r.hasClass)(e,"current")?(t.coords=this.instance.selections.current.cellRange.highlight,t.TD=this.instance.wtTable.getCell(t.coords)):(0,r.hasClass)(e,"wtBorder")&&(0,r.hasClass)(e,"area")&&this.instance.selections.area.cellRange&&(t.coords=this.instance.selections.area.cellRange.to,t.TD=this.instance.wtTable.getCell(t.coords)),t},t.default=u},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function(){function e(t,n,o){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.offset=t,this.total=n,this.countTH=o}return o(e,[{key:"offsetted",value:function(e){return e+this.offset}},{key:"unOffsetted",value:function(e){return e-this.offset}},{key:"renderedToSource",value:function(e){return this.offsetted(e)}},{key:"sourceToRendered",value:function(e){return this.unOffsetted(e)}},{key:"offsettedTH",value:function(e){return e-this.countTH}},{key:"unOffsettedTH",value:function(e){return e+this.countTH}},{key:"visibleRowHeadedColumnToSourceColumn",value:function(e){return this.renderedToSource(this.offsettedTH(e))}},{key:"sourceColumnToVisibleRowHeadedColumn",value:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}}]),e}();t.default=r},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function(){function e(t,n,o){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.offset=t,this.total=n,this.countTH=o}return o(e,[{key:"offsetted",value:function(e){return e+this.offset}},{key:"unOffsetted",value:function(e){return e-this.offset}},{key:"renderedToSource",value:function(e){return this.offsetted(e)}},{key:"sourceToRendered",value:function(e){return this.unOffsetted(e)}},{key:"offsettedTH",value:function(e){return e-this.countTH}},{key:"unOffsettedTH",value:function(e){return e+this.countTH}},{key:"visibleColHeadedRowToSourceRow",value:function(e){return this.renderedToSource(this.offsettedTH(e))}},{key:"sourceRowToVisibleColHeadedRow",value:function(e){return this.unOffsettedTH(this.sourceToRendered(e))}}]),e}();t.default=r},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(1),a=n(16),s=n(25),l=c(n(4)),u=c(n(28));function c(e){return e&&e.__esModule?e:{default:e}}var d=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.wot=t,this.instance=this.wot,this.eventManager=new l.default(this.wot),this.wot.update("scrollbarWidth",(0,r.getScrollbarWidth)()),this.wot.update("scrollbarHeight",(0,r.getScrollbarWidth)()),this.scrollableElement=(0,r.getScrollableElement)(this.wot.wtTable.TABLE),this.prepareOverlays(),this.destroyed=!1,this.keyPressed=!1,this.spreaderLastSize={width:null,height:null},this.overlayScrollPositions={master:{top:0,left:0},top:{top:null,left:0},bottom:{top:null,left:0},left:{top:0,left:null}},this.pendingScrollCallbacks={master:{top:0,left:0},top:{left:0},bottom:{left:0},left:{top:0}},this.verticalScrolling=!1,this.horizontalScrolling=!1,this.delegatedScrollCallback=!1,this.registeredListeners=[],this.registerListeners()}return o(e,[{key:"prepareOverlays",value:function(){var e=!1;return this.topOverlay?e=this.topOverlay.updateStateOfRendering()||e:this.topOverlay=u.default.createOverlay(u.default.CLONE_TOP,this.wot),u.default.hasOverlay(u.default.CLONE_BOTTOM)||(this.bottomOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),u.default.hasOverlay(u.default.CLONE_BOTTOM_LEFT_CORNER)||(this.bottomLeftCornerOverlay={needFullRender:!1,updateStateOfRendering:function(){return!1}}),this.bottomOverlay?e=this.bottomOverlay.updateStateOfRendering()||e:this.bottomOverlay=u.default.createOverlay(u.default.CLONE_BOTTOM,this.wot),this.leftOverlay?e=this.leftOverlay.updateStateOfRendering()||e:this.leftOverlay=u.default.createOverlay(u.default.CLONE_LEFT,this.wot),this.topOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.topLeftCornerOverlay?e=this.topLeftCornerOverlay.updateStateOfRendering()||e:this.topLeftCornerOverlay=u.default.createOverlay(u.default.CLONE_TOP_LEFT_CORNER,this.wot)),this.bottomOverlay.needFullRender&&this.leftOverlay.needFullRender&&(this.bottomLeftCornerOverlay?e=this.bottomLeftCornerOverlay.updateStateOfRendering()||e:this.bottomLeftCornerOverlay=u.default.createOverlay(u.default.CLONE_BOTTOM_LEFT_CORNER,this.wot)),this.wot.getSetting("debug")&&!this.debug&&(this.debug=u.default.createOverlay(u.default.CLONE_DEBUG,this.wot)),e}},{key:"refreshAll",value:function(){this.wot.drawn&&(this.wot.wtTable.holder.parentNode?(this.wot.draw(!0),this.verticalScrolling&&this.leftOverlay.onScroll(),this.horizontalScrolling&&this.topOverlay.onScroll(),this.verticalScrolling=!1,this.horizontalScrolling=!1):this.destroy())}},{key:"registerListeners",value:function(){var e=this,t=this.topOverlay.mainTableScrollableElement,n=this.leftOverlay.mainTableScrollableElement,o=[];for(o.push([document.documentElement,"keydown",function(t){return e.onKeyDown(t)}]),o.push([document.documentElement,"keyup",function(){return e.onKeyUp()}]),o.push([document,"visibilitychange",function(){return e.onKeyUp()}]),o.push([t,"scroll",function(t){return e.onTableScroll(t)}]),t!==n&&o.push([n,"scroll",function(t){return e.onTableScroll(t)}]),this.topOverlay.needFullRender&&(o.push([this.topOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),o.push([this.topOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.bottomOverlay.needFullRender&&(o.push([this.bottomOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),o.push([this.bottomOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.leftOverlay.needFullRender&&(o.push([this.leftOverlay.clone.wtTable.holder,"scroll",function(t){return e.onTableScroll(t)}]),o.push([this.leftOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}])),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.needFullRender&&o.push([this.topLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.needFullRender&&o.push([this.bottomLeftCornerOverlay.clone.wtTable.holder,"wheel",function(t){return e.onTableScroll(t)}]),this.topOverlay.trimmingContainer!==window&&this.leftOverlay.trimmingContainer!==window&&o.push([window,"wheel",function(t){var n=void 0,o=t.wheelDeltaY||t.deltaY,r=t.wheelDeltaX||t.deltaX;e.topOverlay.clone.wtTable.holder.contains(t.realTarget)?n="top":e.bottomOverlay.clone&&e.bottomOverlay.clone.wtTable.holder.contains(t.realTarget)?n="bottom":e.leftOverlay.clone.wtTable.holder.contains(t.realTarget)?n="left":e.topLeftCornerOverlay&&e.topLeftCornerOverlay.clone&&e.topLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)?n="topLeft":e.bottomLeftCornerOverlay&&e.bottomLeftCornerOverlay.clone&&e.bottomLeftCornerOverlay.clone.wtTable.holder.contains(t.realTarget)&&(n="bottomLeft"),("top"==n&&0!==o||"left"==n&&0!==r||"bottom"==n&&0!==o||("topLeft"===n||"bottomLeft"===n)&&(0!==o||0!==r))&&t.preventDefault()}]);o.length;){var r=o.pop();this.eventManager.addEventListener(r[0],r[1],r[2]),this.registeredListeners.push(r)}}},{key:"deregisterListeners",value:function(){for(;this.registeredListeners.length;){var e=this.registeredListeners.pop();this.eventManager.removeEventListener(e[0],e[1],e[2])}}},{key:"onTableScroll",value:function(e){if(!(0,s.isMobileBrowser)()){var t=this.leftOverlay.mainTableScrollableElement,n=this.topOverlay.mainTableScrollableElement,o=e.target;this.keyPressed&&(n!==window&&o!==window&&!e.target.contains(n)||t!==window&&o!==window&&!e.target.contains(t))||("scroll"===e.type?this.syncScrollPositions(e):this.translateMouseWheelToScroll(e))}}},{key:"onKeyDown",value:function(e){this.keyPressed=(0,a.isKey)(e.keyCode,"ARROW_UP|ARROW_RIGHT|ARROW_DOWN|ARROW_LEFT")}},{key:"onKeyUp",value:function(){this.keyPressed=!1}},{key:"translateMouseWheelToScroll",value:function(e){var t=this.topOverlay.clone.wtTable.holder,n=this.bottomOverlay.clone?this.bottomOverlay.clone.wtTable.holder:null,o=this.leftOverlay.clone.wtTable.holder,r=this.topLeftCornerOverlay&&this.topLeftCornerOverlay.clone?this.topLeftCornerOverlay.clone.wtTable.holder:null,i=this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone?this.bottomLeftCornerOverlay.clone.wtTable.holder:null,a=e.wheelDeltaY||-1*e.deltaY,s=e.wheelDeltaX||-1*e.deltaX,l=null,u={type:"wheel"},c=e.target,d=null;for(1===e.deltaMode&&(a*=120,s*=120);c!=document&&null!=c;){if(c.className.indexOf("wtHolder")>-1){l=c;break}c=c.parentNode}return u.target=l,l===r||l===i?(this.syncScrollPositions(u,-.2*s,"x"),this.syncScrollPositions(u,-.2*a,"y")):(l===t||l===n?d=a:l===o&&(d=s),this.syncScrollPositions(u,-.2*d)),!1}},{key:"syncScrollPositions",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null;if(!this.destroyed)if(0!==arguments.length){var o=this.leftOverlay.mainTableScrollableElement,i=this.topOverlay.mainTableScrollableElement,a=e.target,s=0,l=!1,u=void 0,c=void 0,d=void 0,h=void 0,f=void 0,p=!1,m=this.wot.getSetting("preventOverflow");this.topOverlay.needFullRender&&(u=this.topOverlay.clone.wtTable.holder),this.bottomOverlay.needFullRender&&(f=this.bottomOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&(c=this.leftOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.topOverlay.needFullRender&&(d=this.topLeftCornerOverlay.clone.wtTable.holder),this.leftOverlay.needFullRender&&this.bottomOverlay.needFullRender&&(h=this.bottomLeftCornerOverlay.clone.wtTable.holder),a===document&&(a=window),a===o||a===i?(s=m?(0,r.getScrollLeft)(this.scrollableElement):(0,r.getScrollLeft)(a),this.horizontalScrolling=!0,this.overlayScrollPositions.master.left=s,l=!0,this.pendingScrollCallbacks.master.left>0?this.pendingScrollCallbacks.master.left--:(u&&u.scrollLeft!==s&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=s,p=o!==window),f&&f.scrollLeft!==s&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=s,p=o!==window)),s=(0,r.getScrollTop)(a),this.verticalScrolling=!0,this.overlayScrollPositions.master.top=s,l=!0,this.pendingScrollCallbacks.master.top>0?this.pendingScrollCallbacks.master.top--:c&&c.scrollTop!==s&&(null==t&&this.pendingScrollCallbacks.left.top++,c.scrollTop=s,p=i!==window)):a===f?(s=(0,r.getScrollLeft)(a),this.horizontalScrolling=!0,this.overlayScrollPositions.bottom.left=s,l=!0,this.pendingScrollCallbacks.bottom.left>0?this.pendingScrollCallbacks.bottom.left--:(null==t&&this.pendingScrollCallbacks.master.left++,o.scrollLeft=s,u&&u.scrollLeft!==s&&(null==t&&this.pendingScrollCallbacks.top.left++,u.scrollLeft=s,p=i!==window)),null!==t&&(l=!0,i.scrollTop+=t)):a===u?(s=(0,r.getScrollLeft)(a),this.horizontalScrolling=!0,this.overlayScrollPositions.top.left=s,l=!0,this.pendingScrollCallbacks.top.left>0?this.pendingScrollCallbacks.top.left--:(null==t&&this.pendingScrollCallbacks.master.left++,o.scrollLeft=s),null!==t&&(l=!0,i.scrollTop+=t),f&&f.scrollLeft!==s&&(null==t&&this.pendingScrollCallbacks.bottom.left++,f.scrollLeft=s,p=i!==window)):a===c?(s=(0,r.getScrollTop)(a),this.overlayScrollPositions.left.top!==s&&(this.verticalScrolling=!0,this.overlayScrollPositions.left.top=s,l=!0,this.pendingScrollCallbacks.left.top>0?this.pendingScrollCallbacks.left.top--:(null==t&&this.pendingScrollCallbacks.master.top++,i.scrollTop=s)),null!==t&&(l=!0,i.scrollLeft+=t)):a!==d&&a!==h||null!==t&&(l=!0,"x"===n?i.scrollLeft+=t:"y"===n&&(i.scrollTop+=t)),!this.keyPressed&&l&&"scroll"===e.type&&(this.delegatedScrollCallback?this.delegatedScrollCallback=!1:this.refreshAll(),p&&(this.delegatedScrollCallback=!0))}else this.syncScrollWithMaster()}},{key:"syncScrollWithMaster",value:function(){var e=this.topOverlay.mainTableScrollableElement,t=e.scrollLeft,n=e.scrollTop;this.topOverlay.needFullRender&&(this.topOverlay.clone.wtTable.holder.scrollLeft=t),this.bottomOverlay.needFullRender&&(this.bottomOverlay.clone.wtTable.holder.scrollLeft=t),this.leftOverlay.needFullRender&&(this.leftOverlay.clone.wtTable.holder.scrollTop=n)}},{key:"updateMainScrollableElements",value:function(){this.deregisterListeners(),this.leftOverlay.updateMainScrollableElement(),this.topOverlay.updateMainScrollableElement(),this.bottomOverlay.needFullRender&&this.bottomOverlay.updateMainScrollableElement(),this.scrollableElement=(0,r.getScrollableElement)(this.wot.wtTable.TABLE),this.registerListeners()}},{key:"destroy",value:function(){this.eventManager.destroy(),this.topOverlay.destroy(),this.bottomOverlay.clone&&this.bottomOverlay.destroy(),this.leftOverlay.destroy(),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.destroy(),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.destroy(),this.debug&&this.debug.destroy(),this.destroyed=!0}},{key:"refresh",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted){var t=this.wot.wtTable.wtRootElement.parentNode||this.wot.wtTable.wtRootElement,n=t.clientWidth,o=t.clientHeight;n===this.spreaderLastSize.width&&o===this.spreaderLastSize.height||(this.spreaderLastSize.width=n,this.spreaderLastSize.height=o,this.adjustElementsSize())}this.bottomOverlay.clone&&this.bottomOverlay.refresh(e),this.leftOverlay.refresh(e),this.topOverlay.refresh(e),this.topLeftCornerOverlay&&this.topLeftCornerOverlay.refresh(e),this.bottomLeftCornerOverlay&&this.bottomLeftCornerOverlay.clone&&this.bottomLeftCornerOverlay.refresh(e),this.debug&&this.debug.refresh(e)}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.wot.getSetting("totalColumns"),n=this.wot.getSetting("totalRows"),o=this.wot.wtViewport.getRowHeaderWidth(),r=this.wot.wtViewport.getColumnHeaderHeight(),i=this.wot.wtTable.hider.style;i.width=o+this.leftOverlay.sumCellSizes(0,t)+"px",i.height=r+this.topOverlay.sumCellSizes(0,n)+1+"px",this.topOverlay.adjustElementsSize(e),this.leftOverlay.adjustElementsSize(e),this.bottomOverlay.clone&&this.bottomOverlay.adjustElementsSize(e)}},{key:"applyToDOM",value:function(){this.topOverlay.areElementSizesAdjusted&&this.leftOverlay.areElementSizesAdjusted||this.adjustElementsSize(),this.topOverlay.applyToDOM(),this.bottomOverlay.clone&&this.bottomOverlay.applyToDOM(),this.leftOverlay.applyToDOM()}},{key:"getParentOverlay",value:function(e){if(!e)return null;var t=[this.topOverlay,this.leftOverlay,this.bottomOverlay,this.topLeftCornerOverlay,this.bottomLeftCornerOverlay],n=null;return(0,i.arrayEach)(t,function(t,o){t&&t.clone&&t.clone.wtTable.TABLE.contains(e)&&(n=t.clone)}),n}}]),e}();t.default=d},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(6),a=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.wot=t,this.instance=t}return o(e,[{key:"scrollViewport",value:function(e){if(this.wot.drawn){var t=this._getVariables(),n=t.topOverlay,o=t.leftOverlay,r=t.totalRows,i=t.totalColumns,a=t.fixedRowsTop,s=t.fixedRowsBottom,l=t.fixedColumnsLeft;if(e.row<0||e.row>Math.max(r-1,0))throw new Error("row "+e.row+" does not exist");if(e.col<0||e.col>Math.max(i-1,0))throw new Error("column "+e.col+" does not exist");e.row>=a&&e.row<this.getFirstVisibleRow()?n.scrollTo(e.row):e.row>this.getLastVisibleRow()&&e.row<r-s&&n.scrollTo(e.row,!0),e.col>=l&&e.col<this.getFirstVisibleColumn()?o.scrollTo(e.col):e.col>this.getLastVisibleColumn()&&o.scrollTo(e.col,!0)}}},{key:"getFirstVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,n=e.wtTable,o=e.wtViewport,a=e.totalRows,s=e.fixedRowsTop,l=n.getFirstVisibleRow();if(t.mainTableScrollableElement===window){var u=(0,r.offset)(n.wtRootElement),c=(0,r.innerHeight)(n.hider),d=(0,r.innerHeight)(window),h=(0,r.getScrollTop)(window);if(u.top+c-d<=h){var f=o.getColumnHeaderHeight();f+=t.sumCellSizes(0,s),(0,i.rangeEachReverse)(a,1,function(e){if(f+=t.sumCellSizes(e-1,e),u.top+c-f<=h)return l=e,!1})}}return l}},{key:"getLastVisibleRow",value:function(){var e=this._getVariables(),t=e.topOverlay,n=e.wtTable,o=e.wtViewport,a=e.totalRows,s=n.getLastVisibleRow();if(t.mainTableScrollableElement===window){var l=(0,r.offset)(n.wtRootElement),u=(0,r.innerHeight)(window),c=(0,r.getScrollTop)(window);if(l.top>c){var d=o.getColumnHeaderHeight();(0,i.rangeEach)(1,a,function(e){if(d+=t.sumCellSizes(e-1,e),l.top+d-c>=u)return s=e-2,!1})}}return s}},{key:"getFirstVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,n=e.wtTable,o=e.wtViewport,a=e.totalColumns,s=(e.fixedColumnsLeft,n.getFirstVisibleColumn());if(t.mainTableScrollableElement===window){var l=(0,r.offset)(n.wtRootElement),u=(0,r.innerWidth)(n.hider),c=(0,r.innerWidth)(window),d=(0,r.getScrollLeft)(window);if(l.left+u-c<=d){var h=o.getRowHeaderWidth();(0,i.rangeEachReverse)(a,1,function(e){if(h+=t.sumCellSizes(e-1,e),l.left+u-h<=d)return s=e,!1})}}return s}},{key:"getLastVisibleColumn",value:function(){var e=this._getVariables(),t=e.leftOverlay,n=e.wtTable,o=e.wtViewport,a=e.totalColumns,s=n.getLastVisibleColumn();if(t.mainTableScrollableElement===window){var l=(0,r.offset)(n.wtRootElement),u=(0,r.innerWidth)(window),c=(0,r.getScrollLeft)(window);if(l.left>c){var d=o.getRowHeaderWidth();(0,i.rangeEach)(1,a,function(e){if(d+=t.sumCellSizes(e-1,e),l.left+d-c>=u)return s=e-2,!1})}}return s}},{key:"_getVariables",value:function(){var e=this.wot;return{topOverlay:e.wtOverlays.topOverlay,leftOverlay:e.wtOverlays.leftOverlay,wtTable:e.wtTable,wtViewport:e.wtViewport,totalRows:e.getSetting("totalRows"),totalColumns:e.getSetting("totalColumns"),fixedRowsTop:e.getSetting("fixedRowsTop"),fixedRowsBottom:e.getSetting("fixedRowsBottom"),fixedColumnsLeft:e.getSetting("fixedColumnsLeft")}}}]),e}();t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(2),a=function(){function e(t,n){var o=this;for(var a in function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.wot=t,this.instance=t,this.defaults={table:void 0,debug:!1,externalRowCalculator:!1,stretchH:"none",currentRowClassName:null,currentColumnClassName:null,preventOverflow:function(){return!1},data:void 0,freezeOverlays:!1,fixedColumnsLeft:0,fixedRowsTop:0,fixedRowsBottom:0,minSpareRows:0,rowHeaders:function(){return[]},columnHeaders:function(){return[]},totalRows:void 0,totalColumns:void 0,cellRenderer:function(e,t,n){var i=o.getSetting("data",e,t);(0,r.fastInnerText)(n,null==i?"":i)},columnWidth:function(e){},rowHeight:function(e){},defaultRowHeight:23,defaultColumnWidth:50,selections:null,hideBorderOnMouseDownOver:!1,viewportRowCalculatorOverride:null,viewportColumnCalculatorOverride:null,onCellMouseDown:null,onCellMouseOver:null,onCellMouseOut:null,onCellMouseUp:null,onCellDblClick:null,onCellCornerMouseDown:null,onCellCornerDblClick:null,beforeDraw:null,onDraw:null,onBeforeDrawBorders:null,onScrollVertically:null,onScrollHorizontally:null,onBeforeTouchScroll:null,onAfterMomentumScroll:null,onBeforeStretchingColumnWidth:function(e){return e},onModifyRowHeaderWidth:null,scrollbarWidth:10,scrollbarHeight:10,renderAllRows:!1,groups:!1,rowHeaderWidth:null,columnHeaderHeight:null,headerClassName:null},this.settings={},this.defaults)if((0,i.hasOwnProperty)(this.defaults,a))if(void 0!==n[a])this.settings[a]=n[a];else{if(void 0===this.defaults[a])throw new Error('A required setting "'+a+'" was not provided');this.settings[a]=this.defaults[a]}}return o(e,[{key:"update",value:function(e,t){if(void 0===t)for(var n in e)(0,i.hasOwnProperty)(e,n)&&(this.settings[n]=e[n]);else this.settings[e]=t;return this.wot}},{key:"getSetting",value:function(e,t,n,o,r){return"function"==typeof this.settings[e]?this.settings[e](t,n,o,r):void 0!==t&&Array.isArray(this.settings[e])?this.settings[e][t]:this.settings[e]}},{key:"has",value:function(e){return!!this.settings[e]}}]),e}();t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=n(35),s=h(n(42)),l=(h(n(69)),h(n(139))),u=h(n(140)),c=h(n(145)),d=h(n(28));function h(e){return e&&e.__esModule?e:{default:e}}var f=function(){function e(t,n){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.wot=t,this.instance=this.wot,this.TABLE=n,this.TBODY=null,this.THEAD=null,this.COLGROUP=null,this.tableOffset=0,this.holderOffset=0,(0,i.removeTextNodes)(this.TABLE),this.spreader=this.createSpreader(this.TABLE),this.hider=this.createHider(this.spreader),this.holder=this.createHolder(this.hider),this.wtRootElement=this.holder.parentNode,this.alignOverlaysWithTrimmingContainer(),this.fixTableDomTree(),this.colgroupChildrenLength=this.COLGROUP.childNodes.length,this.theadChildrenLength=this.THEAD.firstChild?this.THEAD.firstChild.childNodes.length:0,this.tbodyChildrenLength=this.TBODY.childNodes.length,this.rowFilter=null,this.columnFilter=null,this.correctHeaderWidth=!1;var r=this.wot.wtSettings.settings.rowHeaderWidth;this.wot.wtSettings.settings.rowHeaderWidth=function(){return o._modifyRowHeaderWidth(r)}}return r(e,[{key:"fixTableDomTree",value:function(){this.TBODY=this.TABLE.querySelector("tbody"),this.TBODY||(this.TBODY=document.createElement("tbody"),this.TABLE.appendChild(this.TBODY)),this.THEAD=this.TABLE.querySelector("thead"),this.THEAD||(this.THEAD=document.createElement("thead"),this.TABLE.insertBefore(this.THEAD,this.TBODY)),this.COLGROUP=this.TABLE.querySelector("colgroup"),this.COLGROUP||(this.COLGROUP=document.createElement("colgroup"),this.TABLE.insertBefore(this.COLGROUP,this.THEAD)),this.wot.getSetting("columnHeaders").length&&!this.THEAD.childNodes.length&&this.THEAD.appendChild(document.createElement("TR"))}},{key:"createSpreader",value:function(e){var t=e.parentNode,n=void 0;return t&&1===t.nodeType&&(0,i.hasClass)(t,"wtHolder")||((n=document.createElement("div")).className="wtSpreader",t&&t.insertBefore(n,e),n.appendChild(e)),n.style.position="relative",n}},{key:"createHider",value:function(e){var t=e.parentNode,n=void 0;return t&&1===t.nodeType&&(0,i.hasClass)(t,"wtHolder")||((n=document.createElement("div")).className="wtHider",t&&t.insertBefore(n,e),n.appendChild(e)),n}},{key:"createHolder",value:function(e){var t=e.parentNode,n=void 0;return t&&1===t.nodeType&&(0,i.hasClass)(t,"wtHolder")||((n=document.createElement("div")).style.position="relative",n.className="wtHolder",t&&t.insertBefore(n,e),this.isWorkingOnClone()||(n.parentNode.className+="ht_master handsontable"),n.appendChild(e)),n}},{key:"alignOverlaysWithTrimmingContainer",value:function(){var e=(0,i.getTrimmingContainer)(this.wtRootElement);this.isWorkingOnClone()||(this.holder.parentNode.style.position="relative",e===window?this.wot.getSetting("preventOverflow")||(this.holder.style.overflow="visible",this.wtRootElement.style.overflow="visible"):(this.holder.style.width=(0,i.getStyle)(e,"width"),this.holder.style.height=(0,i.getStyle)(e,"height"),this.holder.style.overflow=""))}},{key:"isWorkingOnClone",value:function(){return!!this.wot.cloneSource}},{key:"draw",value:function(e){var t=this.wot,n=t.wtOverlays,o=t.wtViewport,r=this.instance.getSetting("totalRows"),a=this.wot.getSetting("rowHeaders").length,s=this.wot.getSetting("columnHeaders").length,c=!1;if(!this.isWorkingOnClone()&&(this.holderOffset=(0,i.offset)(this.holder),e=o.createRenderCalculators(e),a&&!this.wot.getSetting("fixedColumnsLeft"))){var h=n.leftOverlay.getScrollPosition(),f=this.correctHeaderWidth;this.correctHeaderWidth=h>0,f!==this.correctHeaderWidth&&(e=!1)}if(this.isWorkingOnClone()||(c=n.prepareOverlays()),e)this.isWorkingOnClone()||o.createVisibleCalculators(),n&&n.refresh(!0);else{this.isWorkingOnClone()?this.tableOffset=this.wot.cloneSource.wtTable.tableOffset:this.tableOffset=(0,i.offset)(this.TABLE);var p=void 0;p=d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_DEBUG)||d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_TOP)||d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_TOP_LEFT_CORNER)?0:d.default.isOverlayTypeOf(this.instance.cloneOverlay,d.default.CLONE_BOTTOM)||d.default.isOverlayTypeOf(this.instance.cloneOverlay,d.default.CLONE_BOTTOM_LEFT_CORNER)?Math.max(r-this.wot.getSetting("fixedRowsBottom"),0):o.rowsRenderCalculator.startRow;var m=void 0;m=d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_DEBUG)||d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_LEFT)||d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_TOP_LEFT_CORNER)||d.default.isOverlayTypeOf(this.wot.cloneOverlay,d.default.CLONE_BOTTOM_LEFT_CORNER)?0:o.columnsRenderCalculator.startColumn,this.rowFilter=new u.default(p,r,s),this.columnFilter=new l.default(m,this.wot.getSetting("totalColumns"),a),this.alignOverlaysWithTrimmingContainer(),this._doDraw()}return this.refreshSelections(e),this.isWorkingOnClone()||(n.topOverlay.resetFixedPosition(),n.bottomOverlay.clone&&n.bottomOverlay.resetFixedPosition(),n.leftOverlay.resetFixedPosition(),n.topLeftCornerOverlay&&n.topLeftCornerOverlay.resetFixedPosition(),n.bottomLeftCornerOverlay&&n.bottomLeftCornerOverlay.clone&&n.bottomLeftCornerOverlay.resetFixedPosition()),c&&n.syncScrollWithMaster(),this.wot.drawn=!0,this}},{key:"_doDraw",value:function(){new c.default(this).render()}},{key:"removeClassFromCells",value:function(e){for(var t=this.TABLE.querySelectorAll("."+e),n=0,o=t.length;n<o;n++)(0,i.removeClass)(t[n],e)}},{key:"refreshSelections",value:function(e){if(this.wot.selections){var t=this.wot.selections.length;if(e)for(var n=0;n<t;n++)this.wot.selections[n].settings.className&&this.removeClassFromCells(this.wot.selections[n].settings.className),this.wot.selections[n].settings.highlightHeaderClassName&&this.removeClassFromCells(this.wot.selections[n].settings.highlightHeaderClassName),this.wot.selections[n].settings.highlightRowClassName&&this.removeClassFromCells(this.wot.selections[n].settings.highlightRowClassName),this.wot.selections[n].settings.highlightColumnClassName&&this.removeClassFromCells(this.wot.selections[n].settings.highlightColumnClassName);for(var o=0;o<t;o++)this.wot.selections[o].draw(this.wot,e)}}},{key:"getCell",value:function(e){if(this.isRowBeforeRenderedRows(e.row))return-1;if(this.isRowAfterRenderedRows(e.row))return-2;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e.row)];return t?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e.col)]:void 0}},{key:"getColumnHeader",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.THEAD.childNodes[t];if(n)return n.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(e)]}},{key:"getRowHeader",value:function(e){if(0===this.columnFilter.sourceColumnToVisibleRowHeadedColumn(0))return null;var t=this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)];return t?t.childNodes[0]:void 0}},{key:"getCoords",value:function(e){if("TD"!==e.nodeName&&"TH"!==e.nodeName&&(e=(0,i.closest)(e,["TD","TH"])),null===e)return null;var t=e.parentNode,n=t.parentNode,o=(0,i.index)(t),r=e.cellIndex;return(0,i.overlayContainsElement)(d.default.CLONE_TOP_LEFT_CORNER,e)||(0,i.overlayContainsElement)(d.default.CLONE_TOP,e)?"THEAD"===n.nodeName&&(o-=n.childNodes.length):o=n===this.THEAD?this.rowFilter.visibleColHeadedRowToSourceRow(o):this.rowFilter.renderedToSource(o),r=(0,i.overlayContainsElement)(d.default.CLONE_TOP_LEFT_CORNER,e)||(0,i.overlayContainsElement)(d.default.CLONE_LEFT,e)?this.columnFilter.offsettedTH(r):this.columnFilter.visibleRowHeadedColumnToSourceColumn(r),new s.default(o,r)}},{key:"getTrForRow",value:function(e){return this.TBODY.childNodes[this.rowFilter.sourceToRendered(e)]}},{key:"getFirstRenderedRow",value:function(){return this.wot.wtViewport.rowsRenderCalculator.startRow}},{key:"getFirstVisibleRow",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.startRow}},{key:"getFirstRenderedColumn",value:function(){return this.wot.wtViewport.columnsRenderCalculator.startColumn}},{key:"getFirstVisibleColumn",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.startColumn}},{key:"getLastRenderedRow",value:function(){return this.wot.wtViewport.rowsRenderCalculator.endRow}},{key:"getLastVisibleRow",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.endRow}},{key:"getLastRenderedColumn",value:function(){return this.wot.wtViewport.columnsRenderCalculator.endColumn}},{key:"getLastVisibleColumn",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.endColumn}},{key:"isRowBeforeRenderedRows",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)<0&&e>=0}},{key:"isRowAfterViewport",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastVisibleRow()}},{key:"isRowAfterRenderedRows",value:function(e){return this.rowFilter&&this.rowFilter.sourceToRendered(e)>this.getLastRenderedRow()}},{key:"isColumnBeforeViewport",value:function(e){return this.columnFilter&&this.columnFilter.sourceToRendered(e)<0&&e>=0}},{key:"isColumnAfterViewport",value:function(e){return this.columnFilter&&this.columnFilter.sourceToRendered(e)>this.getLastVisibleColumn()}},{key:"isLastRowFullyVisible",value:function(){return this.getLastVisibleRow()===this.getLastRenderedRow()}},{key:"isLastColumnFullyVisible",value:function(){return this.getLastVisibleColumn()===this.getLastRenderedColumn()}},{key:"getRenderedColumnsCount",value:function(){var e=this.wot.wtViewport.columnsRenderCalculator.count,t=this.wot.getSetting("totalColumns");if(this.wot.isOverlayName(d.default.CLONE_DEBUG))e=t;else if(this.wot.isOverlayName(d.default.CLONE_LEFT)||this.wot.isOverlayName(d.default.CLONE_TOP_LEFT_CORNER)||this.wot.isOverlayName(d.default.CLONE_BOTTOM_LEFT_CORNER))return Math.min(this.wot.getSetting("fixedColumnsLeft"),t);return e}},{key:"getRenderedRowsCount",value:function(){var e=this.wot.wtViewport.rowsRenderCalculator.count,t=this.wot.getSetting("totalRows");return this.wot.isOverlayName(d.default.CLONE_DEBUG)?e=t:this.wot.isOverlayName(d.default.CLONE_TOP)||this.wot.isOverlayName(d.default.CLONE_TOP_LEFT_CORNER)?e=Math.min(this.wot.getSetting("fixedRowsTop"),t):(this.wot.isOverlayName(d.default.CLONE_BOTTOM)||this.wot.isOverlayName(d.default.CLONE_BOTTOM_LEFT_CORNER))&&(e=Math.min(this.wot.getSetting("fixedRowsBottom"),t)),e}},{key:"getVisibleRowsCount",value:function(){return this.wot.wtViewport.rowsVisibleCalculator.count}},{key:"allRowsInViewport",value:function(){return this.wot.getSetting("totalRows")==this.getVisibleRowsCount()}},{key:"getRowHeight",value:function(e){var t=this.wot.wtSettings.settings.rowHeight(e),n=this.wot.wtViewport.oversizedRows[e];return void 0!==n&&(t=void 0===t?n:Math.max(t,n)),t}},{key:"getColumnHeaderHeight",value:function(e){var t=this.wot.wtSettings.settings.defaultRowHeight,n=this.wot.wtViewport.oversizedColumnHeaders[e];return void 0!==n&&(t=t?Math.max(t,n):n),t}},{key:"getVisibleColumnsCount",value:function(){return this.wot.wtViewport.columnsVisibleCalculator.count}},{key:"allColumnsInViewport",value:function(){return this.wot.getSetting("totalColumns")==this.getVisibleColumnsCount()}},{key:"getColumnWidth",value:function(e){var t=this.wot.wtSettings.settings.columnWidth;return"function"==typeof t?t=t(e):"object"===(void 0===t?"undefined":o(t))&&(t=t[e]),t||this.wot.wtSettings.settings.defaultColumnWidth}},{key:"getStretchedColumnWidth",value:function(e){var t=this.getColumnWidth(e),n=null==t?this.instance.wtSettings.settings.defaultColumnWidth:t,o=this.wot.wtViewport.columnsRenderCalculator;if(o){var r=o.getStretchedColumnWidth(e,n);r&&(n=r)}return n}},{key:"_modifyRowHeaderWidth",value:function(e){var t=(0,a.isFunction)(e)?e():null;return Array.isArray(t)?(t=[].concat(function(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}(t)))[t.length-1]=this._correctRowHeaderWidth(t[t.length-1]):t=this._correctRowHeaderWidth(t),t}},{key:"_correctRowHeaderWidth",value:function(e){return"number"!=typeof e&&(e=this.wot.getSetting("defaultColumnWidth")),this.correctHeaderWidth&&e++,e}}]),e}();t.default=f},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=n(28),s=(o=a)&&o.__esModule?o:{default:o},l=!1,u=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.wtTable=t,this.wot=t.instance,this.instance=t.instance,this.rowFilter=t.rowFilter,this.columnFilter=t.columnFilter,this.TABLE=t.TABLE,this.THEAD=t.THEAD,this.TBODY=t.TBODY,this.COLGROUP=t.COLGROUP,this.rowHeaders=[],this.rowHeaderCount=0,this.columnHeaders=[],this.columnHeaderCount=0,this.fixedRowsTop=0,this.fixedRowsBottom=0}return r(e,[{key:"render",value:function(){if(!this.wtTable.isWorkingOnClone()){var e={};if(this.wot.getSetting("beforeDraw",!0,e),!0===e.skipRender)return}this.rowHeaders=this.wot.getSetting("rowHeaders"),this.rowHeaderCount=this.rowHeaders.length,this.fixedRowsTop=this.wot.getSetting("fixedRowsTop"),this.fixedRowsBottom=this.wot.getSetting("fixedRowsBottom"),this.columnHeaders=this.wot.getSetting("columnHeaders"),this.columnHeaderCount=this.columnHeaders.length;var t=this.wtTable.getRenderedColumnsCount(),n=this.wtTable.getRenderedRowsCount(),o=this.wot.getSetting("totalColumns"),r=this.wot.getSetting("totalRows"),a=void 0,l=!1;if((s.default.isOverlayTypeOf(this.wot.cloneOverlay,s.default.CLONE_BOTTOM)||s.default.isOverlayTypeOf(this.wot.cloneOverlay,s.default.CLONE_BOTTOM_LEFT_CORNER))&&(this.columnHeaders=[],this.columnHeaderCount=0),o>=0&&(this.adjustAvailableNodes(),l=!0,this.renderColumnHeaders(),this.renderRows(r,n,t),this.wtTable.isWorkingOnClone()||(a=this.wot.wtViewport.getWorkspaceWidth(),this.wot.wtViewport.containerWidth=null),this.adjustColumnWidths(t),this.markOversizedColumnHeaders(),this.adjustColumnHeaderHeights()),l||this.adjustAvailableNodes(),this.removeRedundantRows(n),this.wtTable.isWorkingOnClone()&&!this.wot.isOverlayName(s.default.CLONE_BOTTOM)||this.markOversizedRows(),this.wtTable.isWorkingOnClone())this.wot.isOverlayName(s.default.CLONE_BOTTOM)&&this.wot.cloneSource.wtOverlays.adjustElementsSize();else{this.wot.wtViewport.createVisibleCalculators(),this.wot.wtOverlays.refresh(!1),this.wot.wtOverlays.applyToDOM();var u=(0,i.outerWidth)(this.wtTable.hider),c=(0,i.outerWidth)(this.wtTable.TABLE);if(0!==u&&c!==u&&this.adjustColumnWidths(t),a!==this.wot.wtViewport.getWorkspaceWidth()){this.wot.wtViewport.containerWidth=null;var d=this.wtTable.getFirstRenderedColumn(),h=this.wtTable.getLastRenderedColumn(),f=this.wot.getSetting("defaultColumnWidth"),p=this.wot.getSetting("rowHeaderWidth");if(null!=(p=this.instance.getSetting("onModifyRowHeaderWidth",p)))for(var m=0;m<this.rowHeaderCount;m++){var g=Array.isArray(p)?p[m]:p;g=null==g?f:g,this.COLGROUP.childNodes[m].style.width=g+"px"}for(var v=d;v<h;v++){var y=this.wtTable.getStretchedColumnWidth(v),_=this.columnFilter.sourceToRendered(v);this.COLGROUP.childNodes[_+this.rowHeaderCount].style.width=y+"px"}}this.wot.getSetting("onDraw",!0)}}},{key:"removeRedundantRows",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}},{key:"renderRows",value:function(e,t,n){for(var o=void 0,r=0,i=this.rowFilter.renderedToSource(r),a=this.wtTable.isWorkingOnClone();i<e&&i>=0&&(!l&&r>1e3&&(l=!0,console.warn('Performance tip: Handsontable rendered more than 1000 visible rows. Consider limiting the number of rendered rows by specifying the table height and/or turning off the "renderAllRows" option.')),void 0===t||r!==t);){if(o=this.getOrCreateTrForRow(r,o),this.renderRowHeaders(i,o),this.adjustColumns(o,n+this.rowHeaderCount),this.renderCells(i,o,n),a&&!this.wot.isOverlayName(s.default.CLONE_BOTTOM)||this.resetOversizedRow(i),o.firstChild){var u=this.wot.wtTable.getRowHeight(i);u?(u--,o.firstChild.style.height=u+"px"):o.firstChild.style.height=""}r++,i=this.rowFilter.renderedToSource(r)}}},{key:"resetOversizedRow",value:function(e){this.wot.getSetting("externalRowCalculator")||this.wot.wtViewport.oversizedRows&&this.wot.wtViewport.oversizedRows[e]&&(this.wot.wtViewport.oversizedRows[e]=void 0)}},{key:"markOversizedRows",value:function(){if(!this.wot.getSetting("externalRowCalculator")){var e=this.instance.wtTable.TBODY.childNodes.length,t=e*this.instance.wtSettings.settings.defaultRowHeight,n=(0,i.innerHeight)(this.instance.wtTable.TBODY)-1,o=void 0,r=void 0,a=void 0,s=void 0,l=void 0;if(this.instance.getSetting("totalRows"),t!==n||this.instance.getSetting("fixedRowsBottom"))for(;e;)e--,a=this.instance.wtTable.rowFilter.renderedToSource(e),o=this.instance.wtTable.getRowHeight(a),r=(l=(s=this.instance.wtTable.getTrForRow(a)).querySelector("th"))?(0,i.innerHeight)(l):(0,i.innerHeight)(s)-1,(!o&&this.instance.wtSettings.settings.defaultRowHeight<r||o<r)&&(this.instance.wtViewport.oversizedRows[a]=++r)}}},{key:"markOversizedColumnHeaders",value:function(){var e=this.wot.getOverlayName();if(this.columnHeaderCount&&!this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]&&!this.wtTable.isWorkingOnClone()){for(var t=this.wtTable.getRenderedColumnsCount(),n=0;n<this.columnHeaderCount;n++)for(var o=-1*this.rowHeaderCount;o<t;o++)this.markIfOversizedColumnHeader(o);this.wot.wtViewport.hasOversizedColumnHeadersMarked[e]=!0}}},{key:"adjustColumnHeaderHeights",value:function(){for(var e=this.wot.getSetting("columnHeaders"),t=this.wot.wtTable.THEAD.childNodes,n=this.wot.wtViewport.oversizedColumnHeaders,o=0,r=e.length;o<r;o++)if(n[o]){if(!t[o]||0===t[o].childNodes.length)return;t[o].childNodes[0].style.height=n[o]+"px"}}},{key:"markIfOversizedColumnHeader",value:function(e){for(var t=this.wot.wtTable.columnFilter.renderedToSource(e),n=this.columnHeaderCount,o=this.wot.wtSettings.settings.defaultRowHeight,r=void 0,a=void 0,s=void 0,l=this.wot.getSetting("columnHeaderHeight")||[];n;)n--,r=this.wot.wtTable.getColumnHeaderHeight(n),(a=this.wot.wtTable.getColumnHeader(t,n))&&(s=(0,i.innerHeight)(a),(!r&&o<s||r<s)&&(this.wot.wtViewport.oversizedColumnHeaders[n]=s),Array.isArray(l)?null!=l[n]&&(this.wot.wtViewport.oversizedColumnHeaders[n]=l[n]):isNaN(l)||(this.wot.wtViewport.oversizedColumnHeaders[n]=l),this.wot.wtViewport.oversizedColumnHeaders[n]<(l[n]||l)&&(this.wot.wtViewport.oversizedColumnHeaders[n]=l[n]||l))}},{key:"renderCells",value:function(e,t,n){for(var o=void 0,r=void 0,a=0;a<n;a++)r=this.columnFilter.renderedToSource(a),"TH"==(o=0===a?t.childNodes[this.columnFilter.sourceColumnToVisibleRowHeadedColumn(r)]:o.nextSibling).nodeName&&(o=d(o,t)),(0,i.hasClass)(o,"hide")||(o.className=""),o.removeAttribute("style"),this.wot.wtSettings.settings.cellRenderer(e,r,o);return o}},{key:"adjustColumnWidths",value:function(e){var t=0,n=(this.wot.cloneSource?this.wot.cloneSource:this.wot).wtTable.holder,o=this.wot.getSetting("defaultColumnWidth"),r=this.wot.getSetting("rowHeaderWidth");if(n.offsetHeight<n.scrollHeight&&(t=(0,i.getScrollbarWidth)()),this.wot.wtViewport.columnsRenderCalculator.refreshStretching(this.wot.wtViewport.getViewportWidth()-t),null!=(r=this.instance.getSetting("onModifyRowHeaderWidth",r)))for(var a=0;a<this.rowHeaderCount;a++){var s=Array.isArray(r)?r[a]:r;s=null==s?o:s,this.COLGROUP.childNodes[a].style.width=s+"px"}for(var l=0;l<e;l++){var u=this.wtTable.getStretchedColumnWidth(this.columnFilter.renderedToSource(l));this.COLGROUP.childNodes[l+this.rowHeaderCount].style.width=u+"px"}}},{key:"appendToTbody",value:function(e){this.TBODY.appendChild(e),this.wtTable.tbodyChildrenLength++}},{key:"getOrCreateTrForRow",value:function(e,t){var n=void 0;return e>=this.wtTable.tbodyChildrenLength?(n=this.createRow(),this.appendToTbody(n)):n=0===e?this.TBODY.firstChild:t.nextSibling,n.className&&n.removeAttribute("class"),n}},{key:"createRow",value:function(){for(var e=document.createElement("TR"),t=0;t<this.rowHeaderCount;t++)e.appendChild(document.createElement("TH"));return e}},{key:"renderRowHeader",value:function(e,t,n){n.className="",n.removeAttribute("style"),this.rowHeaders[t](e,n,t)}},{key:"renderRowHeaders",value:function(e,t){for(var n=t.firstChild,o=0;o<this.rowHeaderCount;o++)n?"TD"==n.nodeName&&(n=c(n,t)):(n=document.createElement("TH"),t.appendChild(n)),this.renderRowHeader(e,o,n),n=n.nextSibling}},{key:"adjustAvailableNodes",value:function(){this.adjustColGroups(),this.adjustThead()}},{key:"renderColumnHeaders",value:function(){if(this.columnHeaderCount)for(var e=this.wtTable.getRenderedColumnsCount(),t=0;t<this.columnHeaderCount;t++)for(var n=this.getTrForColumnHeaders(t),o=-1*this.rowHeaderCount;o<e;o++){var r=this.columnFilter.renderedToSource(o);this.renderColumnHeader(t,r,n.childNodes[o+this.rowHeaderCount])}}},{key:"adjustColGroups",value:function(){for(var e=this.wtTable.getRenderedColumnsCount();this.wtTable.colgroupChildrenLength<e+this.rowHeaderCount;)this.COLGROUP.appendChild(document.createElement("COL")),this.wtTable.colgroupChildrenLength++;for(;this.wtTable.colgroupChildrenLength>e+this.rowHeaderCount;)this.COLGROUP.removeChild(this.COLGROUP.lastChild),this.wtTable.colgroupChildrenLength--;this.rowHeaderCount&&(0,i.addClass)(this.COLGROUP.childNodes[0],"rowHeader")}},{key:"adjustThead",value:function(){var e=this.wtTable.getRenderedColumnsCount(),t=this.THEAD.firstChild;if(this.columnHeaders.length){for(var n=0,o=this.columnHeaders.length;n<o;n++){for((t=this.THEAD.childNodes[n])||(t=document.createElement("TR"),this.THEAD.appendChild(t)),this.theadChildrenLength=t.childNodes.length;this.theadChildrenLength<e+this.rowHeaderCount;)t.appendChild(document.createElement("TH")),this.theadChildrenLength++;for(;this.theadChildrenLength>e+this.rowHeaderCount;)t.removeChild(t.lastChild),this.theadChildrenLength--}var r=this.THEAD.childNodes.length;if(r>this.columnHeaders.length)for(var a=this.columnHeaders.length;a<r;a++)this.THEAD.removeChild(this.THEAD.lastChild)}else t&&(0,i.empty)(t)}},{key:"getTrForColumnHeaders",value:function(e){return this.THEAD.childNodes[e]}},{key:"renderColumnHeader",value:function(e,t,n){return n.className="",n.removeAttribute("style"),this.columnHeaders[e](t,n,e)}},{key:"adjustColumns",value:function(e,t){for(var n=e.childNodes.length;n<t;){var o=document.createElement("TD");e.appendChild(o),n++}for(;n>t;)e.removeChild(e.lastChild),n--}},{key:"removeRedundantColumns",value:function(e){for(;this.wtTable.tbodyChildrenLength>e;)this.TBODY.removeChild(this.TBODY.lastChild),this.wtTable.tbodyChildrenLength--}}]),e}();function c(e,t){var n=document.createElement("TH");return t.insertBefore(n,e),t.removeChild(e),n}function d(e,t){var n=document.createElement("TD");return t.insertBefore(n,e),t.removeChild(e),n}t.default=u},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(2),a=u(n(4)),s=u(n(135)),l=u(n(136));function u(e){return e&&e.__esModule?e:{default:e}}var c=function(){function e(t){var n=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.wot=t,this.instance=this.wot,this.oversizedRows=[],this.oversizedColumnHeaders=[],this.hasOversizedColumnHeadersMarked={},this.clientHeight=0,this.containerWidth=NaN,this.rowHeaderWidth=NaN,this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,this.eventManager=new a.default(this.wot),this.eventManager.addEventListener(window,"resize",function(){n.clientHeight=n.getWorkspaceHeight()})}return o(e,[{key:"getWorkspaceHeight",value:function(){var e=this.instance.wtOverlays.topOverlay.trimmingContainer;return e===window?document.documentElement.clientHeight:(0,r.outerHeight)(e)>0&&e.clientHeight>0?e.clientHeight:1/0}},{key:"getWorkspaceWidth",value:function(){var e=void 0,t=this.wot.getSetting("totalColumns"),n=this.instance.wtOverlays.leftOverlay.trimmingContainer,o=void 0,i=this.wot.getSetting("stretchH"),a=document.documentElement.offsetWidth;return this.wot.getSetting("preventOverflow")?(0,r.outerWidth)(this.instance.wtTable.wtRootElement):(e=this.wot.getSetting("freezeOverlays")?Math.min(a-this.getWorkspaceOffset().left,a):Math.min(this.getContainerFillWidth(),a-this.getWorkspaceOffset().left,a),n===window&&t>0&&this.sumColumnWidths(0,t-1)>e?document.documentElement.clientWidth:n===window||"scroll"!=(o=(0,r.getStyle)(this.instance.wtOverlays.leftOverlay.trimmingContainer,"overflow"))&&"hidden"!=o&&"auto"!=o?"none"!==i&&i?e:Math.max(e,(0,r.outerWidth)(this.instance.wtTable.TABLE)):Math.max(e,n.clientWidth))}},{key:"hasVerticalScroll",value:function(){return this.getWorkspaceActualHeight()>this.getWorkspaceHeight()}},{key:"hasHorizontalScroll",value:function(){return this.getWorkspaceActualWidth()>this.getWorkspaceWidth()}},{key:"sumColumnWidths",value:function(e,t){for(var n=0;e<t;)n+=this.wot.wtTable.getColumnWidth(e),e++;return n}},{key:"getContainerFillWidth",value:function(){if(this.containerWidth)return this.containerWidth;var e,t=this.instance.wtTable.holder,n=void 0;return(n=document.createElement("div")).style.width="100%",n.style.height="1px",t.appendChild(n),e=n.offsetWidth,this.containerWidth=e,t.removeChild(n),e}},{key:"getWorkspaceOffset",value:function(){return(0,r.offset)(this.wot.wtTable.TABLE)}},{key:"getWorkspaceActualHeight",value:function(){return(0,r.outerHeight)(this.wot.wtTable.TABLE)}},{key:"getWorkspaceActualWidth",value:function(){return(0,r.outerWidth)(this.wot.wtTable.TABLE)||(0,r.outerWidth)(this.wot.wtTable.TBODY)||(0,r.outerWidth)(this.wot.wtTable.THEAD)}},{key:"getColumnHeaderHeight",value:function(){return isNaN(this.columnHeaderHeight)&&(this.columnHeaderHeight=(0,r.outerHeight)(this.wot.wtTable.THEAD)),this.columnHeaderHeight}},{key:"getViewportHeight",value:function(){var e,t=this.getWorkspaceHeight();return t===1/0?t:((e=this.getColumnHeaderHeight())>0&&(t-=e),t)}},{key:"getRowHeaderWidth",value:function(){var e=this.instance.getSetting("rowHeaderWidth"),t=this.instance.getSetting("rowHeaders");if(e){this.rowHeaderWidth=0;for(var n=0,o=t.length;n<o;n++)this.rowHeaderWidth+=e[n]||e}if(this.wot.cloneSource)return this.wot.cloneSource.wtViewport.getRowHeaderWidth();if(isNaN(this.rowHeaderWidth))if(t.length){var i=this.instance.wtTable.TABLE.querySelector("TH");this.rowHeaderWidth=0;for(var a=0,s=t.length;a<s;a++)i?(this.rowHeaderWidth+=(0,r.outerWidth)(i),i=i.nextSibling):this.rowHeaderWidth+=50}else this.rowHeaderWidth=0;return this.rowHeaderWidth=this.instance.getSetting("onModifyRowHeaderWidth",this.rowHeaderWidth)||this.rowHeaderWidth,this.rowHeaderWidth}},{key:"getViewportWidth",value:function(){var e,t=this.getWorkspaceWidth();return t===1/0?t:(e=this.getRowHeaderWidth())>0?t-e:t}},{key:"createRowsCalculator",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=void 0,o=void 0,i=void 0,a=void 0,s=void 0,u=void 0,c=void 0;return this.rowHeaderWidth=NaN,n=this.wot.wtSettings.settings.renderAllRows?1/0:this.getViewportHeight(),(o=this.wot.wtOverlays.topOverlay.getScrollPosition()-this.wot.wtOverlays.topOverlay.getTableParentOffset())<0&&(o=0),i=this.wot.getSetting("fixedRowsTop"),s=this.wot.getSetting("fixedRowsBottom"),c=this.wot.getSetting("totalRows"),i&&(o+=u=this.wot.wtOverlays.topOverlay.sumCellSizes(0,i),n-=u),s&&this.wot.wtOverlays.bottomOverlay.clone&&(n-=u=this.wot.wtOverlays.bottomOverlay.sumCellSizes(c-s,c)),a=this.wot.wtTable.holder.clientHeight===this.wot.wtTable.holder.offsetHeight?0:(0,r.getScrollbarWidth)(),new l.default(n,o,this.wot.getSetting("totalRows"),function(t){return e.wot.wtTable.getRowHeight(t)},t?null:this.wot.wtSettings.settings.viewportRowCalculatorOverride,t,a)}},{key:"createColumnsCalculator",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=this.getViewportWidth(),o=void 0,i=void 0;if(this.columnHeaderHeight=NaN,(o=this.wot.wtOverlays.leftOverlay.getScrollPosition()-this.wot.wtOverlays.leftOverlay.getTableParentOffset())<0&&(o=0),i=this.wot.getSetting("fixedColumnsLeft")){var a=this.wot.wtOverlays.leftOverlay.sumCellSizes(0,i);o+=a,n-=a}return this.wot.wtTable.holder.clientWidth!==this.wot.wtTable.holder.offsetWidth&&(n-=(0,r.getScrollbarWidth)()),new s.default(n,o,this.wot.getSetting("totalColumns"),function(t){return e.wot.wtTable.getColumnWidth(t)},t?null:this.wot.wtSettings.settings.viewportColumnCalculatorOverride,t,this.wot.getSetting("stretchH"),function(t,n){return e.wot.getSetting("onBeforeStretchingColumnWidth",t,n)})}},{key:"createRenderCalculators",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e){var t=this.createRowsCalculator(!0),n=this.createColumnsCalculator(!0);this.areAllProposedVisibleRowsAlreadyRendered(t)&&this.areAllProposedVisibleColumnsAlreadyRendered(n)||(e=!1)}return e||(this.rowsRenderCalculator=this.createRowsCalculator(),this.columnsRenderCalculator=this.createColumnsCalculator()),this.rowsVisibleCalculator=null,this.columnsVisibleCalculator=null,e}},{key:"createVisibleCalculators",value:function(){this.rowsVisibleCalculator=this.createRowsCalculator(!0),this.columnsVisibleCalculator=this.createColumnsCalculator(!0)}},{key:"areAllProposedVisibleRowsAlreadyRendered",value:function(e){return!(!this.rowsVisibleCalculator||e.startRow<this.rowsRenderCalculator.startRow||e.startRow===this.rowsRenderCalculator.startRow&&e.startRow>0||e.endRow>this.rowsRenderCalculator.endRow||e.endRow===this.rowsRenderCalculator.endRow&&e.endRow<this.wot.getSetting("totalRows")-1)}},{key:"areAllProposedVisibleColumnsAlreadyRendered",value:function(e){return!(!this.columnsVisibleCalculator||e.startColumn<this.columnsRenderCalculator.startColumn||e.startColumn===this.columnsRenderCalculator.startColumn&&e.startColumn>0||e.endColumn>this.columnsRenderCalculator.endColumn||e.endColumn===this.columnsRenderCalculator.endColumn&&e.endColumn<this.wot.getSetting("totalColumns")-1)}},{key:"resetHasOversizedColumnHeadersMarked",value:function(){(0,i.objectEach)(this.hasOversizedColumnHeadersMarked,function(e,t,n){n[t]=void 0})}}]),e}();t.default=c},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(16),i=n(20),a=n(27),s=n(1),l=n(0),u=n(148),c=(o=u)&&o.__esModule?o:{default:o},d=c.default.prototype.extend();d.prototype.init=function(){c.default.prototype.init.apply(this,arguments),this.query=null,this.strippedChoices=[],this.rawChoices=[]},d.prototype.getValue=function(){var e=this,t=this.rawChoices.find(function(t){return e.stripValueIfNeeded(t)===e.TEXTAREA.value});return(0,i.isDefined)(t)?t:this.TEXTAREA.value},d.prototype.createElements=function(){c.default.prototype.createElements.apply(this,arguments),(0,l.addClass)(this.htContainer,"autocompleteEditor"),(0,l.addClass)(this.htContainer,-1===window.navigator.platform.indexOf("Mac")?"":"htMacScroll")};var h=!1;function f(e){h=!1;var t=this.getActiveEditor();if((0,r.isPrintableChar)(e.keyCode)||e.keyCode===r.KEY_CODES.BACKSPACE||e.keyCode===r.KEY_CODES.DELETE||e.keyCode===r.KEY_CODES.INSERT){var n=0;if(e.keyCode===r.KEY_CODES.C&&(e.ctrlKey||e.metaKey))return;t.isOpened()||(n+=10),t.htEditor&&t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value),h=!0},n))}}d.prototype.prepare=function(){this.instance.addHook("beforeKeyDown",f),c.default.prototype.prepare.apply(this,arguments)},d.prototype.open=function(){this.TEXTAREA_PARENT.style.overflow="auto",c.default.prototype.open.apply(this,arguments),this.TEXTAREA_PARENT.style.overflow="";var e=this.htEditor.getInstance(),t=this,n=void 0===this.cellProperties.trimDropdown||this.cellProperties.trimDropdown;this.TEXTAREA.style.visibility="visible",this.focus(),e.updateSettings({colWidths:n?[(0,l.outerWidth)(this.TEXTAREA)-2]:void 0,width:n?(0,l.outerWidth)(this.TEXTAREA)+(0,l.getScrollbarWidth)()+2:void 0,afterRenderer:function(e,n,o,r,a,s){var l=t.cellProperties,u=l.filteringCaseSensitive,c=l.allowHtml,d=void 0,h=void 0;(a=(0,i.stringify)(a))&&!c&&-1!==(d=!0===u?a.indexOf(this.query):a.toLowerCase().indexOf(t.query.toLowerCase()))&&(h=a.substr(d,t.query.length),a=a.replace(h,"<strong>"+h+"</strong>")),e.innerHTML=a},autoColumnSize:!0,modifyColWidth:function(e,t){var o=this.getPlugin("autoColumnSize").widths;return o[t]&&(e=o[t]),n?e:e+15}}),this.htEditor.view.wt.wtTable.holder.parentNode.style["padding-right"]=(0,l.getScrollbarWidth)()+2+"px",h&&(h=!1),t.instance._registerTimeout(setTimeout(function(){t.queryChoices(t.TEXTAREA.value)},0))},d.prototype.close=function(){c.default.prototype.close.apply(this,arguments)},d.prototype.queryChoices=function(e){var t=this;this.query=e;var n=this.cellProperties.source;"function"==typeof n?n.call(this.cellProperties,e,function(e){t.rawChoices=e,t.updateChoicesList(t.stripValuesIfNeeded(e))}):Array.isArray(n)?(this.rawChoices=n,this.updateChoicesList(this.stripValuesIfNeeded(n))):this.updateChoicesList([])},d.prototype.updateChoicesList=function(e){var t=(0,l.getCaretPosition)(this.TEXTAREA),n=(0,l.getSelectionEndPosition)(this.TEXTAREA),o=this.cellProperties.sortByRelevance,r=this.cellProperties.filter,i=null,a=null;o&&(i=d.sortByRelevance(this.stripValueIfNeeded(this.getValue()),e,this.cellProperties.filteringCaseSensitive));var u=Array.isArray(i)?i.length:0;if(!1===r)u&&(a=i[0]);else{for(var c=[],h=0,f=e.length;h<f&&!(o&&u<=h);h++)u?c.push(e[i[h]]):c.push(e[h]);a=0,e=c}this.strippedChoices=e,this.htEditor.loadData((0,s.pivot)([e])),this.updateDropdownHeight(),this.flipDropdownIfNeeded(),!0===this.cellProperties.strict&&this.highlightBestMatchingChoice(a),this.instance.listen(),this.TEXTAREA.focus(),(0,l.setCaretPosition)(this.TEXTAREA,t,t===n?void 0:n)},d.prototype.flipDropdownIfNeeded=function(){var e=(0,l.offset)(this.TEXTAREA),t=(0,l.outerHeight)(this.TEXTAREA),n=this.getDropdownHeight(),o=(0,l.getTrimmingContainer)(this.instance.view.wt.wtTable.TABLE),r=o.scrollTop,i=(0,l.outerHeight)(this.instance.view.wt.wtTable.THEAD),a={row:0,col:0};o!==window&&(a=(0,l.offset)(o));var s=e.top-a.top-i+r,u=o.scrollHeight-s-i-t,c=n>u&&s>u;return c?this.flipDropdown(n):this.unflipDropdown(),this.limitDropdownIfNeeded(c?s:u,n),c},d.prototype.limitDropdownIfNeeded=function(e,t){if(t>e){var n,o=0,r=0,i=0;do{o+=i=this.htEditor.getRowHeight(r)||this.htEditor.view.wt.wtSettings.settings.defaultRowHeight,r++}while(o<e);n=o-i,this.htEditor.flipped&&(this.htEditor.rootElement.style.top=parseInt(this.htEditor.rootElement.style.top,10)+t-n+"px"),this.setDropdownHeight(o-i)}},d.prototype.flipDropdown=function(e){var t=this.htEditor.rootElement.style;t.position="absolute",t.top=-e+"px",this.htEditor.flipped=!0},d.prototype.unflipDropdown=function(){var e=this.htEditor.rootElement.style;"absolute"===e.position&&(e.position="",e.top=""),this.htEditor.flipped=void 0},d.prototype.updateDropdownHeight=function(){var e=this.htEditor.getColWidth(0)+(0,l.getScrollbarWidth)()+2,t=this.cellProperties.trimDropdown;this.htEditor.updateSettings({height:this.getDropdownHeight(),width:t?void 0:e}),this.htEditor.view.wt.wtTable.alignOverlaysWithTrimmingContainer()},d.prototype.setDropdownHeight=function(e){this.htEditor.updateSettings({height:e})},d.prototype.finishEditing=function(e){e||this.instance.removeHook("beforeKeyDown",f),c.default.prototype.finishEditing.apply(this,arguments)},d.prototype.highlightBestMatchingChoice=function(e){"number"==typeof e?this.htEditor.selectCell(e,0):this.htEditor.deselectCell()},d.sortByRelevance=function(e,t,n){var o=[],r=void 0,s=e.length,l=void 0,u=void 0,c=[],d=void 0,h=t.length;if(0===s){for(d=0;d<h;d++)c.push(d);return c}for(d=0;d<h;d++)r=(0,a.stripTags)((0,i.stringify)(t[d])),-1!==(l=n?r.indexOf(e):r.toLowerCase().indexOf(e.toLowerCase()))&&(u=r.length-l-s,o.push({baseIndex:d,index:l,charsLeft:u,value:r}));for(o.sort(function(e,t){if(-1===t.index)return-1;if(-1===e.index)return 1;if(e.index<t.index)return-1;if(t.index<e.index)return 1;if(e.index===t.index){if(e.charsLeft<t.charsLeft)return-1;if(e.charsLeft>t.charsLeft)return 1}return 0}),d=0,h=o.length;d<h;d++)c.push(o[d].baseIndex);return c},d.prototype.getDropdownHeight=function(){var e=this.htEditor.getInstance().getRowHeight(0)||23,t=this.cellProperties.visibleRows;return this.strippedChoices.length>=t?t*e:this.strippedChoices.length*e+8},d.prototype.stripValueIfNeeded=function(e){return this.stripValuesIfNeeded([e])[0]},d.prototype.stripValuesIfNeeded=function(e){var t=this.cellProperties.allowHtml,n=(0,s.arrayMap)(e,function(e){return(0,i.stringify)(e)});return(0,s.arrayMap)(n,function(e){return t?e:(0,a.stripTags)(e)})},d.prototype.allowKeyEventPropagation=function(e){var t=this.htEditor.getSelectedRange()?this.htEditor.getSelectedRange().from.row:-1,n=!1;return e===r.KEY_CODES.ARROW_DOWN&&t>0&&t<this.htEditor.countRows()-1&&(n=!0),e===r.KEY_CODES.ARROW_UP&&t>-1&&(n=!0),n},d.prototype.discardEditor=function(e){c.default.prototype.discardEditor.apply(this,arguments),this.instance.view.render()},t.default=d},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(16),i=n(2),a=n(0),s=n(7),l=n(43),u=(o=l)&&o.__esModule?o:{default:o},c=u.default.prototype.extend();c.prototype.createElements=function(){u.default.prototype.createElements.apply(this,arguments);var e=document.createElement("DIV");e.className="handsontableEditor",this.TEXTAREA_PARENT.appendChild(e),this.htContainer=e,this.assignHooks()},c.prototype.prepare=function(e,t,n,o,r,a){u.default.prototype.prepare.apply(this,arguments);var s=this,l={startRows:0,startCols:0,minRows:0,minCols:0,className:"listbox",copyPaste:!1,autoColumnSize:!1,autoRowSize:!1,readOnly:!0,fillHandle:!1,afterOnCellMouseDown:function(e,t){var n=this.getSourceData(t.row,t.col);void 0!==n&&s.setValue(n),s.instance.destroyEditor()}};this.cellProperties.handsontable&&(0,i.extend)(l,a.handsontable),this.htOptions=l};var d=function(e){if(!(0,s.isImmediatePropagationStopped)(e)){var t,n,o=this.getActiveEditor(),i=o.htEditor.getInstance();if(e.keyCode==r.KEY_CODES.ARROW_DOWN)if(i.getSelected()||i.flipped){if(i.getSelected())if(i.flipped)t=i.getSelected()[0]+1;else if(!i.flipped){n=i.getSelected()[0];var a=i.countRows()-1;t=Math.min(a,n+1)}}else t=0;else e.keyCode==r.KEY_CODES.ARROW_UP&&(!i.getSelected()&&i.flipped?t=i.countRows()-1:i.getSelected()&&(i.flipped?(n=i.getSelected()[0],t=Math.max(0,n-1)):t=(n=i.getSelected()[0])-1));void 0!==t&&(t<0||i.flipped&&t>i.countRows()-1?i.deselectCell():i.selectCell(t,0),i.getData().length&&(e.preventDefault(),(0,s.stopImmediatePropagation)(e),o.instance.listen(),o.TEXTAREA.focus()))}};c.prototype.open=function(){this.instance.addHook("beforeKeyDown",d),u.default.prototype.open.apply(this,arguments),this.htEditor&&this.htEditor.destroy(),this.htEditor=new Handsontable(this.htContainer,this.htOptions),this.cellProperties.strict?(this.htEditor.selectCell(0,0),this.TEXTAREA.style.visibility="hidden"):(this.htEditor.deselectCell(),this.TEXTAREA.style.visibility="visible"),(0,a.setCaretPosition)(this.TEXTAREA,0,this.TEXTAREA.value.length)},c.prototype.close=function(){this.instance.removeHook("beforeKeyDown",d),this.instance.listen(),u.default.prototype.close.apply(this,arguments)},c.prototype.focus=function(){this.instance.listen(),u.default.prototype.focus.apply(this,arguments)},c.prototype.beginEditing=function(e){var t=this.instance.getSettings().onBeginEditing;t&&!1===t()||u.default.prototype.beginEditing.apply(this,arguments)},c.prototype.finishEditing=function(e,t){if(this.htEditor&&this.htEditor.isListening()&&this.instance.listen(),this.htEditor&&this.htEditor.getSelected()){var n=this.htEditor.getInstance().getValue();void 0!==n&&this.setValue(n)}return u.default.prototype.finishEditing.apply(this,arguments)},c.prototype.assignHooks=function(){var e=this;this.instance.addHook("afterDestroy",function(){e.htEditor&&e.htEditor.destroy()})},t.default=c},function(e,t,n){"use strict";t.__esModule=!0;var o=n(1),r=n(2),i=n(6),a={_arrayMap:[],getValueByIndex:function(e){var t;return void 0===(t=this._arrayMap[e])?null:t},getIndexByValue:function(e){var t;return-1===(t=this._arrayMap.indexOf(e))?null:t},insertItems:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=(0,o.arrayMax)(this._arrayMap)+1,a=[];return(0,i.rangeEach)(n-1,function(n){a.push(t._arrayMap.splice(e+n,0,r+n))}),a},removeItems:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=[];if(Array.isArray(e)){var i=[].concat(this._arrayMap);e.sort(function(e,t){return t-e}),r=(0,o.arrayReduce)(e,function(e,n){return t._arrayMap.splice(n,1),e.concat(i.slice(n,n+1))},[])}else r=this._arrayMap.splice(e,n);return r},unshiftItems:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=this.removeItems(e,t);function r(e){return(0,o.arrayReduce)(n,function(t,n){return e>n&&t++,t},0)}this._arrayMap=(0,o.arrayMap)(this._arrayMap,function(e,t){var n=r(e);return n&&(e-=n),e})},shiftItems:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;this._arrayMap=(0,o.arrayMap)(this._arrayMap,function(t){return t>=e&&(t+=n),t}),(0,i.rangeEach)(n-1,function(n){t._arrayMap.splice(e+n,0,e+n)})},clearMap:function(){this._arrayMap.length=0}};(0,r.defineGetter)(a,"MIXIN_NAME","arrayMapper",{writable:!1,enumerable:!1}),t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o=n(1),r=n(2),i={_localHooks:Object.create(null),addLocalHook:function(e,t){this._localHooks[e]||(this._localHooks[e]=[]),this._localHooks[e].push(t)},runLocalHooks:function(e){for(var t=this,n=arguments.length,r=Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];this._localHooks[e]&&(0,o.arrayEach)(this._localHooks[e],function(e){return e.apply(t,r)})},clearLocalHooks:function(){this._localHooks={}}};(0,r.defineGetter)(i,"MIXIN_NAME","localHooks",{writable:!1,enumerable:!1}),t.default=i},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(6),i=0,a=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this._element=null,this.state=i}return o(e,[{key:"appendTo",value:function(e){e.appendChild(this._element),this.state=2}},{key:"build",value:function(){this._element=document.createElement("div"),this.state=1}},{key:"destroy",value:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=i}},{key:"isAppended",value:function(){return 2===this.state}},{key:"isBuilt",value:function(){return this.state>=1}},{key:"setPosition",value:function(e,t){(0,r.isNumeric)(e)&&(this._element.style.top=e+"px"),(0,r.isNumeric)(t)&&(this._element.style.left=t+"px")}},{key:"getPosition",value:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}}},{key:"setSize",value:function(e,t){(0,r.isNumeric)(e)&&(this._element.style.width=e+"px"),(0,r.isNumeric)(t)&&(this._element.style.height=t+"px")}},{key:"getSize",value:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}}},{key:"setOffset",value:function(e,t){(0,r.isNumeric)(e)&&(this._element.style.marginTop=e+"px"),(0,r.isNumeric)(t)&&(this._element.style.marginLeft=t+"px")}},{key:"getOffset",value:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}}]),e}();t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=0,i=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this._element=null,this.state=r}return o(e,[{key:"appendTo",value:function(e){e.appendChild(this._element),this.state=2}},{key:"build",value:function(){this._element=document.createElement("div"),this.state=1}},{key:"destroy",value:function(){this.isAppended()&&this._element.parentElement.removeChild(this._element),this._element=null,this.state=r}},{key:"isAppended",value:function(){return 2===this.state}},{key:"isBuilt",value:function(){return this.state>=1}},{key:"setPosition",value:function(e,t){e&&(this._element.style.top=e+"px"),t&&(this._element.style.left=t+"px")}},{key:"getPosition",value:function(){return{top:this._element.style.top?parseInt(this._element.style.top,10):0,left:this._element.style.left?parseInt(this._element.style.left,10):0}}},{key:"setSize",value:function(e,t){e&&(this._element.style.width=e+"px"),t&&(this._element.style.height=t+"px")}},{key:"getSize",value:function(){return{width:this._element.style.width?parseInt(this._element.style.width,10):0,height:this._element.style.height?parseInt(this._element.style.height,10):0}}},{key:"setOffset",value:function(e,t){e&&(this._element.style.marginTop=e+"px"),t&&(this._element.style.marginLeft=t+"px")}},{key:"getOffset",value:function(){return{top:this._element.style.marginTop?parseInt(this._element.style.marginTop,10):0,left:this._element.style.marginLeft?parseInt(this._element.style.marginLeft,10):0}}}]),e}();t.default=i},function(e,t,n){"use strict";t.__esModule=!0,t.RecordTranslator=void 0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.registerIdentity=function(e,t){u.set(e,t)},t.getTranslator=function(e){var t=void 0;if(!(e instanceof a.default)){if(!u.has(e))throw Error("Record translator was not registered for this object identity");e=u.get(e)}return c.has(e)?t=c.get(e):(t=new l(e),c.set(e,t)),t};var r,i=n(64),a=(r=i)&&r.__esModule?r:{default:r},s=n(2),l=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t}return o(e,[{key:"toVisualRow",value:function(e){return this.hot.runHooks("unmodifyRow",e)}},{key:"toVisualColumn",value:function(e){return this.hot.runHooks("unmodifyCol",e)}},{key:"toVisual",value:function(e,t){return(0,s.isObject)(e)?{row:this.toVisualRow(e.row),column:this.toVisualColumn(e.column)}:[this.toVisualRow(e),this.toVisualColumn(t)]}},{key:"toPhysicalRow",value:function(e){return this.hot.runHooks("modifyRow",e)}},{key:"toPhysicalColumn",value:function(e){return this.hot.runHooks("modifyCol",e)}},{key:"toPhysical",value:function(e,t){return(0,s.isObject)(e)?{row:this.toPhysicalRow(e.row),column:this.toPhysicalColumn(e.column)}:[this.toPhysicalRow(e),this.toPhysicalColumn(t)]}}]),e}();t.RecordTranslator=l;var u=new WeakMap,c=new WeakMap},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(2),i=n(6),a=n(20),s=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.samples=null,this.dataFactory=t,this.customSampleCount=null,this.allowDuplicates=!1}return o(e,null,[{key:"SAMPLE_COUNT",get:function(){return 3}}]),o(e,[{key:"getSampleCount",value:function(){return this.customSampleCount?this.customSampleCount:e.SAMPLE_COUNT}},{key:"setSampleCount",value:function(e){this.customSampleCount=e}},{key:"setAllowDuplicates",value:function(e){this.allowDuplicates=e}},{key:"generateRowSamples",value:function(e,t){return this.generateSamples("row",t,e)}},{key:"generateColumnSamples",value:function(e,t){return this.generateSamples("col",t,e)}},{key:"generateSamples",value:function(e,t,n){var o=this,r=new Map;return"number"==typeof n&&(n={from:n,to:n}),(0,i.rangeEach)(n.from,n.to,function(n){var i=o.generateSample(e,t,n);r.set(n,i)}),r}},{key:"generateSample",value:function(e,t,n){var o=this,s=new Map,l=[],u=void 0;return(0,i.rangeEach)(t.from,t.to,function(t){var i=void 0;if("row"===e)i=o.dataFactory(n,t);else{if("col"!==e)throw new Error("Unsupported sample type");i=o.dataFactory(t,n)}u=(0,r.isObject)(i)?Object.keys(i).length:Array.isArray(i)?i.length:(0,a.stringify)(i).length,s.has(u)||s.set(u,{needed:o.getSampleCount(),strings:[]});var c=s.get(u);if(c.needed&&(!(l.indexOf(i)>-1)||o.allowDuplicates)){var d="row"===e?"col":"row";c.strings.push(function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({value:i},d,t)),l.push(i),c.needed--}}),s}}]),e}();t.default=s},function(e,t,n){var o=n(23),r=n(24),i=n(60);e.exports=function(e){return function(t,n,a){var s,l=o(t),u=r(l.length),c=i(a,u);if(e&&n!=n){for(;u>c;)if((s=l[c++])!=s)return!0}else for(;u>c;c++)if((e||c in l)&&l[c]===n)return e||c||0;return!e&&-1}}},function(e,t,n){var o=n(38),r=n(10)("toStringTag"),i="Arguments"==o(function(){return arguments}());e.exports=function(e){var t,n,a;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(n=function(e,t){try{return e[t]}catch(e){}}(t=Object(e),r))?n:i?o(t):"Object"==(a=o(t))&&"function"==typeof t.callee?"Arguments":a}},function(e,t,n){"use strict";var o=n(19).f,r=n(78),i=n(59),a=n(29),s=n(52),l=n(30),u=n(56),c=n(166),d=n(167),h=n(172),f=n(21),p=n(46).fastKey,m=f?"_s":"size",g=function(e,t){var n,o=p(t);if("F"!==o)return e._i[o];for(n=e._f;n;n=n.n)if(n.k==t)return n};e.exports={getConstructor:function(e,t,n,c){var d=e(function(e,o){s(e,d,t,"_i"),e._i=r(null),e._f=void 0,e._l=void 0,e[m]=0,null!=o&&u(o,n,e[c],e)});return i(d.prototype,{clear:function(){for(var e=this._i,t=this._f;t;t=t.n)t.r=!0,t.p&&(t.p=t.p.n=void 0),delete e[t.i];this._f=this._l=void 0,this[m]=0},delete:function(e){var t=g(this,e);if(t){var n=t.n,o=t.p;delete this._i[t.i],t.r=!0,o&&(o.n=n),n&&(n.p=o),this._f==t&&(this._f=n),this._l==t&&(this._l=o),this[m]--}return!!t},forEach:function(e){s(this,d,"forEach");for(var t,n=a(e,arguments.length>1?arguments[1]:void 0,3);t=t?t.n:this._f;)for(n(t.v,t.k,this);t&&t.r;)t=t.p},has:function(e){return!!g(this,e)}}),f&&o(d.prototype,"size",{get:function(){return l(this[m])}}),d},def:function(e,t,n){var o,r,i=g(e,t);return i?i.v=n:(e._l=i={i:r=p(t,!0),k:t,v:n,p:o=e._l,n:void 0,r:!1},e._f||(e._f=i),o&&(o.n=i),e[m]++,"F"!==r&&(e._i[r]=i)),e},getEntry:g,setStrong:function(e,t,n){c(e,t,function(e,t){this._t=e,this._k=t,this._l=void 0},function(){for(var e=this._k,t=this._l;t&&t.r;)t=t.p;return this._t&&(this._l=t=t?t.n:this._t._f)?d(0,"keys"==e?t.k:"values"==e?t.v:[t.k,t.v]):(this._t=void 0,d(1))},n?"entries":"values",!n,!0),h(t)}}},function(e,t,n){"use strict";var o=n(59),r=n(46).getWeak,i=n(18),a=n(15),s=n(52),l=n(56),u=n(53),c=n(22),d=u(5),h=u(6),f=0,p=function(e){return e._l||(e._l=new m)},m=function(){this.a=[]},g=function(e,t){return d(e.a,function(e){return e[0]===t})};m.prototype={get:function(e){var t=g(this,e);if(t)return t[1]},has:function(e){return!!g(this,e)},set:function(e,t){var n=g(this,e);n?n[1]=t:this.a.push([e,t])},delete:function(e){var t=h(this.a,function(t){return t[0]===e});return~t&&this.a.splice(t,1),!!~t}},e.exports={getConstructor:function(e,t,n,i){var u=e(function(e,o){s(e,u,t,"_i"),e._i=f++,e._l=void 0,null!=o&&l(o,n,e[i],e)});return o(u.prototype,{delete:function(e){if(!a(e))return!1;var t=r(e);return!0===t?p(this).delete(e):t&&c(t,this._i)&&delete t[this._i]},has:function(e){if(!a(e))return!1;var t=r(e);return!0===t?p(this).has(e):t&&c(t,this._i)}}),u},def:function(e,t,n){var o=r(i(t),!0);return!0===o?p(e).set(t,n):o[e._i]=n,e},ufstore:p}},function(e,t,n){e.exports=n(13).document&&document.documentElement},function(e,t,n){e.exports=!n(21)&&!n(31)(function(){return 7!=Object.defineProperty(n(73)("div"),"a",{get:function(){return 7}}).a})},function(e,t,n){var o=n(45),r=n(10)("iterator"),i=Array.prototype;e.exports=function(e){return void 0!==e&&(o.Array===e||i[r]===e)}},function(e,t,n){var o=n(38);e.exports=Array.isArray||function(e){return"Array"==o(e)}},function(e,t,n){var o=n(15),r=Math.floor;e.exports=function(e){return!o(e)&&isFinite(e)&&r(e)===e}},function(e,t,n){var o=n(15),r=n(38),i=n(10)("match");e.exports=function(e){var t;return o(e)&&(void 0!==(t=e[i])?!!t:"RegExp"==r(e))}},function(e,t,n){var o=n(18);e.exports=function(e,t,n,r){try{return r?t(o(n)[0],n[1]):t(n)}catch(t){var i=e.return;throw void 0!==i&&o(i.call(e)),t}}},function(e,t,n){"use strict";var o=n(57),r=n(3),i=n(33),a=n(32),s=n(22),l=n(45),u=n(283),c=n(48),d=n(288),h=n(10)("iterator"),f=!([].keys&&"next"in[].keys()),p=function(){return this};e.exports=function(e,t,n,m,g,v,y){u(n,t,m);var _,w,b,C=function(e){if(!f&&e in T)return T[e];switch(e){case"keys":case"values":return function(){return new n(this,e)}}return function(){return new n(this,e)}},M=t+" Iterator",k="values"==g,S=!1,T=e.prototype,L=T[h]||T["@@iterator"]||g&&T[g],x=L||C(g),D=g?k?C("entries"):x:void 0,O="Array"==t&&T.entries||L;if(O&&(b=d(O.call(new e)))!==Object.prototype&&(c(b,M,!0),o||s(b,h)||a(b,h,p)),k&&L&&"values"!==L.name&&(S=!0,x=function(){return L.call(this)}),o&&!y||!f&&!S&&T[h]||a(T,h,x),l[t]=x,l[M]=p,g)if(_={values:k?x:C("values"),keys:v?x:C("keys"),entries:D},y)for(w in _)w in T||i(T,w,_[w]);else r(r.P+r.F*(f||S),t,_);return _}},function(e,t){e.exports=function(e,t){return{value:t,done:!!e}}},function(e,t,n){"use strict";var o=n(39),r=n(58),i=n(47),a=n(41),s=n(76),l=Object.assign;e.exports=!l||n(31)(function(){var e={},t={},n=Symbol(),o="abcdefghijklmnopqrst";return e[n]=7,o.split("").forEach(function(e){t[e]=e}),7!=l({},e)[n]||Object.keys(l({},t)).join("")!=o})?function(e,t){for(var n=a(e),l=arguments.length,u=1,c=r.f,d=i.f;l>u;)for(var h,f=s(arguments[u++]),p=c?o(f).concat(c(f)):o(f),m=p.length,g=0;m>g;)d.call(f,h=p[g++])&&(n[h]=f[h]);return n}:l},function(e,t,n){var o=n(22),r=n(23),i=n(155)(!1),a=n(81)("IE_PROTO");e.exports=function(e,t){var n,s=r(e),l=0,u=[];for(n in s)n!=a&&o(s,n)&&u.push(n);for(;t.length>l;)o(s,n=t[l++])&&(~i(u,n)||u.push(n));return u}},function(e,t,n){var o=n(39),r=n(23),i=n(47).f;e.exports=function(e){return function(t){for(var n,a=r(t),s=o(a),l=s.length,u=0,c=[];l>u;)i.call(a,n=s[u++])&&c.push(e?[n,a[n]]:a[n]);return c}}},function(e,t,n){var o=n(15),r=n(18),i=function(e,t){if(r(e),!o(t)&&null!==t)throw TypeError(t+": can't set as prototype!")};e.exports={set:Object.setPrototypeOf||("__proto__"in{}?function(e,t,o){try{(o=n(29)(Function.call,n(79).f(Object.prototype,"__proto__").set,2))(e,[]),t=!(e instanceof Array)}catch(e){t=!0}return function(e,n){return i(e,n),t?e.__proto__=n:o(e,n),e}}({},!1):void 0),check:i}},function(e,t,n){"use strict";var o=n(13),r=n(19),i=n(21),a=n(10)("species");e.exports=function(e){var t=o[e];i&&t&&!t[a]&&r.f(t,a,{configurable:!0,get:function(){return this}})}},function(e,t,n){var o=n(24),r=n(174),i=n(30);e.exports=function(e,t,n,a){var s=String(i(e)),l=s.length,u=void 0===n?" ":String(n),c=o(t);if(c<=l||""==u)return s;var d=c-l,h=r.call(u,Math.ceil(d/u.length));return h.length>d&&(h=h.slice(0,d)),a?h+s:s+h}},function(e,t,n){"use strict";var o=n(61),r=n(30);e.exports=function(e){var t=String(r(this)),n="",i=o(e);if(i<0||i==1/0)throw RangeError("Count can't be negative");for(;i>0;(i>>>=1)&&(t+=t))1&i&&(n+=t);return n}},function(e,t,n){t.f=n(10)},function(e,t,n){var o=n(156),r=n(10)("iterator"),i=n(45);e.exports=n(44).getIteratorMethod=function(e){if(null!=e)return e[r]||e["@@iterator"]||i[o(e)]}},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){var t="undefined"!=typeof window&&window.jQuery;t&&(t.fn.handsontable=function(t){var n=this.first(),o=n.data("handsontable");if("string"!=typeof t){var r=t||{};return o?o.updateSettings(r):(o=new e.Core(n[0],r),n.data("handsontable",o),o.init()),n}var i=[],a=void 0;if(arguments.length>1)for(var s=1,l=arguments.length;s<l;s++)i.push(arguments[s]);if(o){if(void 0===o[t])throw new Error("Handsontable do not provide action: "+t);a=o[t].apply(o,i),"destroy"===t&&n.removeData()}return a})}},function(e,t,n){"use strict";t.__esModule=!0,t.Base=t.UndoRedo=t.TouchScroll=t.Search=t.PersistentState=t.ObserveChanges=t.MultipleSelectionHandles=t.MergeCells=t.ManualRowResize=t.ManualRowMove=t.ManualColumnResize=t.ManualColumnMove=t.ManualColumnFreeze=t.DragToScroll=t.CustomBorders=t.CopyPaste=t.ContextMenuCopyPaste=t.ContextMenu=t.Comments=t.ColumnSorting=t.AutoRowSize=t.AutoFill=t.AutoColumnSize=void 0;var o=T(n(211)),r=T(n(213)),i=T(n(212)),a=T(n(215)),s=T(n(217)),l=T(n(219)),u=T(n(234)),c=T(n(235)),d=T(n(236)),h=T(n(237)),f=T(n(240)),p=T(n(242)),m=T(n(245)),g=T(n(246)),v=T(n(250)),y=T(n(251)),_=T(n(252)),w=T(n(254)),b=T(n(256)),C=T(n(257)),M=T(n(258)),k=T(n(259)),S=T(n(12));function T(e){return e&&e.__esModule?e:{default:e}}t.AutoColumnSize=o.default,t.AutoFill=r.default,t.AutoRowSize=i.default,t.ColumnSorting=a.default,t.Comments=s.default,t.ContextMenu=l.default,t.ContextMenuCopyPaste=u.default,t.CopyPaste=c.default,t.CustomBorders=d.default,t.DragToScroll=h.default,t.ManualColumnFreeze=f.default,t.ManualColumnMove=p.default,t.ManualColumnResize=m.default,t.ManualRowMove=g.default,t.ManualRowResize=v.default,t.MergeCells=y.default,t.MultipleSelectionHandles=_.default,t.ObserveChanges=w.default,t.PersistentState=b.default,t.Search=C.default,t.TouchScroll=M.default,t.UndoRedo=k.default,t.Base=S.default},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t,n){"use strict";e.exports=function(){var e,t={minHeight:200,maxHeight:300,minWidth:100,maxWidth:300},n=document.body,o=document.createTextNode(""),r=document.createElement("SPAN"),i=function(e,t,n){window.attachEvent?e.attachEvent("on"+t,n):e.addEventListener(t,n,!1)},a=function(e,t,n){window.removeEventListener?e.removeEventListener(t,n,!1):e.detachEvent("on"+t,n)},s=function(i){var a,s;i?/^[a-zA-Z \.,\\\/\|0-9]$/.test(i)||(i="."):i="",void 0!==o.textContent?o.textContent=e.value+i:o.data=e.value+i,r.style.fontSize=c(e).fontSize,r.style.fontFamily=c(e).fontFamily,r.style.whiteSpace="pre",n.appendChild(r),a=r.clientWidth+2,n.removeChild(r),e.style.height=t.minHeight+"px",t.minWidth>a?e.style.width=t.minWidth+"px":a>t.maxWidth?e.style.width=t.maxWidth+"px":e.style.width=a+"px",s=e.scrollHeight?e.scrollHeight-1:0,t.minHeight>s?e.style.height=t.minHeight+"px":t.maxHeight<s?(e.style.height=t.maxHeight+"px",e.style.overflowY="visible"):e.style.height=s+"px"},l=function(){window.setTimeout(s,0)},u=function(n,a,u){e=n,function(n){if(n&&n.minHeight)if("inherit"==n.minHeight)t.minHeight=e.clientHeight;else{var i=parseInt(n.minHeight);isNaN(i)||(t.minHeight=i)}if(n&&n.maxHeight)if("inherit"==n.maxHeight)t.maxHeight=e.clientHeight;else{var a=parseInt(n.maxHeight);isNaN(a)||(t.maxHeight=a)}if(n&&n.minWidth)if("inherit"==n.minWidth)t.minWidth=e.clientWidth;else{var s=parseInt(n.minWidth);isNaN(s)||(t.minWidth=s)}if(n&&n.maxWidth)if("inherit"==n.maxWidth)t.maxWidth=e.clientWidth;else{var l=parseInt(n.maxWidth);isNaN(l)||(t.maxWidth=l)}r.firstChild||(r.className="autoResize",r.style.display="inline-block",r.appendChild(o))}(a),"TEXTAREA"==e.nodeName&&(e.style.resize="none",e.style.overflowY="",e.style.height=t.minHeight+"px",e.style.minWidth=t.minWidth+"px",e.style.maxWidth=t.maxWidth+"px",e.style.overflowY="hidden"),u&&(i(e,"change",s),i(e,"cut",l),i(e,"paste",l),i(e,"drop",l),i(e,"keydown",l),i(e,"focus",s)),s()};function c(e){return e.currentStyle||document.defaultView.getComputedStyle(e)}return{init:function(e,t,n){u(e,t,n)},unObserve:function(){a(e,"change",s),a(e,"cut",l),a(e,"paste",l),a(e,"drop",l),a(e,"keydown",l),a(e,"focus",s)},resize:s}}},function(e,t,n){"use strict";var o;function r(){this.refCounter=0,this.init()}e.exports=function(){return o?o.hasBeenDestroyed()&&o.init():o=new r,o.refCounter++,o},r.prototype.init=function(){var e,t;this.copyCallbacks=[],this.cutCallbacks=[],this.pasteCallbacks=[],t=document.body,document.getElementById("CopyPasteDiv")?(this.elDiv=document.getElementById("CopyPasteDiv"),this.elTextarea=this.elDiv.firstChild):(this.elDiv=document.createElement("div"),this.elDiv.id="CopyPasteDiv",(e=this.elDiv.style).position="fixed",e.top="-10000px",e.left="-10000px",t.appendChild(this.elDiv),this.elTextarea=document.createElement("textarea"),this.elTextarea.className="copyPaste",this.elTextarea.onpaste=function(e){var t,n;"WebkitAppearance"in document.documentElement.style&&(t=e.clipboardData.getData("Text"),-1!==navigator.userAgent.indexOf("Safari")&&-1===navigator.userAgent.indexOf("Chrome")&&(""===(n=t.split("\n"))[n.length-1]&&n.pop(),t=n.join("\n")),this.value=t,e.preventDefault())},(e=this.elTextarea.style).width="10000px",e.height="10000px",e.overflow="hidden",this.elDiv.appendChild(this.elTextarea),void 0!==e.opacity&&(e.opacity=0)),this.onKeyDownRef=this.onKeyDown.bind(this),document.documentElement.addEventListener("keydown",this.onKeyDownRef,!1)},r.prototype.onKeyDown=function(e){var t,n=this,o=!1;if(e.metaKey?o=!0:e.ctrlKey&&-1===navigator.userAgent.indexOf("Mac")&&(o=!0),o){if(document.activeElement!==this.elTextarea&&(""!==this.getSelectionText()||((t=document.activeElement).shadowRoot&&t.shadowRoot.activeElement&&(t=t.shadowRoot.activeElement),["INPUT","SELECT","TEXTAREA"].indexOf(t.nodeName)>-1||"true"===t.contentEditable)))return;this.selectNodeText(this.elTextarea),setTimeout(function(){document.activeElement!==n.elTextarea&&n.selectNodeText(n.elTextarea)},0)}!1===e.isImmediatePropagationEnabled||!o||67!==e.keyCode&&86!==e.keyCode&&88!==e.keyCode||(88===e.keyCode?setTimeout(function(){n.triggerCut(e)},0):86===e.keyCode&&setTimeout(function(){n.triggerPaste(e)},0))},r.prototype.selectNodeText=function(e){e&&e.select()},r.prototype.getSelectionText=function(){var e="";return window.getSelection?e=window.getSelection().toString():document.selection&&"Control"!==document.selection.type&&(e=document.selection.createRange().text),e},r.prototype.copyable=function(e){if("string"!=typeof e&&void 0===e.toString)throw new Error("copyable requires string parameter");this.elTextarea.value=e,this.selectNodeText(this.elTextarea)},r.prototype.onCut=function(e){this.cutCallbacks.push(e)},r.prototype.onPaste=function(e){this.pasteCallbacks.push(e)},r.prototype.removeCallback=function(e){var t,n;for(t=0,n=this.copyCallbacks.length;t<n;t++)if(this.copyCallbacks[t]===e)return this.copyCallbacks.splice(t,1),!0;for(t=0,n=this.cutCallbacks.length;t<n;t++)if(this.cutCallbacks[t]===e)return this.cutCallbacks.splice(t,1),!0;for(t=0,n=this.pasteCallbacks.length;t<n;t++)if(this.pasteCallbacks[t]===e)return this.pasteCallbacks.splice(t,1),!0;return!1},r.prototype.triggerCut=function(e){var t=this;t.cutCallbacks&&setTimeout(function(){for(var n=0,o=t.cutCallbacks.length;n<o;n++)t.cutCallbacks[n](e)},50)},r.prototype.triggerPaste=function(e,t){var n=this;n.pasteCallbacks&&setTimeout(function(){for(var o=t||n.elTextarea.value,r=0,i=n.pasteCallbacks.length;r<i;r++)n.pasteCallbacks[r](o,e)},50)},r.prototype.destroy=function(){this.hasBeenDestroyed()||0!=--this.refCounter||(this.elDiv&&this.elDiv.parentNode&&(this.elDiv.parentNode.removeChild(this.elDiv),this.elDiv=null,this.elTextarea=null),document.documentElement.removeEventListener("keydown",this.onKeyDownRef),this.onKeyDownRef=null)},r.prototype.hasBeenDestroyed=function(){return!this.refCounter}},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(0),i=n(28),a=(o=i)&&o.__esModule?o:{default:o},s=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(a.default.CLONE_DEBUG),n.clone.wtTable.holder.style.opacity=.4,n.clone.wtTable.holder.style.textShadow="0 0 2px #ff0000",(0,r.addClass)(n.clone.wtTable.holder.parentNode,"wtDebugVisible"),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),t}();a.default.registerOverlay(a.default.CLONE_DEBUG,s),t.default=s},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=n(28),s=(o=a)&&o.__esModule?o:{default:o},l=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(s.default.CLONE_LEFT),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,s.default),r(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||n&&"horizontal"===n)t=this.getScrollPosition(),(0,i.resetCssTransform)(e);else{var o=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(o.left),a=Math.ceil(o.right),s=void 0,l=void 0;l=""===(l=this.wot.wtTable.hider.style.top)?0:l,t=s=r<0&&a-e.offsetWidth>0?-r:0,s+="px",(0,i.setOverlayPosition)(e,s,l)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo(e,(0,i.getWindowScrollTop)()):this.mainTableScrollableElement.scrollLeft=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollVertically")}},{key:"sumCellSizes",value:function(e,t){for(var n=0,o=this.wot.wtSettings.defaultColumnWidth;e<t;)n+=this.wot.wtTable.getStretchedColumnWidth(e)||o,e++;return n}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))}},{key:"adjustRootElementSize",value:function(){var e,t=this.wot.wtTable.holder,n=t.clientHeight===t.offsetHeight?0:(0,i.getScrollbarWidth)(),o=this.clone.wtTable.holder.parentNode.style,r=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||"vertical"===r){var a=this.wot.wtViewport.getWorkspaceHeight()-n;a=Math.min(a,(0,i.innerHeight)(this.wot.wtTable.wtRootElement)),o.height=a+"px"}else o.height="";this.clone.wtTable.holder.style.height=o.height,e=(0,i.outerWidth)(this.clone.wtTable.TABLE),o.width=(0===e?e:e+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,i.getScrollbarWidth)();this.clone.wtTable.hider.style.height=this.hider.style.height,this.clone.wtTable.holder.style.height=this.clone.wtTable.holder.parentNode.style.height,0===e&&(e=30),this.clone.wtTable.holder.style.width=parseInt(this.clone.wtTable.holder.parentNode.style.width,10)+e+"px"}},{key:"applyToDOM",value:function(){var e=this.wot.getSetting("totalColumns");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition)this.spreader.style.left=this.wot.wtViewport.columnsRenderCalculator.startPosition+"px";else{if(0!==e)throw new Error("Incorrect value of the columnsRenderCalculator");this.spreader.style.left="0"}this.spreader.style.right="",this.needFullRender&&this.syncOverlayOffset()}},{key:"syncOverlayOffset",value:function(){"number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition?this.clone.wtTable.spreader.style.top=this.wot.wtViewport.rowsRenderCalculator.startPosition+"px":this.clone.wtTable.spreader.style.top=""}},{key:"scrollTo",value:function(e,t){var n=this.getTableParentOffset(),o=(this.wot.cloneSource?this.wot.cloneSource:this.wot).wtTable.holder,r=0;t&&o.offsetWidth!==o.clientWidth&&(r=(0,i.getScrollbarWidth)()),t?(n+=this.sumCellSizes(0,e+1),n-=this.wot.wtViewport.getViewportWidth()):n+=this.sumCellSizes(this.wot.getSetting("fixedColumnsLeft"),e),n+=r,this.setScrollPosition(n)}},{key:"getTableParentOffset",value:function(){var e=0;return this.wot.getSetting("preventOverflow")||this.trimmingContainer!==window||(e=this.wot.wtTable.holderOffset.left),e}},{key:"getScrollPosition",value:function(){return(0,i.getScrollLeft)(this.mainTableScrollableElement)}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode,n=this.wot.getSetting("rowHeaders"),o=this.wot.getSetting("fixedColumnsLeft");if(this.wot.getSetting("totalRows")?(0,i.removeClass)(t,"emptyRows"):(0,i.addClass)(t,"emptyRows"),o&&!n.length)(0,i.addClass)(t,"innerBorderLeft");else if(!o&&n.length){var r=(0,i.hasClass)(t,"innerBorderLeft");e?(0,i.addClass)(t,"innerBorderLeft"):(0,i.removeClass)(t,"innerBorderLeft"),(!r&&e||r&&!e)&&this.wot.wtOverlays.adjustElementsSize()}}}]),t}();s.default.registerOverlay(s.default.CLONE_LEFT,l),t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=n(28),s=(o=a)&&o.__esModule?o:{default:o},l=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(s.default.CLONE_TOP),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,s.default),r(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.needFullRender&&this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=0,n=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||n&&"vertical"===n)t=this.getScrollPosition(),(0,i.resetCssTransform)(e);else{var o=this.wot.wtTable.hider.getBoundingClientRect(),r=Math.ceil(o.top),a=Math.ceil(o.bottom),s=void 0,l=void 0;s=""===(s=this.wot.wtTable.hider.style.left)?0:s,t=l=r<0&&a-e.offsetHeight>0?-r:0,l+="px",(0,i.setOverlayPosition)(e,s,l)}this.adjustHeaderBordersPosition(t),this.adjustElementsSize()}}},{key:"setScrollPosition",value:function(e){this.mainTableScrollableElement===window?window.scrollTo((0,i.getWindowScrollLeft)(),e):this.mainTableScrollableElement.scrollTop=e}},{key:"onScroll",value:function(){this.wot.getSetting("onScrollHorizontally")}},{key:"sumCellSizes",value:function(e,t){for(var n=0,o=this.wot.wtSettings.settings.defaultRowHeight;e<t;){var r=this.wot.wtTable.getRowHeight(e);n+=void 0===r?o:r,e++}return n}},{key:"adjustElementsSize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.updateTrimmingContainer(),(this.needFullRender||e)&&(this.adjustRootElementSize(),this.adjustRootChildrenSize(),e||(this.areElementSizesAdjusted=!0))}},{key:"adjustRootElementSize",value:function(){var e,t=this.wot.wtTable.holder,n=t.clientWidth===t.offsetWidth?0:(0,i.getScrollbarWidth)(),o=this.clone.wtTable.holder.parentNode.style,r=this.wot.getSetting("preventOverflow");if(this.trimmingContainer!==window||"horizontal"===r){var a=this.wot.wtViewport.getWorkspaceWidth()-n;a=Math.min(a,(0,i.innerWidth)(this.wot.wtTable.wtRootElement)),o.width=a+"px"}else o.width="";this.clone.wtTable.holder.style.width=o.width,e=(0,i.outerHeight)(this.clone.wtTable.TABLE),o.height=(0===e?e:e+4)+"px"}},{key:"adjustRootChildrenSize",value:function(){var e=(0,i.getScrollbarWidth)();this.clone.wtTable.hider.style.width=this.hider.style.width,this.clone.wtTable.holder.style.width=this.clone.wtTable.holder.parentNode.style.width,0===e&&(e=30),this.clone.wtTable.holder.style.height=parseInt(this.clone.wtTable.holder.parentNode.style.height,10)+e+"px"}},{key:"applyToDOM",value:function(){var e=this.wot.getSetting("totalRows");if(this.areElementSizesAdjusted||this.adjustElementsSize(),"number"==typeof this.wot.wtViewport.rowsRenderCalculator.startPosition)this.spreader.style.top=this.wot.wtViewport.rowsRenderCalculator.startPosition+"px";else{if(0!==e)throw new Error("Incorrect value of the rowsRenderCalculator");this.spreader.style.top="0"}this.spreader.style.bottom="",this.needFullRender&&this.syncOverlayOffset()}},{key:"syncOverlayOffset",value:function(){"number"==typeof this.wot.wtViewport.columnsRenderCalculator.startPosition?this.clone.wtTable.spreader.style.left=this.wot.wtViewport.columnsRenderCalculator.startPosition+"px":this.clone.wtTable.spreader.style.left=""}},{key:"scrollTo",value:function(e,t){var n=this.getTableParentOffset(),o=(this.wot.cloneSource?this.wot.cloneSource:this.wot).wtTable.holder,r=0;if(t&&o.offsetHeight!==o.clientHeight&&(r=(0,i.getScrollbarWidth)()),t){var a=this.wot.getSetting("fixedRowsBottom"),s=(this.wot.getSetting("fixedRowsTop"),this.wot.getSetting("totalRows"));n+=this.sumCellSizes(0,e+1),n-=this.wot.wtViewport.getViewportHeight()-this.sumCellSizes(s-a,s),n+=1}else n+=this.sumCellSizes(this.wot.getSetting("fixedRowsTop"),e);n+=r,this.setScrollPosition(n)}},{key:"getTableParentOffset",value:function(){return this.mainTableScrollableElement===window?this.wot.wtTable.holderOffset.top:0}},{key:"getScrollPosition",value:function(){return(0,i.getScrollTop)(this.mainTableScrollableElement)}},{key:"redrawSelectionBorders",value:function(e){if(e&&e.cellRange){var t=e.getBorder(this.wot);if(t){var n=e.getCorners();t.disappear(),t.appear(n)}}}},{key:"redrawAllSelectionsBorders",value:function(){var e=this.wot.selections;this.redrawSelectionBorders(e.current),this.redrawSelectionBorders(e.area),this.redrawSelectionBorders(e.fill),this.wot.wtTable.wot.wtOverlays.leftOverlay.refresh()}},{key:"adjustHeaderBordersPosition",value:function(e){var t=this.wot.wtTable.holder.parentNode;if(this.wot.getSetting("totalColumns")?(0,i.removeClass)(t,"emptyColumns"):(0,i.addClass)(t,"emptyColumns"),0===this.wot.getSetting("fixedRowsTop")&&this.wot.getSetting("columnHeaders").length>0){var n=(0,i.hasClass)(t,"innerBorderTop");e||0===this.wot.getSetting("totalRows")?(0,i.addClass)(t,"innerBorderTop"):(0,i.removeClass)(t,"innerBorderTop"),(!n&&e||n&&!e)&&(this.wot.wtOverlays.adjustElementsSize(),this.redrawAllSelectionsBorders())}if(0===this.wot.getSetting("rowHeaders").length){var o=this.clone.wtTable.THEAD.querySelectorAll("th:nth-of-type(2)");if(o)for(var r=0;r<o.length;r++)o[r].style["border-left-width"]=0}}}]),t}();s.default.registerOverlay(s.default.CLONE_TOP,l),t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=n(28),s=(o=a)&&o.__esModule?o:{default:o},l=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.clone=n.makeClone(s.default.CLONE_TOP_LEFT_CORNER),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,s.default),r(t,[{key:"shouldBeRendered",value:function(){return!(!this.wot.getSetting("fixedRowsTop")&&!this.wot.getSetting("columnHeaders").length||!this.wot.getSetting("fixedColumnsLeft")&&!this.wot.getSetting("rowHeaders").length)}},{key:"resetFixedPosition",value:function(){if(this.updateTrimmingContainer(),this.wot.wtTable.holder.parentNode){var e=this.clone.wtTable.holder.parentNode,t=(0,i.outerHeight)(this.clone.wtTable.TABLE),n=(0,i.outerWidth)(this.clone.wtTable.TABLE),o=this.wot.getSetting("preventOverflow");if(this.trimmingContainer===window){var r=this.wot.wtTable.hider.getBoundingClientRect(),a=Math.ceil(r.top),s=Math.ceil(r.left),l=Math.ceil(r.bottom),u=Math.ceil(r.right),c="0",d="0";o&&"vertical"!==o||s<0&&u-e.offsetWidth>0&&(c=-s+"px"),o&&"horizontal"!==o||a<0&&l-e.offsetHeight>0&&(d=-a+"px"),(0,i.setOverlayPosition)(e,c,d)}else(0,i.resetCssTransform)(e);e.style.height=(0===t?t:t+4)+"px",e.style.width=(0===n?n:n+4)+"px"}}}]),t}();s.default.registerOverlay(s.default.CLONE_TOP_LEFT_CORNER,l),t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=u(n(134)),s=u(n(42)),l=u(n(69));function u(e){return e&&e.__esModule?e:{default:e}}var c=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.settings=t,this.cellRange=n||null,this.instanceBorders={}}return r(e,[{key:"getBorder",value:function(e){if(this.instanceBorders[e.guid])return this.instanceBorders[e.guid];this.instanceBorders[e.guid]=new a.default(e,this.settings)}},{key:"isEmpty",value:function(){return null===this.cellRange}},{key:"add",value:function(e){this.isEmpty()?this.cellRange=new l.default(e,e,e):this.cellRange.expand(e)}},{key:"replace",value:function(e,t){if(!this.isEmpty()){if(this.cellRange.from.isEqual(e))return this.cellRange.from=t,!0;if(this.cellRange.to.isEqual(e))return this.cellRange.to=t,!0}return!1}},{key:"clear",value:function(){this.cellRange=null}},{key:"getCorners",value:function(){var e=this.cellRange.getTopLeftCorner(),t=this.cellRange.getBottomRightCorner();return[e.row,e.col,t.row,t.col]}},{key:"addClassAtCoords",value:function(e,t,n,r){var a=e.wtTable.getCell(new s.default(t,n));"object"===(void 0===a?"undefined":o(a))&&(0,i.addClass)(a,r)}},{key:"draw",value:function(e){if(this.isEmpty()){if(this.settings.border){var t=this.getBorder(e);t&&t.disappear()}}else{for(var n=e.wtTable.getRenderedRowsCount(),o=e.wtTable.getRenderedColumnsCount(),r=this.getCorners(),a=void 0,s=void 0,l=void 0,u=0;u<o;u++)if((s=e.wtTable.columnFilter.renderedToSource(u))>=r[1]&&s<=r[3]&&(l=e.wtTable.getColumnHeader(s))){var c=[];this.settings.highlightHeaderClassName&&c.push(this.settings.highlightHeaderClassName),this.settings.highlightColumnClassName&&c.push(this.settings.highlightColumnClassName),(0,i.addClass)(l,c)}for(var d=0;d<n;d++){if((a=e.wtTable.rowFilter.renderedToSource(d))>=r[0]&&a<=r[2]&&(l=e.wtTable.getRowHeader(a))){var h=[];this.settings.highlightHeaderClassName&&h.push(this.settings.highlightHeaderClassName),this.settings.highlightRowClassName&&h.push(this.settings.highlightRowClassName),(0,i.addClass)(l,h)}for(var f=0;f<o;f++)s=e.wtTable.columnFilter.renderedToSource(f),a>=r[0]&&a<=r[2]&&s>=r[1]&&s<=r[3]?this.settings.className&&this.addClassAtCoords(e,a,s,this.settings.className):a>=r[0]&&a<=r[2]?this.settings.highlightRowClassName&&this.addClassAtCoords(e,a,s,this.settings.highlightRowClassName):s>=r[1]&&s<=r[3]&&this.settings.highlightColumnClassName&&this.addClassAtCoords(e,a,s,this.settings.highlightColumnClassName)}if(e.getSetting("onBeforeDrawBorders",r,this.settings.className),this.settings.border){var p=this.getBorder(e);p&&p.appear(r)}}}}]),e}();t.default=c},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9),i=n(26);t.default={editor:(0,o.getEditor)("autocomplete"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9);t.default={editor:(0,o.getEditor)("checkbox"),renderer:(0,r.getRenderer)("checkbox")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9),i=n(26);t.default={editor:(0,o.getEditor)("date"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("date")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9),i=n(26);t.default={editor:(0,o.getEditor)("dropdown"),renderer:(0,r.getRenderer)("autocomplete"),validator:(0,i.getValidator)("autocomplete")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9);t.default={editor:(0,o.getEditor)("handsontable"),renderer:(0,r.getRenderer)("autocomplete")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9),i=n(26);t.default={editor:(0,o.getEditor)("numeric"),renderer:(0,r.getRenderer)("numeric"),validator:(0,i.getValidator)("numeric"),dataType:"number"}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9);n(26),t.default={editor:(0,o.getEditor)("password"),renderer:(0,r.getRenderer)("password"),copyable:!1}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(25),r=n(14),i=n(9);t.default={editor:(0,o.isMobileBrowser)()?(0,r.getEditor)("mobile"):(0,r.getEditor)("text"),renderer:(0,i.getRenderer)("text")}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(14),r=n(9),i=n(26);t.default={editor:(0,o.getEditor)("text"),renderer:(0,r.getRenderer)("text"),validator:(0,i.getValidator)("time")}},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=h(n(132)),i=n(65),a=n(66),s=n(2),l=n(1),u=h(n(269)),c=n(6),d=h(n(210));function h(e){return e&&e.__esModule?e:{default:e}}function f(e,t,n){var o=this;this.instance=e,this.priv=t,this.GridSettings=n,this.dataSource=this.instance.getSettings().data,this.cachedLength=null,this.skipCache=!1,this.latestSourceRowsCount=0,this.dataSource&&this.dataSource[0]?this.duckSchema=this.recursiveDuckSchema(this.dataSource[0]):this.duckSchema={},this.createMap(),this.interval=u.default.create(function(){return o.clearLengthCache()},"15fps"),this.instance.addHook("skipLengthCache",function(e){return o.onSkipLengthCache(e)}),this.onSkipLengthCache(500)}h(n(8)),f.prototype.DESTINATION_RENDERER=1,f.prototype.DESTINATION_CLIPBOARD_GENERATOR=2,f.prototype.recursiveDuckSchema=function(e){return(0,s.duckSchema)(e)},f.prototype.recursiveDuckColumns=function(e,t,n){var r,i;if(void 0===t&&(t=0,n=""),"object"===(void 0===e?"undefined":o(e))&&!Array.isArray(e))for(i in e)(0,s.hasOwnProperty)(e,i)&&(null===e[i]?(r=n+i,this.colToPropCache.push(r),this.propToColCache.set(r,t),t++):t=this.recursiveDuckColumns(e[i],t,i+"."));return t},f.prototype.createMap=function(){var e=void 0,t=this.getSchema();if(void 0===t)throw new Error("trying to create `columns` definition but you didn't provide `schema` nor `data`");this.colToPropCache=[],this.propToColCache=new d.default;var n=this.instance.getSettings().columns;if(n){var o=this.instance.getSettings().maxCols,r=Math.min(o,n.length),i=0,a=!1,l=(0,s.deepObjectSize)(t);for("function"==typeof n&&(r=l>0?l:this.instance.countSourceCols(),a=!0),e=0;e<r;e++){var u=a?n(e):n[e];if((0,s.isObject)(u)){if(void 0!==u.data){var c=a?i:e;this.colToPropCache[c]=u.data,this.propToColCache.set(u.data,c)}i++}}}else this.recursiveDuckColumns(t)},f.prototype.colToProp=function(e){return e=this.instance.runHooks("modifyCol",e),!isNaN(e)&&this.colToPropCache&&void 0!==this.colToPropCache[e]?this.colToPropCache[e]:e},f.prototype.propToCol=function(e){var t;return t=void 0===this.propToColCache.get(e)?e:this.propToColCache.get(e),t=this.instance.runHooks("unmodifyCol",t)},f.prototype.getSchema=function(){var e=this.instance.getSettings().dataSchema;return e?"function"==typeof e?e():e:this.duckSchema},f.prototype.createRow=function(e,t,n){var o,r=this.instance.countCols(),i=0;t||(t=1),("number"!=typeof e||e>=this.instance.countSourceRows())&&(e=this.instance.countSourceRows()),this.instance.runHooks("beforeCreateRow",e,t,n);for(var a=this.instance.getSettings().maxRows;i<t&&this.instance.countSourceRows()<a;)"array"===this.instance.dataType?this.instance.getSettings().dataSchema?o=(0,s.deepClone)(this.getSchema()):(o=[],(0,c.rangeEach)(r-1,function(){return o.push(null)})):"function"===this.instance.dataType?o=this.instance.getSettings().dataSchema(e):(o={},(0,s.deepExtend)(o,this.getSchema())),e===this.instance.countSourceRows()?this.dataSource.push(o):this.spliceData(e,0,o),i++;return this.instance.runHooks("afterCreateRow",e,i,n),this.instance.forceFullRender=!0,i},f.prototype.createCol=function(e,t,n){if(!this.instance.isColumnModificationAllowed())throw new Error("Cannot create new column. When data source in an object, you can only have as much columns as defined in first data row, data schema or in the 'columns' setting.If you want to be able to add new columns, you have to use array datasource.");var o,r,i=this.instance.countSourceRows(),s=this.dataSource,l=0;t||(t=1),("number"!=typeof e||e>=this.instance.countCols())&&(e=this.instance.countCols()),this.instance.runHooks("beforeCreateCol",e,t,n),r=e;for(var u=this.instance.getSettings().maxCols;l<t&&this.instance.countCols()<u;){if(o=(0,a.columnFactory)(this.GridSettings,this.priv.columnsSettingConflicts),"number"!=typeof e||e>=this.instance.countCols()){if(i>0)for(var c=0;c<i;c++)void 0===s[c]&&(s[c]=[]),s[c].push(null);else s.push([null]);this.priv.columnSettings.push(o)}else{for(var d=0;d<i;d++)s[d].splice(r,0,null);this.priv.columnSettings.splice(r,0,o)}l++,r++}return this.instance.runHooks("afterCreateCol",e,l,n),this.instance.forceFullRender=!0,l},f.prototype.removeRow=function(e,t,n){t||(t=1),"number"!=typeof e&&(e=-t),t=this.instance.runHooks("modifyRemovedAmount",t,e),e=(this.instance.countSourceRows()+e)%this.instance.countSourceRows();var o=this.physicalRowsToLogical(e,t);if(!1!==this.instance.runHooks("beforeRemoveRow",e,t,o,n)){var r,i=this.dataSource;(r=this.filterData(e,t))&&(i.length=0,Array.prototype.push.apply(i,r)),this.instance.runHooks("afterRemoveRow",e,t,o,n),this.instance.forceFullRender=!0}},f.prototype.removeCol=function(e,t,n){if("object"===this.instance.dataType||this.instance.getSettings().columns)throw new Error("cannot remove column with object data source or columns option specified");t||(t=1),"number"!=typeof e&&(e=-t),e=(this.instance.countCols()+e)%this.instance.countCols();var o=this.physicalColumnsToLogical(e,t),r=o.slice(0).sort(function(e,t){return t-e});if(!1!==this.instance.runHooks("beforeRemoveCol",e,t,o,n)){for(var i=!0,a=r.length,s=this.dataSource,l=0;l<a;l++)i&&o[0]!==o[l]-l&&(i=!1);if(i)for(var u=0,c=this.instance.countSourceRows();u<c;u++)s[u].splice(o[0],t);else{for(var d=0,h=this.instance.countSourceRows();d<h;d++)for(var f=0;f<a;f++)s[d].splice(r[f],1);for(var p=0;p<a;p++)this.priv.columnSettings.splice(o[p],1)}this.instance.runHooks("afterRemoveCol",e,t,o,n),this.instance.forceFullRender=!0}},f.prototype.spliceCol=function(e,t,n){var o=arguments.length>=4?[].slice.call(arguments,3):[],r=this.instance.getDataAtCol(e),i=r.slice(t,t+n),a=r.slice(t+n);(0,l.extendArray)(o,a);for(var s=0;s<n;)o.push(null),s++;return(0,l.to2dArray)(o),this.instance.populateFromArray(t,e,o,null,null,"spliceCol"),i},f.prototype.spliceRow=function(e,t,n){var o=arguments.length>=4?[].slice.call(arguments,3):[],r=this.instance.getSourceDataAtRow(e),i=r.slice(t,t+n),a=r.slice(t+n);(0,l.extendArray)(o,a);for(var s=0;s<n;)o.push(null),s++;return this.instance.populateFromArray(e,t,[o],null,null,"spliceRow"),i},f.prototype.spliceData=function(e,t,n){!1!==this.instance.runHooks("beforeDataSplice",e,t,n)&&this.dataSource.splice(e,t,n)},f.prototype.filterData=function(e,t){var n=this.physicalRowsToLogical(e,t);if(!1!==this.instance.runHooks("beforeDataFilter",e,t,n))return this.dataSource.filter(function(e,t){return-1==n.indexOf(t)})},f.prototype.get=function(e,t){e=this.instance.runHooks("modifyRow",e);var n=this.dataSource[e],o=this.instance.runHooks("modifyRowData",e),r=null;if((n=isNaN(o)?o:n)&&n.hasOwnProperty&&(0,s.hasOwnProperty)(n,t))r=n[t];else if("string"==typeof t&&t.indexOf(".")>-1){var i=t.split("."),a=n;if(!a)return null;for(var l=0,u=i.length;l<u;l++)if(void 0===(a=a[i[l]]))return null;r=a}else"function"==typeof t&&(r=t(this.dataSource.slice(e,e+1)[0]));if(this.instance.hasHook("modifyData")){var c=(0,s.createObjectPropListener)(r);this.instance.runHooks("modifyData",e,this.propToCol(t),c,"get"),c.isTouched()&&(r=c.value)}return r};var p=(0,i.cellMethodLookupFactory)("copyable",!1);f.prototype.getCopyable=function(e,t){return p.call(this.instance,e,this.propToCol(t))?this.get(e,t):""},f.prototype.set=function(e,t,n,o){e=this.instance.runHooks("modifyRow",e,o||"datamapGet");var r=this.dataSource[e],i=this.instance.runHooks("modifyRowData",e);if(r=isNaN(i)?i:r,this.instance.hasHook("modifyData")){var a=(0,s.createObjectPropListener)(n);this.instance.runHooks("modifyData",e,this.propToCol(t),a,"set"),a.isTouched()&&(n=a.value)}if(r&&r.hasOwnProperty&&(0,s.hasOwnProperty)(r,t))r[t]=n;else if("string"==typeof t&&t.indexOf(".")>-1){var l,u=t.split("."),c=r,d=0;for(d=0,l=u.length-1;d<l;d++)void 0===c[u[d]]&&(c[u[d]]={}),c=c[u[d]];c[u[d]]=n}else"function"==typeof t?t(this.dataSource.slice(e,e+1)[0],n):r[t]=n},f.prototype.physicalRowsToLogical=function(e,t){for(var n,o=this.instance.countSourceRows(),r=(o+e)%o,i=[],a=t;r<o&&a;)n=this.instance.runHooks("modifyRow",r),i.push(n),a--,r++;return i},f.prototype.physicalColumnsToLogical=function(e,t){for(var n=this.instance.countCols(),o=(n+e)%n,r=[],i=t;o<n&&i;){var a=this.instance.runHooks("modifyCol",o);r.push(a),i--,o++}return r},f.prototype.clear=function(){for(var e=0;e<this.instance.countSourceRows();e++)for(var t=0;t<this.instance.countCols();t++)this.set(e,this.colToProp(t),"")},f.prototype.clearLengthCache=function(){this.cachedLength=null},f.prototype.getLength=function(){var e=this,t=void 0,n=this.instance.getSettings().maxRows;t=n<0||0===n?0:n||1/0;var o=this.instance.countSourceRows();if(this.instance.hasHook("modifyRow")){var r=this.skipCache;this.interval.start(),o!==this.latestSourceRowsCount&&(r=!0),this.latestSourceRowsCount=o,null===this.cachedLength||r?((0,c.rangeEach)(o-1,function(t){null===(t=e.instance.runHooks("modifyRow",t))&&--o}),this.cachedLength=o):o=this.cachedLength}else this.interval.stop();return Math.min(o,t)},f.prototype.getAll=function(){var e={row:0,col:0},t={row:Math.max(this.instance.countSourceRows()-1,0),col:Math.max(this.instance.countCols()-1,0)};return e.row-t.row!=0||this.instance.countSourceRows()?this.getRange(e,t,f.prototype.DESTINATION_RENDERER):[]},f.prototype.getRange=function(e,t,n){var o,r,i,a,s,l=[],u=this.instance.getSettings().maxRows,c=this.instance.getSettings().maxCols;if(0===u||0===c)return[];var d=n===this.DESTINATION_CLIPBOARD_GENERATOR?this.getCopyable:this.get;for(r=Math.min(Math.max(u-1,0),Math.max(e.row,t.row)),a=Math.min(Math.max(c-1,0),Math.max(e.col,t.col)),o=Math.min(e.row,t.row);o<=r;o++){s=[];var h=this.instance.runHooks("modifyRow",o);for(i=Math.min(e.col,t.col);i<=a&&null!==h;i++)s.push(d.call(this,o,this.colToProp(i)));null!==h&&l.push(s)}return l},f.prototype.getText=function(e,t){return r.default.stringify(this.getRange(e,t,this.DESTINATION_RENDERER))},f.prototype.getCopyableText=function(e,t){return r.default.stringify(this.getRange(e,t,this.DESTINATION_CLIPBOARD_GENERATOR))},f.prototype.onSkipLengthCache=function(e){var t=this;this.skipCache=!0,setTimeout(function(){t.skipCache=!1},e)},f.prototype.destroy=function(){this.interval.stop(),this.interval=null,this.instance=null,this.priv=null,this.GridSettings=null,this.dataSource=null,this.cachedLength=null,this.duckSchema=null},t.default=f},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(2),i=n(1),a=n(6),s=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this.data=n,this.dataType="array",this.colToProp=function(){},this.propToCol=function(){}}return o(e,[{key:"getData",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],t=this.data;return e&&(t=this.getByRange({row:0,col:0},{row:Math.max(this.countRows()-1,0),col:Math.max(this.countColumns()-1,0)},!0)),t}},{key:"setData",value:function(e){this.data=e}},{key:"getAtColumn",value:function(e){var t=this,n=[];return(0,i.arrayEach)(this.data,function(o){var i=t.colToProp(e);o="string"==typeof i?(0,r.getProperty)(o,i):o[i],n.push(o)}),n}},{key:"getAtRow",value:function(e){return this.data[e]}},{key:"getAtCell",value:function(e,t){var n=null,o=this.hot.runHooks("modifyRowData",e),i=isNaN(o)?o:this.data[e];if(i){var a=this.colToProp(t);n="string"==typeof a?(0,r.getProperty)(i,a):"function"==typeof a?a(this.data.slice(e,e+1)[0]):i[a]}return n}},{key:"getByRange",value:function(e,t){var n=this,o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=Math.min(e.row,t.row),i=Math.min(e.col,t.col),s=Math.max(e.row,t.row),l=Math.max(e.col,t.col),u=[];return(0,a.rangeEach)(r,s,function(e){var t=n.getAtRow(e),r=void 0;"array"===n.dataType?r=t.slice(i,l+1):"object"===n.dataType&&(r=o?[]:{},(0,a.rangeEach)(i,l,function(e){var i=n.colToProp(e);o?r.push(t[i]):r[i]=t[i]})),u.push(r)}),u}},{key:"countRows",value:function(){return Array.isArray(this.data)?this.data.length:0}},{key:"countColumns",value:function(){var e=0;return Array.isArray(this.data)&&("array"===this.dataType?e=this.data[0].length:"object"===this.dataType&&(e=Object.keys(this.data[0]).length)),e}},{key:"destroy",value:function(){this.data=null,this.hot=null}}]),e}();t.default=s},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(11),i=n(16),a=n(7),s=n(14),l=n(4),u=(o=l)&&o.__esModule?o:{default:o},c=n(36);t.default=function(e,t,n){var o,l,d=this,h=!1;function f(e){n.setSelectedHeaders(!1,!1,!1);var o="function"==typeof t.settings.enterMoves?t.settings.enterMoves(event):t.settings.enterMoves;e?n.transformStart(-o.row,-o.col):n.transformStart(o.row,o.col,!0)}function p(o){var s,u;if(e.isListening()&&(e.runHooks("beforeKeyDown",o),!h&&!(0,a.isImmediatePropagationStopped)(o)&&(t.lastKeyCode=o.keyCode,n.isSelected())))if(s=(o.ctrlKey||o.metaKey)&&!o.altKey,!l||l.isWaiting()||(0,i.isMetaKey)(o.keyCode)||(0,i.isCtrlKey)(o.keyCode)||s||d.isEditorOpened())switch(u=o.shiftKey?n.setRangeEnd:n.setRangeStart,o.keyCode){case i.KEY_CODES.A:!d.isEditorOpened()&&s&&(n.selectAll(),o.preventDefault(),(0,a.stopPropagation)(o));break;case i.KEY_CODES.ARROW_UP:d.isEditorOpened()&&!l.isWaiting()&&d.closeEditorAndSaveChanges(s),o.shiftKey?(n.selectedHeader.cols&&n.setSelectedHeaders(n.selectedHeader.rows,!1,!1),n.transformEnd(-1,0)):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(-1,0)),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.ARROW_DOWN:d.isEditorOpened()&&!l.isWaiting()&&d.closeEditorAndSaveChanges(s),function(e){e?n.transformEnd(1,0):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(1,0))}(o.shiftKey),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.ARROW_RIGHT:d.isEditorOpened()&&!l.isWaiting()&&d.closeEditorAndSaveChanges(s),function(e){e?n.transformEnd(0,1):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(0,1))}(o.shiftKey),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.ARROW_LEFT:d.isEditorOpened()&&!l.isWaiting()&&d.closeEditorAndSaveChanges(s),function(e){e?(n.selectedHeader.rows&&n.setSelectedHeaders(!1,n.selectedHeader.cols,!1),n.transformEnd(0,-1)):(n.setSelectedHeaders(!1,!1,!1),n.transformStart(0,-1))}(o.shiftKey),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.TAB:n.setSelectedHeaders(!1,!1,!1);var p="function"==typeof t.settings.tabMoves?t.settings.tabMoves(o):t.settings.tabMoves;o.shiftKey?n.transformStart(-p.row,-p.col):n.transformStart(p.row,p.col,!0),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.BACKSPACE:case i.KEY_CODES.DELETE:n.empty(o),d.prepareEditor(),o.preventDefault();break;case i.KEY_CODES.F2:d.openEditor(null,o),l&&l.enableFullEditMode(),o.preventDefault();break;case i.KEY_CODES.ENTER:d.isEditorOpened()?(l&&l.state!==c.EditorState.WAITING&&d.closeEditorAndSaveChanges(s),f(o.shiftKey)):e.getSettings().enterBeginsEditing?(d.openEditor(null,o),l&&l.enableFullEditMode()):f(o.shiftKey),o.preventDefault(),(0,a.stopImmediatePropagation)(o);break;case i.KEY_CODES.ESCAPE:d.isEditorOpened()&&d.closeEditorAndRestoreOriginalValue(s),o.preventDefault();break;case i.KEY_CODES.HOME:n.setSelectedHeaders(!1,!1,!1),o.ctrlKey||o.metaKey?u(new r.CellCoords(0,t.selRange.from.col)):u(new r.CellCoords(t.selRange.from.row,0)),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.END:n.setSelectedHeaders(!1,!1,!1),o.ctrlKey||o.metaKey?u(new r.CellCoords(e.countRows()-1,t.selRange.from.col)):u(new r.CellCoords(t.selRange.from.row,e.countCols()-1)),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.PAGE_UP:n.setSelectedHeaders(!1,!1,!1),n.transformStart(-e.countVisibleRows(),0),o.preventDefault(),(0,a.stopPropagation)(o);break;case i.KEY_CODES.PAGE_DOWN:n.setSelectedHeaders(!1,!1,!1),n.transformStart(e.countVisibleRows(),0),o.preventDefault(),(0,a.stopPropagation)(o)}else d.openEditor("",o)}o=new u.default(e),this.destroyEditor=function(e){this.closeEditor(e)},this.getActiveEditor=function(){return l},this.prepareEditor=function(){var n,o,r,i,a,u,c;l&&l.isWaiting()?this.closeEditor(!1,!1,function(e){e&&d.prepareEditor()}):(n=t.selRange.highlight.row,o=t.selRange.highlight.col,r=e.colToProp(o),i=e.getCell(n,o),a=e.getSourceDataAtCell(e.runHooks("modifyRow",n),o),u=e.getCellMeta(n,o),(c=e.getCellEditor(u))?(l=(0,s.getEditorInstance)(c,e)).prepare(n,o,r,i,a,u):l=void 0)},this.isEditorOpened=function(){return l&&l.isOpened()},this.openEditor=function(e,t){l&&!l.cellProperties.readOnly?l.beginEditing(e,t):l&&l.cellProperties.readOnly&&t&&t.keyCode===i.KEY_CODES.ENTER&&f()},this.closeEditor=function(e,t,n){l?l.finishEditing(e,t,n):n&&n(!1)},this.closeEditorAndSaveChanges=function(e){return this.closeEditor(!1,e)},this.closeEditorAndRestoreOriginalValue=function(e){return this.closeEditor(!0,e)},e.addHook("afterDocumentKeyDown",p),o.addEventListener(document.documentElement,"keydown",function(t){h||e.runHooks("afterDocumentKeyDown",t)}),e.view.wt.update("onCellDblClick",function(e,t,n){"TD"==n.nodeName&&(d.openEditor(),l&&l.enableFullEditMode())}),e.addHook("afterDestroy",function(){h=!0})}},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(36),a=(o=i)&&o.__esModule?o:{default:o},s=n(0),l=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),r(t,[{key:"beginEditing",value:function(e,t){if(void 0===t){var n=this.TD.querySelector('input[type="checkbox"]');(0,s.hasClass)(n,"htBadValue")||n.click()}}},{key:"finishEditing",value:function(){}},{key:"init",value:function(){}},{key:"open",value:function(){}},{key:"close",value:function(){}},{key:"getValue",value:function(){}},{key:"setValue",value:function(){}},{key:"focus",value:function(){}}]),t}();t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=f(n(62)),a=f(n(299));n(182);var s=n(0),l=n(2),u=f(n(4)),c=n(16),d=n(7),h=f(n(43));function f(e){return e&&e.__esModule?e:{default:e}}var p=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.defaultDateFormat="DD/MM/YYYY",n.isCellEdited=!1,n.parentDestroyed=!1,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,h.default),o(t,[{key:"init",value:function(){var e=this;if("function"!=typeof i.default)throw new Error("You need to include moment.js to your project.");if("function"!=typeof a.default)throw new Error("You need to include Pikaday to your project.");r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"init",this).call(this),this.instance.addHook("afterDestroy",function(){e.parentDestroyed=!0,e.destroyElements()})}},{key:"createElements",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"createElements",this).call(this),this.datePicker=document.createElement("DIV"),this.datePickerStyle=this.datePicker.style,this.datePickerStyle.position="absolute",this.datePickerStyle.top=0,this.datePickerStyle.left=0,this.datePickerStyle.zIndex=9999,(0,s.addClass)(this.datePicker,"htDatepickerHolder"),document.body.appendChild(this.datePicker),this.$datePicker=new a.default(this.getDatePickerConfig()),new u.default(this).addEventListener(this.datePicker,"mousedown",function(e){return(0,d.stopPropagation)(e)}),this.hideDatepicker()}},{key:"destroyElements",value:function(){this.$datePicker.destroy()}},{key:"prepare",value:function(e,n,o,i,a,s){this._opened=!1,r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,n,o,i,a,s)}},{key:"open",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"open",this).call(this),this.showDatepicker(e)}},{key:"close",value:function(){var e=this;this._opened=!1,this.instance._registerTimeout(setTimeout(function(){e.instance.selection.refreshBorders()},0)),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"close",this).call(this)}},{key:"finishEditing",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e){var o=this.originalValue;void 0!==o&&this.setValue(o)}this.hideDatepicker(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"finishEditing",this).call(this,e,n)}},{key:"showDatepicker",value:function(e){this.$datePicker.config(this.getDatePickerConfig());var t=this.TD.getBoundingClientRect(),n=this.cellProperties.dateFormat||this.defaultDateFormat,o=this.$datePicker.config(),r=void 0,a=this.instance.view.isMouseDown(),l=!!e&&(0,c.isMetaKey)(e.keyCode);this.datePickerStyle.top=window.pageYOffset+t.top+(0,s.outerHeight)(this.TD)+"px",this.datePickerStyle.left=window.pageXOffset+t.left+"px",this.$datePicker._onInputFocus=function(){},o.format=n,this.originalValue?(r=this.originalValue,(0,i.default)(r,n,!0).isValid()&&this.$datePicker.setMoment((0,i.default)(r,n),!0),this.getValue()!==this.originalValue&&this.setValue(this.originalValue),l||a||this.setValue("")):this.cellProperties.defaultDate?(r=this.cellProperties.defaultDate,o.defaultDate=r,(0,i.default)(r,n,!0).isValid()&&this.$datePicker.setMoment((0,i.default)(r,n),!0),l||a||this.setValue("")):this.$datePicker.gotoToday(),this.datePickerStyle.display="block",this.$datePicker.show()}},{key:"hideDatepicker",value:function(){this.datePickerStyle.display="none",this.$datePicker.hide()}},{key:"getDatePickerConfig",value:function(){var e=this,t=this.TEXTAREA,n={};this.cellProperties&&this.cellProperties.datePickerConfig&&(0,l.deepExtend)(n,this.cellProperties.datePickerConfig);var o=n.onSelect,r=n.onClose;return n.field=t,n.trigger=t,n.container=this.datePicker,n.bound=!1,n.format=n.format||this.defaultDateFormat,n.reposition=n.reposition||!1,n.onSelect=function(t){isNaN(t.getTime())||(t=(0,i.default)(t).format(e.cellProperties.dateFormat||e.defaultDateFormat)),e.setValue(t),e.hideDatepicker(),o&&o()},n.onClose=function(){e.parentDestroyed||e.finishEditing(!1),r&&r()},n}}]),t}();t.default=p},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=a(n(147)),i=a(n(8));function a(e){return e&&e.__esModule?e:{default:e}}var s=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,r.default),o(t,[{key:"prepare",value:function(e,n,o,r,i,a){(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"prepare",this).call(this,e,n,o,r,i,a),this.cellProperties.filter=!1,this.cellProperties.strict=!0}}]),t}();i.default.getSingleton().add("beforeValidate",function(e,t,n,o){var r=this.getCellMeta(t,this.propToCol(n));r.editor===s&&void 0===r.strict&&(r.filter=!1,r.strict=!0)}),t.default=s},function(e,t,n){"use strict";t.__esModule=!0;var o=n(16),r=n(7),i=n(0),a=l(n(36)),s=l(n(4));function l(e){return e&&e.__esModule?e:{default:e}}var u=a.default.prototype.extend(),c={},d=function(){for(var e in this.controls={},this.controls.leftButton=document.createElement("DIV"),this.controls.leftButton.className="leftButton",this.controls.rightButton=document.createElement("DIV"),this.controls.rightButton.className="rightButton",this.controls.upButton=document.createElement("DIV"),this.controls.upButton.className="upButton",this.controls.downButton=document.createElement("DIV"),this.controls.downButton.className="downButton",this.controls)Object.prototype.hasOwnProperty.call(this.controls,e)&&this.positionControls.appendChild(this.controls[e])};u.prototype.valueChanged=function(){return this.initValue!=this.getValue()},u.prototype.init=function(){var e=this;this.eventManager=new s.default(this.instance),this.createElements(),this.bindEvents(),this.instance.addHook("afterDestroy",function(){e.destroy()})},u.prototype.getValue=function(){return this.TEXTAREA.value},u.prototype.setValue=function(e){this.initValue=e,this.TEXTAREA.value=e},u.prototype.createElements=function(){this.editorContainer=document.createElement("DIV"),this.editorContainer.className="htMobileEditorContainer",this.cellPointer=document.createElement("DIV"),this.cellPointer.className="cellPointer",this.moveHandle=document.createElement("DIV"),this.moveHandle.className="moveHandle",this.inputPane=document.createElement("DIV"),this.inputPane.className="inputs",this.positionControls=document.createElement("DIV"),this.positionControls.className="positionControls",this.TEXTAREA=document.createElement("TEXTAREA"),(0,i.addClass)(this.TEXTAREA,"handsontableInput"),this.inputPane.appendChild(this.TEXTAREA),this.editorContainer.appendChild(this.cellPointer),this.editorContainer.appendChild(this.moveHandle),this.editorContainer.appendChild(this.inputPane),this.editorContainer.appendChild(this.positionControls),d.call(this),document.body.appendChild(this.editorContainer)},u.prototype.onBeforeKeyDown=function(e){var t=this.getActiveEditor();if(e.target===t.TEXTAREA&&!(0,r.isImmediatePropagationStopped)(e))switch(e.keyCode){case o.KEY_CODES.ENTER:t.close(),e.preventDefault();break;case o.KEY_CODES.BACKSPACE:(0,r.stopImmediatePropagation)(e)}},u.prototype.open=function(){this.instance.addHook("beforeKeyDown",this.onBeforeKeyDown),(0,i.addClass)(this.editorContainer,"active"),(0,i.removeClass)(this.cellPointer,"hidden"),this.updateEditorPosition()},u.prototype.focus=function(){this.TEXTAREA.focus(),(0,i.setCaretPosition)(this.TEXTAREA,this.TEXTAREA.value.length)},u.prototype.close=function(){this.TEXTAREA.blur(),this.instance.removeHook("beforeKeyDown",this.onBeforeKeyDown),(0,i.removeClass)(this.editorContainer,"active")},u.prototype.scrollToView=function(){var e=this.instance.getSelectedRange().highlight;this.instance.view.scrollViewport(e)},u.prototype.hideCellPointer=function(){(0,i.hasClass)(this.cellPointer,"hidden")||(0,i.addClass)(this.cellPointer,"hidden")},u.prototype.updateEditorPosition=function(e,t){if(e&&t)e=parseInt(e,10),t=parseInt(t,10),this.editorContainer.style.top=t+"px",this.editorContainer.style.left=e+"px";else{var n=this.instance.getSelected(),o=this.instance.getCell(n[0],n[1]);if(c.cellPointer||(c.cellPointer={height:(0,i.outerHeight)(this.cellPointer),width:(0,i.outerWidth)(this.cellPointer)}),c.editorContainer||(c.editorContainer={width:(0,i.outerWidth)(this.editorContainer)}),void 0!==o){var r=this.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer==window?0:(0,i.getScrollLeft)(this.instance.view.wt.wtOverlays.leftOverlay.holder),a=this.instance.view.wt.wtOverlays.topOverlay.trimmingContainer==window?0:(0,i.getScrollTop)(this.instance.view.wt.wtOverlays.topOverlay.holder),s=(0,i.offset)(o),l=(0,i.outerWidth)(o),u={x:r,y:a};this.editorContainer.style.top=parseInt(s.top+(0,i.outerHeight)(o)-u.y+c.cellPointer.height,10)+"px",this.editorContainer.style.left=parseInt(window.innerWidth/2-c.editorContainer.width/2,10)+"px",s.left+l/2>parseInt(this.editorContainer.style.left,10)+c.editorContainer.width?this.editorContainer.style.left=window.innerWidth-c.editorContainer.width+"px":s.left+l/2<parseInt(this.editorContainer.style.left,10)+20&&(this.editorContainer.style.left="0px"),this.cellPointer.style.left=parseInt(s.left-c.cellPointer.width/2-(0,i.offset)(this.editorContainer).left+l/2-u.x,10)+"px"}}},u.prototype.updateEditorData=function(){var e=this.instance.getSelected(),t=this.instance.getDataAtCell(e[0],e[1]);this.row=e[0],this.col=e[1],this.setValue(t),this.updateEditorPosition()},u.prototype.prepareAndSave=function(){var e;this.valueChanged()&&(e=this.instance.getSettings().trimWhitespace?[[String.prototype.trim.call(this.getValue())]]:[[this.getValue()]],this.saveValue(e))},u.prototype.bindEvents=function(){var e=this;this.eventManager.addEventListener(this.controls.leftButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,-1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.rightButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(0,1,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.upButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(-1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.controls.downButton,"touchend",function(t){e.prepareAndSave(),e.instance.selection.transformStart(1,0,null,!0),e.updateEditorData(),t.preventDefault()}),this.eventManager.addEventListener(this.moveHandle,"touchstart",function(t){if(1==t.touches.length){var n=t.touches[0],o={x:e.editorContainer.offsetLeft,y:e.editorContainer.offsetTop},r={x:n.pageX-o.x,y:n.pageY-o.y};e.eventManager.addEventListener(this,"touchmove",function(t){var n=t.touches[0];e.updateEditorPosition(n.pageX-r.x,n.pageY-r.y),e.hideCellPointer(),t.preventDefault()})}}),this.eventManager.addEventListener(document.body,"touchend",function(t){(0,i.isChildOf)(t.target,e.editorContainer)||(0,i.isChildOf)(t.target,e.instance.rootElement)||e.close()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.leftOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.leftOverlay.trimmingContainer!=window&&e.hideCellPointer()}),this.eventManager.addEventListener(this.instance.view.wt.wtOverlays.topOverlay.holder,"scroll",function(t){e.instance.view.wt.wtOverlays.topOverlay.trimmingContainer!=window&&e.hideCellPointer()})},u.prototype.destroy=function(){this.eventManager.clear(),this.editorContainer.parentNode.removeChild(this.editorContainer)},t.default=u},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=a(n(86)),i=a(n(43));function a(e){return e&&e.__esModule?e:{default:e}}var s=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"beginEditing",value:function(e){if(void 0===e&&this.originalValue){void 0!==this.cellProperties.language&&r.default.culture(this.cellProperties.language);var n=r.default.cultureData().delimiters.decimal;e=(""+this.originalValue).replace(".",n)}(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"beginEditing",this).call(this,e)}}]),t}();t.default=s},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(0),a=n(43),s=(o=a)&&o.__esModule?o:{default:o},l=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,s.default),r(t,[{key:"createElements",value:function(){(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"createElements",this).call(this),this.TEXTAREA=document.createElement("input"),this.TEXTAREA.setAttribute("type","password"),this.TEXTAREA.className="handsontableInput",this.textareaStyle=this.TEXTAREA.style,this.textareaStyle.width=0,this.textareaStyle.height=0,(0,i.empty)(this.TEXTAREA_PARENT),this.TEXTAREA_PARENT.appendChild(this.TEXTAREA)}}]),t}();t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o,r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=n(0),a=n(7),s=n(16),l=n(36),u=(o=l)&&o.__esModule?o:{default:o},c=u.default.prototype.extend();c.prototype.init=function(){this.select=document.createElement("SELECT"),(0,i.addClass)(this.select,"htSelectEditor"),this.select.style.display="none",this.instance.rootElement.appendChild(this.select),this.registerHooks()},c.prototype.registerHooks=function(){var e=this;this.instance.addHook("afterScrollHorizontally",function(){return e.refreshDimensions()}),this.instance.addHook("afterScrollVertically",function(){return e.refreshDimensions()}),this.instance.addHook("afterColumnResize",function(){return e.refreshDimensions()}),this.instance.addHook("afterRowResize",function(){return e.refreshDimensions()})},c.prototype.prepare=function(){u.default.prototype.prepare.apply(this,arguments);var e,t=this.cellProperties.selectOptions;for(var n in e="function"==typeof t?this.prepareOptions(t(this.row,this.col,this.prop)):this.prepareOptions(t),(0,i.empty)(this.select),e)if(Object.prototype.hasOwnProperty.call(e,n)){var o=document.createElement("OPTION");o.value=n,(0,i.fastInnerHTML)(o,e[n]),this.select.appendChild(o)}},c.prototype.prepareOptions=function(e){var t={};if(Array.isArray(e))for(var n=0,o=e.length;n<o;n++)t[e[n]]=e[n];else"object"==(void 0===e?"undefined":r(e))&&(t=e);return t},c.prototype.getValue=function(){return this.select.value},c.prototype.setValue=function(e){this.select.value=e};var d=function(e){var t=this.getActiveEditor();switch(e.keyCode){case s.KEY_CODES.ARROW_UP:var n=t.select.selectedIndex-1;n>=0&&(t.select[n].selected=!0),(0,a.stopImmediatePropagation)(e),e.preventDefault();break;case s.KEY_CODES.ARROW_DOWN:var o=t.select.selectedIndex+1;o<=t.select.length-1&&(t.select[o].selected=!0),(0,a.stopImmediatePropagation)(e),e.preventDefault()}};c.prototype.open=function(){this._opened=!0,this.refreshDimensions(),this.select.style.display="",this.instance.addHook("beforeKeyDown",d)},c.prototype.close=function(){this._opened=!1,this.select.style.display="none",this.instance.removeHook("beforeKeyDown",d)},c.prototype.focus=function(){this.select.focus()},c.prototype.refreshValue=function(){var e=this.instance.getSourceDataAtCell(this.row,this.prop);this.originalValue=e,this.setValue(e),this.refreshDimensions()},c.prototype.refreshDimensions=function(){if(this.state===l.EditorState.EDITING)if(this.TD=this.getEditedCell(),this.TD){var e,t=(0,i.outerWidth)(this.TD)+1,n=(0,i.outerHeight)(this.TD)+1,o=(0,i.offset)(this.TD),r=(0,i.offset)(this.instance.rootElement),a=(0,i.getScrollableElement)(this.TD),s=o.top-r.top-1-(a.scrollTop||0),u=o.left-r.left-1-(a.scrollLeft||0),c=this.checkEditorSection(),d=this.instance.getSettings();switch(d.rowHeaders,d.colHeaders,c){case"top":e=(0,i.getCssTransform)(this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.holder.parentNode);break;case"left":e=(0,i.getCssTransform)(this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.holder.parentNode);break;case"top-left-corner":e=(0,i.getCssTransform)(this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom-left-corner":e=(0,i.getCssTransform)(this.instance.view.wt.wtOverlays.bottomLeftCornerOverlay.clone.wtTable.holder.parentNode);break;case"bottom":e=(0,i.getCssTransform)(this.instance.view.wt.wtOverlays.bottomOverlay.clone.wtTable.holder.parentNode)}0===this.instance.getSelected()[0]&&(s+=1),0===this.instance.getSelected()[1]&&(u+=1);var h=this.select.style;e&&-1!=e?h[e[0]]=e[1]:(0,i.resetCssTransform)(this.select);var f=(0,i.getComputedStyle)(this.TD);parseInt(f.borderTopWidth,10)>0&&(n-=1),parseInt(f.borderLeftWidth,10)>0&&(t-=1),h.height=n+"px",h.minWidth=t+"px",h.top=s+"px",h.left=u+"px",h.margin="0px"}else this.close()},c.prototype.getEditedCell=function(){var e;switch(this.checkEditorSection()){case"top":e=this.instance.view.wt.wtOverlays.topOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=101;break;case"corner":e=this.instance.view.wt.wtOverlays.topLeftCornerOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=103;break;case"left":e=this.instance.view.wt.wtOverlays.leftOverlay.clone.wtTable.getCell({row:this.row,col:this.col}),this.select.style.zIndex=102;break;default:e=this.instance.getCell(this.row,this.col),this.select.style.zIndex=""}return-1!=e&&-2!=e?e:void 0},t.default=c},function(e,t,n){"use strict";n(96),n(113),n(122),n(123),n(107),n(121),n(104),n(105),n(106),n(95),n(118),n(116),n(114),n(119),n(120),n(115),n(117),n(108),n(109),n(110),n(112),n(111),n(93),n(94),n(89),n(92),n(91),n(90),n(68),n(98),n(99),n(101),n(100),n(97),n(103),n(102),n(124),n(127),n(125),n(126),n(129),n(128),n(131),n(130),n(179),n(180),n(181);var o=n(14),r=n(9),i=n(26),a=n(63),s=E(n(64)),l=E(n(177)),u=n(4),c=E(u),d=E(n(8)),h=E(n(67)),f=O(n(1)),p=O(n(25)),m=O(n(65)),g=O(n(88)),v=O(n(34)),y=O(n(35)),_=O(n(20)),w=O(n(6)),b=O(n(2)),C=O(n(66)),M=O(n(27)),k=O(n(16)),S=O(n(0)),T=O(n(7)),L=O(n(178)),x=n(5),D=E(n(87));function O(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t}function E(e){return e&&e.__esModule?e:{default:e}}function R(e,t){var n=new s.default(e,t||{});return n.init(),n}(0,l.default)(R),R.Core=s.default,R.DefaultSettings=D.default,R.EventManager=c.default,R._getListenersCounter=u.getListenersCounter,R.buildDate="2017-05-30T10:18:32.902Z",R.packageName="handsontable",R.version="0.32.0",R.hooks=d.default.getSingleton(),R.__GhostTable=h.default;var A=[f,p,m,g,v,y,_,w,b,C,M,k],H=[S,T];R.helper={},R.dom={},f.arrayEach(A,function(e){f.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(R.helper[t]=e[t])})}),f.arrayEach(H,function(e){f.arrayEach(Object.getOwnPropertyNames(e),function(t){"_"!==t.charAt(0)&&(R.dom[t]=e[t])})}),R.cellTypes={},f.arrayEach((0,a.getRegisteredCellTypeNames)(),function(e){R.cellTypes[e]=(0,a.getCellType)(e)}),R.cellTypes.registerCellType=a.registerCellType,R.cellTypes.getCellType=a.getCellType,R.editors={},f.arrayEach((0,o.getRegisteredEditorNames)(),function(e){R.editors[M.toUpperCaseFirst(e)+"Editor"]=(0,o.getEditor)(e)}),R.editors.registerEditor=o.registerEditor,R.editors.getEditor=o.getEditor,R.renderers={},f.arrayEach((0,r.getRegisteredRendererNames)(),function(e){var t=(0,r.getRenderer)(e);"base"===e&&(R.renderers.cellDecorator=t),R.renderers[M.toUpperCaseFirst(e)+"Renderer"]=t}),R.renderers.registerRenderer=r.registerRenderer,R.renderers.getRenderer=r.getRenderer,R.validators={},f.arrayEach((0,i.getRegisteredValidatorNames)(),function(e){R.validators[M.toUpperCaseFirst(e)+"Validator"]=(0,i.getValidator)(e)}),R.validators.registerValidator=i.registerValidator,R.validators.getValidator=i.getValidator,R.plugins={},f.arrayEach(Object.getOwnPropertyNames(L),function(e){var t=L[e];"Base"===e?R.plugins[e+"Plugin"]=t:R.plugins[e]=t}),R.plugins.registerPlugin=x.registerPlugin,e.exports=R},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.default=function(){var e={arrayMap:[],weakMap:new WeakMap};return{get:function(o){return t(o)?e.arrayMap[o]:n(o)?e.weakMap.get(o):void 0},set:function(o,r){if(t(o))e.arrayMap[o]=r;else{if(!n(o))throw new Error("Invalid key type");e.weakMap.set(o,r)}},delete:function(o){t(o)?delete e.arrayMap[o]:n(o)&&e.weakMap.delete(o)}};function t(e){return null!==e&&!function(e){return e!=e}(e)&&("string"==typeof e||"number"==typeof e)}function n(e){return null!==e&&("object"==(void 0===e?"undefined":o(e))||"function"==typeof e)}}},function(e,t,n){"use strict";t.__esModule=!0;var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(o=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&s.return&&s.return()}finally{if(r)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),a=v(n(12)),s=n(1),l=n(34),u=n(0),c=v(n(67)),d=n(2),h=n(6),f=n(5),p=v(n(154)),m=n(27),g=n(11);function v(e){return e&&e.__esModule?e:{default:e}}var y=new WeakMap,_=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return y.set(n,{cachedColumnHeaders:[]}),n.widths=[],n.ghostTable=new c.default(n.hot),n.samplesGenerator=new p.default(function(e,t){return n.hot.getDataAtCell(e,t)}),n.firstCalculation=!0,n.inProgress=!1,n.addHook("beforeColumnResize",function(e,t,o){return n.onBeforeColumnResize(e,t,o)}),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),i(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 50}}]),i(t,[{key:"isEnabled",value:function(){return!1!==this.hot.getSettings().autoColumnSize&&!this.hot.getSettings().colWidths}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){var n=this.hot.getSettings().autoColumnSize;n&&null!=n.useHeaders&&this.ghostTable.setSetting("useHeaders",n.useHeaders),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("modifyColWidth",function(t,n){return e.getColumnWidth(n,t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.findColumnsWhereHeaderWasChanged();e.length&&this.clearCache(e),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"calculateColumnsWidth",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countRows()-1},o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];"number"==typeof e&&(e={from:e,to:e}),"number"==typeof n&&(n={from:n,to:n}),(0,h.rangeEach)(e.from,e.to,function(e){(o||void 0===t.widths[e]&&!t.hot._getColWidthFromSettings(e))&&t.samplesGenerator.generateColumnSamples(e,n).forEach(function(e,n){return t.ghostTable.addColumn(n,e)})}),this.ghostTable.columns.length&&(this.ghostTable.getWidths(function(e,n){t.widths[e]=n}),this.ghostTable.clean())}},{key:"calculateAllColumnsWidth",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},o=0,r=this.hot.countCols()-1,i=null;this.inProgress=!0;var a=function a(){if(!e.hot)return(0,l.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateColumnsWidth({from:o,to:Math.min(o+t.CALCULATION_STEP,r)},n),(o=o+t.CALCULATION_STEP+1)<r?i=(0,l.requestAnimationFrame)(a):((0,l.cancelAnimationFrame)(i),e.inProgress=!1,e.hot.view.wt.wtOverlays.adjustElementsSize(!0),e.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&e.hot.view.wt.wtOverlays.leftOverlay.clone.draw())};this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateColumnsWidth({from:0,to:this.getSyncCalculationLimit()},n),this.firstCalculation=!1,o=this.getSyncCalculationLimit()+1),o<r?a():this.inProgress=!1}},{key:"setSamplingOptions",value:function(){var e=this.hot.getSettings().autoColumnSize,t=e&&(0,d.hasOwnProperty)(e,"samplingRatio")?this.hot.getSettings().autoColumnSize.samplingRatio:void 0,n=e&&(0,d.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoColumnSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),n&&this.samplesGenerator.setAllowDuplicates(n)}},{key:"recalculateAllColumnsWidth",value:function(){this.hot.view&&(0,u.isVisible)(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllColumnsWidth())}},{key:"getSyncCalculationLimit",value:function(){var e=t.SYNC_CALCULATION_LIMIT,n=this.hot.countCols()-1;return(0,d.isObject)(this.hot.getSettings().autoColumnSize)&&(e=this.hot.getSettings().autoColumnSize.syncLimit,(0,m.isPercentValue)(e)?e=(0,h.valueAccordingPercent)(n,e):e>>=0),Math.min(e,n)}},{key:"getColumnWidth",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],o=t;return void 0===o&&(o=this.widths[e],n&&"number"==typeof o&&(o=Math.max(o,g.ViewportColumnsCalculator.DEFAULT_WIDTH))),o}},{key:"getFirstVisibleColumn",value:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getFirstVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getFirstRenderedColumn():-1}},{key:"getLastVisibleColumn",value:function(){var e=this.hot.view.wt;return e.wtViewport.columnsVisibleCalculator?e.wtTable.getLastVisibleColumn():e.wtViewport.columnsRenderCalculator?e.wtTable.getLastRenderedColumn():-1}},{key:"findColumnsWhereHeaderWasChanged",value:function(){var e=this.hot.getColHeader(),t=y.get(this).cachedColumnHeaders;return(0,s.arrayReduce)(e,function(e,n,o){var r=t.length;return(r-1<o||t[o]!==n)&&e.push(o),r-1<o?t.push(n):t[o]=n,e},[])}},{key:"clearCache",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];t.length?(0,s.arrayEach)(t,function(t){e.widths[t]=void 0}):this.widths.length=0}},{key:"isNeedRecalculate",value:function(){return!!(0,s.arrayFilter)(this.widths,function(e){return void 0===e}).length}},{key:"onBeforeRender",value:function(){var e=this.hot.renderCall;this.hot.countRows()&&(this.calculateColumnsWidth({from:this.getFirstVisibleColumn(),to:this.getLastVisibleColumn()},void 0,e),this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllColumnsWidth())}},{key:"onAfterLoadData",value:function(){var e=this;this.hot.view?this.recalculateAllColumnsWidth():setTimeout(function(){e.hot&&e.recalculateAllColumnsWidth()},0)}},{key:"onBeforeChange",value:function(e){var t=this,n=(0,s.arrayMap)(e,function(e){var n=o(e,2),r=(n[0],n[1]);return t.hot.propToCol(r)});this.clearCache(n)}},{key:"onBeforeColumnResize",value:function(e,t,n){return n&&(this.calculateColumnsWidth(e,void 0,!0),t=this.getColumnWidth(e,void 0,!1)),t}},{key:"onAfterInit",value:function(){y.get(this).cachedColumnHeaders=this.hot.getColHeader()}},{key:"destroy",value:function(){this.ghostTable.clean(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,f.registerPlugin)("autoColumnSize",_),t.default=_},function(e,t,n){"use strict";t.__esModule=!0;var o=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=m(n(12)),a=n(1),s=n(34),l=n(0),u=m(n(67)),c=n(2),d=n(6),h=n(5),f=m(n(154)),p=n(27);function m(e){return e&&e.__esModule?e:{default:e}}var g=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.heights=[],n.ghostTable=new u.default(n.hot),n.samplesGenerator=new f.default(function(e,t){return e>=0?n.hot.getDataAtCell(e,t):-1===e?n.hot.getColHeader(t):null}),n.firstCalculation=!0,n.inProgress=!1,n.addHook("beforeRowResize",function(e,t,o){return n.onBeforeRowResize(e,t,o)}),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),r(t,null,[{key:"CALCULATION_STEP",get:function(){return 50}},{key:"SYNC_CALCULATION_LIMIT",get:function(){return 500}}]),r(t,[{key:"isEnabled",value:function(){return!0===this.hot.getSettings().autoRowSize||(0,c.isObject)(this.hot.getSettings().autoRowSize)}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.setSamplingOptions(),this.addHook("afterLoadData",function(){return e.onAfterLoadData()}),this.addHook("beforeChange",function(t){return e.onBeforeChange(t)}),this.addHook("beforeColumnMove",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnResize",function(){return e.recalculateAllRowsHeight()}),this.addHook("beforeColumnSort",function(){return e.clearCache()}),this.addHook("beforeRender",function(t){return e.onBeforeRender(t)}),this.addHook("beforeRowMove",function(t,n){return e.onBeforeRowMove(t,n)}),this.addHook("modifyRowHeight",function(t,n){return e.getRowHeight(n,t)}),this.addHook("modifyColumnHeaderHeight",function(){return e.getColumnHeaderHeight()}),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"calculateRowsHeight",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countRows()-1},t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{from:0,to:this.hot.countCols()-1},o=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("number"==typeof e&&(e={from:e,to:e}),"number"==typeof n&&(n={from:n,to:n}),null!==this.hot.getColHeader(0)){var r=this.samplesGenerator.generateRowSamples(-1,n);this.ghostTable.addColumnHeadersRow(r.get(-1))}(0,d.rangeEach)(e.from,e.to,function(e){(o||void 0===t.heights[e])&&t.samplesGenerator.generateRowSamples(e,n).forEach(function(e,n){t.ghostTable.addRow(n,e)})}),this.ghostTable.rows.length&&(this.ghostTable.getHeights(function(e,n){t.heights[e]=n}),this.ghostTable.clean())}},{key:"calculateAllRowsHeight",value:function(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{from:0,to:this.hot.countCols()-1},o=0,r=this.hot.countRows()-1,i=null;this.inProgress=!0;var a=function a(){if(!e.hot)return(0,s.cancelAnimationFrame)(i),void(e.inProgress=!1);e.calculateRowsHeight({from:o,to:Math.min(o+t.CALCULATION_STEP,r)},n),(o=o+t.CALCULATION_STEP+1)<r?i=(0,s.requestAnimationFrame)(a):((0,s.cancelAnimationFrame)(i),e.inProgress=!1,e.hot.view.wt.wtOverlays.adjustElementsSize(!0),e.hot.view.wt.wtOverlays.leftOverlay.needFullRender&&e.hot.view.wt.wtOverlays.leftOverlay.clone.draw())};this.firstCalculation&&this.getSyncCalculationLimit()&&(this.calculateRowsHeight({from:0,to:this.getSyncCalculationLimit()},n),this.firstCalculation=!1,o=this.getSyncCalculationLimit()+1),o<r?a():(this.inProgress=!1,this.hot.view.wt.wtOverlays.adjustElementsSize(!1))}},{key:"setSamplingOptions",value:function(){var e=this.hot.getSettings().autoRowSize,t=e&&(0,c.hasOwnProperty)(e,"samplingRatio")?this.hot.getSettings().autoRowSize.samplingRatio:void 0,n=e&&(0,c.hasOwnProperty)(e,"allowSampleDuplicates")?this.hot.getSettings().autoRowSize.allowSampleDuplicates:void 0;t&&!isNaN(t)&&this.samplesGenerator.setSampleCount(parseInt(t,10)),n&&this.samplesGenerator.setAllowDuplicates(n)}},{key:"recalculateAllRowsHeight",value:function(){(0,l.isVisible)(this.hot.view.wt.wtTable.TABLE)&&(this.clearCache(),this.calculateAllRowsHeight())}},{key:"getSyncCalculationLimit",value:function(){var e=t.SYNC_CALCULATION_LIMIT,n=this.hot.countRows()-1;return(0,c.isObject)(this.hot.getSettings().autoRowSize)&&(e=this.hot.getSettings().autoRowSize.syncLimit,(0,p.isPercentValue)(e)?e=(0,d.valueAccordingPercent)(n,e):e>>=0),Math.min(e,n)}},{key:"getRowHeight",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:void 0,n=t;return void 0!==this.heights[e]&&this.heights[e]>(t||0)&&(n=this.heights[e]),n}},{key:"getColumnHeaderHeight",value:function(){return this.heights[-1]}},{key:"getFirstVisibleRow",value:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getFirstVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getFirstRenderedRow():-1}},{key:"getLastVisibleRow",value:function(){var e=this.hot.view.wt;return e.wtViewport.rowsVisibleCalculator?e.wtTable.getLastVisibleRow():e.wtViewport.rowsRenderCalculator?e.wtTable.getLastRenderedRow():-1}},{key:"clearCache",value:function(){this.heights.length=0,this.heights[-1]=void 0}},{key:"clearCacheByRange",value:function(e){var t=this;"number"==typeof e&&(e={from:e,to:e}),(0,d.rangeEach)(Math.min(e.from,e.to),Math.max(e.from,e.to),function(e){t.heights[e]=void 0})}},{key:"isNeedRecalculate",value:function(){return!!(0,a.arrayFilter)(this.heights,function(e){return void 0===e}).length}},{key:"onBeforeRender",value:function(){var e=this.hot.renderCall;this.calculateRowsHeight({from:this.getFirstVisibleRow(),to:this.getLastVisibleRow()},void 0,e);var t=this.hot.getSettings().fixedRowsBottom;if(t){var n=this.hot.countRows()-1;this.calculateRowsHeight({from:n-t,to:n})}this.isNeedRecalculate()&&!this.inProgress&&this.calculateAllRowsHeight()}},{key:"onBeforeRowMove",value:function(e,t){this.clearCacheByRange({from:e,to:t}),this.calculateAllRowsHeight()}},{key:"onBeforeRowResize",value:function(e,t,n){return n&&(this.calculateRowsHeight(e,void 0,!0),t=this.getRowHeight(e)),t}},{key:"onAfterLoadData",value:function(){var e=this;this.hot.view?this.recalculateAllRowsHeight():setTimeout(function(){e.hot&&e.recalculateAllRowsHeight()},0)}},{key:"onBeforeChange",value:function(e){var t=null;1===e.length?t=e[0][0]:e.length>1&&(t={from:e[0][0],to:e[e.length-1][0]}),null!==t&&this.clearCacheByRange(t)}},{key:"destroy",value:function(){this.ghostTable.clean(),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,h.registerPlugin)("autoRowSize",g),t.default=g},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=h(n(12)),a=h(n(8)),s=n(0),l=h(n(4)),u=n(5),c=n(11),d=n(214);function h(e){return e&&e.__esModule?e:{default:e}}a.default.getSingleton().register("modifyAutofillRange"),a.default.getSingleton().register("beforeAutofill");var f=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.eventManager=new l.default(n),n.addingStarted=!1,n.mouseDownOnCellCorner=!1,n.mouseDragOutside=!1,n.handleDraggedCells=0,n.directions=[],n.autoInsertRow=!1,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().fillHandle}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.mapSettings(),this.registerEvents(),this.addHook("afterOnCellCornerMouseDown",function(t){return e.onAfterCellCornerMouseDown(t)}),this.addHook("afterOnCellCornerDblClick",function(t){return e.onCellCornerDblClick(t)}),this.addHook("beforeOnCellMouseOver",function(t,n,o){return e.onBeforeCellMouseOver(n)}),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.clearMappedSettings(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"getSelectionData",value:function(){var e={from:this.hot.getSelectedRange().from,to:this.hot.getSelectedRange().to};return this.hot.getData(e.from.row,e.from.col,e.to.row,e.to.col)}},{key:"fillIn",value:function(){if(this.hot.view.wt.selections.fill.isEmpty())return!1;var e=this.hot.view.wt.selections.fill.getCorners();this.resetSelectionOfDraggedArea();var t=this.getCornersOfSelectedCells(),n=(0,d.getDragDirectionAndRange)(t,e),o=n.directionOfDrag,r=n.startOfDragCoords,i=n.endOfDragCoords;if(this.hot.runHooks("modifyAutofillRange",t,e),r&&r.row>-1&&r.col>-1){var a=this.getSelectionData(),s=(0,d.getDeltas)(r,i,a,o);this.hot.runHooks("beforeAutofill",r,i,a),this.hot.populateFromArray(r.row,r.col,a,i.row,i.col,this.pluginName+".fill",null,o,s),this.setSelection(e)}else this.hot.selection.refreshBorders();return!0}},{key:"reduceSelectionAreaIfNeeded",value:function(e){return e.row<0&&(e.row=0),e.col<0&&(e.col=0),e}},{key:"getCoordsOfDragAndDropBorders",value:function(e){var t=this.hot.getSelectedRange().getTopLeftCorner(),n=this.hot.getSelectedRange().getBottomRightCorner(),o=void 0;if(this.directions.includes(d.DIRECTIONS.vertical)&&(n.row<e.row||t.row>e.row))o=new c.CellCoords(e.row,n.col);else{if(!this.directions.includes(d.DIRECTIONS.horizontal))return;o=new c.CellCoords(n.row,e.col)}return this.reduceSelectionAreaIfNeeded(o)}},{key:"showBorder",value:function(e){var t=this.getCoordsOfDragAndDropBorders(e);t&&this.redrawBorders(t)}},{key:"addRow",value:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.alter("insert_row",void 0,1,e.pluginName+".fill"),e.addingStarted=!1},200))}},{key:"addNewRowIfNeeded",value:function(){if(this.hot.view.wt.selections.fill.cellRange&&!1===this.addingStarted&&this.autoInsertRow){var e=this.hot.getSelected(),t=this.hot.view.wt.selections.fill.getCorners(),n=this.hot.countRows();e[2]<n-1&&t[2]===n-1&&(this.addingStarted=!0,this.addRow())}}},{key:"getCornersOfSelectedCells",value:function(){return this.hot.selection.isMultiple()?this.hot.view.wt.selections.area.getCorners():this.hot.view.wt.selections.current.getCorners()}},{key:"getIndexOfLastAdjacentFilledInRow",value:function(e){for(var t=this.hot.getData(),n=this.hot.countRows(),o=void 0,r=e[2]+1;r<n;r++){for(var i=e[1];i<=e[3];i++)if(t[r][i])return-1;var a=t[r][e[1]-1],s=t[r][e[3]+1];(a||s)&&(o=r)}return o}},{key:"addSelectionFromStartAreaToSpecificRowIndex",value:function(e,t){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(new c.CellCoords(e[0],e[1])),this.hot.view.wt.selections.fill.add(new c.CellCoords(t,e[3]))}},{key:"setSelection",value:function(e){this.hot.selection.setRangeStart(new c.CellCoords(e[0],e[1])),this.hot.selection.setRangeEnd(new c.CellCoords(e[2],e[3]))}},{key:"selectAdjacent",value:function(){var e=this.getCornersOfSelectedCells(),t=this.getIndexOfLastAdjacentFilledInRow(e);return-1!==t&&(this.addSelectionFromStartAreaToSpecificRowIndex(e,t),!0)}},{key:"resetSelectionOfDraggedArea",value:function(){this.handleDraggedCells=0,this.hot.view.wt.selections.fill.clear()}},{key:"redrawBorders",value:function(e){this.hot.view.wt.selections.fill.clear(),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().from),this.hot.view.wt.selections.fill.add(this.hot.getSelectedRange().to),this.hot.view.wt.selections.fill.add(e),this.hot.view.render()}},{key:"getIfMouseWasDraggedOutside",value:function(e){var t=(0,s.offset)(this.hot.table).top-(window.pageYOffset||document.documentElement.scrollTop)+(0,s.outerHeight)(this.hot.table),n=(0,s.offset)(this.hot.table).left-(window.pageXOffset||document.documentElement.scrollLeft)+(0,s.outerWidth)(this.hot.table);return e.clientY>t&&e.clientX<=n}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()}),this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)})}},{key:"onCellCornerDblClick",value:function(){this.selectAdjacent()&&this.fillIn()}},{key:"onAfterCellCornerMouseDown",value:function(){this.handleDraggedCells=1,this.mouseDownOnCellCorner=!0}},{key:"onBeforeCellMouseOver",value:function(e){this.mouseDownOnCellCorner&&!this.hot.view.isMouseDown()&&this.handleDraggedCells&&(this.handleDraggedCells++,this.showBorder(e),this.addNewRowIfNeeded())}},{key:"onMouseUp",value:function(){this.handleDraggedCells&&(this.handleDraggedCells>1&&this.fillIn(),this.handleDraggedCells=0,this.mouseDownOnCellCorner=!1)}},{key:"onMouseMove",value:function(e){var t=this.getIfMouseWasDraggedOutside(e);!1===this.addingStarted&&this.handleDraggedCells>0&&t?(this.mouseDragOutside=!0,this.addingStarted=!0):this.mouseDragOutside=!1,this.mouseDragOutside&&this.autoInsertRow&&this.addRow()}},{key:"clearMappedSettings",value:function(){this.directions.length=0,this.autoInsertRow=!1}},{key:"mapSettings",value:function(){var e=(0,d.getMappedFillHandleSetting)(this.hot.getSettings().fillHandle);this.directions=e.directions,this.autoInsertRow=e.autoInsertRow}},{key:"destroy",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,u.registerPlugin)("autofill",f),t.default=f},function(e,t,n){"use strict";t.__esModule=!0,t.DIRECTIONS=void 0,t.getDeltas=function(e,t,n,o){var r=n.length,i=n?n[0].length:0,a=[],s=t.row-e.row,l=t.col-e.col;if(-1!==["down","up"].indexOf(o)){for(var u=[],c=0;c<=l;c++){var d=parseInt(n[0][c],10),h=parseInt(n[r-1][c],10),f=("down"===o?h-d:d-h)/(r-1)||0;u.push(f)}a.push(u)}if(-1!==["right","left"].indexOf(o))for(var p=0;p<=s;p++){var m=parseInt(n[p][0],10),g=parseInt(n[p][i-1],10),v=("right"===o?g-m:m-g)/(i-1)||0;a.push([v])}return a},t.getDragDirectionAndRange=function(e,t){var n=void 0,o=void 0,r=void 0;return t[0]===e[0]&&t[1]<e[1]?(r="left",n=new i.CellCoords(t[0],t[1]),o=new i.CellCoords(t[2],e[1]-1)):t[0]===e[0]&&t[3]>e[3]?(r="right",n=new i.CellCoords(t[0],e[3]+1),o=new i.CellCoords(t[2],t[3])):t[0]<e[0]&&t[1]===e[1]?(r="up",n=new i.CellCoords(t[0],t[1]),o=new i.CellCoords(e[0]-1,t[3])):t[2]>e[2]&&t[1]===e[1]&&(r="down",n=new i.CellCoords(e[2]+1,t[1]),o=new i.CellCoords(t[2],t[3])),{directionOfDrag:r,startOfDragCoords:n,endOfDragCoords:o}},t.getMappedFillHandleSetting=function(e){var t={};return!0===e?(t.directions=Object.keys(a),t.autoInsertRow=!0):(0,o.isObject)(e)?((0,r.isDefined)(e.autoInsertRow)?e.direction===a.horizontal?t.autoInsertRow=!1:t.autoInsertRow=e.autoInsertRow:t.autoInsertRow=!1,(0,r.isDefined)(e.direction)?t.directions=[e.direction]:t.directions=Object.keys(a)):"string"==typeof e?(t.directions=[e],t.autoInsertRow=!0):(t.directions=[],t.autoInsertRow=!1),t};var o=n(2),r=n(20),i=n(11),a=t.DIRECTIONS={horizontal:"horizontal",vertical:"vertical"}},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},a=m(n(62)),s=n(0),l=n(1),u=n(20),c=n(2),d=m(n(12)),h=n(5),f=m(n(270)),p=m(n(8));function m(e){return e&&e.__esModule?e:{default:e}}function g(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}p.default.getSingleton().register("beforeColumnSort"),p.default.getSingleton().register("afterColumnSort");var v=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.sortIndicators=[],n.lastSortedColumn=null,n.sortEmptyCells=!1,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,d.default),r(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().columnSorting}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.setPluginOptions();var n=this;this.hot.sortIndex=[],this.hot.sort=function(){var e=Array.prototype.slice.call(arguments);return n.sortByColumn.apply(n,g(e))},void 0===this.hot.getSettings().observeChanges&&this.enableObserveChangesPlugin(),this.addHook("afterTrimRow",function(t){return e.sort()}),this.addHook("afterUntrimRow",function(t){return e.sort()}),this.addHook("modifyRow",function(t){return e.translateRow(t)}),this.addHook("unmodifyRow",function(t){return e.untranslateRow(t)}),this.addHook("afterUpdateSettings",function(){return e.onAfterUpdateSettings()}),this.addHook("afterGetColHeader",function(t,n){return e.getColHeader(t,n)}),this.addHook("afterOnCellMouseDown",function(t,n){return e.onAfterOnCellMouseDown(t,n)}),this.addHook("afterCreateRow",function(){n.afterCreateRow.apply(n,arguments)}),this.addHook("afterRemoveRow",function(){n.afterRemoveRow.apply(n,arguments)}),this.addHook("afterInit",function(){return e.sortBySettings()}),this.addHook("afterLoadData",function(){e.hot.sortIndex=[],e.hot.view&&e.sortBySettings()}),this.hot.view&&this.sortBySettings(),i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"disablePlugin",value:function(){this.hot.sort=void 0,i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onAfterUpdateSettings",value:function(){this.sortBySettings()}},{key:"sortBySettings",value:function(){var e=this.hot.getSettings().columnSorting,t=this.loadSortingState(),n=void 0,o=void 0;void 0===t?(n=e.column,o=e.sortOrder):(n=t.sortColumn,o=t.sortOrder),"number"==typeof n&&(this.lastSortedColumn=n,this.sortByColumn(n,o))}},{key:"setSortingColumn",value:function(e,t){if(void 0===e)return this.hot.sortColumn=void 0,void(this.hot.sortOrder=void 0);this.hot.sortColumn===e&&void 0===t?!1===this.hot.sortOrder?this.hot.sortOrder=void 0:this.hot.sortOrder=!this.hot.sortOrder:this.hot.sortOrder=void 0===t||t,this.hot.sortColumn=e}},{key:"sortByColumn",value:function(e,t){this.setSortingColumn(e,t),void 0!==this.hot.sortColumn&&(!1!==this.hot.runHooks("beforeColumnSort",this.hot.sortColumn,this.hot.sortOrder)&&this.sort(),this.updateOrderClass(),this.updateSortIndicator(),this.hot.runHooks("afterColumnSort",this.hot.sortColumn,this.hot.sortOrder),this.hot.render(),this.saveSortingState())}},{key:"saveSortingState",value:function(){var e={};void 0!==this.hot.sortColumn&&(e.sortColumn=this.hot.sortColumn),void 0!==this.hot.sortOrder&&(e.sortOrder=this.hot.sortOrder),((0,c.hasOwnProperty)(e,"sortColumn")||(0,c.hasOwnProperty)(e,"sortOrder"))&&this.hot.runHooks("persistentStateSave","columnSorting",e)}},{key:"loadSortingState",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","columnSorting",e),e.value}},{key:"updateOrderClass",value:function(){var e=void 0;!0===this.hot.sortOrder?e="ascending":!1===this.hot.sortOrder&&(e="descending"),this.sortOrderClass=e}},{key:"enableObserveChangesPlugin",value:function(){var e=this;this.hot._registerTimeout(setTimeout(function(){e.hot.updateSettings({observeChanges:!0})},0))}},{key:"defaultSort",value:function(e,t){return function(n,o){return"string"==typeof n[1]&&(n[1]=n[1].toLowerCase()),"string"==typeof o[1]&&(o[1]=o[1].toLowerCase()),n[1]===o[1]?0:(0,u.isEmpty)(n[1])?(0,u.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1:(0,u.isEmpty)(o[1])?(0,u.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1:isNaN(n[1])&&!isNaN(o[1])?e?1:-1:!isNaN(n[1])&&isNaN(o[1])?e?-1:1:(isNaN(n[1])||isNaN(o[1])||(n[1]=parseFloat(n[1]),o[1]=parseFloat(o[1])),n[1]<o[1]?e?-1:1:n[1]>o[1]?e?1:-1:0)}}},{key:"dateSort",value:function(e,t){return function(n,o){if(n[1]===o[1])return 0;if((0,u.isEmpty)(n[1]))return(0,u.isEmpty)(o[1])?0:t.columnSorting.sortEmptyCells&&e?-1:1;if((0,u.isEmpty)(o[1]))return(0,u.isEmpty)(n[1])?0:t.columnSorting.sortEmptyCells&&e?1:-1;var r=(0,a.default)(n[1],t.dateFormat),i=(0,a.default)(o[1],t.dateFormat);return r.isValid()?i.isValid()?i.isAfter(r)?e?-1:1:i.isBefore(r)?e?1:-1:0:-1:1}}},{key:"numericSort",value:function(e,t){return function(n,o){var r=parseFloat(n[1]),i=parseFloat(o[1]);if(r===i||isNaN(r)&&isNaN(i))return 0;if(t.columnSorting.sortEmptyCells){if((0,u.isEmpty)(n[1]))return e?-1:1;if((0,u.isEmpty)(o[1]))return e?1:-1}return isNaN(r)?1:isNaN(i)?-1:r<i?e?-1:1:r>i?e?1:-1:0}}},{key:"sort",value:function(){if(void 0!==this.hot.sortOrder){var e=this.hot.getCellMeta(0,this.hot.sortColumn),t=this.hot.countEmptyRows(),n=void 0;this.hot.sortingEnabled=!1,this.hot.sortIndex.length=0,void 0===e.columnSorting.sortEmptyCells&&(e.columnSorting={sortEmptyCells:this.sortEmptyCells});for(var o=0,r=this.hot.getSettings().maxRows===Number.POSITIVE_INFINITY?this.hot.countRows()-this.hot.getSettings().minSpareRows:this.hot.countRows()-t;o<r;o++)this.hot.sortIndex.push([o,this.hot.getDataAtCell(o,this.hot.sortColumn)]);if(e.sortFunction)n=e.sortFunction;else switch(e.type){case"date":n=this.dateSort;break;case"numeric":n=this.numericSort;break;default:n=this.defaultSort}(0,f.default)(this.hot.sortIndex,n(this.hot.sortOrder,e));for(var i=this.hot.sortIndex.length;i<this.hot.countRows();i++)this.hot.sortIndex.push([i,this.hot.getDataAtCell(i,this.hot.sortColumn)]);this.hot.sortingEnabled=!0}else this.hot.sortIndex.length=0}},{key:"updateSortIndicator",value:function(){if(void 0!==this.hot.sortOrder){var e=this.hot.getCellMeta(0,this.hot.sortColumn);this.sortIndicators[this.hot.sortColumn]=e.sortIndicator}}},{key:"translateRow",value:function(e){return this.hot.sortingEnabled&&void 0!==this.hot.sortOrder&&this.hot.sortIndex&&this.hot.sortIndex.length&&this.hot.sortIndex[e]?this.hot.sortIndex[e][0]:e}},{key:"untranslateRow",value:function(e){if(this.hot.sortingEnabled&&this.hot.sortIndex&&this.hot.sortIndex.length)for(var t=0;t<this.hot.sortIndex.length;t++)if(this.hot.sortIndex[t][0]==e)return t}},{key:"getColHeader",value:function(e,t){if(e<0||!t.parentNode)return!1;var n=t.querySelector(".colHeader"),o=(t.getAttribute("colspan"),t.parentNode.parentNode.childNodes),r=Array.prototype.indexOf.call(o,t.parentNode);r-=o.length,n&&(this.hot.getSettings().columnSorting&&e>=0&&-1===r&&(0,s.addClass)(n,"columnSorting"),(0,s.removeClass)(n,"descending"),(0,s.removeClass)(n,"ascending"),this.sortIndicators[e]&&e===this.hot.sortColumn&&("ascending"===this.sortOrderClass?(0,s.addClass)(n,"ascending"):"descending"===this.sortOrderClass&&(0,s.addClass)(n,"descending")))}},{key:"isSorted",value:function(){return void 0!==this.hot.sortColumn}},{key:"afterCreateRow",value:function(e,t){if(this.isSorted()){for(var n=0;n<this.hot.sortIndex.length;n++)this.hot.sortIndex[n][0]>=e&&(this.hot.sortIndex[n][0]+=t);for(var o=0;o<t;o++)this.hot.sortIndex.splice(e+o,0,[e+o,this.hot.getSourceData()[e+o][this.hot.sortColumn+this.hot.colOffset()]]);this.saveSortingState()}}},{key:"afterRemoveRow",value:function(e,t){if(this.isSorted()){var n=this.hot.sortIndex.splice(e,t);n=(0,l.arrayMap)(n,function(e){return e[0]}),this.hot.sortIndex=(0,l.arrayMap)(this.hot.sortIndex,function(e,t){var o=function(e){return(0,l.arrayReduce)(n,function(t,n){return e>n&&t++,t},0)}(e[0]);return o&&(e[0]-=o),e}),this.saveSortingState()}}},{key:"setPluginOptions",value:function(){var e=this.hot.getSettings().columnSorting;"object"===(void 0===e?"undefined":o(e))?this.sortEmptyCells=e.sortEmptyCells||!1:this.sortEmptyCells=!1}},{key:"onAfterOnCellMouseDown",value:function(e,t){t.row>-1||(0,s.hasClass)(e.realTarget,"columnSorting")&&(t.col!==this.lastSortedColumn&&(this.hot.sortOrder=!0),this.lastSortedColumn=t.col,this.sortByColumn(t.col))}}]),t}();(0,h.registerPlugin)("columnSorting",v),t.default=v},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=function(){function e(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.editor=this.createEditor(),this.editorStyle=this.editor.style,this.hidden=!0,this.hide()}return o(e,null,[{key:"CLASS_EDITOR_CONTAINER",get:function(){return"htCommentsContainer"}},{key:"CLASS_EDITOR",get:function(){return"htComments"}},{key:"CLASS_INPUT",get:function(){return"htCommentTextArea"}},{key:"CLASS_CELL",get:function(){return"htCommentCell"}}]),o(e,[{key:"setPosition",value:function(e,t){this.editorStyle.left=e+"px",this.editorStyle.top=t+"px"}},{key:"setSize",value:function(e,t){if(e&&t){var n=this.getInputElement();n.style.width=e+"px",n.style.height=t+"px"}}},{key:"resetSize",value:function(){var e=this.getInputElement();e.style.width="",e.style.height=""}},{key:"setReadOnlyState",value:function(e){this.getInputElement().readOnly=e}},{key:"show",value:function(){this.editorStyle.display="block",this.hidden=!1}},{key:"hide",value:function(){this.editorStyle.display="none",this.hidden=!0}},{key:"isVisible",value:function(){return"block"===this.editorStyle.display}},{key:"setValue",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";e=e||"",this.getInputElement().value=e}},{key:"getValue",value:function(){return this.getInputElement().value}},{key:"isFocused",value:function(){return document.activeElement===this.getInputElement()}},{key:"focus",value:function(){this.getInputElement().focus()}},{key:"createEditor",value:function(){var t,n=document.querySelector("."+e.CLASS_EDITOR_CONTAINER),o=void 0;return n||(n=document.createElement("div"),(0,r.addClass)(n,e.CLASS_EDITOR_CONTAINER),document.body.appendChild(n)),o=document.createElement("div"),(0,r.addClass)(o,e.CLASS_EDITOR),t=document.createElement("textarea"),(0,r.addClass)(t,e.CLASS_INPUT),o.appendChild(t),n.appendChild(o),o}},{key:"getInputElement",value:function(){return this.editor.querySelector("."+e.CLASS_INPUT)}},{key:"destroy",value:function(){this.editor.parentNode.removeChild(this.editor),this.editor=null,this.editorStyle=null}}]),e}();t.default=i},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=n(0),a=n(2),s=n(35),l=p(n(4)),u=n(11),c=n(5),d=p(n(12)),h=p(n(216)),f=n(17);function p(e){return e&&e.__esModule?e:{default:e}}function m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n(294);var g=new WeakMap,v=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.editor=null,n.eventManager=null,n.range={},n.mouseDown=!1,n.contextMenuEvent=!1,n.timer=null,n.displayDelay=250,g.set(n,{tempEditorDimensions:{},cellBelowCursor:null}),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,d.default),o(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().comments}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.editor||(this.editor=new h.default),this.eventManager||(this.eventManager=new l.default(this)),this.addHook("afterContextMenuDefaultOptions",function(t){return e.addToContextMenu(t)}),this.addHook("afterRenderer",function(t,n,o,r,i,a){return e.onAfterRenderer(t,a)}),this.addHook("afterScrollHorizontally",function(){return e.hide()}),this.addHook("afterScrollVertically",function(){return e.hide()}),this.addHook("afterBeginEditing",function(t){return e.onAfterBeginEditing(t)}),this.registerListeners(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerListeners",value:function(){var e=this;this.eventManager.addEventListener(document,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(document,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(document,"mouseup",function(t){return e.onMouseUp(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"blur",function(t){return e.onEditorBlur(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mousedown",function(t){return e.onEditorMouseDown(t)}),this.eventManager.addEventListener(this.editor.getInputElement(),"mouseup",function(t){return e.onEditorMouseUp(t)})}},{key:"setRange",value:function(e){this.range=e}},{key:"clearRange",value:function(){this.range={}}},{key:"targetIsCellWithComment",value:function(e){var t=(0,i.closest)(e.target,"TD","TBODY");return!!(t&&(0,i.hasClass)(t,"htCommentCell")&&(0,i.closest)(t,[this.hot.rootElement]))}},{key:"targetIsCommentTextArea",value:function(e){return this.editor.getInputElement()===e.target}},{key:"setComment",value:function(e){if(!this.range.from)throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var t=this.editor.getValue(),n="";null!=e?n=e:null!=t&&(n=t);var o=this.range.from.row,r=this.range.from.col;this.updateCommentMeta(o,r,m({},"value",n)),this.hot.render()}},{key:"setCommentAtCell",value:function(e,t,n){this.setRange({from:new u.CellCoords(e,t)}),this.setComment(n)}},{key:"removeComment",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(!this.range.from)throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');this.hot.setCellMeta(this.range.from.row,this.range.from.col,"comment",void 0),e&&this.hot.render(),this.hide()}},{key:"removeCommentAtCell",value:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2];this.setRange({from:new u.CellCoords(e,t)}),this.removeComment(n)}},{key:"getComment",value:function(){var e=this.range.from.row,t=this.range.from.col;return this.getCommentMeta(e,t,"value")}},{key:"getCommentAtCell",value:function(e,t){return this.getCommentMeta(e,t,"value")}},{key:"show",value:function(){if(!this.range.from)throw new Error('Before using this method, first set cell range (hot.getPlugin("comment").setRange())');var e=this.hot.getCellMeta(this.range.from.row,this.range.from.col);return this.refreshEditor(!0),this.editor.setValue(e.comment?e.comment.value:""),this.editor.hidden&&this.editor.show(),!0}},{key:"showAtCell",value:function(e,t){return this.setRange({from:new u.CellCoords(e,t)}),this.show()}},{key:"hide",value:function(){this.editor.hidden||this.editor.hide()}},{key:"refreshEditor",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(e||this.range.from&&this.editor.isVisible()){var t=(0,i.getScrollableElement)(this.hot.view.wt.wtTable.TABLE),n=this.hot.view.wt.wtTable.getCell(this.range.from),o=this.range.from.row,r=this.range.from.col,a=(0,i.offset)(n),s=this.hot.view.wt.wtTable.getStretchedColumnWidth(r),l=a.top<0?0:a.top,u=a.left;this.hot.view.wt.wtViewport.hasVerticalScroll()&&t!==window&&(l-=this.hot.view.wt.wtOverlays.topOverlay.getScrollPosition()),this.hot.view.wt.wtViewport.hasHorizontalScroll()&&t!==window&&(u-=this.hot.view.wt.wtOverlays.leftOverlay.getScrollPosition());var c=u+s,d=l,h=this.getCommentMeta(o,r,"style"),f=this.getCommentMeta(o,r,"readOnly");h?this.editor.setSize(h.width,h.height):this.editor.resetSize(),this.editor.setReadOnlyState(f),this.editor.setPosition(c,d)}}},{key:"checkSelectionCommentsConsistency",value:function(){var e=this.hot.getSelectedRange();if(!e)return!1;var t=!1,n=e.from;return this.getCommentMeta(n.row,n.col,"value")&&(t=!0),t}},{key:"updateCommentMeta",value:function(e,t,n){var o=this.hot.getCellMeta(e,t).comment,r=void 0;o?(r=(0,a.deepClone)(o),(0,a.deepExtend)(r,n)):r=n,this.hot.setCellMeta(e,t,"comment",r)}},{key:"getCommentMeta",value:function(e,t,n){var o=this.hot.getCellMeta(e,t);if(o.comment)return o.comment[n]}},{key:"onMouseDown",value:function(e){if(this.mouseDown=!0,this.hot.view&&this.hot.view.wt){if(!this.contextMenuEvent&&!this.targetIsCommentTextArea(e)){var t=(0,i.closest)(e.target,"TD","TBODY"),n=null;t&&(n=this.hot.view.wt.wtTable.getCoords(t)),(!t||this.range.from&&n&&(this.range.from.row!==n.row||this.range.from.col!==n.col))&&this.hide()}this.contextMenuEvent=!1}}},{key:"onMouseOver",value:function(e){var t=this;if(!this.mouseDown&&!this.editor.isFocused()){var n=g.get(this);n.cellBelowCursor=document.elementFromPoint(e.clientX,e.clientY),(0,s.debounce)(function(){if(!(0,i.hasClass)(e.target,"wtBorder")&&n.cellBelowCursor===e.target&&t.editor)if(t.targetIsCellWithComment(e)){var o=t.hot.view.wt.wtTable.getCoords(e.target),r={from:new u.CellCoords(o.row,o.col)};t.setRange(r),t.show()}else!(0,i.isChildOf)(e.target,document)||t.targetIsCommentTextArea(e)||t.editor.isFocused()||t.hide()},this.displayDelay)()}}},{key:"onMouseUp",value:function(e){this.mouseDown=!1}},{key:"onAfterRenderer",value:function(e,t){t.comment&&t.comment.value&&(0,i.addClass)(e,t.commentedCellClassName)}},{key:"onEditorBlur",value:function(e){this.setComment()}},{key:"onEditorMouseDown",value:function(e){g.get(this).tempEditorDimensions={width:(0,i.outerWidth)(e.target),height:(0,i.outerHeight)(e.target)}}},{key:"onEditorMouseUp",value:function(e){var t=g.get(this),n=(0,i.outerWidth)(e.target),o=(0,i.outerHeight)(e.target);n===t.tempEditorDimensions.width+1&&o===t.tempEditorDimensions.height+2||this.updateCommentMeta(this.range.from.row,this.range.from.col,m({},"style",{width:n,height:o}))}},{key:"onContextMenuAddComment",value:function(){var e=this,t=this.hot.getSelectedRange();this.contextMenuEvent=!0,this.setRange({from:t.from}),this.show(),setTimeout(function(){e.hot&&(e.hot.deselectCell(),e.editor.focus())},10)}},{key:"onContextMenuRemoveComment",value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;t<=e.end.row;t++)for(var n=e.start.col;n<=e.end.col;n++)this.removeCommentAtCell(t,n,!1);this.hot.render()}},{key:"onContextMenuMakeReadOnly",value:function(e){this.contextMenuEvent=!0;for(var t=e.start.row;t<=e.end.row;t++)for(var n=e.start.col;n<=e.end.col;n++){var o=!!this.getCommentMeta(t,n,"readOnly");this.updateCommentMeta(t,n,m({},"readOnly",!o))}}},{key:"addToContextMenu",value:function(e){var t=this;e.items.push((0,c.getPlugin)(this.hot,"contextMenu").constructor.SEPARATOR,{key:"commentsAddEdit",name:function(){return t.checkSelectionCommentsConsistency()?"Edit comment":"Add comment"},callback:function(){return t.onContextMenuAddComment()},disabled:function(){return!(this.getSelected()&&!this.selection.selectedHeader.corner)}},{key:"commentsRemove",name:function(){return"Delete comment"},callback:function(e,n){return t.onContextMenuRemoveComment(n)},disabled:function(){return t.hot.selection.selectedHeader.corner}},{key:"commentsReadOnly",name:function(){var e=this,t="Read only comment";return(0,f.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).comment;if(o&&(o=o.readOnly),o)return!0})&&(t=(0,f.markLabelAsSelected)(t)),t},callback:function(e,n){return t.onContextMenuMakeReadOnly(n)},disabled:function(){return t.hot.selection.selectedHeader.corner||!t.checkSelectionCommentsConsistency()}})}},{key:"onAfterBeginEditing",value:function(e,t){this.hide()}},{key:"destroy",value:function(){this.editor&&this.editor.destroy(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,c.registerPlugin)("comments",v),t.default=v},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(1),i=n(2),a=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this.commands={},this.commonCallback=null}return o(e,[{key:"registerCommand",value:function(e,t){this.commands[e]=t}},{key:"setCommonCallback",value:function(e){this.commonCallback=e}},{key:"execute",value:function(e){for(var t=this,n=arguments.length,o=Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];var l=e.split(":");e=l[0];var u=2===l.length?l[1]:null,c=this.commands[e];if(!c)throw new Error("Menu command '"+e+"' not exists.");if(u&&c.submenu&&(c=s(u,c.submenu.items)),!0!==c.disabled&&("function"!=typeof c.disabled||!0!==c.disabled.call(this.hot))&&!(0,i.hasOwnProperty)(c,"submenu")){var d=[];"function"==typeof c.callback&&d.push(c.callback),"function"==typeof this.commonCallback&&d.push(this.commonCallback),o.unshift(l.join(":")),(0,r.arrayEach)(d,function(e){return e.apply(t.hot,o)})}}}]),e}();function s(e,t){var n=void 0;return(0,r.arrayEach)(t,function(t){var o=t.key?t.key.split(":"):null;if(Array.isArray(o)&&o[1]===e)return n=t,!1}),n}t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=g(n(12)),a=g(n(8)),s=n(1),l=g(n(218)),u=g(n(4)),c=g(n(221)),d=g(n(222)),h=n(5),f=n(7),p=n(0),m=n(50);function g(e){return e&&e.__esModule?e:{default:e}}n(295),a.default.getSingleton().register("afterContextMenuDefaultOptions"),a.default.getSingleton().register("afterContextMenuShow"),a.default.getSingleton().register("afterContextMenuHide"),a.default.getSingleton().register("afterContextMenuExecute");var v=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.eventManager=new u.default(n),n.commandExecutor=new l.default(n.hot),n.itemsFactory=null,n.menu=null,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),r(t,null,[{key:"DEFAULT_ITEMS",get:function(){return[m.ROW_ABOVE,m.ROW_BELOW,m.SEPARATOR,m.COLUMN_LEFT,m.COLUMN_RIGHT,m.SEPARATOR,m.REMOVE_ROW,m.REMOVE_COLUMN,m.SEPARATOR,m.UNDO,m.REDO,m.SEPARATOR,m.READ_ONLY,m.SEPARATOR,m.ALIGNMENT]}}]),r(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().contextMenu}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.itemsFactory=new c.default(this.hot,t.DEFAULT_ITEMS);var n=this.hot.getSettings().contextMenu,r={items:this.itemsFactory.getItems(n)};this.registerEvents(),"function"==typeof n.callback&&this.commandExecutor.setCommonCallback(n.callback),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this),this.callOnPluginsReady(function(){e.hot.runHooks("afterContextMenuDefaultOptions",r),e.itemsFactory.setPredefinedItems(r.items);var t=e.itemsFactory.getItems(n);e.menu=new d.default(e.hot,{className:"htContextMenu",keepInViewport:!0}),e.hot.runHooks("beforeContextMenuSetItems",t),e.menu.setMenuItems(t),e.menu.addLocalHook("afterOpen",function(){return e.onMenuAfterOpen()}),e.menu.addLocalHook("afterClose",function(){return e.onMenuAfterClose()}),e.menu.addLocalHook("executeCommand",function(){for(var t=arguments.length,n=Array(t),o=0;o<t;o++)n[o]=arguments[o];return e.executeCommand.apply(e,n)}),(0,s.arrayEach)(t,function(t){return e.commandExecutor.registerCommand(t.key,t)})})}}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){this.close(),this.menu&&(this.menu.destroy(),this.menu=null),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"contextmenu",function(t){return e.onContextMenu(t)})}},{key:"open",value:function(e){this.menu&&(this.menu.open(),this.menu.setPosition({top:parseInt((0,f.pageY)(e),10)-(0,p.getWindowScrollTop)(),left:parseInt((0,f.pageX)(e),10)-(0,p.getWindowScrollLeft)()}),this.menu.hotMenu.isHotTableEnv=this.hot.isHotTableEnv)}},{key:"close",value:function(){this.menu&&this.menu.close()}},{key:"executeCommand",value:function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];this.commandExecutor.execute.apply(this.commandExecutor,t)}},{key:"onContextMenu",value:function(e){var t=this.hot.getSettings(),n=t.rowHeaders,o=t.colHeaders,r=e.realTarget;this.close(),(0,p.hasClass)(r,"handsontableInput")||(e.preventDefault(),(0,f.stopPropagation)(e),(n||o||function(e){return"TD"===e.nodeName||"TD"===e.parentNode.nodeName}(r)||(0,p.hasClass)(r,"current")&&(0,p.hasClass)(r,"wtBorder"))&&this.open(e))}},{key:"onMenuAfterOpen",value:function(){this.hot.runHooks("afterContextMenuShow",this)}},{key:"onMenuAfterClose",value:function(){this.hot.listen(),this.hot.runHooks("afterContextMenuHide",this)}},{key:"destroy",value:function(){this.close(),this.menu&&this.menu.destroy(),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();v.SEPARATOR={name:m.SEPARATOR},(0,h.registerPlugin)("contextMenu",v),t.default=v},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(0),i=n(7),a=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e);var n=(0,r.getWindowScrollTop)(),o=(0,r.getWindowScrollLeft)(),a=void 0,s=void 0,l=void 0,u=void 0,c=void 0,d=void 0;this.type=this.getSourceType(t),"literal"===this.type?(a=parseInt(t.top,10),l=parseInt(t.left,10),c=t.height||0,d=t.width||0,s=a,u=l,a+=n,l+=o):"event"===this.type&&(a=parseInt((0,i.pageY)(t),10),l=parseInt((0,i.pageX)(t),10),c=t.target.clientHeight,d=t.target.clientWidth,s=a-n,u=l-o),this.top=a,this.topRelative=s,this.left=l,this.leftRelative=u,this.scrollTop=n,this.scrollLeft=o,this.cellHeight=c,this.cellWidth=d}return o(e,[{key:"getSourceType",value:function(e){var t="literal";return e instanceof Event&&(t="event"),t}},{key:"fitsAbove",value:function(e){return this.topRelative>=e.offsetHeight}},{key:"fitsBelow",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.innerHeight;return this.topRelative+e.offsetHeight<=t}},{key:"fitsOnRight",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.innerWidth;return this.leftRelative+this.cellWidth+e.offsetWidth<=t}},{key:"fitsOnLeft",value:function(e){return this.leftRelative>=e.offsetWidth}}]),e}();t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=n(2),i=n(1),a=n(50),s=function(){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this.predefinedItems=(0,a.predefinedItems)(),this.defaultOrderPattern=n}return o(e,[{key:"setPredefinedItems",value:function(e){var t=this,n={};this.defaultOrderPattern.length=0,(0,r.objectEach)(e,function(e,o){var r="";e.name===a.SEPARATOR?(n[a.SEPARATOR]=e,r=a.SEPARATOR):isNaN(parseInt(o,10))?(e.key=void 0===e.key?o:e.key,n[o]=e,r=e.key):(n[e.key]=e,r=e.key),t.defaultOrderPattern.push(r)}),this.predefinedItems=n}},{key:"getItems",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;return l(e,this.defaultOrderPattern,this.predefinedItems)}}]),e}();function l(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=[];return e&&e.items?e=e.items:Array.isArray(e)||(e=t),(0,r.isObject)(e)?(0,r.objectEach)(e,function(e,t){var i=n["string"==typeof e?e:t];i||(i=e),(0,r.isObject)(e)?(0,r.extend)(i,e):"string"==typeof i&&(i={name:i}),void 0===i.key&&(i.key=t),o.push(i)}):(0,i.arrayEach)(e,function(e,t){var i=n[e];!i&&a.ITEMS.indexOf(e)>=0||(i||(i={name:e,key:""+t}),(0,r.isObject)(e)&&(0,r.extend)(i,e),void 0===i.key&&(i.key=t),o.push(i))}),o}t.default=s},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=g(n(64)),i=n(0),a=n(1),s=g(n(220)),l=g(n(4)),u=n(2),c=n(35),d=n(17),h=n(16),f=g(n(150)),p=n(50),m=n(7);function g(e){return e&&e.__esModule?e:{default:e}}var v=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.hot=t,this.options=n||{parent:null,name:null,className:"",keepInViewport:!0,standalone:!1},this.eventManager=new l.default(this),this.container=this.createContainer(this.options.name),this.hotMenu=null,this.hotSubMenus={},this.parentMenu=this.options.parent||null,this.menuItems=null,this.origOutsideClickDeselects=null,this.keyEvent=!1,this.offset={above:0,below:0,left:0,right:0},this._afterScrollCallback=null,this.registerEvents()}return o(e,[{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){return e.onDocumentMouseDown(t)})}},{key:"setMenuItems",value:function(e){this.menuItems=e}},{key:"setOffset",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;this.offset[e]=t}},{key:"isSubMenu",value:function(){return null!==this.parentMenu}},{key:"open",value:function(){var e=this;this.container.removeAttribute("style"),this.container.style.display="block";var t=(0,c.debounce)(function(t){return e.openSubMenu(t)},300),n=(0,a.arrayFilter)(this.menuItems,function(t){return(0,d.isItemHidden)(t,e.hot)}),o={data:n=(0,d.filterSeparators)(n,p.SEPARATOR),colHeaders:!1,colWidths:[200],autoRowSize:!1,readOnly:!0,copyPaste:!1,columns:[{data:"name",renderer:function(t,n,o,r,i,a){return e.menuItemRenderer(t,n,o,r,i,a)}}],renderAllRows:!0,fragmentSelection:"cell",disableVisualSelection:"area",beforeKeyDown:function(t){return e.onBeforeKeyDown(t)},afterOnCellMouseOver:function(n,o,r){e.isAllSubMenusClosed()?t(o.row):e.openSubMenu(o.row)},rowHeights:function(e){return n[e].name===p.SEPARATOR?1:23}};this.origOutsideClickDeselects=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1,this.hotMenu=new r.default(this.container,o),this.hotMenu.addHook("afterInit",function(){return e.onAfterInit()}),this.hotMenu.addHook("afterSelection",function(t,n,o,r,i){return e.onAfterSelection(t,n,o,r,i)}),this.hotMenu.init(),this.hotMenu.listen(),this.blockMainTableCallbacks(),this.runLocalHooks("afterOpen")}},{key:"close",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];this.isOpened()&&(e&&this.parentMenu?this.parentMenu.close():(this.closeAllSubMenus(),this.container.style.display="none",this.releaseMainTableCallbacks(),this.hotMenu.destroy(),this.hotMenu=null,this.hot.getSettings().outsideClickDeselects=this.origOutsideClickDeselects,this.runLocalHooks("afterClose"),this.parentMenu&&this.parentMenu.hotMenu.listen()))}},{key:"openSubMenu",value:function(t){if(!this.hotMenu)return!1;var n=this.hotMenu.getCell(t,0);if(this.closeAllSubMenus(),!n||!(0,d.hasSubMenu)(n))return!1;var o=this.hotMenu.getSourceDataAtRow(t),r=new e(this.hot,{parent:this,name:o.name,className:this.options.className,keepInViewport:!0});return r.setMenuItems(o.submenu.items),r.open(),r.setPosition(n.getBoundingClientRect()),this.hotSubMenus[o.key]=r,r}},{key:"closeSubMenu",value:function(e){var t=this.hotMenu.getSourceDataAtRow(e),n=this.hotSubMenus[t.key];n&&(n.destroy(),delete this.hotSubMenus[t.key])}},{key:"closeAllSubMenus",value:function(){var e=this;(0,a.arrayEach)(this.hotMenu.getData(),function(t,n){return e.closeSubMenu(n)})}},{key:"isAllSubMenusClosed",value:function(){return 0===Object.keys(this.hotSubMenus).length}},{key:"destroy",value:function(){this.clearLocalHooks(),this.close(),this.parentMenu=null,this.eventManager.destroy()}},{key:"isOpened",value:function(){return null!==this.hotMenu}},{key:"executeCommand",value:function(e){if(this.isOpened()&&this.hotMenu.getSelected()){var t=this.hotMenu.getSourceDataAtRow(this.hotMenu.getSelected()[0]);if(this.runLocalHooks("select",t,e),!1!==t.isCommand&&t.name!==p.SEPARATOR){var n=this.hot.getSelectedRange(),o=n?(0,d.normalizeSelection)(n):{},r=!0;(!0===t.disabled||"function"==typeof t.disabled&&!0===t.disabled.call(this.hot)||t.submenu)&&(r=!1),this.runLocalHooks("executeCommand",t.key,o,e),this.isSubMenu()&&this.parentMenu.runLocalHooks("executeCommand",t.key,o,e),r&&this.close(!0)}}}},{key:"setPosition",value:function(e){var t=new s.default(e);this.options.keepInViewport?(t.fitsBelow(this.container)?this.setPositionBelowCursor(t):t.fitsAbove(this.container)?this.setPositionAboveCursor(t):this.setPositionBelowCursor(t),t.fitsOnRight(this.container)?this.setPositionOnRightOfCursor(t):this.setPositionOnLeftOfCursor(t)):(this.setPositionBelowCursor(t),this.setPositionOnRightOfCursor(t))}},{key:"setPositionAboveCursor",value:function(e){var t=this.offset.above+e.top-this.container.offsetHeight;this.isSubMenu()&&(t=e.top+e.cellHeight-this.container.offsetHeight+3),this.container.style.top=t+"px"}},{key:"setPositionBelowCursor",value:function(e){var t=this.offset.below+e.top;this.isSubMenu()&&(t=e.top-1),this.container.style.top=t+"px"}},{key:"setPositionOnRightOfCursor",value:function(e){var t=void 0;t=this.isSubMenu()?1+e.left+e.cellWidth:this.offset.right+1+e.left,this.container.style.left=t+"px"}},{key:"setPositionOnLeftOfCursor",value:function(e){var t=this.offset.left+e.left-this.container.offsetWidth+(0,i.getScrollbarWidth)()+4;this.container.style.left=t+"px"}},{key:"selectFirstCell",value:function(){var e=this.hotMenu.getCell(0,0);(0,d.isSeparator)(e)||(0,d.isDisabled)(e)||(0,d.isSelectionDisabled)(e)?this.selectNextCell(0,0):this.hotMenu.selectCell(0,0)}},{key:"selectLastCell",value:function(){var e=this.hotMenu.countRows()-1,t=this.hotMenu.getCell(e,0);(0,d.isSeparator)(t)||(0,d.isDisabled)(t)||(0,d.isSelectionDisabled)(t)?this.selectPrevCell(e,0):this.hotMenu.selectCell(e,0)}},{key:"selectNextCell",value:function(e,t){var n=e+1,o=n<this.hotMenu.countRows()?this.hotMenu.getCell(n,t):null;o&&((0,d.isSeparator)(o)||(0,d.isDisabled)(o)||(0,d.isSelectionDisabled)(o)?this.selectNextCell(n,t):this.hotMenu.selectCell(n,t))}},{key:"selectPrevCell",value:function(e,t){var n=e-1,o=n>=0?this.hotMenu.getCell(n,t):null;o&&((0,d.isSeparator)(o)||(0,d.isDisabled)(o)||(0,d.isSelectionDisabled)(o)?this.selectPrevCell(n,t):this.hotMenu.selectCell(n,t))}},{key:"menuItemRenderer",value:function(e,t,n,o,r,a){var s=this,l=e.getSourceDataAtRow(n),c=document.createElement("div"),d=function(e){return e.disableSelection};"function"==typeof a&&(a=a.call(this.hot)),(0,i.empty)(t),(0,i.addClass)(c,"htItemWrapper"),t.appendChild(c),function(e){return new RegExp(p.SEPARATOR,"i").test(e.name)}(l)?(0,i.addClass)(t,"htSeparator"):"function"==typeof l.renderer?((0,i.addClass)(t,"htCustomMenuRenderer"),t.appendChild(l.renderer(e,c,n,o,r,a))):(0,i.fastInnerHTML)(c,a),function(e){return!0===e.disabled||"function"==typeof e.disabled&&!0===e.disabled.call(s.hot)}(l)?((0,i.addClass)(t,"htDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):d(l)?((0,i.addClass)(t,"htSelectionDisabled"),this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()})):function(e){return(0,u.hasOwnProperty)(e,"submenu")}(l)?((0,i.addClass)(t,"htSubmenu"),d(l)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(n,o,void 0,void 0,!1,!1)})):((0,i.removeClass)(t,"htSubmenu"),(0,i.removeClass)(t,"htDisabled"),d(l)?this.eventManager.addEventListener(t,"mouseenter",function(){return e.deselectCell()}):this.eventManager.addEventListener(t,"mouseenter",function(){return e.selectCell(n,o,void 0,void 0,!1,!1)}))}},{key:"createContainer",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;e&&(e=e.replace(/[^A-z0-9]/g,"_"),e=this.options.className+"Sub_"+e);var t=void 0;return(t=e?document.querySelector("."+this.options.className+"."+e):document.querySelector("."+this.options.className))||(t=document.createElement("div"),(0,i.addClass)(t,"htMenu "+this.options.className),e&&(0,i.addClass)(t,e),document.getElementsByTagName("body")[0].appendChild(t)),t}},{key:"blockMainTableCallbacks",value:function(){this._afterScrollCallback=function(){},this.hot.addHook("afterScrollVertically",this._afterScrollCallback),this.hot.addHook("afterScrollHorizontally",this._afterScrollCallback)}},{key:"releaseMainTableCallbacks",value:function(){this._afterScrollCallback&&(this.hot.removeHook("afterScrollVertically",this._afterScrollCallback),this.hot.removeHook("afterScrollHorizontally",this._afterScrollCallback),this._afterScrollCallback=null)}},{key:"onBeforeKeyDown",value:function(e){var t=this.hotMenu.getSelected(),n=!1;switch(this.keyEvent=!0,e.keyCode){case h.KEY_CODES.ESCAPE:this.close(),n=!0;break;case h.KEY_CODES.ENTER:t&&(this.hotMenu.getSourceDataAtRow(t[0]).submenu?n=!0:(this.executeCommand(e),this.close(!0)));break;case h.KEY_CODES.ARROW_DOWN:t?this.selectNextCell(t[0],t[1]):this.selectFirstCell(),n=!0;break;case h.KEY_CODES.ARROW_UP:t?this.selectPrevCell(t[0],t[1]):this.selectLastCell(),n=!0;break;case h.KEY_CODES.ARROW_RIGHT:if(t){var o=this.openSubMenu(t[0]);o&&o.selectFirstCell()}n=!0;break;case h.KEY_CODES.ARROW_LEFT:t&&this.isSubMenu()&&(this.close(),this.parentMenu&&this.parentMenu.hotMenu.listen(),n=!0)}n&&(e.preventDefault(),(0,m.stopImmediatePropagation)(e)),this.keyEvent=!1}},{key:"onAfterInit",value:function(){var e=this.hotMenu.getSettings().data,t=this.hotMenu.view.wt.wtTable.hider.style,n=this.hotMenu.view.wt.wtTable.holder.style,o=parseInt(t.width,10),r=(0,a.arrayReduce)(e,function(e,t){return e+(t.name===p.SEPARATOR?1:26)},0);n.width=o+22+"px",n.height=r+4+"px",t.height=n.height}},{key:"onAfterSelection",value:function(e,t,n,o,r){!1===this.keyEvent&&(r.value=!0)}},{key:"onDocumentMouseDown",value:function(e){this.isOpened()&&(this.container&&(0,i.isChildOf)(e.target,this.container)&&this.executeCommand(e),this.options.standalone&&this.hotMenu&&!(0,i.isChildOf)(e.target,this.hotMenu.rootElement)?this.close(!0):(this.isAllSubMenusClosed()||this.isSubMenu())&&!(0,i.isChildOf)(e.target,".htMenu")&&(0,i.isChildOf)(e.target,document)&&this.close(!0))}}]),e}();(0,u.mixin)(v,f.default),t.default=v},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:i,name:"Alignment",disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)},submenu:{items:[{key:i+":left",name:function(){var e=this,t="Left";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htLeft"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htLeft"),(0,o.align)(t,"horizontal","htLeft",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:i+":center",name:function(){var e=this,t="Center";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htCenter"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htCenter"),(0,o.align)(t,"horizontal","htCenter",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:i+":right",name:function(){var e=this,t="Right";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htRight"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htRight"),(0,o.align)(t,"horizontal","htRight",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:i+":justify",name:function(){var e=this,t="Justify";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htJustify"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"horizontal","htJustify"),(0,o.align)(t,"horizontal","htJustify",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{name:r.KEY},{key:i+":top",name:function(){var e=this,t="Top";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htTop"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"vertical","htTop"),(0,o.align)(t,"vertical","htTop",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:i+":middle",name:function(){var e=this,t="Middle";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htMiddle"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"vertical","htMiddle"),(0,o.align)(t,"vertical","htMiddle",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1},{key:i+":bottom",name:function(){var e=this,t="Bottom";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){var o=e.getCellMeta(t,n).className;if(o&&-1!==o.indexOf("htBottom"))return!0})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.getAlignmentClasses)(t,function(t,n){return e.getCellMeta(t,n).className});this.runHooks("beforeCellAlignment",n,t,"vertical","htBottom"),(0,o.align)(t,"vertical","htBottom",function(t,n){return e.getCellMeta(t,n)},function(t,n,o,r){return e.setCellMeta(t,n,o,r)}),this.render()},disabled:!1}]}}};var o=n(17),r=n(70),i=t.KEY="alignment"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Clear column",callback:function(e,t){var n=t.start.col;this.countRows()&&this.populateFromArray(0,n,[[null]],Math.max(t.start.row,t.end.row),n,"ContextMenu.clearColumn")},disabled:function(){var e=(0,o.getValidSelection)(this);if(!e)return!0;var t=[e[0],0,e[0],this.countCols()-1].join(",")==e.join(",");return e[1]<0||this.countCols()>=this.getSettings().maxCols||t}}};var o=n(17),r=t.KEY="clear_column"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Insert column on the left",callback:function(e,t){this.alter("insert_col",t.start.col,1,"ContextMenu.columnLeft")},disabled:function(){var e=(0,o.getValidSelection)(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1].join(",")==e.join(","),n=1===this.countCols();return e[1]<0||this.countCols()>=this.getSettings().maxCols||!n&&t},hidden:function(){return!this.getSettings().allowInsertColumn}}};var o=n(17),r=t.KEY="col_left"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Insert column on the right",callback:function(e,t){this.alter("insert_col",t.end.col+1,1,"ContextMenu.columnRight")},disabled:function(){var e=(0,o.getValidSelection)(this);if(!e)return!0;if(!this.isColumnModificationAllowed())return!0;var t=[e[0],0,e[0],this.countCols()-1].join(",")==e.join(","),n=1===this.countCols();return e[1]<0||this.countCols()>=this.getSettings().maxCols||!n&&t},hidden:function(){return!this.getSettings().allowInsertColumn}}};var o=n(17),r=t.KEY="col_right"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:function(){var e=this,t="Read only";return(0,o.checkSelectionConsistency)(this.getSelectedRange(),function(t,n){return e.getCellMeta(t,n).readOnly})&&(t=(0,o.markLabelAsSelected)(t)),t},callback:function(){var e=this,t=this.getSelectedRange(),n=(0,o.checkSelectionConsistency)(t,function(t,n){return e.getCellMeta(t,n).readOnly});t.forAll(function(t,o){e.setCellMeta(t,o,"readOnly",!n)}),this.render()},disabled:function(){return!(this.getSelectedRange()&&!this.selection.selectedHeader.corner)}}};var o=n(17),r=t.KEY="make_read_only"},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(){return{key:o,name:"Redo",callback:function(){this.redo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isRedoAvailable()}}};var o=t.KEY="redo"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Remove column",callback:function(e,t){var n=t.end.col-t.start.col+1;this.alter("remove_col",t.start.col,n,"ContextMenu.removeColumn")},disabled:function(){var e=(0,o.getValidSelection)(this),t=this.countCols();return!e||this.selection.selectedHeader.rows||this.selection.selectedHeader.corner||!this.isColumnModificationAllowed()||!t},hidden:function(){return!this.getSettings().allowRemoveColumn}}};var o=n(17),r=t.KEY="remove_col"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Remove row",callback:function(e,t){var n=t.end.row-t.start.row+1;this.alter("remove_row",t.start.row,n,"ContextMenu.removeRow")},disabled:function(){var e=(0,o.getValidSelection)(this),t=this.countRows();return!e||this.selection.selectedHeader.cols||this.selection.selectedHeader.corner||!t},hidden:function(){return!this.getSettings().allowRemoveRow}}};var o=n(17),r=t.KEY="remove_row"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Insert row above",callback:function(e,t){this.alter("insert_row",t.start.row,1,"ContextMenu.rowAbove")},disabled:function(){return!(0,o.getValidSelection)(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}};var o=n(17),r=t.KEY="row_above"},function(e,t,n){"use strict";t.__esModule=!0,t.KEY=void 0,t.default=function(){return{key:r,name:"Insert row below",callback:function(e,t){this.alter("insert_row",t.end.row+1,1,"ContextMenu.rowBelow")},disabled:function(){return!(0,o.getValidSelection)(this)||this.selection.selectedHeader.cols||this.countRows()>=this.getSettings().maxRows},hidden:function(){return!this.getSettings().allowInsertRow}}};var o=n(17),r=t.KEY="row_below"},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(){return{key:o,name:"Undo",callback:function(){this.undo()},disabled:function(){return this.undoRedo&&!this.undoRedo.isUndoAvailable()}}};var o=t.KEY="undo"},function(e,t,n){"use strict";t.__esModule=!0;var o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},a=f(n(300)),s=f(n(12)),l=n(0),u=n(1),c=f(n(4)),d=n(5),h=n(50);function f(e){return e&&e.__esModule?e:{default:e}}var p=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.eventManager=new c.default(n),n.swfPath=null,n.outsideClickDeselectsCache=null,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,s.default),r(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().contextMenuCopyPaste}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){"object"===o(this.hot.getSettings().contextMenuCopyPaste)&&(this.swfPath=this.hot.getSettings().contextMenuCopyPaste.swfPath),void 0===a.default&&console.error("To be able to use the Copy/Paste feature from the context menu, you need to manually include ZeroClipboard.js file to your website.");try{new ActiveXObject("ShockwaveFlash.ShockwaveFlash")}catch(e){void 0===navigator.mimeTypes["application/x-shockwave-flash"]&&console.error("To be able to use the Copy/Paste feature from the context menu, your browser needs to have Flash Plugin installed.")}this.swfPath&&a.default.config({swfPath:this.swfPath}),this.hot.addHook("afterContextMenuShow",function(){return e.onAfterContextMenuShow()}),this.hot.addHook("afterContextMenuDefaultOptions",function(t){return e.onAfterContextMenuDefaultOptions(t)}),this.registerEvents(),i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"disablePlugin",value:function(){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document,"mouseenter",function(){return e.removeCurrentClass()}),this.eventManager.addEventListener(document,"mouseleave",function(){return e.removeZeroClipboardClass()})}},{key:"getCopyValue",value:function(){return this.hot.copyPaste.setCopyableText(),this.hot.copyPaste.copyPasteInstance.triggerCopy(),this.hot.copyPaste.copyPasteInstance.elTextarea.value}},{key:"onAfterContextMenuDefaultOptions",value:function(e){e.items.unshift({key:"copy",name:"Copy",disabled:function(){return this.selection.selectedHeader.corner}},{key:"paste",name:"Paste",callback:function(){this.copyPaste.triggerPaste()},disabled:function(){return this.selection.selectedHeader.corner}},{name:h.SEPARATOR})}},{key:"onAfterContextMenuShow",value:function(){var e=this,t=this.hot.getPlugin("contextMenu"),n=t.menu.hotMenu.getSourceData();(0,u.arrayEach)(n,function(n,o){if("copy"===n.key){var r=new a.default(t.menu.hotMenu.getCell(o,0));return r.off(),r.on("copy",function(t){t.clipboardData.setData("text/plain",e.getCopyValue()),e.hot.getSettings().outsideClickDeselects=e.outsideClickDeselectsCache}),!1}})}},{key:"removeCurrentClass",value:function(){var e=this.hot.getPlugin("contextMenu");if(e.enabled){if(e.menu.isOpened()){var t=e.menu.hotMenu.rootElement.querySelector("td.current");t&&(0,l.removeClass)(t,"current")}this.outsideClickDeselectsCache=this.hot.getSettings().outsideClickDeselects,this.hot.getSettings().outsideClickDeselects=!1}}},{key:"removeZeroClipboardClass",value:function(){var e=this.hot.getPlugin("contextMenu");if(e.enabled){if(e.menu.isOpened()){var t=e.menu.hotMenu.rootElement.querySelector("td.zeroclipboard-is-hover");t&&(0,l.removeClass)(t,"zeroclipboard-is-hover")}this.hot.getSettings().outsideClickDeselects=this.outsideClickDeselectsCache}}}]),t}();(0,d.registerPlugin)("contextMenuCopyPaste",p),t.default=p},function(e,t,n){"use strict";t.__esModule=!0;var o=h(n(184)),r=h(n(132)),i=h(n(8)),a=n(16),s=n(1),l=n(6),u=n(7),c=n(0),d=n(11);function h(e){return e&&e.__esModule?e:{default:e}}function f(e){var t=this;function n(){e.isListening()}function i(){if(e.isListening()){var n=t.getRangedData(t.copyableRanges);e.getSettings().fragmentSelection&&r.default.stringify(n)!=(0,c.getSelectionText)()||(e.runHooks("beforeCopy",n,t.copyableRanges)?(e.copyPaste.copyPasteInstance.copyable(r.default.stringify(n)),e.runHooks("afterCopy",n,t.copyableRanges)):e.copyPaste.copyPasteInstance.copyable(""))}}function h(n){var o,i,a,l,u,c,h,f,p,m;if(e.isListening()&&e.selection.isSelected()){o=n,i=r.default.parse(o),a=e.getSelected(),l=new d.CellCoords(a[0],a[1]),u=new d.CellCoords(a[2],a[3]),h=(c=new d.CellRange(l,l,u)).getTopLeftCorner(),f=c.getBottomRightCorner(),p=h,m=new d.CellCoords(Math.max(f.row,i.length-1+h.row),Math.max(f.col,i[0].length-1+h.col));var g=u.row-l.row>=i.length-1,v=u.col-l.col>=i[0].length-1;e.addHookOnce("afterChange",function(t,n){var o=t?t.length:0;if(o){var r={row:0,col:0},i=-1;(0,s.arrayEach)(t,function(e,n){var a=o>n+1?t[n+1]:null;a&&(g||(r.row+=Math.max(a[0]-e[0]-1,0)),!v&&e[1]>i&&(i=e[1],r.col+=Math.max(a[1]-e[1]-1,0)))}),e.selectCell(p.row,p.col,m.row+r.row,m.col+r.col)}}),e.runHooks("beforePaste",i,t.copyableRanges)&&(e.populateFromArray(p.row,p.col,i,m.row,m.col,"CopyPaste.paste",e.getSettings().pasteMode),e.runHooks("afterPaste",i,t.copyableRanges))}}function f(n){if(e.getSelected()&&!(e.getActiveEditor()&&e.getActiveEditor().isOpened()||(0,u.isImmediatePropagationStopped)(n))){if((0,a.isCtrlKey)(n.keyCode)){if(e.getSettings().fragmentSelection&&(0,c.getSelectionText)())return;return t.setCopyableText(),void(0,u.stopImmediatePropagation)(n)}var o;(n.ctrlKey||n.metaKey)&&!n.altKey&&(n.keyCode==a.KEY_CODES.A&&e._registerTimeout(setTimeout(t.setCopyableText.bind(t),0)),n.keyCode==a.KEY_CODES.X&&(o=t.getRangedData(t.copyableRanges),e.getSettings().fragmentSelection&&r.default.stringify(o)!=(0,c.getSelectionText)()||(e.runHooks("beforeCut",o,t.copyableRanges)?(e.copyPaste.copyPasteInstance.copyable(r.default.stringify(o)),e.selection.empty(),e.runHooks("afterCut",o,t.copyableRanges)):e.copyPaste.copyPasteInstance.copyable(""))),n.keyCode==a.KEY_CODES.C&&i())}}this.copyPasteInstance=(0,o.default)(),this.copyPasteInstance.onCut(n),this.copyPasteInstance.triggerCopy=i,this.copyPasteInstance.onPaste(h),this.onPaste=h,this.copyableRanges=[],e.addHook("beforeKeyDown",f),this.destroy=function(){this.copyPasteInstance&&(this.copyPasteInstance.removeCallback(n),this.copyPasteInstance.removeCallback(h),this.copyPasteInstance.destroy(),this.copyPasteInstance=null),e.removeHook("beforeKeyDown",f)},e.addHook("afterDestroy",this.destroy.bind(this)),this.triggerPaste=this.copyPasteInstance.triggerPaste.bind(this.copyPasteInstance),this.triggerCut=this.copyPasteInstance.triggerCut.bind(this.copyPasteInstance),this.setCopyableText=function(){var t=e.getSettings(),n=t.copyRowsLimit,o=t.copyColsLimit,r=e.getSelectedRange(),i=r.getTopLeftCorner(),a=r.getBottomRightCorner(),s=i.row,l=i.col,u=a.row,c=a.col,d=Math.min(u,s+n-1),h=Math.min(c,l+o-1);this.copyableRanges.length=0,this.copyableRanges.push({startRow:s,startCol:l,endRow:d,endCol:h}),this.copyableRanges=e.runHooks("modifyCopyableRange",this.copyableRanges);var f=this.getRangedCopyableData(this.copyableRanges);e.copyPaste.copyPasteInstance.copyable(f),u===d&&c===h||e.runHooks("afterCopyLimit",u-s+1,c-l+1,n,o)},this.getRangedCopyableData=function(t){var n=[],o=[],i=[];return(0,s.arrayEach)(t,function(e){(0,l.rangeEach)(e.startRow,e.endRow,function(e){-1===o.indexOf(e)&&o.push(e)}),(0,l.rangeEach)(e.startCol,e.endCol,function(e){-1===i.indexOf(e)&&i.push(e)})}),(0,s.arrayEach)(o,function(t){var o=[];(0,s.arrayEach)(i,function(n){o.push(e.getCopyableData(t,n))}),n.push(o)}),r.default.stringify(n)},this.getRangedData=function(t){var n=[],o=[],r=[];return(0,s.arrayEach)(t,function(e){(0,l.rangeEach)(e.startRow,e.endRow,function(e){-1===o.indexOf(e)&&o.push(e)}),(0,l.rangeEach)(e.startCol,e.endCol,function(e){-1===r.indexOf(e)&&r.push(e)})}),(0,s.arrayEach)(o,function(t){var o=[];(0,s.arrayEach)(r,function(n){o.push(e.getCopyableData(t,n))}),n.push(o)}),n}}function p(){var e=!1!==this.getSettings().copyPaste;e&&!this.copyPaste?this.copyPaste=new f(this):!e&&this.copyPaste&&(this.copyPaste.destroy(),this.copyPaste=null)}i.default.getSingleton().register("afterCopyLimit"),i.default.getSingleton().register("modifyCopyableRange"),i.default.getSingleton().register("beforeCut"),i.default.getSingleton().register("afterCut"),i.default.getSingleton().register("beforePaste"),i.default.getSingleton().register("afterPaste"),i.default.getSingleton().register("beforeCopy"),i.default.getSingleton().register("afterCopy"),i.default.getSingleton().add("afterInit",p),i.default.getSingleton().add("afterUpdateSettings",p),t.default=f},function(e,t,n){"use strict";var o,r,i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a=n(8),s=(o=a)&&o.__esModule?o:{default:o},l=(n(5),n(2)),u=n(11);function c(){}var d=function(e){var t={row:e.row,col:e.col},n=new u.Selection(e,new u.CellRange(t,t,t)),o=function(e){for(var t=0;t<r.view.wt.selections.length;t++)if(r.view.wt.selections[t].settings.className==e)return t;return-1}(e.className);o>=0?r.view.wt.selections[o]=n:r.view.wt.selections.push(n)},h=function(e,t,n){var o=m(e,t);o=g(o,n),this.setCellMeta(e,t,"borders",o),d(o)},f=function(e){for(var t=e.range,n=t.from.row;n<=t.to.row;n++)for(var o=t.from.col;o<=t.to.col;o++){var r=m(n,o),i=0;n==t.from.row&&(i++,(0,l.hasOwnProperty)(e,"top")&&(r.top=e.top)),n==t.to.row&&(i++,(0,l.hasOwnProperty)(e,"bottom")&&(r.bottom=e.bottom)),o==t.from.col&&(i++,(0,l.hasOwnProperty)(e,"left")&&(r.left=e.left)),o==t.to.col&&(i++,(0,l.hasOwnProperty)(e,"right")&&(r.right=e.right)),i>0&&(this.setCellMeta(n,o,"borders",r),d(r))}},p=function(e,t){return"border_row"+e+"col"+t},m=function(e,t){return{className:p(e,t),border:{width:1,color:"#000",cornerVisible:!1},row:e,col:t,top:{hide:!0},right:{hide:!0},bottom:{hide:!0},left:{hide:!0}}},g=function(e,t){return(0,l.hasOwnProperty)(t,"border")&&(e.border=t.border),(0,l.hasOwnProperty)(t,"top")&&(e.top=t.top),(0,l.hasOwnProperty)(t,"right")&&(e.right=t.right),(0,l.hasOwnProperty)(t,"bottom")&&(e.bottom=t.bottom),(0,l.hasOwnProperty)(t,"left")&&(e.left=t.left),e},v=function(e){for(var t=document.querySelectorAll("."+e),n=0;n<t.length;n++)if(t[n]&&"TD"!=t[n].nodeName){var o=t[n].parentNode;o.parentNode&&o.parentNode.removeChild(o)}},y=function(e,t){var n=p(e,t);v(n),this.removeCellMeta(e,t,"borders")},_=function(e,t,n,o){var r=this.getCellMeta(e,t).borders;r&&null!=r.border||(r=m(e,t)),r[n]=o?{hide:!0}:{width:1,color:"#000"},this.setCellMeta(e,t,"borders",r);var i=p(e,t);v(i),d(r),this.render()},w=function(e,t,n){if(e.from.row==e.to.row&&e.from.col==e.to.col)"noBorders"==t?y.call(this,e.from.row,e.from.col):_.call(this,e.from.row,e.from.col,t,n);else switch(t){case"noBorders":for(var o=e.from.col;o<=e.to.col;o++)for(var r=e.from.row;r<=e.to.row;r++)y.call(this,r,o);break;case"top":for(var i=e.from.col;i<=e.to.col;i++)_.call(this,e.from.row,i,t,n);break;case"right":for(var a=e.from.row;a<=e.to.row;a++)_.call(this,a,e.to.col,t);break;case"bottom":for(var s=e.from.col;s<=e.to.col;s++)_.call(this,e.to.row,s,t);break;case"left":for(var l=e.from.row;l<=e.to.row;l++)_.call(this,l,e.from.col,t)}},b=function(e,t){var n=!1;return e.getSelectedRange().forAll(function(o,r){var i=e.getCellMeta(o,r).borders;if(i){if(!t)return n=!0,!1;if(!(0,l.hasOwnProperty)(i[t],"hide"))return n=!0,!1}}),n},C=function(e){return'<span class="selected">'+String.fromCharCode(10003)+"</span>"+e};s.default.getSingleton().add("beforeInit",function(){var e;("boolean"==typeof(e=this.getSettings().customBorders)&&!0===e||"object"===(void 0===e?"undefined":i(e))&&e.length>0)&&(this.customBorders||(r=this,this.customBorders=new c))}),s.default.getSingleton().add("afterContextMenuDefaultOptions",function(e){this.getSettings().customBorders&&(e.items.push({name:"---------"}),e.items.push({key:"borders",name:"Borders",disabled:function(){return this.selection.selectedHeader.corner},submenu:{items:[{key:"borders:top",name:function(){var e="Top";return b(this,"top")&&(e=C(e)),e},callback:function(){var e=b(this,"top");w.call(this,this.getSelectedRange(),"top",e)}},{key:"borders:right",name:function(){var e="Right";return b(this,"right")&&(e=C(e)),e},callback:function(){var e=b(this,"right");w.call(this,this.getSelectedRange(),"right",e)}},{key:"borders:bottom",name:function(){var e="Bottom";return b(this,"bottom")&&(e=C(e)),e},callback:function(){var e=b(this,"bottom");w.call(this,this.getSelectedRange(),"bottom",e)}},{key:"borders:left",name:function(){var e="Left";return b(this,"left")&&(e=C(e)),e},callback:function(){var e=b(this,"left");w.call(this,this.getSelectedRange(),"left",e)}},{key:"borders:no_borders",name:"Remove border(s)",callback:function(){w.call(this,this.getSelectedRange(),"noBorders")},disabled:function(){return!b(this)}}]}}))}),s.default.getSingleton().add("afterInit",function(){var e=this.getSettings().customBorders;if(e){for(var t=0;t<e.length;t++)e[t].range?f.call(this,e[t]):h.call(this,e[t].row,e[t].col,e[t]);this.render(),this.view.wt.draw(!0)}})},function(e,t,n){"use strict";t.__esModule=!0;var o,r=a(n(8)),i=a(n(4));function a(e){return e&&e.__esModule?e:{default:e}}function s(){this.boundaries=null,this.callback=null}n(5),s.prototype.setBoundaries=function(e){this.boundaries=e},s.prototype.setCallback=function(e){this.callback=e},s.prototype.check=function(e,t){var n=0,o=0;t<this.boundaries.top?o=t-this.boundaries.top:t>this.boundaries.bottom&&(o=t-this.boundaries.bottom),e<this.boundaries.left?n=e-this.boundaries.left:e>this.boundaries.right&&(n=e-this.boundaries.right),this.callback(n,o)};var l=function(e){e.dragToScrollListening=!1;var t=e.view.wt.wtTable.holder;o=new s,t!==window&&(o.setBoundaries(t.getBoundingClientRect()),o.setCallback(function(e,n){e<0?t.scrollLeft-=50:e>0&&(t.scrollLeft+=50),n<0?t.scrollTop-=20:n>0&&(t.scrollTop+=20)}),e.dragToScrollListening=!0)};r.default.getSingleton().add("afterInit",function(){var e=this,t=new i.default(this);t.addEventListener(document,"mouseup",function(){e.dragToScrollListening=!1}),t.addEventListener(document,"mousemove",function(t){e.dragToScrollListening&&o.check(t.clientX,t.clientY)})}),r.default.getSingleton().add("afterDestroy",function(){new i.default(this).clear()}),r.default.getSingleton().add("afterOnCellMouseDown",function(){l(this)}),r.default.getSingleton().add("afterOnCellCornerMouseDown",function(){l(this)}),t.default=s},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){return{key:"freeze_column",name:"Freeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.freezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:(e.from.col!==e.to.col||e.from.col<=this.getSettings().fixedColumnsLeft-1)&&(t=!0),t}}}},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e){return{key:"unfreeze_column",name:"Unfreeze this column",callback:function(){var t=this.getSelectedRange().from.col;e.unfreezeColumn(t),this.render(),this.view.wt.wtOverlays.adjustElementsSize(!0)},hidden:function(){var e=this.getSelectedRange(),t=!1;return void 0===e?t=!0:(e.from.col!==e.to.col||e.from.col>=this.getSettings().fixedColumnsLeft)&&(t=!0),t}}}},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=c(n(12)),a=n(5),s=n(1),l=c(n(238)),u=c(n(239));function c(e){return e&&e.__esModule?e:{default:e}}n(296);var d=new WeakMap,h=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return d.set(n,{moveByFreeze:!1,afterFirstUse:!1}),n.frozenColumnsBasePositions=[],n.manualColumnMovePlugin=void 0,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnFreeze}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("afterContextMenuDefaultOptions",function(t){return e.addContextMenuEntry(t)}),this.addHook("afterInit",function(){return e.onAfterInit()}),this.addHook("beforeColumnMove",function(t,n){return e.onBeforeColumnMove(t,n)}),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){var e=d.get(this);e.afterFirstUse=!1,e.moveByFreeze=!1,r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"freezeColumn",value:function(e){var t=d.get(this),n=this.hot.getSettings();t.afterFirstUse||(t.afterFirstUse=!0),n.fixedColumnsLeft===this.hot.countCols()||e<=n.fixedColumnsLeft-1||(t.moveByFreeze=!0,e!==this.getMovePlugin().columnsMapper.getValueByIndex(e)&&(this.frozenColumnsBasePositions[n.fixedColumnsLeft]=e),this.getMovePlugin().moveColumn(e,n.fixedColumnsLeft++))}},{key:"unfreezeColumn",value:function(e){var t=d.get(this),n=this.hot.getSettings();if(t.afterFirstUse||(t.afterFirstUse=!0),!(n.fixedColumnsLeft<=0||e>n.fixedColumnsLeft-1)){var o=this.getBestColumnReturnPosition(e);t.moveByFreeze=!0,n.fixedColumnsLeft--,this.getMovePlugin().moveColumn(e,o+1)}}},{key:"getMovePlugin",value:function(){return this.manualColumnMovePlugin||(this.manualColumnMovePlugin=this.hot.getPlugin("manualColumnMove")),this.manualColumnMovePlugin}},{key:"getBestColumnReturnPosition",value:function(e){var t=this.getMovePlugin(),n=this.hot.getSettings().fixedColumnsLeft,o=t.columnsMapper.getValueByIndex(n),r=void 0;if(null==this.frozenColumnsBasePositions[e])for(r=t.columnsMapper.getValueByIndex(e);o<r;)n++,o=t.columnsMapper.getValueByIndex(n);else{for(r=this.frozenColumnsBasePositions[e],this.frozenColumnsBasePositions[e]=void 0;o<=r;)n++,o=t.columnsMapper.getValueByIndex(n);n=o}return n-1}},{key:"addContextMenuEntry",value:function(e){e.items.push({name:"---------"},(0,l.default)(this),(0,u.default)(this))}},{key:"onAfterInit",value:function(){this.getMovePlugin().isEnabled()||this.getMovePlugin().enablePlugin()}},{key:"onBeforeColumnMove",value:function(e,t){var n=d.get(this);if(n.afterFirstUse&&!n.moveByFreeze){var o=this.hot.getSettings().fixedColumnsLeft,r=t<o;if(r||(0,s.arrayEach)(e,function(e,t,n){if(e<o)return r=!0,!1}),r)return!1}n.moveByFreeze&&(n.moveByFreeze=!1)}},{key:"destroy",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,a.registerPlugin)("manualColumnFreeze",h),t.default=h},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(149),a=(o=i)&&o.__esModule?o:{default:o},s=n(1),l=n(2),u=n(6),c=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.manualColumnMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,n=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(n-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveColumn",value:function(e,t){var n=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,n)}},{key:"clearNull",value:function(){this._arrayMap=(0,s.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,l.mixin)(c,a.default),t.default=c},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=g(n(12)),a=g(n(8)),s=n(1),l=n(0),u=n(6),c=g(n(4)),d=n(5),h=g(n(241)),f=g(n(243)),p=g(n(244)),m=n(11);function g(e){return e&&e.__esModule?e:{default:e}}n(297),a.default.getSingleton().register("beforeColumnMove"),a.default.getSingleton().register("afterColumnMove"),a.default.getSingleton().register("unmodifyCol");var v=new WeakMap,y=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return v.set(n,{columnsToMove:[],countCols:0,fixedColumns:0,pressed:void 0,disallowMoving:void 0,target:{eventPageX:void 0,coords:void 0,TD:void 0,col:void 0}}),n.removedColumns=[],n.columnsMapper=new h.default(n),n.eventManager=new c.default(n),n.backlight=new f.default(e),n.guideline=new p.default(e),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualColumnMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,n,o,r){return e.onBeforeOnCellMouseDown(t,n,o,r)}),this.addHook("beforeOnCellMouseOver",function(t,n,o,r){return e.onBeforeOnCellMouseOver(t,n,o,r)}),this.addHook("afterScrollVertically",function(){return e.onAfterScrollVertically()}),this.addHook("modifyCol",function(t,n){return e.onModifyCol(t,n)}),this.addHook("beforeRemoveCol",function(t,n){return e.onBeforeRemoveCol(t,n)}),this.addHook("afterRemoveCol",function(t,n){return e.onAfterRemoveCol(t,n)}),this.addHook("afterCreateCol",function(t,n){return e.onAfterCreateCol(t,n)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),this.addHook("unmodifyCol",function(t){return e.onUnmodifyCol(t)}),this.registerEvents(),(0,l.addClass)(this.hot.rootElement,"ht__manualColumnMove"),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)&&this.columnsMapper.clearMap(),(0,l.removeClass)(this.hot.rootElement,"ht__manualColumnMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"moveColumn",value:function(e,t){this.moveColumns([e],t)}},{key:"moveColumns",value:function(e,t){var n=this,o=v.get(this),r=this.hot.runHooks("beforeColumnMove",e,t);o.disallowMoving=!r,!1!==r&&((0,s.arrayEach)(e,function(e,t,o){o[t]=n.columnsMapper.getValueByIndex(e)}),(0,s.arrayEach)(e,function(e,o){var r=n.columnsMapper.getIndexByValue(e);r!==t&&n.columnsMapper.moveColumn(r,t+o)}),this.columnsMapper.clearNull()),this.hot.runHooks("afterColumnMove",e,t)}},{key:"changeSelection",value:function(e,t){var n=this.hot.selection,o=this.hot.countRows()-1;n.setRangeStartOnly(new m.CellCoords(0,e)),n.setRangeEnd(new m.CellCoords(o,t),!1)}},{key:"getColumnsWidth",value:function(e,t){for(var n=0,o=e;o<t;o++)n+=o<0?this.hot.view.wt.wtTable.getColumnWidth(o)||0:this.hot.view.wt.wtTable.getStretchedColumnWidth(o)||0;return n}},{key:"initialSettings",value:function(){var e=this.hot.getSettings().manualColumnMove;Array.isArray(e)?this.moveColumns(e,0):void 0!==e&&this.persistentStateLoad()}},{key:"isFixedColumnsLeft",value:function(e){return e<this.hot.getSettings().fixedColumnsLeft}},{key:"persistentStateSave",value:function(){this.hot.runHooks("persistentStateSave","manualColumnMove",this.columnsMapper._arrayMap)}},{key:"persistentStateLoad",value:function(){var e={};this.hot.runHooks("persistentStateLoad","manualColumnMove",e),e.value&&(this.columnsMapper._arrayMap=e.value)}},{key:"prepareColumnsToMoving",value:function(e,t){var n=[];return(0,u.rangeEach)(e,t,function(e){n.push(e)}),n}},{key:"refreshPositions",value:function(){var e=v.get(this),t=this.hot.view.wt.wtTable.getFirstVisibleColumn(),n=this.hot.view.wt.wtTable.getLastVisibleColumn(),o=this.hot.view.wt.wtTable,r=this.hot.view.wt.wtOverlays.scrollableElement,i="number"==typeof r.scrollX?r.scrollX:r.scrollLeft,a=this.hot.view.THEAD.offsetLeft+this.getColumnsWidth(0,e.coordsColumn),s=e.target.eventPageX-(e.rootElementOffset-(void 0===r.scrollX?i:0)),l=o.hider.offsetWidth,u=o.TBODY.offsetLeft,c=this.backlight.getOffset().left,d=this.backlight.getSize().width,h=0;if(e.rootElementOffset+o.holder.offsetWidth+i<e.target.eventPageX&&e.coordsColumn<e.countCols&&e.coordsColumn++,e.hasRowHeaders&&(h=this.hot.view.wt.wtOverlays.leftOverlay.clone.wtTable.getColumnHeader(-1).offsetWidth),this.isFixedColumnsLeft(e.coordsColumn)&&(a+=i),a+=h,e.coordsColumn<0)e.fixedColumns>0?e.target.col=0:e.target.col=t>0?t-1:t;else if(e.target.TD.offsetWidth/2+a<=s){var f=e.coordsColumn>=e.countCols?e.countCols-1:e.coordsColumn;e.target.col=f+1,a+=e.target.TD.offsetWidth,e.target.col>n&&this.hot.scrollViewportTo(void 0,n+1,void 0,!0)}else e.target.col=e.coordsColumn,e.target.col<=t&&e.target.col>=e.fixedColumns&&this.hot.scrollViewportTo(void 0,t-1);e.target.col<=t&&e.target.col>=e.fixedColumns&&this.hot.scrollViewportTo(void 0,t-1);var p=s,m=a;s+d+c>=l?p=l-d-c:s+c<u+h&&(p=u+h+Math.abs(c)),a>=l-1?m=l-1:0===m?m=1:void 0!==r.scrollX&&e.coordsColumn<e.fixedColumns&&(m-=e.rootElementOffset<=r.scrollX?e.rootElementOffset:0),this.backlight.setPosition(null,p),this.guideline.setPosition(null,m)}},{key:"updateColumnsMapper",value:function(){var e=this.hot.countSourceCols(),t=this.columnsMapper._arrayMap.length;if(0===t)this.columnsMapper.createMap(e||this.hot.getSettings().startCols);else if(t<e){var n=e-t;this.columnsMapper.insertItems(t,n)}else if(t>e){var o=e-1,r=[];(0,s.arrayEach)(this.columnsMapper._arrayMap,function(e,t,n){e>o&&r.push(t)}),this.columnsMapper.removeItems(r)}}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})}},{key:"unregisterEvents",value:function(){this.eventManager.clear()}},{key:"onBeforeOnCellMouseDown",value:function(e,t,n,o){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.cols,a=this.hot.getSelectedRange(),s=v.get(this),u=e.realTarget.className.indexOf("columnSorting")>-1;if(!a||!i||s.pressed||0!==e.button||u)return s.pressed=!1,s.columnsToMove.length=0,void(0,l.removeClass)(this.hot.rootElement,["on-moving--columns","show-ui"]);var c=this.guideline.isBuilt()&&!this.guideline.isAppended(),d=this.backlight.isBuilt()&&!this.backlight.isAppended();c&&d&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var h=a.from,f=a.to,p=Math.min(h.col,f.col),m=Math.max(h.col,f.col);if(t.row<0&&t.col>=p&&t.col<=m){o.column=!0,s.pressed=!0,s.target.eventPageX=e.pageX,s.coordsColumn=t.col,s.target.TD=n,s.target.col=t.col,s.columnsToMove=this.prepareColumnsToMoving(p,m),s.hasRowHeaders=!!this.hot.getSettings().rowHeaders,s.countCols=this.hot.countCols(),s.fixedColumns=this.hot.getSettings().fixedColumnsLeft,s.rootElementOffset=(0,l.offset)(this.hot.rootElement).left;var g=s.hasRowHeaders?-1:0,y=r.holder.scrollTop+r.getColumnHeaderHeight(0)+1,_=t.col<s.fixedColumns,w=this.hot.view.wt.wtOverlays.scrollableElement,b=w.scrollX?w.scrollX-s.rootElementOffset:0,C=e.layerX-(_?b:0),M=Math.abs(this.getColumnsWidth(p,t.col)+C);this.backlight.setPosition(y,this.getColumnsWidth(g,p)+M),this.backlight.setSize(this.getColumnsWidth(p,m+1),r.hider.offsetHeight-y),this.backlight.setOffset(null,-1*M),(0,l.addClass)(this.hot.rootElement,"on-moving--columns")}else(0,l.removeClass)(this.hot.rootElement,"after-selection--columns"),s.pressed=!1,s.columnsToMove.length=0}},{key:"onMouseMove",value:function(e){var t=v.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var n=this.backlight.getSize().width;this.backlight.setSize(0),setTimeout(function(){this.backlight.setPosition(n)})}t.target.eventPageX=e.pageX,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,n,o){var r=this.hot.getSelectedRange(),i=v.get(this);r&&i.pressed&&(i.columnsToMove.indexOf(t.col)>-1?(0,l.removeClass)(this.hot.rootElement,"show-ui"):(0,l.addClass)(this.hot.rootElement,"show-ui"),o.row=!0,o.column=!0,o.cell=!0,i.coordsColumn=t.col,i.target.TD=n)}},{key:"onMouseUp",value:function(){var e=v.get(this);if(e.coordsColumn=void 0,e.pressed=!1,e.backlightWidth=0,(0,l.removeClass)(this.hot.rootElement,["on-moving--columns","show-ui","after-selection--columns"]),this.hot.selection.selectedHeader.cols&&(0,l.addClass)(this.hot.rootElement,"after-selection--columns"),!(e.columnsToMove.length<1||void 0===e.target.col||e.columnsToMove.indexOf(e.target.col)>-1)){if(this.moveColumns(e.columnsToMove,e.target.col),this.persistentStateSave(),this.hot.render(),this.hot.view.wt.wtOverlays.adjustElementsSize(!0),!e.disallowMoving){var t=this.columnsMapper.getIndexByValue(e.columnsToMove[0]),n=this.columnsMapper.getIndexByValue(e.columnsToMove[e.columnsToMove.length-1]);this.changeSelection(t,n)}e.columnsToMove.length=0}}},{key:"onAfterScrollVertically",value:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnHeaderHeight(0)+1+e.holder.scrollTop;this.backlight.setPosition(t),this.backlight.setSize(null,e.hider.offsetHeight-t)}},{key:"onAfterCreateCol",value:function(e,t){this.columnsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveCol",value:function(e,t){var n=this;this.removedColumns.length=0,!1!==e&&(0,u.rangeEach)(e,e+t-1,function(e){n.removedColumns.push(n.hot.runHooks("modifyCol",e,n.pluginName))})}},{key:"onAfterRemoveCol",value:function(e,t){this.columnsMapper.unshiftItems(this.removedColumns)}},{key:"onAfterLoadData",value:function(e){this.updateColumnsMapper()}},{key:"onModifyCol",value:function(e,t){if(t!==this.pluginName){var n=this.columnsMapper.getValueByIndex(e);e=null===n?e:n}return e}},{key:"onUnmodifyCol",value:function(e){var t=this.columnsMapper.getIndexByValue(e);return null===t?e:t}},{key:"onAfterPluginsInitialized",value:function(){this.updateColumnsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()}},{key:"destroy",value:function(){this.backlight.destroy(),this.guideline.destroy(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,d.registerPlugin)("ManualColumnMove",y),t.default=y},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(151),a=(o=i)&&o.__esModule?o:{default:o},s=n(0),l=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),r(t,[{key:"build",value:function(){(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,s.addClass)(this._element,"ht__manualColumnMove--backlight")}}]),t}();t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(151),a=(o=i)&&o.__esModule?o:{default:o},s=n(0),l=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),r(t,[{key:"build",value:function(){(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,s.addClass)(this._element,"ht__manualColumnMove--guideline")}}]),t}();t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=h(n(12)),a=n(0),s=h(n(4)),l=n(7),u=n(1),c=n(6),d=n(5);function h(e){return e&&e.__esModule?e:{default:e}}var f=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.currentTH=null,n.currentCol=null,n.selectedCols=[],n.currentWidth=null,n.newSize=null,n.startY=null,n.startWidth=null,n.startOffset=null,n.handle=document.createElement("DIV"),n.guide=document.createElement("DIV"),n.eventManager=new s.default(n),n.pressed=null,n.dblclick=0,n.autoresizeTimeout=null,n.manualColumnWidths=[],(0,a.addClass)(n.handle,"manualColumnResizer"),(0,a.addClass)(n.guide,"manualColumnResizerGuide"),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualColumnResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualColumnWidths=[];var n=this.hot.getSettings().manualColumnResize,o=this.loadManualColumnWidths();this.addHook("modifyColWidth",function(t,n){return e.onModifyColWidth(t,n)}),this.addHook("beforeStretchingColumnWidth",function(t,n){return e.onBeforeStretchingColumnWidth(t,n)}),this.addHook("beforeColumnResize",function(t,n,o){return e.onBeforeColumnResize(t,n,o)}),void 0!==o?this.manualColumnWidths=o:Array.isArray(n)?this.manualColumnWidths=n:this.manualColumnWidths=[],this.bindEvents(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.hot.getSettings().manualColumnResize;Array.isArray(e)?this.manualColumnWidths=e:e||(this.manualColumnWidths=[])}},{key:"disablePlugin",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"saveManualColumnWidths",value:function(){this.hot.runHooks("persistentStateSave","manualColumnWidths",this.manualColumnWidths)}},{key:"loadManualColumnWidths",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualColumnWidths",e),e.value}},{key:"setupHandlePosition",value:function(e){var t=this;if(!e.parentNode)return!1;this.currentTH=e;var n=this.hot.view.wt.wtTable.getCoords(e).col,o=(0,a.outerHeight)(this.currentTH);if(n>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentCol=n,this.selectedCols=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.cols){var i=this.hot.getSelectedRange(),s=i.from,l=i.to,u=s.col,d=l.col;u>=d&&(u=l.col,d=s.col),this.currentCol>=u&&this.currentCol<=d?(0,c.rangeEach)(u,d,function(e){return t.selectedCols.push(e)}):this.selectedCols.push(this.currentCol)}else this.selectedCols.push(this.currentCol);this.startOffset=r.left-6,this.startWidth=parseInt(r.width,10),this.handle.style.top=r.top+"px",this.handle.style.left=this.startOffset+this.startWidth+"px",this.handle.style.height=o+"px",this.hot.rootElement.appendChild(this.handle)}}},{key:"refreshHandlePosition",value:function(){this.handle.style.left=this.startOffset+this.currentWidth+"px"}},{key:"setupGuidePosition",value:function(){var e=parseInt((0,a.outerHeight)(this.handle),10),t=parseInt(this.handle.style.top,10)+e,n=parseInt(this.hot.view.maximumVisibleElementHeight(0),10);(0,a.addClass)(this.handle,"active"),(0,a.addClass)(this.guide,"active"),this.guide.style.top=t+"px",this.guide.style.left=this.handle.style.left,this.guide.style.height=n-e+"px",this.hot.rootElement.appendChild(this.guide)}},{key:"refreshGuidePosition",value:function(){this.guide.style.left=this.handle.style.left}},{key:"hideHandleAndGuide",value:function(){(0,a.removeClass)(this.handle,"active"),(0,a.removeClass)(this.guide,"active")}},{key:"checkIfColumnHeader",value:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"THEAD"===t.tagName||this.checkIfColumnHeader(t)}return!1}},{key:"getTHFromTargetElement",value:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null}},{key:"onMouseOver",value:function(e){if(this.checkIfColumnHeader(e.target)){var t=this.getTHFromTargetElement(e.target);if(!t)return;var n=t.getAttribute("colspan");!t||null!==n&&1!==n||this.pressed||this.setupHandlePosition(t)}}},{key:"afterMouseDownTimeout",value:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(n,o){var r=e.hot.runHooks("beforeColumnResize",n,e.newSize,!0);void 0!==r&&(e.newSize=r),"all"===e.hot.getSettings().stretchH?e.clearManualSize(n):e.setManualSize(n,e.newSize),o&&t(),e.saveManualColumnWidths(),e.hot.runHooks("afterColumnResize",n,e.newSize,!0)};this.dblclick>=2&&(this.selectedCols.length>1?((0,u.arrayEach)(this.selectedCols,function(e){n(e)}),t()):(0,u.arrayEach)(this.selectedCols,function(e){n(e,!0)})),this.dblclick=0,this.autoresizeTimeout=null}},{key:"onMouseDown",value:function(e){var t=this;(0,a.hasClass)(e.target,"manualColumnResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null===this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startX=(0,l.pageX)(e),this.newSize=this.startWidth)}},{key:"onMouseMove",value:function(e){var t=this;this.pressed&&(this.currentWidth=this.startWidth+((0,l.pageX)(e)-this.startX),(0,u.arrayEach)(this.selectedCols,function(e){t.newSize=t.setManualSize(e,t.currentWidth)}),this.refreshHandlePosition(),this.refreshGuidePosition())}},{key:"onMouseUp",value:function(e){var t=this,n=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(e,o){t.hot.runHooks("beforeColumnResize",e,t.newSize),o&&n(),t.saveManualColumnWidths(),t.hot.runHooks("afterColumnResize",e,t.newSize)};this.pressed&&(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startWidth&&(this.selectedCols.length>1?((0,u.arrayEach)(this.selectedCols,function(e){o(e)}),n()):(0,u.arrayEach)(this.selectedCols,function(e){o(e,!0)})),this.setupHandlePosition(this.currentTH))}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})}},{key:"setManualSize",value:function(e,t){return t=Math.max(t,20),e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=t,t}},{key:"clearManualSize",value:function(e){e=this.hot.runHooks("modifyCol",e),this.manualColumnWidths[e]=void 0}},{key:"onModifyColWidth",value:function(e,t){return this.enabled&&(t=this.hot.runHooks("modifyCol",t),this.hot.getSettings().manualColumnResize&&this.manualColumnWidths[t])?this.manualColumnWidths[t]:e}},{key:"onBeforeStretchingColumnWidth",value:function(e,t){var n=this.manualColumnWidths[t];return void 0===n&&(n=e),n}},{key:"onBeforeColumnResize",value:function(){this.hot.view.wt.wtViewport.hasOversizedColumnHeadersMarked={}}}]),t}();(0,d.registerPlugin)("manualColumnResize",f),t.default=f},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=g(n(12)),a=g(n(8)),s=n(1),l=n(0),u=n(6),c=g(n(4)),d=n(5),h=g(n(247)),f=g(n(248)),p=g(n(249)),m=n(11);function g(e){return e&&e.__esModule?e:{default:e}}n(298),a.default.getSingleton().register("beforeRowMove"),a.default.getSingleton().register("afterRowMove"),a.default.getSingleton().register("unmodifyRow");var v=new WeakMap,y=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return v.set(n,{rowsToMove:[],pressed:void 0,disallowMoving:void 0,target:{eventPageY:void 0,coords:void 0,TD:void 0,row:void 0}}),n.removedRows=[],n.rowsMapper=new h.default(n),n.eventManager=new c.default(n),n.backlight=new f.default(e),n.guideline=new p.default(e),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return!!this.hot.getSettings().manualRowMove}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("beforeOnCellMouseDown",function(t,n,o,r){return e.onBeforeOnCellMouseDown(t,n,o,r)}),this.addHook("beforeOnCellMouseOver",function(t,n,o,r){return e.onBeforeOnCellMouseOver(t,n,o,r)}),this.addHook("afterScrollHorizontally",function(){return e.onAfterScrollHorizontally()}),this.addHook("modifyRow",function(t,n){return e.onModifyRow(t,n)}),this.addHook("beforeRemoveRow",function(t,n){return e.onBeforeRemoveRow(t,n)}),this.addHook("afterRemoveRow",function(t,n){return e.onAfterRemoveRow(t,n)}),this.addHook("afterCreateRow",function(t,n){return e.onAfterCreateRow(t,n)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),this.addHook("beforeColumnSort",function(t,n){return e.onBeforeColumnSort(t,n)}),this.addHook("unmodifyRow",function(t){return e.onUnmodifyRow(t)}),this.registerEvents(),(0,l.addClass)(this.hot.rootElement,"ht__manualRowMove"),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.disablePlugin(),this.enablePlugin(),this.onAfterPluginsInitialized(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){var e=this.hot.getSettings().manualRowMove;Array.isArray(e)&&this.rowsMapper.clearMap(),(0,l.removeClass)(this.hot.rootElement,"ht__manualRowMove"),this.unregisterEvents(),this.backlight.destroy(),this.guideline.destroy(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"moveRow",value:function(e,t){this.moveRows([e],t)}},{key:"moveRows",value:function(e,t){var n=this,o=v.get(this),r=this.hot.runHooks("beforeRowMove",e,t);o.disallowMoving=!1===r,o.disallowMoving||((0,s.arrayEach)(e,function(e,t,o){o[t]=n.rowsMapper.getValueByIndex(e)}),(0,s.arrayEach)(e,function(e,o){var r=n.rowsMapper.getIndexByValue(e);r!==t&&n.rowsMapper.moveRow(r,t+o)}),this.rowsMapper.clearNull()),this.hot.runHooks("afterRowMove",e,t)}},{key:"changeSelection",value:function(e,t){var n=this.hot.selection,o=this.hot.countCols()-1;n.setRangeStartOnly(new m.CellCoords(e,0)),n.setRangeEnd(new m.CellCoords(t,o),!1)}},{key:"getRowsHeight",value:function(e,t){for(var n=0,o=e;o<t;o++)n+=this.hot.view.wt.wtTable.getRowHeight(o)||23;return n}},{key:"initialSettings",value:function(){var e=this.hot.getSettings().manualRowMove;if(Array.isArray(e))this.moveRows(e,0);else if(void 0!==e){var t=this.persistentStateLoad();t.length&&this.moveRows(t,0)}}},{key:"isFixedRowTop",value:function(e){return e<this.hot.getSettings().fixedRowsTop}},{key:"isFixedRowBottom",value:function(e){return e>this.hot.getSettings().fixedRowsBottom}},{key:"persistentStateSave",value:function(){this.hot.runHooks("persistentStateSave","manualRowMove",this.rowsMapper._arrayMap)}},{key:"persistentStateLoad",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowMove",e),e.value?e.value:[]}},{key:"prepareRowsToMoving",value:function(){var e=this.hot.getSelectedRange(),t=[];if(!e)return t;var n=e.from,o=e.to,r=Math.min(n.row,o.row),i=Math.max(n.row,o.row);return(0,u.rangeEach)(r,i,function(e){t.push(e)}),t}},{key:"refreshPositions",value:function(){var e=v.get(this),t=e.target.coords,n=this.hot.view.wt.wtTable.getFirstVisibleRow(),o=this.hot.view.wt.wtTable.getLastVisibleRow(),r=this.hot.getSettings().fixedRowsTop,i=this.hot.countRows();t.row<r&&n>0&&this.hot.scrollViewportTo(n-1),t.row>=o&&o<i&&this.hot.scrollViewportTo(o+1,void 0,!0);var a=this.hot.view.wt.wtTable,s=e.target.TD,u=(0,l.offset)(this.hot.rootElement),c=this.hot.view.THEAD.offsetHeight+this.getRowsHeight(0,t.row),d=e.target.eventPageY-u.top+a.holder.scrollTop,h=a.hider.offsetHeight,f=a.TBODY.offsetTop,p=this.backlight.getOffset().top,m=this.backlight.getSize().height;u.top+a.holder.offsetHeight<e.target.eventPageY&&e.target.coords.row++,this.isFixedRowTop(t.row)&&(c+=a.holder.scrollTop),t.row<0?e.target.row=n>0?n-1:n:s.offsetHeight/2+c<=d?(e.target.row=t.row+1,c+=0===t.row?s.offsetHeight-1:s.offsetHeight):e.target.row=t.row;var g=d,y=c;d+m+p>=h?g=h-m-p:d+p<f&&(g=f+Math.abs(p)),c>=h-1&&(y=h-1);var _=0;this.hot.view.wt.wtOverlays.topOverlay&&(_=this.hot.view.wt.wtOverlays.topOverlay.clone.wtTable.TABLE.offsetHeight),t.row>=r&&y-a.holder.scrollTop<_&&this.hot.scrollViewportTo(t.row),this.backlight.setPosition(g),this.guideline.setPosition(y)}},{key:"updateRowsMapper",value:function(){var e=this.hot.countSourceRows(),t=this.rowsMapper._arrayMap.length;if(0===t)this.rowsMapper.createMap(e||this.hot.getSettings().startRows);else if(t<e){var n=e-t;this.rowsMapper.insertItems(t,n)}else if(t>e){var o=e-1,r=[];(0,s.arrayEach)(this.rowsMapper._arrayMap,function(e,t,n){e>o&&r.push(t)}),this.rowsMapper.removeItems(r)}}},{key:"registerEvents",value:function(){var e=this;this.eventManager.addEventListener(document.documentElement,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(document.documentElement,"mouseup",function(){return e.onMouseUp()})}},{key:"unregisterEvents",value:function(){this.eventManager.clear()}},{key:"onBeforeColumnSort",value:function(e,t){v.get(this).disallowMoving=void 0!==t}},{key:"onBeforeOnCellMouseDown",value:function(e,t,n,o){var r=this.hot.view.wt.wtTable,i=this.hot.selection.selectedHeader.rows,a=this.hot.getSelectedRange(),s=v.get(this);if(!a||!i||s.pressed||0!==e.button)return s.pressed=!1,s.rowsToMove.length=0,void(0,l.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui"]);var u=this.guideline.isBuilt()&&!this.guideline.isAppended(),c=this.backlight.isBuilt()&&!this.backlight.isAppended();u&&c&&(this.guideline.appendTo(r.hider),this.backlight.appendTo(r.hider));var d=a.from,h=a.to,f=Math.min(d.row,h.row),p=Math.max(d.row,h.row);if(t.col<0&&t.row>=f&&t.row<=p){o.row=!0,s.pressed=!0,s.target.eventPageY=e.pageY,s.target.coords=t,s.target.TD=n,s.rowsToMove=this.prepareRowsToMoving();var m=r.holder.scrollLeft+r.getColumnWidth(-1);this.backlight.setPosition(null,m),this.backlight.setSize(r.hider.offsetWidth-m,this.getRowsHeight(f,p+1)),this.backlight.setOffset(-1*(this.getRowsHeight(f,t.row)+e.layerY),null),(0,l.addClass)(this.hot.rootElement,"on-moving--rows"),this.refreshPositions()}else(0,l.removeClass)(this.hot.rootElement,"after-selection--rows"),s.pressed=!1,s.rowsToMove.length=0}},{key:"onMouseMove",value:function(e){var t=v.get(this);if(t.pressed){if(e.realTarget===this.backlight.element){var n=this.backlight.getSize().height;this.backlight.setSize(null,0),setTimeout(function(){this.backlight.setPosition(null,n)})}t.target.eventPageY=e.pageY,this.refreshPositions()}}},{key:"onBeforeOnCellMouseOver",value:function(e,t,n,o){var r=this.hot.getSelectedRange(),i=v.get(this);r&&i.pressed&&(i.rowsToMove.indexOf(t.row)>-1?(0,l.removeClass)(this.hot.rootElement,"show-ui"):(0,l.addClass)(this.hot.rootElement,"show-ui"),o.row=!0,o.column=!0,o.cell=!0,i.target.coords=t,i.target.TD=n)}},{key:"onMouseUp",value:function(){var e=v.get(this),t=e.target.row,n=e.rowsToMove.length;if(e.pressed=!1,e.backlightHeight=0,(0,l.removeClass)(this.hot.rootElement,["on-moving--rows","show-ui","after-selection--rows"]),this.hot.selection.selectedHeader.rows&&(0,l.addClass)(this.hot.rootElement,"after-selection--rows"),!(n<1||void 0===t||e.rowsToMove.indexOf(t)>-1||e.rowsToMove[n-1]===t-1)){if(this.moveRows(e.rowsToMove,t),this.persistentStateSave(),this.hot.render(),!e.disallowMoving){var o=this.rowsMapper.getIndexByValue(e.rowsToMove[0]),r=this.rowsMapper.getIndexByValue(e.rowsToMove[n-1]);this.changeSelection(o,r)}e.rowsToMove.length=0}}},{key:"onAfterScrollHorizontally",value:function(){var e=this.hot.view.wt.wtTable,t=e.getColumnWidth(-1)+e.holder.scrollLeft;this.backlight.setPosition(null,t),this.backlight.setSize(e.hider.offsetWidth-t)}},{key:"onAfterCreateRow",value:function(e,t){this.rowsMapper.shiftItems(e,t)}},{key:"onBeforeRemoveRow",value:function(e,t){var n=this;this.removedRows.length=0,!1!==e&&(0,u.rangeEach)(e,e+t-1,function(e){n.removedRows.push(n.hot.runHooks("modifyRow",e,n.pluginName))})}},{key:"onAfterRemoveRow",value:function(e,t){this.rowsMapper.unshiftItems(this.removedRows)}},{key:"onAfterLoadData",value:function(e){this.updateRowsMapper()}},{key:"onModifyRow",value:function(e,t){if(t!==this.pluginName){var n=this.rowsMapper.getValueByIndex(e);e=null===n?e:n}return e}},{key:"onUnmodifyRow",value:function(e){var t=this.rowsMapper.getIndexByValue(e);return null===t?e:t}},{key:"onAfterPluginsInitialized",value:function(){this.updateRowsMapper(),this.initialSettings(),this.backlight.build(),this.guideline.build()}},{key:"destroy",value:function(){this.backlight.destroy(),this.guideline.destroy(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}}]),t}();(0,d.registerPlugin)("ManualRowMove",y),t.default=y},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(149),a=(o=i)&&o.__esModule?o:{default:o},s=n(1),l=n(2),u=n(6),c=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.manualRowMove=t}return r(e,[{key:"createMap",value:function(e){var t=this,n=void 0===e?this._arrayMap.length:e;this._arrayMap.length=0,(0,u.rangeEach)(n-1,function(e){t._arrayMap[e]=e})}},{key:"destroy",value:function(){this._arrayMap=null}},{key:"moveRow",value:function(e,t){var n=this._arrayMap[e];this._arrayMap[e]=null,this._arrayMap.splice(t,0,n)}},{key:"clearNull",value:function(){this._arrayMap=(0,s.arrayFilter)(this._arrayMap,function(e){return null!==e})}}]),e}();(0,l.mixin)(c,a.default),t.default=c},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(152),a=(o=i)&&o.__esModule?o:{default:o},s=n(0),l=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),r(t,[{key:"build",value:function(){(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,s.addClass)(this._element,"ht__manualRowMove--backlight")}}]),t}();t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=n(152),a=(o=i)&&o.__esModule?o:{default:o},s=n(0),l=function(e){function t(){return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t),function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),r(t,[{key:"build",value:function(){(function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0})(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"build",this).call(this),(0,s.addClass)(this._element,"ht__manualRowMove--guideline")}}]),t}();t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=h(n(12)),a=n(0),s=h(n(4)),l=n(7),u=n(1),c=n(6),d=n(5);function h(e){return e&&e.__esModule?e:{default:e}}var f=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.currentTH=null,n.currentRow=null,n.selectedRows=[],n.currentHeight=null,n.newSize=null,n.startY=null,n.startHeight=null,n.startOffset=null,n.handle=document.createElement("DIV"),n.guide=document.createElement("DIV"),n.eventManager=new s.default(n),n.pressed=null,n.dblclick=0,n.autoresizeTimeout=null,n.manualRowHeights=[],(0,a.addClass)(n.handle,"manualRowResizer"),(0,a.addClass)(n.guide,"manualRowResizerGuide"),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().manualRowResize}},{key:"enablePlugin",value:function(){var e=this;if(!this.enabled){this.manualRowHeights=[];var n=this.hot.getSettings().manualRowResize,o=this.loadManualRowHeights();void 0!==o?this.manualRowHeights=o:Array.isArray(n)?this.manualRowHeights=n:this.manualRowHeights=[],this.addHook("modifyRowHeight",function(t,n){return e.onModifyRowHeight(t,n)}),this.bindEvents(),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this)}}},{key:"updatePlugin",value:function(){var e=this.hot.getSettings().manualRowResize;Array.isArray(e)?this.manualRowHeights=e:e||(this.manualRowHeights=[])}},{key:"disablePlugin",value:function(){r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"saveManualRowHeights",value:function(){this.hot.runHooks("persistentStateSave","manualRowHeights",this.manualRowHeights)}},{key:"loadManualRowHeights",value:function(){var e={};return this.hot.runHooks("persistentStateLoad","manualRowHeights",e),e.value}},{key:"setupHandlePosition",value:function(e){var t=this;this.currentTH=e;var n=this.hot.view.wt.wtTable.getCoords(e).row,o=(0,a.outerWidth)(this.currentTH);if(n>=0){var r=this.currentTH.getBoundingClientRect();if(this.currentRow=n,this.selectedRows=[],this.hot.selection.isSelected()&&this.hot.selection.selectedHeader.rows){var i=this.hot.getSelectedRange(),s=i.from,l=i.to,u=s.row,d=l.row;u>=d&&(u=l.row,d=s.row),this.currentRow>=u&&this.currentRow<=d?(0,c.rangeEach)(u,d,function(e){return t.selectedRows.push(e)}):this.selectedRows.push(this.currentRow)}else this.selectedRows.push(this.currentRow);this.startOffset=r.top-6,this.startHeight=parseInt(r.height,10),this.handle.style.left=r.left+"px",this.handle.style.top=this.startOffset+this.startHeight+"px",this.handle.style.width=o+"px",this.hot.rootElement.appendChild(this.handle)}}},{key:"refreshHandlePosition",value:function(){this.handle.style.top=this.startOffset+this.currentHeight+"px"}},{key:"setupGuidePosition",value:function(){var e=parseInt((0,a.outerWidth)(this.handle),10),t=parseInt(this.handle.style.left,10)+e,n=parseInt(this.hot.view.maximumVisibleElementWidth(0),10);(0,a.addClass)(this.handle,"active"),(0,a.addClass)(this.guide,"active"),this.guide.style.top=this.handle.style.top,this.guide.style.left=t+"px",this.guide.style.width=n-e+"px",this.hot.rootElement.appendChild(this.guide)}},{key:"refreshGuidePosition",value:function(){this.guide.style.top=this.handle.style.top}},{key:"hideHandleAndGuide",value:function(){(0,a.removeClass)(this.handle,"active"),(0,a.removeClass)(this.guide,"active")}},{key:"checkIfRowHeader",value:function(e){if(e!=this.hot.rootElement){var t=e.parentNode;return"TBODY"===t.tagName||this.checkIfRowHeader(t)}return!1}},{key:"getTHFromTargetElement",value:function(e){return"TABLE"!=e.tagName?"TH"==e.tagName?e:this.getTHFromTargetElement(e.parentNode):null}},{key:"onMouseOver",value:function(e){if(this.checkIfRowHeader(e.target)){var t=this.getTHFromTargetElement(e.target);t&&(this.pressed||this.setupHandlePosition(t))}}},{key:"afterMouseDownTimeout",value:function(){var e=this,t=function(){e.hot.forceFullRender=!0,e.hot.view.render(),e.hot.view.wt.wtOverlays.adjustElementsSize(!0)},n=function(n,o){var r=e.hot.runHooks("beforeRowResize",n,e.newSize,!0);void 0!==r&&(e.newSize=r),e.setManualSize(n,e.newSize),o&&t(),e.hot.runHooks("afterRowResize",n,e.newSize,!0)};this.dblclick>=2&&(this.selectedRows.length>1?((0,u.arrayEach)(this.selectedRows,function(e){n(e)}),t()):(0,u.arrayEach)(this.selectedRows,function(e){n(e,!0)})),this.dblclick=0,this.autoresizeTimeout=null}},{key:"onMouseDown",value:function(e){var t=this;(0,a.hasClass)(e.target,"manualRowResizer")&&(this.setupGuidePosition(),this.pressed=this.hot,null==this.autoresizeTimeout&&(this.autoresizeTimeout=setTimeout(function(){return t.afterMouseDownTimeout()},500),this.hot._registerTimeout(this.autoresizeTimeout)),this.dblclick++,this.startY=(0,l.pageY)(e),this.newSize=this.startHeight)}},{key:"onMouseMove",value:function(e){var t=this;this.pressed&&(this.currentHeight=this.startHeight+((0,l.pageY)(e)-this.startY),(0,u.arrayEach)(this.selectedRows,function(e){t.newSize=t.setManualSize(e,t.currentHeight)}),this.refreshHandlePosition(),this.refreshGuidePosition())}},{key:"onMouseUp",value:function(e){var t=this,n=function(){t.hot.forceFullRender=!0,t.hot.view.render(),t.hot.view.wt.wtOverlays.adjustElementsSize(!0)},o=function(e,o){t.hot.runHooks("beforeRowResize",e,t.newSize),o&&n(),t.saveManualRowHeights(),t.hot.runHooks("afterRowResize",e,t.newSize)};this.pressed&&(this.hideHandleAndGuide(),this.pressed=!1,this.newSize!=this.startHeight&&(this.selectedRows.length>1?((0,u.arrayEach)(this.selectedRows,function(e){o(e)}),n()):(0,u.arrayEach)(this.selectedRows,function(e){o(e,!0)})),this.setupHandlePosition(this.currentTH))}},{key:"bindEvents",value:function(){var e=this;this.eventManager.addEventListener(this.hot.rootElement,"mouseover",function(t){return e.onMouseOver(t)}),this.eventManager.addEventListener(this.hot.rootElement,"mousedown",function(t){return e.onMouseDown(t)}),this.eventManager.addEventListener(window,"mousemove",function(t){return e.onMouseMove(t)}),this.eventManager.addEventListener(window,"mouseup",function(t){return e.onMouseUp(t)})}},{key:"setManualSize",value:function(e,t){return e=this.hot.runHooks("modifyRow",e),this.manualRowHeights[e]=t,t}},{key:"onModifyRowHeight",value:function(e,t){if(this.enabled){var n=this.hot.getPlugin("autoRowSize"),o=n?n.heights[t]:null;t=this.hot.runHooks("modifyRow",t);var r=this.manualRowHeights[t];if(void 0!==r&&(r===o||r>(e||0)))return r}return e}}]),t}();(0,d.registerPlugin)("manualRowResize",f),t.default=f},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(8),i=(o=r)&&o.__esModule?o:{default:o},a=(n(5),n(7)),s=n(11);function l(){var e=[];return e.getInfo=function(e,t){for(var n=0,o=this.length;n<o;n++)if(this[n].row<=e&&this[n].row+this[n].rowspan-1>=e&&this[n].col<=t&&this[n].col+this[n].colspan-1>=t)return this[n]},e.setInfo=function(e){for(var t=0,n=this.length;t<n;t++)if(this[t].row===e.row&&this[t].col===e.col)return void(this[t]=e);this.push(e)},e.removeInfo=function(e,t){for(var n=0,o=this.length;n<o;n++)if(this[n].row===e&&this[n].col===t){this.splice(n,1);break}},e}function u(e){if(this.mergedCellInfoCollection=new l,Array.isArray(e))for(var t=0,n=e.length;t<n;t++)this.mergedCellInfoCollection.setInfo(e[t])}u.prototype.canMergeRange=function(e){return!e.isSingle()},u.prototype.mergeRange=function(e){if(this.canMergeRange(e)){var t=e.getTopLeftCorner(),n=e.getBottomRightCorner(),o={};o.row=t.row,o.col=t.col,o.rowspan=n.row-t.row+1,o.colspan=n.col-t.col+1,this.mergedCellInfoCollection.setInfo(o)}},u.prototype.mergeOrUnmergeSelection=function(e){this.mergedCellInfoCollection.getInfo(e.from.row,e.from.col)?this.unmergeSelection(e.from):this.mergeSelection(e)},u.prototype.mergeSelection=function(e){this.mergeRange(e)},u.prototype.unmergeSelection=function(e){var t=this.mergedCellInfoCollection.getInfo(e.row,e.col);this.mergedCellInfoCollection.removeInfo(t.row,t.col)},u.prototype.applySpanProperties=function(e,t,n){var o=this.mergedCellInfoCollection.getInfo(t,n);o?o.row===t&&o.col===n?(e.setAttribute("rowspan",o.rowspan),e.setAttribute("colspan",o.colspan)):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"),e.style.display="none"):(e.removeAttribute("rowspan"),e.removeAttribute("colspan"))},u.prototype.modifyTransform=function(e,t,n){var o,r,i=function(e,t){return t.col>=e.col&&t.col<=e.col+e.colspan-1},a=function(e){return new s.CellCoords(t.to.row+e.row,t.to.col+e.col)},l={row:n.row,col:n.col};if("modifyTransformStart"==e){var u;this.lastDesiredCoords||(this.lastDesiredCoords=new s.CellCoords(null,null));for(var c=new s.CellCoords(t.highlight.row,t.highlight.col),d=this.mergedCellInfoCollection.getInfo(c.row,c.col),h=0,f=this.mergedCellInfoCollection.length;h<f;h++){var p=this.mergedCellInfoCollection[h];if(p=new s.CellCoords(p.row+p.rowspan-1,p.col+p.colspan-1),t.includes(p))break}if(d){var m=new s.CellCoords(d.row,d.col),g=new s.CellCoords(d.row+d.rowspan-1,d.col+d.colspan-1);new s.CellRange(m,m,g).includes(this.lastDesiredCoords)||(this.lastDesiredCoords=new s.CellCoords(null,null)),l.row=this.lastDesiredCoords.row?this.lastDesiredCoords.row-c.row:l.row,l.col=this.lastDesiredCoords.col?this.lastDesiredCoords.col-c.col:l.col,n.row>0?l.row=d.row+d.rowspan-1-c.row+n.row:n.row<0&&(l.row=c.row-d.row+n.row),n.col>0?l.col=d.col+d.colspan-1-c.col+n.col:n.col<0&&(l.col=c.col-d.col+n.col)}u=new s.CellCoords(t.highlight.row+l.row,t.highlight.col+l.col);var v=this.mergedCellInfoCollection.getInfo(u.row,u.col);v&&(this.lastDesiredCoords=u,l={row:v.row-c.row,col:v.col-c.col})}else if("modifyTransformEnd"==e)for(var y=0,_=this.mergedCellInfoCollection.length;y<_;y++){var w=this.mergedCellInfoCollection[y],b=new s.CellCoords(w.row,w.col),C=new s.CellCoords(w.row+w.rowspan-1,w.col+w.colspan-1),M=new s.CellRange(b,b,C),k=t.getBordersSharedWith(M);if(M.isEqual(t))t.setDirection("NW-SE");else if(k.length>0){var S=t.highlight.isEqual(M.from);k.indexOf("top")>-1?t.to.isSouthEastOf(M.from)&&S?t.setDirection("NW-SE"):t.to.isSouthWestOf(M.from)&&S&&t.setDirection("NE-SW"):k.indexOf("bottom")>-1&&(t.to.isNorthEastOf(M.from)&&S?t.setDirection("SW-NE"):t.to.isNorthWestOf(M.from)&&S&&t.setDirection("SE-NW"))}u=a(l);var T=(o=w,(r=u).row>=o.row&&r.row<=o.row+o.rowspan-1),L=i(w,u);t.includesRange(M)&&(M.includes(u)||T||L)&&(T&&(l.row<0?l.row-=w.rowspan-1:l.row>0&&(l.row+=w.rowspan-1)),L&&(l.col<0?l.col-=w.colspan-1:l.col>0&&(l.col+=w.colspan-1)))}0!==l.row&&(n.row=l.row),0!==l.col&&(n.col=l.col)},u.prototype.shiftCollection=function(e,t,n){var o=[0,0];switch(e){case"right":o[0]+=1;break;case"left":o[0]-=1;break;case"down":o[1]+=1;break;case"up":o[1]-=1}for(var r=0;r<this.mergedCellInfoCollection.length;r++){var i=this.mergedCellInfoCollection[r];"right"===e||"left"===e?t<=i.col&&(i.col+=o[0]):t<=i.row&&(i.row+=o[1])}};var c=function(e){return function(t){if(this.getSettings().mergeCells){var n=this.getSelectedRange();if(this.mergeCells.modifyTransform(e,n,t),"modifyTransformEnd"===e){var o=this.countRows(),r=this.countCols();n.from.row<0?n.from.row=0:n.from.row>0&&n.from.row>=o&&(n.from.row=n.from-1),n.from.col<0?n.from.col=0:n.from.col>0&&n.from.col>=r&&(n.from.col=r-1)}}}},d=i.default.getSingleton();d.add("beforeInit",function(){var e=this.getSettings().mergeCells;e&&(this.mergeCells||(this.mergeCells=new u(e)))}),d.add("afterInit",function(){var e=this;e.mergeCells&&(e.view.wt.wtTable.getCell=function(t){if(e.getSettings().mergeCells){var n=e.mergeCells.mergedCellInfoCollection.getInfo(t.row,t.col);n&&(t=n)}return s.Table.prototype.getCell.call(this,t)})}),d.add("afterUpdateSettings",function(){var e=this.getSettings().mergeCells;if(e)if(this.mergeCells){if(this.mergeCells.mergedCellInfoCollection=new l,Array.isArray(e))for(var t=0,n=e.length;t<n;t++)this.mergeCells.mergedCellInfoCollection.setInfo(e[t])}else this.mergeCells=new u(e);else this.mergeCells&&(this.mergeCells.mergedCellInfoCollection=new l)}),d.add("beforeKeyDown",function(e){this.mergeCells&&(e.ctrlKey||e.metaKey)&&!e.altKey&&77===e.keyCode&&(this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render(),(0,a.stopImmediatePropagation)(e))}),d.add("modifyTransformStart",c("modifyTransformStart")),d.add("modifyTransformEnd",c("modifyTransformEnd")),d.add("beforeSetRangeEnd",function(e){if(this.lastDesiredCoords=null,this.getSettings().mergeCells){var t=this.getSelectedRange();t.highlight=new s.CellCoords(t.highlight.row,t.highlight.col),t.to=e;var n=!1;do{n=!1;for(var o=0,r=this.mergeCells.mergedCellInfoCollection.length;o<r;o++){var i=this.mergeCells.mergedCellInfoCollection[o],a=new s.CellCoords(i.row,i.col),l=new s.CellCoords(i.row+i.rowspan-1,i.col+i.colspan-1),u=new s.CellRange(a,a,l);t.expandByRange(u)&&(e.row=t.to.row,e.col=t.to.col,n=!0)}}while(n)}}),d.add("beforeDrawBorders",function(e,t){if(t&&"area"==t&&this.getSettings().mergeCells)for(var n=this.getSelectedRange(),o=new s.CellRange(n.from,n.from,n.from),r=new s.CellRange(n.to,n.to,n.to),i=0,a=this.mergeCells.mergedCellInfoCollection.length;i<a;i++){var l=this.mergeCells.mergedCellInfoCollection[i],u=new s.CellCoords(l.row,l.col),c=new s.CellCoords(l.row+l.rowspan-1,l.col+l.colspan-1),d=new s.CellRange(u,u,c);o.expandByRange(d)&&(e[0]=o.from.row,e[1]=o.from.col),r.expandByRange(d)&&(e[2]=r.from.row,e[3]=r.from.col)}}),d.add("afterIsMultipleSelection",function(e){if(e&&this.mergeCells){var t=this.mergeCells.mergedCellInfoCollection,n=this.getSelectedRange();for(var o in t)if(n.highlight.row==t[o].row&&n.highlight.col==t[o].col&&n.to.row==t[o].row+t[o].rowspan-1&&n.to.col==t[o].col+t[o].colspan-1)return!1}return e}),d.add("afterRenderer",function(e,t,n,o,r,i){this.mergeCells&&this.mergeCells.applySpanProperties(e,t,n)}),d.add("afterContextMenuDefaultOptions",function(e){this.getSettings().mergeCells&&(e.items.push({name:"---------"}),e.items.push({key:"mergeCells",name:function(){var e=this.getSelected();return this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1])?"Unmerge cells":"Merge cells"},callback:function(){this.mergeCells.mergeOrUnmergeSelection(this.getSelectedRange()),this.render()},disabled:function(){return this.selection.selectedHeader.corner}}))}),d.add("afterGetCellMeta",function(e,t,n){if(this.getSettings().mergeCells){var o=this.mergeCells.mergedCellInfoCollection.getInfo(e,t);!o||o.row==e&&o.col==t||(n.copyable=!1)}}),d.add("afterViewportRowCalculatorOverride",function e(t){if(this.getSettings().mergeCells)for(var n,o=this.countCols(),r=0;r<o;r++){if((n=this.mergeCells.mergedCellInfoCollection.getInfo(t.startRow,r))&&n.row<t.startRow)return t.startRow=n.row,e.call(this,t);if(n=this.mergeCells.mergedCellInfoCollection.getInfo(t.endRow,r)){var i=n.row+n.rowspan-1;if(i>t.endRow)return t.endRow=i,e.call(this,t)}}}),d.add("afterViewportColumnCalculatorOverride",function e(t){if(this.getSettings().mergeCells)for(var n,o=this.countRows(),r=0;r<o;r++){if((n=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.startColumn))&&n.col<t.startColumn)return t.startColumn=n.col,e.call(this,t);if(n=this.mergeCells.mergedCellInfoCollection.getInfo(r,t.endColumn)){var i=n.col+n.colspan-1;if(i>t.endColumn)return t.endColumn=i,e.call(this,t)}}}),d.add("modifyAutofillRange",function(e,t){if(this.getSettings().mergeCells&&!this.selection.isMultiple()){var n=this.mergeCells.mergedCellInfoCollection.getInfo(e[0],e[1]);n&&(e[0]=n.row,e[1]=n.col,e[2]=n.row+n.rowspan-1,e[3]=n.col+n.colspan-1)}}),d.add("afterCreateCol",function(e,t){this.mergeCells&&this.mergeCells.shiftCollection("right",e,t)}),d.add("afterRemoveCol",function(e,t){this.mergeCells&&this.mergeCells.shiftCollection("left",e,t)}),d.add("afterCreateRow",function(e,t){this.mergeCells&&this.mergeCells.shiftCollection("down",e,t)}),d.add("afterRemoveRow",function(e,t){this.mergeCells&&this.mergeCells.shiftCollection("up",e,t)}),t.default=u},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=(c(n(8)),n(0)),i=n(25),a=c(n(12)),s=c(n(4)),l=n(5),u=n(11);function c(e){return e&&e.__esModule?e:{default:e}}var d=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.dragged=[],n.eventManager=null,n.lastSetCell=null,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,a.default),o(t,[{key:"isEnabled",value:function(){return(0,i.isMobileBrowser)()}},{key:"enablePlugin",value:function(){this.enabled||(this.eventManager||(this.eventManager=new s.default(this)),this.registerListeners(),function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0}(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"registerListeners",value:function(){var e=this;function t(t){if(1===e.dragged.length)return e.dragged.splice(0,e.dragged.length),!0;var n=e.dragged.indexOf(t);if(-1==n)return!1;0===n?e.dragged=e.dragged.slice(0,1):1==n&&(e.dragged=e.dragged.slice(-1))}this.eventManager.addEventListener(this.hot.rootElement,"touchstart",function(t){var n=void 0;return(0,r.hasClass)(t.target,"topLeftSelectionHandle-HitArea")?(n=e.hot.getSelectedRange(),e.dragged.push("topLeft"),e.touchStartRange={width:n.getWidth(),height:n.getHeight(),direction:n.getDirection()},t.preventDefault(),!1):(0,r.hasClass)(t.target,"bottomRightSelectionHandle-HitArea")?(n=e.hot.getSelectedRange(),e.dragged.push("bottomRight"),e.touchStartRange={width:n.getWidth(),height:n.getHeight(),direction:n.getDirection()},t.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchend",function(n){return(0,r.hasClass)(n.target,"topLeftSelectionHandle-HitArea")?(t.call(e,"topLeft"),e.touchStartRange=void 0,n.preventDefault(),!1):(0,r.hasClass)(n.target,"bottomRightSelectionHandle-HitArea")?(t.call(e,"bottomRight"),e.touchStartRange=void 0,n.preventDefault(),!1):void 0}),this.eventManager.addEventListener(this.hot.rootElement,"touchmove",function(t){var n,o=(0,r.getWindowScrollTop)(),i=(0,r.getWindowScrollLeft)(),a=void 0,s=void 0,l=void 0,u=void 0,c=void 0,d=void 0;0!==e.dragged.length&&(n=document.elementFromPoint(t.touches[0].screenX-i,t.touches[0].screenY-o))&&n!==e.lastSetCell&&("TD"!=n.nodeName&&"TH"!=n.nodeName||(-1==(a=e.hot.getCoords(n)).col&&(a.col=0),l=(s=e.hot.getSelectedRange()).getWidth(),u=s.getHeight(),c=s.getDirection(),1==l&&1==u&&e.hot.selection.setRangeEnd(a),null!==(d=e.getCurrentRangeCoords(s,a,e.touchStartRange.direction,c,e.dragged[0])).start&&e.hot.selection.setRangeStart(d.start),e.hot.selection.setRangeEnd(d.end),e.lastSetCell=n),t.preventDefault())})}},{key:"getCurrentRangeCoords",value:function(e,t,n,o,r){var i=e.getTopLeftCorner(),a=e.getBottomRightCorner(),s=e.getBottomLeftCorner(),l=e.getTopRightCorner(),c={start:null,end:null};switch(n){case"NE-SW":switch(o){case"NE-SW":case"NW-SE":c="topLeft"==r?{start:new u.CellCoords(t.row,e.highlight.col),end:new u.CellCoords(s.row,t.col)}:{start:new u.CellCoords(e.highlight.row,t.col),end:new u.CellCoords(t.row,i.col)};break;case"SE-NW":"bottomRight"==r&&(c={start:new u.CellCoords(a.row,t.col),end:new u.CellCoords(t.row,i.col)})}break;case"NW-SE":switch(o){case"NE-SW":"topLeft"==r?c={start:t,end:s}:c.end=t;break;case"NW-SE":"topLeft"==r?c={start:t,end:a}:c.end=t;break;case"SE-NW":"topLeft"==r?c={start:t,end:i}:c.end=t;break;case"SW-NE":"topLeft"==r?c={start:t,end:l}:c.end=t}break;case"SW-NE":switch(o){case"NW-SE":c="bottomRight"==r?{start:new u.CellCoords(t.row,i.col),end:new u.CellCoords(s.row,t.col)}:{start:new u.CellCoords(i.row,t.col),end:new u.CellCoords(t.row,a.col)};break;case"SW-NE":c="topLeft"==r?{start:new u.CellCoords(e.highlight.row,t.col),end:new u.CellCoords(t.row,a.col)}:{start:new u.CellCoords(t.row,i.col),end:new u.CellCoords(i.row,t.col)};break;case"SE-NW":"bottomRight"==r?c={start:new u.CellCoords(t.row,l.col),end:new u.CellCoords(i.row,t.col)}:"topLeft"==r&&(c={start:s,end:t})}break;case"SE-NW":switch(o){case"NW-SE":case"NE-SW":case"SW-NE":"topLeft"==r&&(c.end=t);break;case"SE-NW":"topLeft"==r?c.end=t:c={start:t,end:i}}}return c}},{key:"isDragged",value:function(){return this.dragged.length>0}}]),t}();(0,l.registerPlugin)("multipleSelectionHandles",d),t.default=d},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=l(n(133)),i=l(n(150)),a=n(2),s=n(255);function l(e){return e&&e.__esModule?e:{default:e}}var u=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.observedData=null,this.observer=null,this.paused=!1,this.setObservedData(t)}return o(e,[{key:"setObservedData",value:function(e){var t=this;this.observer&&r.default.unobserve(this.observedData,this.observer),this.observedData=e,this.observer=r.default.observe(this.observedData,function(e){return t.onChange(e)})}},{key:"isPaused",value:function(){return this.paused}},{key:"pause",value:function(){this.paused=!0}},{key:"resume",value:function(){this.paused=!1}},{key:"onChange",value:function(e){this.runLocalHooks("change",(0,s.cleanPatches)(e))}},{key:"destroy",value:function(){r.default.unobserve(this.observedData,this.observer),this.observedData=null,this.observer=null}}]),e}();(0,a.mixin)(u,i.default),t.default=u},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),r=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},i=u(n(12)),a=(u(n(133)),u(n(253))),s=n(1),l=n(5);function u(e){return e&&e.__esModule?e:{default:e}}var c=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.observer=null,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,i.default),o(t,[{key:"isEnabled",value:function(){return this.hot.getSettings().observeChanges}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.observer||(this.observer=new a.default(this.hot.getSourceData()),this._exposePublicApi()),this.observer.addLocalHook("change",function(t){return e.onDataChange(t)}),this.addHook("afterCreateRow",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveRow",function(){return e.onAfterTableAlter()}),this.addHook("afterCreateCol",function(){return e.onAfterTableAlter()}),this.addHook("afterRemoveCol",function(){return e.onAfterTableAlter()}),this.addHook("afterChange",function(t,n){return e.onAfterTableAlter(n)}),this.addHook("afterLoadData",function(t){return e.onAfterLoadData(t)}),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"disablePlugin",value:function(){this.observer&&(this.observer.destroy(),this.observer=null,this._deletePublicApi()),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"onDataChange",value:function(e){var t=this;if(!this.observer.isPaused()){var n=this.pluginName+".change",o={add:function(e){isNaN(e.col)?t.hot.runHooks("afterCreateRow",e.row,1,n):t.hot.runHooks("afterCreateCol",e.col,1,n)},remove:function(e){isNaN(e.col)?t.hot.runHooks("afterRemoveRow",e.row,1,n):t.hot.runHooks("afterRemoveCol",e.col,1,n)},replace:function(e){t.hot.runHooks("afterChange",[e.row,e.col,null,e.value],n)}};(0,s.arrayEach)(e,function(e){o[e.op]&&o[e.op](e)}),this.hot.render()}this.hot.runHooks("afterChangesObserved")}},{key:"onAfterTableAlter",value:function(e){var t=this;"loadData"!==e&&(this.observer.pause(),this.hot.addHookOnce("afterChangesObserved",function(){return t.observer.resume()}))}},{key:"onAfterLoadData",value:function(e){e||this.observer.setObservedData(this.hot.getSourceData())}},{key:"destroy",value:function(){this.observer&&(this.observer.destroy(),this._deletePublicApi()),r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"destroy",this).call(this)}},{key:"_exposePublicApi",value:function(){var e=this,t=this.hot;t.pauseObservingChanges=function(){return e.observer.pause()},t.resumeObservingChanges=function(){return e.observer.resume()},t.isPausedObservingChanges=function(){return e.observer.isPaused()}}},{key:"_deletePublicApi",value:function(){var e=this.hot;delete e.pauseObservingChanges,delete e.resumeObservingChanges,delete e.isPausedObservingChanges}}]),t}();t.default=c,(0,l.registerPlugin)("observeChanges",c)},function(e,t,n){"use strict";t.__esModule=!0;var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(o=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&s.return&&s.return()}finally{if(r)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")};t.cleanPatches=function(e){var t=[];return e=(0,r.arrayFilter)(e,function(e){return!/[\/]length/gi.test(e.path)&&!!i(e.path)}),e=(0,r.arrayMap)(e,function(e){var t=i(e.path);return e.row=t.row,e.col=t.col,e}),e=(0,r.arrayFilter)(e,function(e){if(-1!==["add","remove"].indexOf(e.op)&&!isNaN(e.col)){if(-1!==t.indexOf(e.col))return!1;t.push(e.col)}return!0}),t.length=0,e},t.parsePath=i;var r=n(1);function i(e){var t=e.match(/^\/(\d+)\/?(.*)?$/);if(!t)return null;var n=o(t,3),r=n[1],i=n[2];return{row:parseInt(r,10),col:/^\d*$/.test(i)?parseInt(i,10):i}}},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(8),i=(o=r)&&o.__esModule?o:{default:o},a=(n(5),n(2));function s(e){var t,n,o,r=function(){window.localStorage[e+"__persistentStateKeys"]=JSON.stringify(t)};n=window.localStorage[e+"__persistentStateKeys"],o="string"==typeof n?JSON.parse(n):void 0,t=o||[],this.saveValue=function(n,o){window.localStorage[e+"_"+n]=JSON.stringify(o),-1==t.indexOf(n)&&(t.push(n),r())},this.loadValue=function(t,n){t=void 0===t?n:t;var o=window.localStorage[e+"_"+t];return void 0===o?void 0:JSON.parse(o)},this.reset=function(t){window.localStorage.removeItem(e+"_"+t)},this.resetAll=function(){for(var n=0;n<t.length;n++)window.localStorage.removeItem(e+"_"+t[n]);t=[],r()}}function l(){var e=this;this.init=function(){var t=this.getSettings().persistentState;e.enabled=!!t,e.enabled?(this.storage||(this.storage=new s(this.rootElement.id)),this.resetState=e.resetValue,o.call(this)):r.call(this)},this.saveValue=function(e,t){this.storage.saveValue(e,t)},this.loadValue=function(e,t){t.value=this.storage.loadValue(e)},this.resetValue=function(e){void 0===e?this.storage.resetAll():this.storage.reset(e)};var t={persistentStateSave:e.saveValue,persistentStateLoad:e.loadValue,persistentStateReset:e.resetValue};for(var n in t)(0,a.hasOwnProperty)(t,n)&&i.default.getSingleton().register(n);function o(){for(var e in t)(0,a.hasOwnProperty)(t,e)&&this.addHook(e,t[e])}function r(){for(var e in t)(0,a.hasOwnProperty)(t,e)&&this.removeHook(e,t[e])}}var u=new l;i.default.getSingleton().add("beforeInit",u.init),i.default.getSingleton().add("afterUpdateSettings",u.init),t.default=l},function(e,t,n){"use strict";t.__esModule=!0;var o,r,i,a,s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},l=n(8),u=(o=l)&&o.__esModule?o:{default:o},c=n(0),d=n(9);function h(e){this.query=function(t,n,o){var r=e.countRows(),i=e.countCols(),a=[];n||(n=h.global.getDefaultCallback()),o||(o=h.global.getDefaultQueryMethod());for(var s=0;s<r;s++)for(var l=0;l<i;l++){var u=e.getDataAtCell(s,l),c=e.getCellMeta(s,l),d=c.search.callback||n,f=(c.search.queryMethod||o)(t,u);if(f){var p={row:s,col:l,data:u};a.push(p)}d&&d(e,s,l,u,f)}return a}}function f(e,t,n,o,r,i,a){var l=null!==a.search&&"object"==s(a.search)&&a.search.searchResultClass||h.global.getDefaultSearchResultClass();a.isSearchResult?(0,c.addClass)(t,l):(0,c.removeClass)(t,l)}h.DEFAULT_CALLBACK=function(e,t,n,o,r){e.getCellMeta(t,n).isSearchResult=r},h.DEFAULT_QUERY_METHOD=function(e,t){return!(void 0===e||null==e||!e.toLowerCase||0===e.length)&&void 0!==t&&null!=t&&-1!=t.toString().toLowerCase().indexOf(e.toLowerCase())},h.DEFAULT_SEARCH_RESULT_CLASS="htSearchResult",h.global=(r=h.DEFAULT_CALLBACK,i=h.DEFAULT_QUERY_METHOD,a=h.DEFAULT_SEARCH_RESULT_CLASS,{getDefaultCallback:function(){return r},setDefaultCallback:function(e){r=e},getDefaultQueryMethod:function(){return i},setDefaultQueryMethod:function(e){i=e},getDefaultSearchResultClass:function(){return a},setDefaultSearchResultClass:function(e){a=e}});var p=(0,d.getRenderer)("base");function m(){this.getSettings().search?this.search=new h(this):delete this.search}(0,d.registerRenderer)("base",function(e,t,n,o,r,i,a){p.apply(this,arguments),f.apply(this,arguments)}),u.default.getSingleton().add("afterInit",m),u.default.getSingleton().add("afterUpdateSettings",m),t.default=h},function(e,t,n){"use strict";t.__esModule=!0;var o,r=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}(),i=function e(t,n,o){null===t&&(t=Function.prototype);var r=Object.getOwnPropertyDescriptor(t,n);if(void 0===r){var i=Object.getPrototypeOf(t);return null===i?void 0:e(i,n,o)}if("value"in r)return r.value;var a=r.get;return void 0!==a?a.call(o):void 0},a=n(0),s=n(1),l=n(12),u=(o=l)&&o.__esModule?o:{default:o},c=n(5),d=n(34),h=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.scrollbars=[],n.clones=[],n.lockedCollection=!1,n.freezeOverlays=!1,n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,u.default),r(t,[{key:"isEnabled",value:function(){return(0,d.isTouchSupported)()}},{key:"enablePlugin",value:function(){var e=this;this.enabled||(this.addHook("afterRender",function(){return e.onAfterRender()}),this.registerEvents(),i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"enablePlugin",this).call(this))}},{key:"updatePlugin",value:function(){this.lockedCollection=!1,i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"updatePlugin",this).call(this)}},{key:"disablePlugin",value:function(){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"disablePlugin",this).call(this)}},{key:"registerEvents",value:function(){var e=this;this.addHook("beforeTouchScroll",function(){return e.onBeforeTouchScroll()}),this.addHook("afterMomentumScroll",function(){return e.onAfterMomentumScroll()})}},{key:"onAfterRender",value:function(){if(!this.lockedCollection){var e=this.hot.view.wt.wtOverlays,t=e.topOverlay,n=e.bottomOverlay,o=e.leftOverlay,r=e.topLeftCornerOverlay,i=e.bottomLeftCornerOverlay;this.lockedCollection=!0,this.scrollbars.length=0,this.scrollbars.push(t),n.clone&&this.scrollbars.push(n),this.scrollbars.push(o),r&&this.scrollbars.push(r),i&&i.clone&&this.scrollbars.push(i),this.clones.length=0,t.needFullRender&&this.clones.push(t.clone.wtTable.holder.parentNode),n.needFullRender&&this.clones.push(n.clone.wtTable.holder.parentNode),o.needFullRender&&this.clones.push(o.clone.wtTable.holder.parentNode),r&&this.clones.push(r.clone.wtTable.holder.parentNode),i&&i.clone&&this.clones.push(i.clone.wtTable.holder.parentNode)}}},{key:"onBeforeTouchScroll",value:function(){this.freezeOverlays=!0,(0,s.arrayEach)(this.clones,function(e){(0,a.addClass)(e,"hide-tween")})}},{key:"onAfterMomentumScroll",value:function(){var e=this;this.freezeOverlays=!1,(0,s.arrayEach)(this.clones,function(e){(0,a.removeClass)(e,"hide-tween"),(0,a.addClass)(e,"show-tween")}),setTimeout(function(){(0,s.arrayEach)(e.clones,function(e){(0,a.removeClass)(e,"show-tween")})},400),(0,s.arrayEach)(this.scrollbars,function(e){e.refresh(),e.resetFixedPosition()}),this.hot.view.wt.wtOverlays.syncScrollWithMaster()}}]),t}();(0,c.registerPlugin)("touchScroll",h),t.default=h},function(e,t,n){"use strict";var o,r=n(8),i=(o=r)&&o.__esModule?o:{default:o},a=n(1),s=n(6),l=n(2),u=n(7),c=n(11);function d(e){var t=this;this.instance=e,this.doneActions=[],this.undoneActions=[],this.ignoreNewActions=!1,e.addHook("afterChange",function(e,n){e&&"UndoRedo.undo"!==n&&"UndoRedo.redo"!==n&&t.done(new d.ChangeAction(e))}),e.addHook("afterCreateRow",function(e,n,o){if("UndoRedo.undo"!==o&&"UndoRedo.undo"!==o&&"auto"!==o){var r=new d.CreateRowAction(e,n);t.done(r)}}),e.addHook("beforeRemoveRow",function(e,n,o,r){if("UndoRedo.undo"!==r&&"UndoRedo.redo"!==r&&"auto"!==r){var i=t.instance.getSourceDataArray();e=(i.length+e)%i.length;var a=(0,l.deepClone)(i.slice(e,e+n));t.done(new d.RemoveRowAction(e,a))}}),e.addHook("afterCreateCol",function(e,n,o){"UndoRedo.undo"!==o&&"UndoRedo.redo"!==o&&"auto"!==o&&t.done(new d.CreateColumnAction(e,n))}),e.addHook("beforeRemoveCol",function(n,o,r,i){if("UndoRedo.undo"!==i&&"UndoRedo.redo"!==i&&"auto"!==i){var a=t.instance.getSourceDataArray();n=(t.instance.countCols()+n)%t.instance.countCols();var l=[],u=[],c=[];(0,s.rangeEach)(a.length-1,function(t){var r=[],i=a[t];(0,s.rangeEach)(n,n+(o-1),function(t){r.push(i[e.runHooks("modifyCol",t)])}),l.push(r)}),(0,s.rangeEach)(o-1,function(t){c.push(e.runHooks("modifyCol",n+t))}),Array.isArray(e.getSettings().colHeaders)&&(0,s.rangeEach)(o-1,function(t){u.push(e.getSettings().colHeaders[e.runHooks("modifyCol",n+t)]||null)});var h=t.instance.getPlugin("manualColumnMove"),f=h.isEnabled()?h.columnsMapper.__arrayMap:[],p=new d.RemoveColumnAction(n,c,l,u,f);t.done(p)}}),e.addHook("beforeCellAlignment",function(e,n,o,r){var i=new d.CellAlignmentAction(e,n,o,r);t.done(i)}),e.addHook("beforeFilter",function(e){t.done(new d.FiltersAction(e))}),e.addHook("beforeRowMove",function(e,n){!1!==e&&t.done(new d.RowMoveAction(e,n))})}function h(){void 0===this.getSettings().undo||this.getSettings().undo?this.undoRedo||(this.undoRedo=new d(this),function(e){e.undo=function(){return e.undoRedo.undo()},e.redo=function(){return e.undoRedo.redo()},e.isUndoAvailable=function(){return e.undoRedo.isUndoAvailable()},e.isRedoAvailable=function(){return e.undoRedo.isRedoAvailable()},e.clearUndo=function(){return e.undoRedo.clear()}}(this),this.addHook("beforeKeyDown",f),this.addHook("afterChange",p)):this.undoRedo&&(delete this.undoRedo,function(e){delete e.undo,delete e.redo,delete e.isUndoAvailable,delete e.isRedoAvailable,delete e.clearUndo}(this),this.removeHook("beforeKeyDown",f),this.removeHook("afterChange",p))}function f(e){(e.ctrlKey||e.metaKey)&&!e.altKey&&(89===e.keyCode||e.shiftKey&&90===e.keyCode?(this.undoRedo.redo(),(0,u.stopImmediatePropagation)(e)):90===e.keyCode&&(this.undoRedo.undo(),(0,u.stopImmediatePropagation)(e)))}function p(e,t){if("loadData"===t)return this.undoRedo.clear()}d.prototype.done=function(e){this.ignoreNewActions||(this.doneActions.push(e),this.undoneActions.length=0)},d.prototype.undo=function(){if(this.isUndoAvailable()){var e=this.doneActions.pop(),t=(0,l.deepClone)(e),n=this.instance;if(!1===n.runHooks("beforeUndo",t))return;this.ignoreNewActions=!0;var o=this;e.undo(this.instance,function(){o.ignoreNewActions=!1,o.undoneActions.push(e)}),n.runHooks("afterUndo",t)}},d.prototype.redo=function(){if(this.isRedoAvailable()){var e=this.undoneActions.pop(),t=(0,l.deepClone)(e),n=this.instance;if(!1===n.runHooks("beforeRedo",t))return;this.ignoreNewActions=!0;var o=this;e.redo(this.instance,function(){o.ignoreNewActions=!1,o.doneActions.push(e)}),n.runHooks("afterRedo",t)}},d.prototype.isUndoAvailable=function(){return this.doneActions.length>0},d.prototype.isRedoAvailable=function(){return this.undoneActions.length>0},d.prototype.clear=function(){this.doneActions.length=0,this.undoneActions.length=0},d.Action=function(){},d.Action.prototype.undo=function(){},d.Action.prototype.redo=function(){},d.ChangeAction=function(e){this.changes=e,this.actionType="change"},(0,l.inherit)(d.ChangeAction,d.Action),d.ChangeAction.prototype.undo=function(e,t){for(var n=(0,l.deepClone)(this.changes),o=e.countEmptyRows(!0),r=e.countEmptyCols(!0),i=0,a=n.length;i<a;i++)n[i].splice(3,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(n,null,null,"UndoRedo.undo");for(var s=0,u=n.length;s<u;s++)e.getSettings().minSpareRows&&n[s][0]+1+e.getSettings().minSpareRows===e.countRows()&&o==e.getSettings().minSpareRows&&(e.alter("remove_row",parseInt(n[s][0]+1,10),e.getSettings().minSpareRows),e.undoRedo.doneActions.pop()),e.getSettings().minSpareCols&&n[s][1]+1+e.getSettings().minSpareCols===e.countCols()&&r==e.getSettings().minSpareCols&&(e.alter("remove_col",parseInt(n[s][1]+1,10),e.getSettings().minSpareCols),e.undoRedo.doneActions.pop())},d.ChangeAction.prototype.redo=function(e,t){for(var n=(0,l.deepClone)(this.changes),o=0,r=n.length;o<r;o++)n[o].splice(2,1);e.addHookOnce("afterChange",t),e.setDataAtRowProp(n,null,null,"UndoRedo.redo")},d.CreateRowAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_row"},(0,l.inherit)(d.CreateRowAction,d.Action),d.CreateRowAction.prototype.undo=function(e,t){var n=e.countRows(),o=e.getSettings().minSpareRows;this.index>=n&&this.index-o<n&&(this.index-=o),e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.amount,"UndoRedo.undo")},d.CreateRowAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateRow",t),e.alter("insert_row",this.index,this.amount,"UndoRedo.redo")},d.RemoveRowAction=function(e,t){this.index=e,this.data=t,this.actionType="remove_row"},(0,l.inherit)(d.RemoveRowAction,d.Action),d.RemoveRowAction.prototype.undo=function(e,t){e.alter("insert_row",this.index,this.data.length,"UndoRedo.undo"),e.addHookOnce("afterRender",t),e.populateFromArray(this.index,0,this.data,void 0,void 0,"UndoRedo.undo")},d.RemoveRowAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveRow",t),e.alter("remove_row",this.index,this.data.length,"UndoRedo.redo")},d.CreateColumnAction=function(e,t){this.index=e,this.amount=t,this.actionType="insert_col"},(0,l.inherit)(d.CreateColumnAction,d.Action),d.CreateColumnAction.prototype.undo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.undo")},d.CreateColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterCreateCol",t),e.alter("insert_col",this.index,this.amount,"UndoRedo.redo")},d.RemoveColumnAction=function(e,t,n,o,r){this.index=e,this.indexes=t,this.data=n,this.amount=this.data[0].length,this.headers=o,this.columnPositions=r.slice(0),this.actionType="remove_col"},(0,l.inherit)(d.RemoveColumnAction,d.Action),d.RemoveColumnAction.prototype.undo=function(e,t){var n,o=this,r=void 0,i=this.indexes.slice(0).sort(),l=function(e,t,n){return n[o.indexes.indexOf(i[t])]},u=[];(0,s.rangeEach)(this.data.length-1,function(e){u[e]=(0,a.arrayMap)(o.data[e],l)}),n=(0,a.arrayMap)(this.headers,l);var c=[];e.runHooks("beforeCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),(0,s.rangeEach)(this.data.length-1,function(t){r=e.getSourceDataAtRow(t),(0,s.rangeEach)(i.length-1,function(e){r.splice(i[e],0,u[t][e]),c.push([t,i[e],null,u[t][e]])})}),e.getPlugin("formulas")&&e.getPlugin("formulas").onAfterSetDataAtCell(c),void 0!==this.headers&&(0,s.rangeEach)(n.length-1,function(t){e.getSettings().colHeaders.splice(i[t],0,n[t])}),e.getPlugin("manualColumnMove")&&(e.getPlugin("manualColumnMove").columnsMapper.__arrayMap=this.columnPositions),e.addHookOnce("afterRender",t),e.runHooks("afterCreateCol",this.indexes[0],this.indexes[this.indexes.length-1],"UndoRedo.undo"),e.getPlugin("formulas")&&e.getPlugin("formulas").recalculateFull(),e.render()},d.RemoveColumnAction.prototype.redo=function(e,t){e.addHookOnce("afterRemoveCol",t),e.alter("remove_col",this.index,this.amount,"UndoRedo.redo")},d.CellAlignmentAction=function(e,t,n,o){this.stateBefore=e,this.range=t,this.type=n,this.alignment=o},d.CellAlignmentAction.prototype.undo=function(e,t){if(e.getPlugin("contextMenu").isEnabled()){for(var n=this.range.from.row;n<=this.range.to.row;n++)for(var o=this.range.from.col;o<=this.range.to.col;o++)e.setCellMeta(n,o,"className",this.stateBefore[n][o]||" htLeft");e.addHookOnce("afterRender",t),e.render()}},d.CellAlignmentAction.prototype.redo=function(e,t){e.getPlugin("contextMenu").isEnabled()&&(e.selectCell(this.range.from.row,this.range.from.col,this.range.to.row,this.range.to.col),e.getPlugin("contextMenu").executeCommand("alignment:"+this.alignment.replace("ht","").toLowerCase()),e.addHookOnce("afterRender",t),e.render())},d.FiltersAction=function(e){this.formulaStacks=e,this.actionType="filter"},(0,l.inherit)(d.FiltersAction,d.Action),d.FiltersAction.prototype.undo=function(e,t){var n=e.getPlugin("filters");e.addHookOnce("afterRender",t),n.formulaCollection.importAllFormulas(this.formulaStacks.slice(0,this.formulaStacks.length-1)),n.filter()},d.FiltersAction.prototype.redo=function(e,t){var n=e.getPlugin("filters");e.addHookOnce("afterRender",t),n.formulaCollection.importAllFormulas(this.formulaStacks),n.filter()},d.RowMoveAction=function(e,t){this.rows=e.slice(),this.target=t},(0,l.inherit)(d.RowMoveAction,d.Action),d.RowMoveAction.prototype.undo=function(e,t){var n=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t);for(var o=this.rows[0]<this.target?-1*this.rows.length:0,r=this.rows[0]>this.target?this.rows[0]+this.rows.length:this.rows[0],i=[],a=this.rows.length+o,s=o;s<a;s++)i.push(this.target+s);n.moveRows(i.slice(),r),e.render(),e.selection.setRangeStartOnly(new c.CellCoords(this.rows[0],0)),e.selection.setRangeEnd(new c.CellCoords(this.rows[this.rows.length-1],e.countCols()-1))},d.RowMoveAction.prototype.redo=function(e,t){var n=e.getPlugin("manualRowMove");e.addHookOnce("afterRender",t),n.moveRows(this.rows.slice(),this.target),e.render();var o=this.rows[0]<this.target?this.target-this.rows.length:this.target;e.selection.setRangeStartOnly(new c.CellCoords(o,0)),e.selection.setRangeEnd(new c.CellCoords(o+this.rows.length-1,e.countCols()-1))};var m=i.default.getSingleton();m.add("afterInit",h),m.add("afterUpdateSettings",h),m.register("beforeUndo"),m.register("afterUndo"),m.register("beforeRedo"),m.register("afterRedo")},function(e,t,n){"use strict";t.__esModule=!0;var o=n(0);t.default=function(e,t,n,r,i,a,s){s.className&&(t.className?t.className=t.className+" "+s.className:t.className=s.className),s.readOnly&&(0,o.addClass)(t,s.readOnlyCellClassName),!1===s.valid&&s.invalidCellClassName?(0,o.addClass)(t,s.invalidCellClassName):(0,o.removeClass)(t,s.invalidCellClassName),!1===s.wordWrap&&s.noWordWrapClassName&&(0,o.addClass)(t,s.noWordWrapClassName),!a&&s.placeholder&&(0,o.addClass)(t,s.placeholderCellClassName)}},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(0),i=n(4),a=(o=i)&&o.__esModule?o:{default:o},s=n(11),l=n(9),u=document.createElement("DIV");u.className="htAutocompleteWrapper";var c=document.createElement("DIV");c.className="htAutocompleteArrow",c.appendChild(document.createTextNode(String.fromCharCode(9660))),t.default=function(e,t,n,o,i,d,h){u.cloneNode(!0);var f=c.cloneNode(!0);if(h.allowHtml?(0,l.getRenderer)("html").apply(this,arguments):(0,l.getRenderer)("text").apply(this,arguments),t.appendChild(f),(0,r.addClass)(t,"htAutocomplete"),t.firstChild||t.appendChild(document.createTextNode(String.fromCharCode(160))),!e.acArrowListener){var p=new a.default(e);e.acArrowListener=function(i){(0,r.hasClass)(i.target,"htAutocompleteArrow")&&e.view.wt.getSetting("onCellDblClick",null,new s.CellCoords(n,o),t)},p.addEventListener(e.rootElement,"mousedown",e.acArrowListener),e.addHookOnce("afterDestroy",function(){p.destroy()})}}},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(0),i=n(27),a=n(4),s=(o=a)&&o.__esModule?o:{default:o},l=n(16),u=n(35),c=n(7),d=n(9),h=new WeakMap,f=new WeakMap,p="htBadValue";function m(e){return"INPUT"===e.tagName&&"checkbox"===e.getAttribute("type")}t.default=function(e,t,n,o,a,g,v){(0,d.getRenderer)("base").apply(this,arguments),function(e){var t=f.get(e);t||((t=new s.default(e)).addEventListener(e.rootElement,"click",function(t){return function(e,t){if(!m(e.target))return!1;var n=parseInt(e.target.getAttribute("data-row"),10),o=parseInt(e.target.getAttribute("data-col"),10);t.getCellMeta(n,o).readOnly&&e.preventDefault()}(t,e)}),t.addEventListener(e.rootElement,"mouseup",function(t){return function(e,t){m(e.target)&&setTimeout(t.listen,10)}(t,e)}),t.addEventListener(e.rootElement,"change",function(t){return function(e,t){if(!m(e.target))return!1;var n=parseInt(e.target.getAttribute("data-row"),10),o=parseInt(e.target.getAttribute("data-col"),10),r=t.getCellMeta(n,o);if(!r.readOnly){var i=null;i=e.target.checked?void 0===r.uncheckedTemplate||r.checkedTemplate:void 0!==r.uncheckedTemplate&&r.uncheckedTemplate,t.setDataAtCell(n,o,i)}}(t,e)}),f.set(e,t))}(e);var y=function(){var e=document.createElement("input");return e.className="htCheckboxRendererInput",e.type="checkbox",e.setAttribute("autocomplete","off"),e.setAttribute("tabindex","-1"),e.cloneNode(!1)}(),_=v.label,w=!1;if(void 0===v.checkedTemplate&&(v.checkedTemplate=!0),void 0===v.uncheckedTemplate&&(v.uncheckedTemplate=!1),(0,r.empty)(t),g===v.checkedTemplate||(0,i.equalsIgnoreCase)(g,v.checkedTemplate)?y.checked=!0:g===v.uncheckedTemplate||(0,i.equalsIgnoreCase)(g,v.uncheckedTemplate)?y.checked=!1:null===g?(0,r.addClass)(y,"noValue"):(y.style.display="none",(0,r.addClass)(y,p),w=!0),y.setAttribute("data-row",n),y.setAttribute("data-col",o),!w&&_){var b="";_.value?b="function"==typeof _.value?_.value.call(this,n,o,a,g):_.value:_.property&&(b=e.getDataAtRowProp(n,_.property));var C=function(e){var t=document.createElement("label");return t.className="htCheckboxRendererLabel",t.appendChild(document.createTextNode(e)),t.cloneNode(!0)}(b);"before"===_.position?C.appendChild(y):C.insertBefore(y,C.firstChild),y=C}function M(){var t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=e.getSelectedRange();if(n){for(var o=n.getTopLeftCorner(),r=n.getBottomRightCorner(),i=[],a=o.row;a<=r.row;a+=1)for(var s=o.col;s<=r.col;s+=1){var l=e.getCellMeta(a,s);if("checkbox"!==l.type)return;if(!0!==l.readOnly){void 0===l.checkedTemplate&&(l.checkedTemplate=!0),void 0===l.uncheckedTemplate&&(l.uncheckedTemplate=!1);var u=e.getDataAtCell(a,s);!1===t?u===l.checkedTemplate?i.push([a,s,l.uncheckedTemplate]):-1!==[l.uncheckedTemplate,null,void 0].indexOf(u)&&i.push([a,s,l.checkedTemplate]):i.push([a,s,l.uncheckedTemplate])}}i.length>0&&e.setDataAtCell(i)}}t.appendChild(y),w&&t.appendChild(document.createTextNode("#bad-value#")),h.has(e)||(h.set(e,!0),e.addHook("beforeKeyDown",function(t){var n=(0,u.partial)(l.isKey,t.keyCode);n("SPACE|ENTER|DELETE|BACKSPACE")&&!(0,c.isImmediatePropagationStopped)(t)&&function(t){var n=e.getSelectedRange();if(n)for(var o=n.getTopLeftCorner(),r=n.getBottomRightCorner(),i=o.row;i<=r.row;i++)for(var a=o.col;a<=r.col;a++){var s=e.getCellMeta(i,a);if("checkbox"!==s.type)return;var l=e.getCell(i,a);if(null==l)t(i,a,s);else{var u=l.querySelectorAll("input[type=checkbox]");u.length>0&&!s.readOnly&&t(u)}}}(function(){(0,c.stopImmediatePropagation)(t),t.preventDefault()}),n("SPACE|ENTER")&&M(),n("DELETE|BACKSPACE")&&M(!0)}))}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(0),r=n(9);t.default=function(e,t,n,i,a,s,l){(0,r.getRenderer)("base").apply(this,arguments),null==s&&(s=""),(0,o.fastInnerHTML)(t,s)}},function(e,t,n){"use strict";t.__esModule=!0;var o,r=n(86),i=(o=r)&&o.__esModule?o:{default:o},a=n(9),s=n(6);t.default=function(e,t,n,o,r,l,u){if((0,s.isNumeric)(l)){void 0!==u.language&&i.default.culture(u.language),l=(0,i.default)(l).format(u.format||"0");var c=u.className||"",d=c.length?c.split(" "):[];d.indexOf("htLeft")<0&&d.indexOf("htCenter")<0&&d.indexOf("htRight")<0&&d.indexOf("htJustify")<0&&d.push("htRight"),d.indexOf("htNumeric")<0&&d.push("htNumeric"),u.className=d.join(" ")}(0,a.getRenderer)("text")(e,t,n,o,r,l,u)}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(0),r=n(9),i=n(6);t.default=function(e,t,n,a,s,l,u){(0,r.getRenderer)("text").apply(this,arguments),l=t.innerHTML;var c=u.hashLength||l.length,d=u.hashSymbol||"*",h="";(0,i.rangeEach)(c-1,function(){h+=d}),(0,o.fastInnerHTML)(t,h)}},function(e,t,n){"use strict";t.__esModule=!0;var o=n(0),r=n(20),i=n(9);t.default=function(e,t,n,a,s,l,u){(0,i.getRenderer)("base").apply(this,arguments),!l&&u.placeholder&&(l=u.placeholder);var c=(0,r.stringify)(l);if(e.getSettings().trimWhitespace||(c=c.replace(/ /g,String.fromCharCode(160))),u.rendererTemplate){(0,o.empty)(t);var d=document.createElement("TEMPLATE");d.setAttribute("bind","{{}}"),d.innerHTML=u.rendererTemplate,HTMLTemplateElement.decorate(d),d.model=e.getSourceDataAtRow(n),t.appendChild(d)}else(0,o.fastInnerText)(t,c)}},function(e,t,n){"use strict";t.__esModule=!0;var o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],o=!0,r=!1,i=void 0;try{for(var a,s=e[Symbol.iterator]();!(o=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);o=!0);}catch(e){r=!0,i=e}finally{try{!o&&s.return&&s.return()}finally{if(r)throw i}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},r=n(0),i=n(25),a=c(n(4)),s=n(7),l=n(11),u=c(l);function c(e){return e&&e.__esModule?e:{default:e}}function d(e){var t=this,n=this;this.eventManager=new a.default(e),this.instance=e,this.settings=e.getSettings(),this.selectionMouseDown=!1;var o=e.rootElement.getAttribute("style");o&&e.rootElement.setAttribute("data-originalstyle",o),(0,r.addClass)(e.rootElement,"handsontable");var c,d=document.createElement("TABLE");(0,r.addClass)(d,"htCore"),e.getSettings().tableClassName&&(0,r.addClass)(d,e.getSettings().tableClassName),this.THEAD=document.createElement("THEAD"),d.appendChild(this.THEAD),this.TBODY=document.createElement("TBODY"),d.appendChild(this.TBODY),e.table=d,e.container.insertBefore(d,e.container.firstChild),this.eventManager.addEventListener(e.rootElement,"mousedown",function(e){this.selectionMouseDown=!0,n.isTextSelectionAllowed(e.target)||(h(),e.preventDefault(),window.focus())}),this.eventManager.addEventListener(e.rootElement,"mouseup",function(e){this.selectionMouseDown=!1}),this.eventManager.addEventListener(e.rootElement,"mousemove",function(e){this.selectionMouseDown&&!n.isTextSelectionAllowed(e.target)&&(h(),e.preventDefault())}),this.eventManager.addEventListener(document.documentElement,"keyup",function(t){e.selection.isInProgress()&&!t.shiftKey&&e.selection.finish()}),this.isMouseDown=function(){return c},this.eventManager.addEventListener(document.documentElement,"mouseup",function(t){e.selection.isInProgress()&&1===t.which&&e.selection.finish(),c=!1,(0,r.isOutsideInput)(document.activeElement)&&e.unlisten()}),this.eventManager.addEventListener(document.documentElement,"mousedown",function(t){var o=t.target,i=t.target,a=t.x||t.clientX,s=t.y||t.clientY;if(!c&&e.rootElement){if(i===e.view.wt.wtTable.holder){var l=(0,r.getScrollbarWidth)();if(document.elementFromPoint(a+l,s)!==e.view.wt.wtTable.holder||document.elementFromPoint(a,s+l)!==e.view.wt.wtTable.holder)return}else for(;i!==document.documentElement;){if(null===i){if(t.isTargetWebComponent)break;return}if(i===e.rootElement)return;i=i.parentNode}("function"==typeof n.settings.outsideClickDeselects?n.settings.outsideClickDeselects(o):n.settings.outsideClickDeselects)?e.deselectCell():e.destroyEditor()}}),this.eventManager.addEventListener(d,"selectstart",function(e){n.settings.fragmentSelection||(0,r.isInput)(e.target)||e.preventDefault()});var h=function(){window.getSelection?window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().removeAllRanges():document.selection&&document.selection.empty()},f=[new l.Selection({className:"current",border:{width:2,color:"#5292F7",cornerVisible:function(){return n.settings.fillHandle&&!n.isCellEdited()&&!e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!n.isCellEdited()&&!e.selection.isMultiple()}}}),new l.Selection({className:"area",border:{width:1,color:"#89AFF9",cornerVisible:function(){return n.settings.fillHandle&&!n.isCellEdited()&&e.selection.isMultiple()},multipleSelectionHandlesVisible:function(){return!n.isCellEdited()&&e.selection.isMultiple()}}}),new l.Selection({className:"highlight",highlightHeaderClassName:n.settings.currentHeaderClassName,highlightRowClassName:n.settings.currentRowClassName,highlightColumnClassName:n.settings.currentColClassName}),new l.Selection({className:"fill",border:{width:1,color:"red"}})];f.current=f[0],f.area=f[1],f.highlight=f[2],f.fill=f[3];var p={debug:function(){return n.settings.debug},externalRowCalculator:this.instance.getPlugin("autoRowSize")&&this.instance.getPlugin("autoRowSize").isEnabled(),table:d,preventOverflow:function(){return t.settings.preventOverflow},stretchH:function(){return n.settings.stretchH},data:e.getDataAtCell,totalRows:function(){return e.countRows()},totalColumns:function(){return e.countCols()},fixedColumnsLeft:function(){return n.settings.fixedColumnsLeft},fixedRowsTop:function(){return n.settings.fixedRowsTop},fixedRowsBottom:function(){return n.settings.fixedRowsBottom},minSpareRows:function(){return n.settings.minSpareRows},renderAllRows:n.settings.renderAllRows,rowHeaders:function(){var t=[];return e.hasRowHeaders()&&t.push(function(e,t){n.appendRowHeader(e,t)}),e.runHooks("afterGetRowHeaderRenderers",t),t},columnHeaders:function(){var t=[];return e.hasColHeaders()&&t.push(function(e,t){n.appendColHeader(e,t)}),e.runHooks("afterGetColumnHeaderRenderers",t),t},columnWidth:e.getColWidth,rowHeight:e.getRowHeight,cellRenderer:function(e,t,o){var r=n.instance.getCellMeta(e,t),i=n.instance.colToProp(t),a=n.instance.getDataAtRowProp(e,i);n.instance.hasHook("beforeValueRender")&&(a=n.instance.runHooks("beforeValueRender",a)),n.instance.runHooks("beforeRenderer",o,e,t,i,a,r),n.instance.getCellRenderer(r)(n.instance,o,e,t,i,a,r),n.instance.runHooks("afterRenderer",o,e,t,i,a,r)},selections:f,hideBorderOnMouseDownOver:function(){return n.settings.fragmentSelection},onCellMouseDown:function(t,o,r,i){var a={row:!1,column:!1,cells:!1};if(e.listen(),n.activeWt=i,c=!0,e.runHooks("beforeOnCellMouseDown",t,o,r,a),!(0,s.isImmediatePropagationStopped)(t)){var u=e.getSelectedRange(),d=e.selection,h=d.selectedHeader;if(t.shiftKey&&u)o.row>=0&&o.col>=0&&!a.cells?(d.setSelectedHeaders(!1,!1),d.setRangeEnd(o)):(h.cols||h.rows)&&o.row>=0&&o.col>=0&&!a.cells?(d.setSelectedHeaders(!1,!1),d.setRangeEnd(new l.CellCoords(o.row,o.col))):h.cols&&o.row<0&&!a.column?d.setRangeEnd(new l.CellCoords(u.to.row,o.col)):h.rows&&o.col<0&&!a.row?d.setRangeEnd(new l.CellCoords(o.row,u.to.col)):(!h.cols&&!h.rows&&o.col<0||h.cols&&o.col<0)&&!a.row?(d.setSelectedHeaders(!0,!1),d.setRangeStartOnly(new l.CellCoords(u.from.row,0)),d.setRangeEnd(new l.CellCoords(o.row,e.countCols()-1))):(!h.cols&&!h.rows&&o.row<0||h.rows&&o.row<0)&&!a.column&&(d.setSelectedHeaders(!1,!0),d.setRangeStartOnly(new l.CellCoords(0,u.from.col)),d.setRangeEnd(new l.CellCoords(e.countRows()-1,o.col)));else{var f=!0;if(u){var p=u.from,m=u.to,g=!d.inInSelection(o);if(o.row<0&&h.cols){var v=Math.min(p.col,m.col),y=Math.max(p.col,m.col);f=o.col<v||o.col>y}else if(o.col<0&&h.rows){var _=Math.min(p.row,m.row),w=Math.max(p.row,m.row);f=o.row<_||o.row>w}else f=g}var b=(0,s.isRightClick)(t),C=(0,s.isLeftClick)(t)||"touchstart"===t.type;o.row<0&&o.col>=0&&!a.column?(d.setSelectedHeaders(!1,!0),(C||b&&f)&&(d.setRangeStartOnly(new l.CellCoords(0,o.col)),d.setRangeEnd(new l.CellCoords(Math.max(e.countRows()-1,0),o.col),!1))):o.col<0&&o.row>=0&&!a.row?(d.setSelectedHeaders(!0,!1),(C||b&&f)&&(d.setRangeStartOnly(new l.CellCoords(o.row,0)),d.setRangeEnd(new l.CellCoords(o.row,Math.max(e.countCols()-1,0)),!1))):o.col>=0&&o.row>=0&&!a.cells?(C||b&&f)&&(d.setSelectedHeaders(!1,!1),d.setRangeStart(o)):o.col<0&&o.row<0&&(o.row=0,o.col=0,d.setSelectedHeaders(!1,!1,!0),d.setRangeStart(o))}e.runHooks("afterOnCellMouseDown",t,o,r),n.activeWt=n.wt}},onCellMouseOut:function(t,o,r,i){n.activeWt=i,e.runHooks("beforeOnCellMouseOut",t,o,r),(0,s.isImmediatePropagationStopped)(t)||(e.runHooks("afterOnCellMouseOut",t,o,r),n.activeWt=n.wt)},onCellMouseOver:function(t,o,r,i){var a={row:!1,column:!1,cell:!1};n.activeWt=i,e.runHooks("beforeOnCellMouseOver",t,o,r,a),(0,s.isImmediatePropagationStopped)(t)||(0===t.button&&c&&(o.row>=0&&o.col,e.selection.selectedHeader.cols&&!a.column?e.selection.setRangeEnd(new l.CellCoords(e.countRows()-1,o.col),!1):e.selection.selectedHeader.rows&&!a.row?e.selection.setRangeEnd(new l.CellCoords(o.row,e.countCols()-1),!1):a.cell||e.selection.setRangeEnd(o)),e.runHooks("afterOnCellMouseOver",t,o,r),n.activeWt=n.wt)},onCellMouseUp:function(t,o,r,i){n.activeWt=i,e.runHooks("beforeOnCellMouseUp",t,o,r),e.runHooks("afterOnCellMouseUp",t,o,r),n.activeWt=n.wt},onCellCornerMouseDown:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerMouseDown",t)},onCellCornerDblClick:function(t){t.preventDefault(),e.runHooks("afterOnCellCornerDblClick",t)},beforeDraw:function(e,t){n.beforeRender(e,t)},onDraw:function(e){n.onDraw(e)},onScrollVertically:function(){e.runHooks("afterScrollVertically")},onScrollHorizontally:function(){e.runHooks("afterScrollHorizontally")},onBeforeDrawBorders:function(t,n){e.runHooks("beforeDrawBorders",t,n)},onBeforeTouchScroll:function(){e.runHooks("beforeTouchScroll")},onAfterMomentumScroll:function(){e.runHooks("afterMomentumScroll")},onBeforeStretchingColumnWidth:function(t,n){return e.runHooks("beforeStretchingColumnWidth",t,n)},onModifyRowHeaderWidth:function(t){return e.runHooks("modifyRowHeaderWidth",t)},viewportRowCalculatorOverride:function(t){var o=e.countRows(),r=n.settings.viewportRowRenderingOffset;if("auto"===r&&n.settings.fixedRowsTop&&(r=10),"number"==typeof r&&(t.startRow=Math.max(t.startRow-r,0),t.endRow=Math.min(t.endRow+r,o-1)),"auto"===r){var i=t.startRow+t.endRow-t.startRow,a=Math.ceil(i/o*12);t.startRow=Math.max(t.startRow-a,0),t.endRow=Math.min(t.endRow+a,o-1)}e.runHooks("afterViewportRowCalculatorOverride",t)},viewportColumnCalculatorOverride:function(t){var o=e.countCols(),r=n.settings.viewportColumnRenderingOffset;if("auto"===r&&n.settings.fixedColumnsLeft&&(r=10),"number"==typeof r&&(t.startColumn=Math.max(t.startColumn-r,0),t.endColumn=Math.min(t.endColumn+r,o-1)),"auto"===r){var i=t.startColumn+t.endColumn-t.startColumn,a=Math.ceil(i/o*12);t.startRow=Math.max(t.startColumn-a,0),t.endColumn=Math.min(t.endColumn+a,o-1)}e.runHooks("afterViewportColumnCalculatorOverride",t)},rowHeaderWidth:function(){return n.settings.rowHeaderWidth},columnHeaderHeight:function(){var t=e.runHooks("modifyColumnHeaderHeight");return n.settings.columnHeaderHeight||t}};e.runHooks("beforeInitWalkontable",p),this.wt=new u.default(p),this.activeWt=this.wt,(0,i.isChrome)()||(0,i.isSafari)()||this.eventManager.addEventListener(e.rootElement,"wheel",function(e){e.preventDefault();var t=parseInt((0,r.getComputedStyle)(document.body)["font-size"],10),o=n.wt.wtOverlays.scrollableElement,i=e.wheelDeltaY||e.deltaY,a=e.wheelDeltaX||e.deltaX;switch(e.deltaMode){case 0:o.scrollLeft+=a,o.scrollTop+=i;break;case 1:o.scrollLeft+=a*t,o.scrollTop+=i*t}}),this.eventManager.addEventListener(n.wt.wtTable.spreader,"mousedown",function(e){e.target===n.wt.wtTable.spreader&&3===e.which&&(0,s.stopPropagation)(e)}),this.eventManager.addEventListener(n.wt.wtTable.spreader,"contextmenu",function(e){e.target===n.wt.wtTable.spreader&&3===e.which&&(0,s.stopPropagation)(e)}),this.eventManager.addEventListener(document.documentElement,"click",function(){n.settings.observeDOMVisibility&&n.wt.drawInterrupted&&(n.instance.forceFullRender=!0,n.render())})}d.prototype.isTextSelectionAllowed=function(e){if((0,r.isInput)(e))return!0;var t=(0,r.isChildOf)(e,this.instance.view.wt.wtTable.spreader);return!(!0!==this.settings.fragmentSelection||!t)||!("cell"!==this.settings.fragmentSelection||!this.isSelectedOnlyCell()||!t)||!(this.settings.fragmentSelection||!this.isCellEdited()||!this.isSelectedOnlyCell())},d.prototype.isSelectedOnlyCell=function(){var e=this.instance.getSelected()||[],t=o(e,4),n=t[0],r=t[1],i=t[2],a=t[3];return void 0!==n&&n===i&&r===a},d.prototype.isCellEdited=function(){var e=this.instance.getActiveEditor();return e&&e.isOpened()},d.prototype.beforeRender=function(e,t){e&&this.instance.runHooks("beforeRender",this.instance.forceFullRender,t)},d.prototype.onDraw=function(e){e&&this.instance.runHooks("afterRender",this.instance.forceFullRender)},d.prototype.render=function(){this.wt.draw(!this.instance.forceFullRender),this.instance.forceFullRender=!1,this.instance.renderCall=!1},d.prototype.getCellAtCoords=function(e,t){var n=this.wt.getCell(e,t);return n<0?null:n},d.prototype.scrollViewport=function(e){this.wt.scrollViewport(e)},d.prototype.appendRowHeader=function(e,t){if(t.firstChild){var n=t.firstChild;if(!(0,r.hasClass)(n,"relative"))return(0,r.empty)(t),void this.appendRowHeader(e,t);this.updateCellHeader(n.querySelector(".rowHeader"),e,this.instance.getRowHeader)}else{var o=document.createElement("div"),i=document.createElement("span");o.className="relative",i.className="rowHeader",this.updateCellHeader(i,e,this.instance.getRowHeader),o.appendChild(i),t.appendChild(o)}this.instance.runHooks("afterGetRowHeader",e,t)},d.prototype.appendColHeader=function(e,t){if(t.firstChild){var n=t.firstChild;(0,r.hasClass)(n,"relative")?this.updateCellHeader(n.querySelector(".colHeader"),e,this.instance.getColHeader):((0,r.empty)(t),this.appendColHeader(e,t))}else{var o=document.createElement("div"),i=document.createElement("span");o.className="relative",i.className="colHeader",this.updateCellHeader(i,e,this.instance.getColHeader),o.appendChild(i),t.appendChild(o)}this.instance.runHooks("afterGetColHeader",e,t)},d.prototype.updateCellHeader=function(e,t,n){var o=t,i=this.wt.wtOverlays.getParentOverlay(e)||this.wt;e.parentNode&&((0,r.hasClass)(e,"colHeader")?o=i.wtTable.columnFilter.sourceToRendered(t):(0,r.hasClass)(e,"rowHeader")&&(o=i.wtTable.rowFilter.sourceToRendered(t))),o>-1?(0,r.fastInnerHTML)(e,n(t)):((0,r.fastInnerText)(e,String.fromCharCode(160)),(0,r.addClass)(e,"cornerHeader"))},d.prototype.maximumVisibleElementWidth=function(e){var t=this.wt.wtViewport.getWorkspaceWidth()-e;return t>0?t:0},d.prototype.maximumVisibleElementHeight=function(e){var t=this.wt.wtViewport.getWorkspaceHeight()-e;return t>0?t:0},d.prototype.mainViewIsActive=function(){return this.wt===this.activeWt},d.prototype.destroy=function(){this.wt.destroy(),this.eventManager.destroy()},t.default=d},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var i=function e(t){r(this,e),this.data=t,this.next=null,this.prev=null},a=function(){function e(){r(this,e),this.first=null,this.last=null}return o(e,[{key:"push",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var n=this.last;this.last=t,t.prev=n,n.next=t}}},{key:"unshift",value:function(e){var t=new i(e);if(null===this.first)this.first=t,this.last=t;else{var n=this.first;this.first=t,t.next=n,n.prev=t}}},{key:"inorder",value:function(e){for(var t=this.first;t;)e(t),t=t.next}},{key:"remove",value:function(e){if(null===this.first)return!1;for(var t=this.first,n=void 0,o=void 0;t;){if(t.data===e)return n=t.next,o=t.prev,n&&(n.prev=o),o&&(o.next=n),t===this.first&&(this.first=n),t===this.last&&(this.last=o),!0;t=t.next}return!1}},{key:"hasCycle",value:function(){for(var e=this.first,t=this.first;;){if(null===e)return!1;if(null===(e=e.next))return!1;if((e=e.next)===(t=t.next))return!0}}},{key:"pop",value:function(){if(null===this.last)return null;var e=this.last;return this.last=this.last.prev,e}},{key:"shift",value:function(){if(null===this.first)return null;var e=this.first;return this.first=this.first.next,e}},{key:"recursiveReverse",value:function(){if(this.first){!function e(t,n){n&&(e(n,n.next),n.next=t)}(this.first,this.first.next),this.first.next=null;var e=this.first;this.first=this.last,this.last=e}}},{key:"reverse",value:function(){if(this.first&&this.first.next){for(var e=this.first.next,t=this.first,n=void 0;e;)n=e.next,e.next=t,t.prev=e,t=e,e=n;this.first.next=null,this.last.prev=null,n=this.first,this.first=t,this.last=n}}}]),e}();t.NodeStructure=i,t.default=a},function(e,t,n){"use strict";t.__esModule=!0;var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();t.parseDelay=a;var r=n(34),i=function(){function e(t,n){var o=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.timer=null,this.func=t,this.delay=a(n),this.stopped=!0,this._then=null,this._callback=function(){return o.__callback()}}return o(e,null,[{key:"create",value:function(t,n){return new e(t,n)}}]),o(e,[{key:"start",value:function(){return this.stopped&&(this._then=Date.now(),this.stopped=!1,this.timer=(0,r.requestAnimationFrame)(this._callback)),this}},{key:"stop",value:function(){return this.stopped||(this.stopped=!0,(0,r.cancelAnimationFrame)(this.timer),this.timer=null),this}},{key:"__callback",value:function(){if(this.timer=(0,r.requestAnimationFrame)(this._callback),this.delay){var e=Date.now(),t=e-this._then;t>this.delay&&(this._then=e-t%this.delay,this.func())}else this.func()}}]),e}();function a(e){return"string"==typeof e&&/fps$/.test(e)&&(e=1e3/parseInt(e.replace("fps","")||0,10)),e}t.default=i},function(e,t,n){"use strict";t.__esModule=!0,t.default=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:a,o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t.length;if(Math.abs(r-o)<=1)return[];var i=Math.ceil((o+r)/2);return e(t,n,o,i),e(t,n,i,r),s(t,n,o,i,r)},t.merge=s;var o,r=n(268),i=(o=r)&&o.__esModule?o:{default:o},a=function(e,t){var n=e.toString(),o=t.toString();return n===o?0:n<o?-1:1};function s(e,t,n,o,r){for(var a=new i.default,s=new i.default,l=o-n,u=r-o,c=Math.max(l,u),d=r-n,h=0;h<c;h+=1)h<l&&a.push(e[n+h]),h<u&&s.push(e[o+h]);for(var f=0;f<d;)a.first&&s.first?t(a.first.data,s.first.data)>0?e[n+f]=s.shift().data:e[n+f]=a.shift().data:a.first?e[n+f]=a.shift().data:e[n+f]=s.shift().data,f+=1;return e}},function(e,t,n){"use strict";function o(e,t){var n=e;return function(e){for(var o=!1,r=0,i=e.length;r<i;r++)if(n===e[r]){o=!0;break}t(o)}}t.__esModule=!0,t.default=function(e,t){null==e&&(e=""),this.allowEmpty&&""===e?t(!0):this.strict&&this.source?"function"==typeof this.source?this.source(e,o(e,t)):o(e,t)(this.source):t(!0)}},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t){var n=!0,o=(0,s.getEditorInstance)("date",this.instance);null==e&&(e="");var r=(0,i.default)(new Date(e)).isValid()||(0,i.default)(e,o.defaultDateFormat).isValid(),a=(0,i.default)(e,this.dateFormat||o.defaultDateFormat,!0).isValid();if(this.allowEmpty&&""===e&&(r=!0,a=!0),r||(n=!1),!r&&a&&(n=!0),r&&!a)if(!0===this.correctFormat){var u=l(e,this.dateFormat),c=this.instance.runHooks("unmodifyRow",this.row),d=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(c,d,u,"dateValidator"),n=!0}else n=!1;t(n)},t.correctFormat=l;var o,r=n(62),i=(o=r)&&o.__esModule?o:{default:o},a=n(88),s=n(14);function l(e,t){var n=(0,i.default)((0,a.getNormalizedDate)(e)),o=(0,i.default)(e,t),r=e.search(/[A-z]/g)>-1;return(n.isValid()&&n.format("x")===o.format("x")||!o.isValid()||r?n:o).format(t)}},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t){null==e&&(e=""),this.allowEmpty&&""===e?t(!0):t(""!==e&&/^-?\d*(\.|,)?\d*$/.test(e))}},function(e,t,n){"use strict";t.__esModule=!0,t.default=function(e,t){var n=!0,o=this.timeFormat||"h:mm:ss a";null===e&&(e=""),e=/^\d{3,}$/.test(e)?parseInt(e,10):e;var r=/^\d{1,2}$/.test(e);r&&(e+=":00");var s=(0,i.default)(e,a,!0).isValid()?(0,i.default)(e):(0,i.default)(e,o),l=s.isValid(),u=(0,i.default)(e,o,!0).isValid()&&!r;if(this.allowEmpty&&""===e&&(l=!0,u=!0),l||(n=!1),!l&&u&&(n=!0),l&&!u)if(!0===this.correctFormat){var c=s.format(o),d=this.instance.runHooks("unmodifyRow",this.row),h=this.instance.runHooks("unmodifyCol",this.col);this.instance.setDataAtCell(d,h,c,"timeValidator"),n=!0}else n=!1;t(n)};var o,r=n(62),i=(o=r)&&o.__esModule?o:{default:o},a=["YYYY-MM-DDTHH:mm:ss.SSSZ","X","x"]},function(e,t,n){"use strict";var o=n(41),r=n(60),i=n(24);e.exports=[].copyWithin||function(e,t){var n=o(this),a=i(n.length),s=r(e,a),l=r(t,a),u=arguments.length>2?arguments[2]:void 0,c=Math.min((void 0===u?a:r(u,a))-l,a-s),d=1;for(l<s&&s<l+c&&(d=-1,l+=c-1,s+=c-1);c-- >0;)l in n?n[s]=n[l]:delete n[s],s+=d,l+=d;return n}},function(e,t,n){"use strict";var o=n(41),r=n(60),i=n(24);e.exports=function(e){for(var t=o(this),n=i(t.length),a=arguments.length,s=r(a>1?arguments[1]:void 0,n),l=a>2?arguments[2]:void 0,u=void 0===l?n:r(l,n);u>s;)t[s++]=e;return t}},function(e,t,n){var o=n(15),r=n(162),i=n(10)("species");e.exports=function(e){var t;return r(e)&&("function"!=typeof(t=e.constructor)||t!==Array&&!r(t.prototype)||(t=void 0),o(t)&&null===(t=t[i])&&(t=void 0)),void 0===t?Array:t}},function(e,t,n){var o=n(277);e.exports=function(e,t){return new(o(e))(t)}},function(e,t,n){var o=n(39),r=n(58),i=n(47);e.exports=function(e){var t=o(e),n=r.f;if(n)for(var a,s=n(e),l=i.f,u=0;s.length>u;)l.call(e,a=s[u++])&&t.push(a);return t}},function(e,t,n){"use strict";var o=n(18);e.exports=function(){var e=o(this),t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),e.unicode&&(t+="u"),e.sticky&&(t+="y"),t}},function(e,t,n){var o=n(15),r=n(171).set;e.exports=function(e,t,n){var i,a=t.constructor;return a!==n&&"function"==typeof a&&(i=a.prototype)!==n.prototype&&o(i)&&r&&r(e,i),e}},function(e,t){e.exports=function(e,t,n){var o=void 0===n;switch(t.length){case 0:return o?e():e.call(n);case 1:return o?e(t[0]):e.call(n,t[0]);case 2:return o?e(t[0],t[1]):e.call(n,t[0],t[1]);case 3:return o?e(t[0],t[1],t[2]):e.call(n,t[0],t[1],t[2]);case 4:return o?e(t[0],t[1],t[2],t[3]):e.call(n,t[0],t[1],t[2],t[3])}return e.apply(n,t)}},function(e,t,n){"use strict";var o=n(78),r=n(40),i=n(48),a={};n(32)(a,n(10)("iterator"),function(){return this}),e.exports=function(e,t,n){e.prototype=o(a,{next:r(1,n)}),i(e,t+" Iterator")}},function(e,t,n){var o=n(39),r=n(23);e.exports=function(e,t){for(var n,i=r(e),a=o(i),s=a.length,l=0;s>l;)if(i[n=a[l++]]===t)return n}},function(e,t,n){var o=n(13),r=n(84).set,i=o.MutationObserver||o.WebKitMutationObserver,a=o.process,s=o.Promise,l="process"==n(38)(a);e.exports=function(){var e,t,n,u=function(){var o,r;for(l&&(o=a.domain)&&o.exit();e;){r=e.fn,e=e.next;try{r()}catch(o){throw e?n():t=void 0,o}}t=void 0,o&&o.enter()};if(l)n=function(){a.nextTick(u)};else if(i){var c=!0,d=document.createTextNode("");new i(u).observe(d,{characterData:!0}),n=function(){d.data=c=!c}}else if(s&&s.resolve){var h=s.resolve();n=function(){h.then(u)}}else n=function(){r.call(o,u)};return function(o){var r={fn:o,next:void 0};t&&(t.next=r),e||(e=r,n()),t=r}}},function(e,t,n){var o=n(19),r=n(18),i=n(39);e.exports=n(21)?Object.defineProperties:function(e,t){r(e);for(var n,a=i(t),s=a.length,l=0;s>l;)o.f(e,n=a[l++],t[n]);return e}},function(e,t,n){var o=n(23),r=n(80).f,i={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];e.exports.f=function(e){return a&&"[object Window]"==i.call(e)?function(e){try{return r(e)}catch(e){return a.slice()}}(e):r(o(e))}},function(e,t,n){var o=n(22),r=n(41),i=n(81)("IE_PROTO"),a=Object.prototype;e.exports=Object.getPrototypeOf||function(e){return e=r(e),o(e,i)?e[i]:"function"==typeof e.constructor&&e instanceof e.constructor?e.constructor.prototype:e instanceof Object?a:null}},function(e,t,n){var o=n(80),r=n(58),i=n(18),a=n(13).Reflect;e.exports=a&&a.ownKeys||function(e){var t=o.f(i(e)),n=r.f;return n?t.concat(n(e)):t}},function(e,t){e.exports=Object.is||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}},function(e,t,n){var o=n(18),r=n(71),i=n(10)("species");e.exports=function(e,t){var n,a=o(e).constructor;return void 0===a||null==(n=o(a)[i])?t:r(n)}},function(e,t,n){var o=n(61),r=n(30);e.exports=function(e){return function(t,n){var i,a,s=String(r(t)),l=o(n),u=s.length;return l<0||l>=u?e?"":void 0:(i=s.charCodeAt(l))<55296||i>56319||l+1===u||(a=s.charCodeAt(l+1))<56320||a>57343?e?s.charAt(l):i:e?s.slice(l,l+2):a-56320+(i-55296<<10)+65536}}},function(e,t,n){var o=n(13),r=n(44),i=n(57),a=n(175),s=n(19).f;e.exports=function(e){var t=r.Symbol||(r.Symbol=i?{}:o.Symbol||{});"_"==e.charAt(0)||e in t||s(t,e,{value:a.f(e)})}},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){},function(e,t){e.exports=n},function(e,t){e.exports=o}])},e.exports=o(n(3),n(408),n(470),n(471))},function(e,t,n){"use strict";var o=n(6);e.exports={_set:function(e,t){return o.merge(this[e]||(this[e]={}),t)}}},,,,,,,,function(e,t,n){e.exports=function(){"use strict";var e=navigator.userAgent,t=navigator.platform,n=/gecko\/\d/i.test(e),o=/MSIE \d/.test(e),r=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(e),i=/Edge\/(\d+)/.exec(e),a=o||r||i,s=a&&(o?document.documentMode||6:+(i||r)[1]),l=!i&&/WebKit\//.test(e),u=l&&/Qt\/\d+\.\d+/.test(e),c=!i&&/Chrome\//.test(e),d=/Opera\//.test(e),h=/Apple Computer/.test(navigator.vendor),f=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(e),p=/PhantomJS/.test(e),m=!i&&/AppleWebKit/.test(e)&&/Mobile\/\w+/.test(e),g=/Android/.test(e),v=m||g||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(e),y=m||/Mac/.test(t),_=/\bCrOS\b/.test(e),w=/win/i.test(t),b=d&&e.match(/Version\/(\d*\.\d*)/);b&&(b=Number(b[1])),b&&b>=15&&(d=!1,l=!0);var C=y&&(u||d&&(null==b||b<12.11)),M=n||a&&s>=9;function k(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var S,T=function(e,t){var n=e.className,o=k(t).exec(n);if(o){var r=n.slice(o.index+o[0].length);e.className=n.slice(0,o.index)+(r?o[1]+r:"")}};function L(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function x(e,t){return L(e).appendChild(t)}function D(e,t,n,o){var r=document.createElement(e);if(n&&(r.className=n),o&&(r.style.cssText=o),"string"==typeof t)r.appendChild(document.createTextNode(t));else if(t)for(var i=0;i<t.length;++i)r.appendChild(t[i]);return r}function O(e,t,n,o){var r=D(e,t,n,o);return r.setAttribute("role","presentation"),r}function E(e,t){if(3==t.nodeType&&(t=t.parentNode),e.contains)return e.contains(t);do{if(11==t.nodeType&&(t=t.host),t==e)return!0}while(t=t.parentNode)}function R(){var e;try{e=document.activeElement}catch(t){e=document.body||null}for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function A(e,t){var n=e.className;k(t).test(n)||(e.className+=(n?" ":"")+t)}function H(e,t){for(var n=e.split(" "),o=0;o<n.length;o++)n[o]&&!k(n[o]).test(t)&&(t+=" "+n[o]);return t}S=document.createRange?function(e,t,n,o){var r=document.createRange();return r.setEnd(o||e,n),r.setStart(e,t),r}:function(e,t,n){var o=document.body.createTextRange();try{o.moveToElementText(e.parentNode)}catch(e){return o}return o.collapse(!0),o.moveEnd("character",n),o.moveStart("character",t),o};var Y=function(e){e.select()};function P(e){var t=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,t)}}function N(e,t,n){for(var o in t||(t={}),e)!e.hasOwnProperty(o)||!1===n&&t.hasOwnProperty(o)||(t[o]=e[o]);return t}function I(e,t,n,o,r){null==t&&-1==(t=e.search(/[^\s\u00a0]/))&&(t=e.length);for(var i=o||0,a=r||0;;){var s=e.indexOf("\t",i);if(s<0||s>=t)return a+(t-i);a+=s-i,a+=n-a%n,i=s+1}}m?Y=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:a&&(Y=function(e){try{e.select()}catch(e){}});var W=function(){this.id=null};function j(e,t){for(var n=0;n<e.length;++n)if(e[n]==t)return n;return-1}W.prototype.set=function(e,t){clearTimeout(this.id),this.id=setTimeout(t,e)};var F=30,z={toString:function(){return"CodeMirror.Pass"}},B={scroll:!1},V={origin:"*mouse"},U={origin:"+move"};function K(e,t,n){for(var o=0,r=0;;){var i=e.indexOf("\t",o);-1==i&&(i=e.length);var a=i-o;if(i==e.length||r+a>=t)return o+Math.min(a,t-r);if(r+=i-o,o=i+1,(r+=n-r%n)>=t)return o}}var G=[""];function X(e){for(;G.length<=e;)G.push(J(G)+" ");return G[e]}function J(e){return e[e.length-1]}function q(e,t){for(var n=[],o=0;o<e.length;o++)n[o]=t(e[o],o);return n}function Q(){}function $(e,t){var n;return Object.create?n=Object.create(e):(Q.prototype=e,n=new Q),t&&N(t,n),n}var Z=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function ee(e){return/\w/.test(e)||e>"€"&&(e.toUpperCase()!=e.toLowerCase()||Z.test(e))}function te(e,t){return t?!!(t.source.indexOf("\\w")>-1&&ee(e))||t.test(e):ee(e)}function ne(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}var oe=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function re(e){return e.charCodeAt(0)>=768&&oe.test(e)}function ie(e,t,n){for(;(n<0?t>0:t<e.length)&&re(e.charAt(t));)t+=n;return t}function ae(e,t,n){for(var o=t>n?-1:1;;){if(t==n)return t;var r=(t+n)/2,i=o<0?Math.ceil(r):Math.floor(r);if(i==t)return e(i)?t:n;e(i)?n=i:t=i+o}}function se(e,t,o){var r=this;this.input=o,r.scrollbarFiller=D("div",null,"CodeMirror-scrollbar-filler"),r.scrollbarFiller.setAttribute("cm-not-content","true"),r.gutterFiller=D("div",null,"CodeMirror-gutter-filler"),r.gutterFiller.setAttribute("cm-not-content","true"),r.lineDiv=O("div",null,"CodeMirror-code"),r.selectionDiv=D("div",null,null,"position: relative; z-index: 1"),r.cursorDiv=D("div",null,"CodeMirror-cursors"),r.measure=D("div",null,"CodeMirror-measure"),r.lineMeasure=D("div",null,"CodeMirror-measure"),r.lineSpace=O("div",[r.measure,r.lineMeasure,r.selectionDiv,r.cursorDiv,r.lineDiv],null,"position: relative; outline: none");var i=O("div",[r.lineSpace],"CodeMirror-lines");r.mover=D("div",[i],null,"position: relative"),r.sizer=D("div",[r.mover],"CodeMirror-sizer"),r.sizerWidth=null,r.heightForcer=D("div",null,null,"position: absolute; height: "+F+"px; width: 1px;"),r.gutters=D("div",null,"CodeMirror-gutters"),r.lineGutter=null,r.scroller=D("div",[r.sizer,r.heightForcer,r.gutters],"CodeMirror-scroll"),r.scroller.setAttribute("tabIndex","-1"),r.wrapper=D("div",[r.scrollbarFiller,r.gutterFiller,r.scroller],"CodeMirror"),a&&s<8&&(r.gutters.style.zIndex=-1,r.scroller.style.paddingRight=0),l||n&&v||(r.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(r.wrapper):e(r.wrapper)),r.viewFrom=r.viewTo=t.first,r.reportedViewFrom=r.reportedViewTo=t.first,r.view=[],r.renderedView=null,r.externalMeasured=null,r.viewOffset=0,r.lastWrapHeight=r.lastWrapWidth=0,r.updateLineNumbers=null,r.nativeBarWidth=r.barHeight=r.barWidth=0,r.scrollbarsClipped=!1,r.lineNumWidth=r.lineNumInnerWidth=r.lineNumChars=null,r.alignWidgets=!1,r.cachedCharWidth=r.cachedTextHeight=r.cachedPaddingH=null,r.maxLine=null,r.maxLineLength=0,r.maxLineChanged=!1,r.wheelDX=r.wheelDY=r.wheelStartX=r.wheelStartY=null,r.shift=!1,r.selForContextMenu=null,r.activeTouch=null,o.init(r)}function le(e,t){if((t-=e.first)<0||t>=e.size)throw new Error("There is no line "+(t+e.first)+" in the document.");for(var n=e;!n.lines;)for(var o=0;;++o){var r=n.children[o],i=r.chunkSize();if(t<i){n=r;break}t-=i}return n.lines[t]}function ue(e,t,n){var o=[],r=t.line;return e.iter(t.line,n.line+1,function(e){var i=e.text;r==n.line&&(i=i.slice(0,n.ch)),r==t.line&&(i=i.slice(t.ch)),o.push(i),++r}),o}function ce(e,t,n){var o=[];return e.iter(t,n,function(e){o.push(e.text)}),o}function de(e,t){var n=t-e.height;if(n)for(var o=e;o;o=o.parent)o.height+=n}function he(e){if(null==e.parent)return null;for(var t=e.parent,n=j(t.lines,e),o=t.parent;o;t=o,o=o.parent)for(var r=0;o.children[r]!=t;++r)n+=o.children[r].chunkSize();return n+t.first}function fe(e,t){var n=e.first;e:do{for(var o=0;o<e.children.length;++o){var r=e.children[o],i=r.height;if(t<i){e=r;continue e}t-=i,n+=r.chunkSize()}return n}while(!e.lines);for(var a=0;a<e.lines.length;++a){var s=e.lines[a].height;if(t<s)break;t-=s}return n+a}function pe(e,t){return t>=e.first&&t<e.first+e.size}function me(e,t){return String(e.lineNumberFormatter(t+e.firstLineNumber))}function ge(e,t,n){if(void 0===n&&(n=null),!(this instanceof ge))return new ge(e,t,n);this.line=e,this.ch=t,this.sticky=n}function ve(e,t){return e.line-t.line||e.ch-t.ch}function ye(e,t){return e.sticky==t.sticky&&0==ve(e,t)}function _e(e){return ge(e.line,e.ch)}function we(e,t){return ve(e,t)<0?t:e}function be(e,t){return ve(e,t)<0?e:t}function Ce(e,t){return Math.max(e.first,Math.min(t,e.first+e.size-1))}function Me(e,t){if(t.line<e.first)return ge(e.first,0);var n=e.first+e.size-1;return t.line>n?ge(n,le(e,n).text.length):function(e,t){var n=e.ch;return null==n||n>t?ge(e.line,t):n<0?ge(e.line,0):e}(t,le(e,t.line).text.length)}function ke(e,t){for(var n=[],o=0;o<t.length;o++)n[o]=Me(e,t[o]);return n}var Se=!1,Te=!1;function Le(e,t,n){this.marker=e,this.from=t,this.to=n}function xe(e,t){if(e)for(var n=0;n<e.length;++n){var o=e[n];if(o.marker==t)return o}}function De(e,t){for(var n,o=0;o<e.length;++o)e[o]!=t&&(n||(n=[])).push(e[o]);return n}function Oe(e,t){if(t.full)return null;var n=pe(e,t.from.line)&&le(e,t.from.line).markedSpans,o=pe(e,t.to.line)&&le(e,t.to.line).markedSpans;if(!n&&!o)return null;var r=t.from.ch,i=t.to.ch,a=0==ve(t.from,t.to),s=function(e,t,n){var o;if(e)for(var r=0;r<e.length;++r){var i=e[r],a=i.marker;if(null==i.from||(a.inclusiveLeft?i.from<=t:i.from<t)||i.from==t&&"bookmark"==a.type&&(!n||!i.marker.insertLeft)){var s=null==i.to||(a.inclusiveRight?i.to>=t:i.to>t);(o||(o=[])).push(new Le(a,i.from,s?null:i.to))}}return o}(n,r,a),l=function(e,t,n){var o;if(e)for(var r=0;r<e.length;++r){var i=e[r],a=i.marker;if(null==i.to||(a.inclusiveRight?i.to>=t:i.to>t)||i.from==t&&"bookmark"==a.type&&(!n||i.marker.insertLeft)){var s=null==i.from||(a.inclusiveLeft?i.from<=t:i.from<t);(o||(o=[])).push(new Le(a,s?null:i.from-t,null==i.to?null:i.to-t))}}return o}(o,i,a),u=1==t.text.length,c=J(t.text).length+(u?r:0);if(s)for(var d=0;d<s.length;++d){var h=s[d];if(null==h.to){var f=xe(l,h.marker);f?u&&(h.to=null==f.to?null:f.to+c):h.to=r}}if(l)for(var p=0;p<l.length;++p){var m=l[p];null!=m.to&&(m.to+=c),null==m.from?xe(s,m.marker)||(m.from=c,u&&(s||(s=[])).push(m)):(m.from+=c,u&&(s||(s=[])).push(m))}s&&(s=Ee(s)),l&&l!=s&&(l=Ee(l));var g=[s];if(!u){var v,y=t.text.length-2;if(y>0&&s)for(var _=0;_<s.length;++_)null==s[_].to&&(v||(v=[])).push(new Le(s[_].marker,null,null));for(var w=0;w<y;++w)g.push(v);g.push(l)}return g}function Ee(e){for(var t=0;t<e.length;++t){var n=e[t];null!=n.from&&n.from==n.to&&!1!==n.marker.clearWhenEmpty&&e.splice(t--,1)}return e.length?e:null}function Re(e){var t=e.markedSpans;if(t){for(var n=0;n<t.length;++n)t[n].marker.detachLine(e);e.markedSpans=null}}function Ae(e,t){if(t){for(var n=0;n<t.length;++n)t[n].marker.attachLine(e);e.markedSpans=t}}function He(e){return e.inclusiveLeft?-1:0}function Ye(e){return e.inclusiveRight?1:0}function Pe(e,t){var n=e.lines.length-t.lines.length;if(0!=n)return n;var o=e.find(),r=t.find(),i=ve(o.from,r.from)||He(e)-He(t);if(i)return-i;var a=ve(o.to,r.to)||Ye(e)-Ye(t);return a||t.id-e.id}function Ne(e,t){var n,o=Te&&e.markedSpans;if(o)for(var r=void 0,i=0;i<o.length;++i)(r=o[i]).marker.collapsed&&null==(t?r.from:r.to)&&(!n||Pe(n,r.marker)<0)&&(n=r.marker);return n}function Ie(e){return Ne(e,!0)}function We(e){return Ne(e,!1)}function je(e,t,n,o,r){var i=le(e,t),a=Te&&i.markedSpans;if(a)for(var s=0;s<a.length;++s){var l=a[s];if(l.marker.collapsed){var u=l.marker.find(0),c=ve(u.from,n)||He(l.marker)-He(r),d=ve(u.to,o)||Ye(l.marker)-Ye(r);if(!(c>=0&&d<=0||c<=0&&d>=0)&&(c<=0&&(l.marker.inclusiveRight&&r.inclusiveLeft?ve(u.to,n)>=0:ve(u.to,n)>0)||c>=0&&(l.marker.inclusiveRight&&r.inclusiveLeft?ve(u.from,o)<=0:ve(u.from,o)<0)))return!0}}}function Fe(e){for(var t;t=Ie(e);)e=t.find(-1,!0).line;return e}function ze(e,t){var n=le(e,t),o=Fe(n);return n==o?t:he(o)}function Be(e,t){if(t>e.lastLine())return t;var n,o=le(e,t);if(!Ve(e,o))return t;for(;n=We(o);)o=n.find(1,!0).line;return he(o)+1}function Ve(e,t){var n=Te&&t.markedSpans;if(n)for(var o=void 0,r=0;r<n.length;++r)if((o=n[r]).marker.collapsed){if(null==o.from)return!0;if(!o.marker.widgetNode&&0==o.from&&o.marker.inclusiveLeft&&Ue(e,t,o))return!0}}function Ue(e,t,n){if(null==n.to){var o=n.marker.find(1,!0);return Ue(e,o.line,xe(o.line.markedSpans,n.marker))}if(n.marker.inclusiveRight&&n.to==t.text.length)return!0;for(var r=void 0,i=0;i<t.markedSpans.length;++i)if((r=t.markedSpans[i]).marker.collapsed&&!r.marker.widgetNode&&r.from==n.to&&(null==r.to||r.to!=n.from)&&(r.marker.inclusiveLeft||n.marker.inclusiveRight)&&Ue(e,t,r))return!0}function Ke(e){for(var t=0,n=(e=Fe(e)).parent,o=0;o<n.lines.length;++o){var r=n.lines[o];if(r==e)break;t+=r.height}for(var i=n.parent;i;i=(n=i).parent)for(var a=0;a<i.children.length;++a){var s=i.children[a];if(s==n)break;t+=s.height}return t}function Ge(e){if(0==e.height)return 0;for(var t,n=e.text.length,o=e;t=Ie(o);){var r=t.find(0,!0);o=r.from.line,n+=r.from.ch-r.to.ch}for(o=e;t=We(o);){var i=t.find(0,!0);n-=o.text.length-i.from.ch,n+=(o=i.to.line).text.length-i.to.ch}return n}function Xe(e){var t=e.display,n=e.doc;t.maxLine=le(n,n.first),t.maxLineLength=Ge(t.maxLine),t.maxLineChanged=!0,n.iter(function(e){var n=Ge(e);n>t.maxLineLength&&(t.maxLineLength=n,t.maxLine=e)})}var Je=null;function qe(e,t,n){var o;Je=null;for(var r=0;r<e.length;++r){var i=e[r];if(i.from<t&&i.to>t)return r;i.to==t&&(i.from!=i.to&&"before"==n?o=r:Je=r),i.from==t&&(i.from!=i.to&&"before"!=n?o=r:Je=r)}return null!=o?o:Je}var Qe=function(){var e="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",t="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111",n=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,o=/[stwN]/,r=/[LRr]/,i=/[Lb1n]/,a=/[1n]/;function s(e,t,n){this.level=e,this.from=t,this.to=n}return function(l,u){var c="ltr"==u?"L":"R";if(0==l.length||"ltr"==u&&!n.test(l))return!1;for(var d,h=l.length,f=[],p=0;p<h;++p)f.push((d=l.charCodeAt(p))<=247?e.charAt(d):1424<=d&&d<=1524?"R":1536<=d&&d<=1785?t.charAt(d-1536):1774<=d&&d<=2220?"r":8192<=d&&d<=8203?"w":8204==d?"b":"L");for(var m=0,g=c;m<h;++m){var v=f[m];"m"==v?f[m]=g:g=v}for(var y=0,_=c;y<h;++y){var w=f[y];"1"==w&&"r"==_?f[y]="n":r.test(w)&&(_=w,"r"==w&&(f[y]="R"))}for(var b=1,C=f[0];b<h-1;++b){var M=f[b];"+"==M&&"1"==C&&"1"==f[b+1]?f[b]="1":","!=M||C!=f[b+1]||"1"!=C&&"n"!=C||(f[b]=C),C=M}for(var k=0;k<h;++k){var S=f[k];if(","==S)f[k]="N";else if("%"==S){var T=void 0;for(T=k+1;T<h&&"%"==f[T];++T);for(var L=k&&"!"==f[k-1]||T<h&&"1"==f[T]?"1":"N",x=k;x<T;++x)f[x]=L;k=T-1}}for(var D=0,O=c;D<h;++D){var E=f[D];"L"==O&&"1"==E?f[D]="L":r.test(E)&&(O=E)}for(var R=0;R<h;++R)if(o.test(f[R])){var A=void 0;for(A=R+1;A<h&&o.test(f[A]);++A);for(var H="L"==(R?f[R-1]:c),Y=H==("L"==(A<h?f[A]:c))?H?"L":"R":c,P=R;P<A;++P)f[P]=Y;R=A-1}for(var N,I=[],W=0;W<h;)if(i.test(f[W])){var j=W;for(++W;W<h&&i.test(f[W]);++W);I.push(new s(0,j,W))}else{var F=W,z=I.length;for(++W;W<h&&"L"!=f[W];++W);for(var B=F;B<W;)if(a.test(f[B])){F<B&&I.splice(z,0,new s(1,F,B));var V=B;for(++B;B<W&&a.test(f[B]);++B);I.splice(z,0,new s(2,V,B)),F=B}else++B;F<W&&I.splice(z,0,new s(1,F,W))}return"ltr"==u&&(1==I[0].level&&(N=l.match(/^\s+/))&&(I[0].from=N[0].length,I.unshift(new s(0,0,N[0].length))),1==J(I).level&&(N=l.match(/\s+$/))&&(J(I).to-=N[0].length,I.push(new s(0,h-N[0].length,h)))),"rtl"==u?I.reverse():I}}();function $e(e,t){var n=e.order;return null==n&&(n=e.order=Qe(e.text,t)),n}var Ze=[],et=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else if(e.attachEvent)e.attachEvent("on"+t,n);else{var o=e._handlers||(e._handlers={});o[t]=(o[t]||Ze).concat(n)}};function tt(e,t){return e._handlers&&e._handlers[t]||Ze}function nt(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else if(e.detachEvent)e.detachEvent("on"+t,n);else{var o=e._handlers,r=o&&o[t];if(r){var i=j(r,n);i>-1&&(o[t]=r.slice(0,i).concat(r.slice(i+1)))}}}function ot(e,t){var n=tt(e,t);if(n.length)for(var o=Array.prototype.slice.call(arguments,2),r=0;r<n.length;++r)n[r].apply(null,o)}function rt(e,t,n){return"string"==typeof t&&(t={type:t,preventDefault:function(){this.defaultPrevented=!0}}),ot(e,n||t.type,e,t),ct(t)||t.codemirrorIgnore}function it(e){var t=e._handlers&&e._handlers.cursorActivity;if(t)for(var n=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),o=0;o<t.length;++o)-1==j(n,t[o])&&n.push(t[o])}function at(e,t){return tt(e,t).length>0}function st(e){e.prototype.on=function(e,t){et(this,e,t)},e.prototype.off=function(e,t){nt(this,e,t)}}function lt(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function ut(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function ct(e){return null!=e.defaultPrevented?e.defaultPrevented:0==e.returnValue}function dt(e){lt(e),ut(e)}function ht(e){return e.target||e.srcElement}function ft(e){var t=e.which;return null==t&&(1&e.button?t=1:2&e.button?t=3:4&e.button&&(t=2)),y&&e.ctrlKey&&1==t&&(t=3),t}var pt,mt,gt=function(){if(a&&s<9)return!1;var e=D("div");return"draggable"in e||"dragDrop"in e}();function vt(e){if(null==pt){var t=D("span","​");x(e,D("span",[t,document.createTextNode("x")])),0!=e.firstChild.offsetHeight&&(pt=t.offsetWidth<=1&&t.offsetHeight>2&&!(a&&s<8))}var n=pt?D("span","​"):D("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function yt(e){if(null!=mt)return mt;var t=x(e,document.createTextNode("AخA")),n=S(t,0,1).getBoundingClientRect(),o=S(t,1,2).getBoundingClientRect();return L(e),!(!n||n.left==n.right)&&(mt=o.right-n.right<3)}var _t,wt=3!="\n\nb".split(/\n/).length?function(e){for(var t=0,n=[],o=e.length;t<=o;){var r=e.indexOf("\n",t);-1==r&&(r=e.length);var i=e.slice(t,"\r"==e.charAt(r-1)?r-1:r),a=i.indexOf("\r");-1!=a?(n.push(i.slice(0,a)),t+=a+1):(n.push(i),t=r+1)}return n}:function(e){return e.split(/\r\n?|\n/)},bt=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(e){return!1}}:function(e){var t;try{t=e.ownerDocument.selection.createRange()}catch(e){}return!(!t||t.parentElement()!=e)&&0!=t.compareEndPoints("StartToEnd",t)},Ct="oncopy"in(_t=D("div"))||(_t.setAttribute("oncopy","return;"),"function"==typeof _t.oncopy),Mt=null,kt={},St={};function Tt(e,t){arguments.length>2&&(t.dependencies=Array.prototype.slice.call(arguments,2)),kt[e]=t}function Lt(e){if("string"==typeof e&&St.hasOwnProperty(e))e=St[e];else if(e&&"string"==typeof e.name&&St.hasOwnProperty(e.name)){var t=St[e.name];"string"==typeof t&&(t={name:t}),(e=$(t,e)).name=t.name}else{if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+xml$/.test(e))return Lt("application/xml");if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+json$/.test(e))return Lt("application/json")}return"string"==typeof e?{name:e}:e||{name:"null"}}function xt(e,t){t=Lt(t);var n=kt[t.name];if(!n)return xt(e,"text/plain");var o=n(e,t);if(Dt.hasOwnProperty(t.name)){var r=Dt[t.name];for(var i in r)r.hasOwnProperty(i)&&(o.hasOwnProperty(i)&&(o["_"+i]=o[i]),o[i]=r[i])}if(o.name=t.name,t.helperType&&(o.helperType=t.helperType),t.modeProps)for(var a in t.modeProps)o[a]=t.modeProps[a];return o}var Dt={};function Ot(e,t){N(t,Dt.hasOwnProperty(e)?Dt[e]:Dt[e]={})}function Et(e,t){if(!0===t)return t;if(e.copyState)return e.copyState(t);var n={};for(var o in t){var r=t[o];r instanceof Array&&(r=r.concat([])),n[o]=r}return n}function Rt(e,t){for(var n;e.innerMode&&(n=e.innerMode(t))&&n.mode!=e;)t=n.state,e=n.mode;return n||{mode:e,state:t}}function At(e,t,n){return!e.startState||e.startState(t,n)}var Ht=function(e,t,n){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};Ht.prototype.eol=function(){return this.pos>=this.string.length},Ht.prototype.sol=function(){return this.pos==this.lineStart},Ht.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Ht.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},Ht.prototype.eat=function(e){var t=this.string.charAt(this.pos);if("string"==typeof e?t==e:t&&(e.test?e.test(t):e(t)))return++this.pos,t},Ht.prototype.eatWhile=function(e){for(var t=this.pos;this.eat(e););return this.pos>t},Ht.prototype.eatSpace=function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},Ht.prototype.skipToEnd=function(){this.pos=this.string.length},Ht.prototype.skipTo=function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},Ht.prototype.backUp=function(e){this.pos-=e},Ht.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=I(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?I(this.string,this.lineStart,this.tabSize):0)},Ht.prototype.indentation=function(){return I(this.string,null,this.tabSize)-(this.lineStart?I(this.string,this.lineStart,this.tabSize):0)},Ht.prototype.match=function(e,t,n){if("string"!=typeof e){var o=this.string.slice(this.pos).match(e);return o&&o.index>0?null:(o&&!1!==t&&(this.pos+=o[0].length),o)}var r=function(e){return n?e.toLowerCase():e};if(r(this.string.substr(this.pos,e.length))==r(e))return!1!==t&&(this.pos+=e.length),!0},Ht.prototype.current=function(){return this.string.slice(this.start,this.pos)},Ht.prototype.hideFirstChars=function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}},Ht.prototype.lookAhead=function(e){var t=this.lineOracle;return t&&t.lookAhead(e)},Ht.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};var Yt=function(e,t){this.state=e,this.lookAhead=t},Pt=function(e,t,n,o){this.state=t,this.doc=e,this.line=n,this.maxLookAhead=o||0,this.baseTokens=null,this.baseTokenPos=1};function Nt(e,t,n,o){var r=[e.state.modeGen],i={};Kt(e,t.text,e.doc.mode,n,function(e,t){return r.push(e,t)},i,o);for(var a=n.state,s=function(o){n.baseTokens=r;var s=e.state.overlays[o],l=1,u=0;n.state=!0,Kt(e,t.text,s.mode,n,function(e,t){for(var n=l;u<e;){var o=r[l];o>e&&r.splice(l,1,e,r[l+1],o),l+=2,u=Math.min(e,o)}if(t)if(s.opaque)r.splice(n,l-n,e,"overlay "+t),l=n+2;else for(;n<l;n+=2){var i=r[n+1];r[n+1]=(i?i+" ":"")+"overlay "+t}},i),n.state=a,n.baseTokens=null,n.baseTokenPos=1},l=0;l<e.state.overlays.length;++l)s(l);return{styles:r,classes:i.bgClass||i.textClass?i:null}}function It(e,t,n){if(!t.styles||t.styles[0]!=e.state.modeGen){var o=Wt(e,he(t)),r=t.text.length>e.options.maxHighlightLength&&Et(e.doc.mode,o.state),i=Nt(e,t,o);r&&(o.state=r),t.stateAfter=o.save(!r),t.styles=i.styles,i.classes?t.styleClasses=i.classes:t.styleClasses&&(t.styleClasses=null),n===e.doc.highlightFrontier&&(e.doc.modeFrontier=Math.max(e.doc.modeFrontier,++e.doc.highlightFrontier))}return t.styles}function Wt(e,t,n){var o=e.doc,r=e.display;if(!o.mode.startState)return new Pt(o,!0,t);var i=function(e,t,n){for(var o,r,i=e.doc,a=n?-1:t-(e.doc.mode.innerMode?1e3:100),s=t;s>a;--s){if(s<=i.first)return i.first;var l=le(i,s-1),u=l.stateAfter;if(u&&(!n||s+(u instanceof Yt?u.lookAhead:0)<=i.modeFrontier))return s;var c=I(l.text,null,e.options.tabSize);(null==r||o>c)&&(r=s-1,o=c)}return r}(e,t,n),a=i>o.first&&le(o,i-1).stateAfter,s=a?Pt.fromSaved(o,a,i):new Pt(o,At(o.mode),i);return o.iter(i,t,function(n){jt(e,n.text,s);var o=s.line;n.stateAfter=o==t-1||o%5==0||o>=r.viewFrom&&o<r.viewTo?s.save():null,s.nextLine()}),n&&(o.modeFrontier=s.line),s}function jt(e,t,n,o){var r=e.doc.mode,i=new Ht(t,e.options.tabSize,n);for(i.start=i.pos=o||0,""==t&&Ft(r,n.state);!i.eol();)zt(r,i,n.state),i.start=i.pos}function Ft(e,t){if(e.blankLine)return e.blankLine(t);if(e.innerMode){var n=Rt(e,t);return n.mode.blankLine?n.mode.blankLine(n.state):void 0}}function zt(e,t,n,o){for(var r=0;r<10;r++){o&&(o[0]=Rt(e,n).mode);var i=e.token(t,n);if(t.pos>t.start)return i}throw new Error("Mode "+e.name+" failed to advance stream.")}Pt.prototype.lookAhead=function(e){var t=this.doc.getLine(this.line+e);return null!=t&&e>this.maxLookAhead&&(this.maxLookAhead=e),t},Pt.prototype.baseToken=function(e){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)this.baseTokenPos+=2;var t=this.baseTokens[this.baseTokenPos+1];return{type:t&&t.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},Pt.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},Pt.fromSaved=function(e,t,n){return t instanceof Yt?new Pt(e,Et(e.mode,t.state),n,t.lookAhead):new Pt(e,Et(e.mode,t),n)},Pt.prototype.save=function(e){var t=!1!==e?Et(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new Yt(t,this.maxLookAhead):t};var Bt=function(e,t,n){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=t||null,this.state=n};function Vt(e,t,n,o){var r,i,a=e.doc,s=a.mode,l=le(a,(t=Me(a,t)).line),u=Wt(e,t.line,n),c=new Ht(l.text,e.options.tabSize,u);for(o&&(i=[]);(o||c.pos<t.ch)&&!c.eol();)c.start=c.pos,r=zt(s,c,u.state),o&&i.push(new Bt(c,r,Et(a.mode,u.state)));return o?i:new Bt(c,r,u.state)}function Ut(e,t){if(e)for(;;){var n=e.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!n)break;e=e.slice(0,n.index)+e.slice(n.index+n[0].length);var o=n[1]?"bgClass":"textClass";null==t[o]?t[o]=n[2]:new RegExp("(?:^|s)"+n[2]+"(?:$|s)").test(t[o])||(t[o]+=" "+n[2])}return e}function Kt(e,t,n,o,r,i,a){var s=n.flattenSpans;null==s&&(s=e.options.flattenSpans);var l,u=0,c=null,d=new Ht(t,e.options.tabSize,o),h=e.options.addModeClass&&[null];for(""==t&&Ut(Ft(n,o.state),i);!d.eol();){if(d.pos>e.options.maxHighlightLength?(s=!1,a&&jt(e,t,o,d.pos),d.pos=t.length,l=null):l=Ut(zt(n,d,o.state,h),i),h){var f=h[0].name;f&&(l="m-"+(l?f+" "+l:f))}if(!s||c!=l){for(;u<d.start;)r(u=Math.min(d.start,u+5e3),c);c=l}d.start=d.pos}for(;u<d.pos;){var p=Math.min(d.pos,u+5e3);r(p,c),u=p}}var Gt=function(e,t,n){this.text=e,Ae(this,t),this.height=n?n(this):1};function Xt(e){e.parent=null,Re(e)}Gt.prototype.lineNo=function(){return he(this)},st(Gt);var Jt={},qt={};function Qt(e,t){if(!e||/^\s*$/.test(e))return null;var n=t.addModeClass?qt:Jt;return n[e]||(n[e]=e.replace(/\S+/g,"cm-$&"))}function $t(e,t){var n=O("span",null,null,l?"padding-right: .1px":null),o={pre:O("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:e,trailingSpace:!1,splitSpaces:(a||l)&&e.getOption("lineWrapping")};t.measure={};for(var r=0;r<=(t.rest?t.rest.length:0);r++){var i=r?t.rest[r-1]:t.line,s=void 0;o.pos=0,o.addToken=en,yt(e.display.measure)&&(s=$e(i,e.doc.direction))&&(o.addToken=tn(o.addToken,s)),o.map=[],on(i,o,It(e,i,t!=e.display.externalMeasured&&he(i))),i.styleClasses&&(i.styleClasses.bgClass&&(o.bgClass=H(i.styleClasses.bgClass,o.bgClass||"")),i.styleClasses.textClass&&(o.textClass=H(i.styleClasses.textClass,o.textClass||""))),0==o.map.length&&o.map.push(0,0,o.content.appendChild(vt(e.display.measure))),0==r?(t.measure.map=o.map,t.measure.cache={}):((t.measure.maps||(t.measure.maps=[])).push(o.map),(t.measure.caches||(t.measure.caches=[])).push({}))}if(l){var u=o.content.lastChild;(/\bcm-tab\b/.test(u.className)||u.querySelector&&u.querySelector(".cm-tab"))&&(o.content.className="cm-tab-wrap-hack")}return ot(e,"renderLine",e,t.line,o.pre),o.pre.className&&(o.textClass=H(o.pre.className,o.textClass||"")),o}function Zt(e){var t=D("span","•","cm-invalidchar");return t.title="\\u"+e.charCodeAt(0).toString(16),t.setAttribute("aria-label",t.title),t}function en(e,t,n,o,r,i,l){if(t){var u,c=e.splitSpaces?function(e,t){if(e.length>1&&!/ /.test(e))return e;for(var n=t,o="",r=0;r<e.length;r++){var i=e.charAt(r);" "!=i||!n||r!=e.length-1&&32!=e.charCodeAt(r+1)||(i=" "),o+=i,n=" "==i}return o}(t,e.trailingSpace):t,d=e.cm.state.specialChars,h=!1;if(d.test(t)){u=document.createDocumentFragment();for(var f=0;;){d.lastIndex=f;var p=d.exec(t),m=p?p.index-f:t.length-f;if(m){var g=document.createTextNode(c.slice(f,f+m));a&&s<9?u.appendChild(D("span",[g])):u.appendChild(g),e.map.push(e.pos,e.pos+m,g),e.col+=m,e.pos+=m}if(!p)break;f+=m+1;var v=void 0;if("\t"==p[0]){var y=e.cm.options.tabSize,_=y-e.col%y;(v=u.appendChild(D("span",X(_),"cm-tab"))).setAttribute("role","presentation"),v.setAttribute("cm-text","\t"),e.col+=_}else"\r"==p[0]||"\n"==p[0]?((v=u.appendChild(D("span","\r"==p[0]?"␍":"␤","cm-invalidchar"))).setAttribute("cm-text",p[0]),e.col+=1):((v=e.cm.options.specialCharPlaceholder(p[0])).setAttribute("cm-text",p[0]),a&&s<9?u.appendChild(D("span",[v])):u.appendChild(v),e.col+=1);e.map.push(e.pos,e.pos+1,v),e.pos++}}else e.col+=t.length,u=document.createTextNode(c),e.map.push(e.pos,e.pos+t.length,u),a&&s<9&&(h=!0),e.pos+=t.length;if(e.trailingSpace=32==c.charCodeAt(t.length-1),n||o||r||h||l){var w=n||"";o&&(w+=o),r&&(w+=r);var b=D("span",[u],w,l);return i&&(b.title=i),e.content.appendChild(b)}e.content.appendChild(u)}}function tn(e,t){return function(n,o,r,i,a,s,l){r=r?r+" cm-force-border":"cm-force-border";for(var u=n.pos,c=u+o.length;;){for(var d=void 0,h=0;h<t.length&&!((d=t[h]).to>u&&d.from<=u);h++);if(d.to>=c)return e(n,o,r,i,a,s,l);e(n,o.slice(0,d.to-u),r,i,null,s,l),i=null,o=o.slice(d.to-u),u=d.to}}}function nn(e,t,n,o){var r=!o&&n.widgetNode;r&&e.map.push(e.pos,e.pos+t,r),!o&&e.cm.display.input.needsContentAttribute&&(r||(r=e.content.appendChild(document.createElement("span"))),r.setAttribute("cm-marker",n.id)),r&&(e.cm.display.input.setUneditable(r),e.content.appendChild(r)),e.pos+=t,e.trailingSpace=!1}function on(e,t,n){var o=e.markedSpans,r=e.text,i=0;if(o)for(var a,s,l,u,c,d,h,f=r.length,p=0,m=1,g="",v=0;;){if(v==p){l=u=c=d=s="",h=null,v=1/0;for(var y=[],_=void 0,w=0;w<o.length;++w){var b=o[w],C=b.marker;"bookmark"==C.type&&b.from==p&&C.widgetNode?y.push(C):b.from<=p&&(null==b.to||b.to>p||C.collapsed&&b.to==p&&b.from==p)?(null!=b.to&&b.to!=p&&v>b.to&&(v=b.to,u=""),C.className&&(l+=" "+C.className),C.css&&(s=(s?s+";":"")+C.css),C.startStyle&&b.from==p&&(c+=" "+C.startStyle),C.endStyle&&b.to==v&&(_||(_=[])).push(C.endStyle,b.to),C.title&&!d&&(d=C.title),C.collapsed&&(!h||Pe(h.marker,C)<0)&&(h=b)):b.from>p&&v>b.from&&(v=b.from)}if(_)for(var M=0;M<_.length;M+=2)_[M+1]==v&&(u+=" "+_[M]);if(!h||h.from==p)for(var k=0;k<y.length;++k)nn(t,0,y[k]);if(h&&(h.from||0)==p){if(nn(t,(null==h.to?f+1:h.to)-p,h.marker,null==h.from),null==h.to)return;h.to==p&&(h=!1)}}if(p>=f)break;for(var S=Math.min(f,v);;){if(g){var T=p+g.length;if(!h){var L=T>S?g.slice(0,S-p):g;t.addToken(t,L,a?a+l:l,c,p+L.length==v?u:"",d,s)}if(T>=S){g=g.slice(S-p),p=S;break}p=T,c=""}g=r.slice(i,i=n[m++]),a=Qt(n[m++],t.cm.options)}}else for(var x=1;x<n.length;x+=2)t.addToken(t,r.slice(i,i=n[x]),Qt(n[x+1],t.cm.options))}function rn(e,t,n){this.line=t,this.rest=function(e){for(var t,n;t=We(e);)e=t.find(1,!0).line,(n||(n=[])).push(e);return n}(t),this.size=this.rest?he(J(this.rest))-n+1:1,this.node=this.text=null,this.hidden=Ve(e,t)}function an(e,t,n){for(var o,r=[],i=t;i<n;i=o){var a=new rn(e.doc,le(e.doc,i),i);o=i+a.size,r.push(a)}return r}var sn=null,ln=null;function un(e,t){var n=tt(e,t);if(n.length){var o,r=Array.prototype.slice.call(arguments,2);sn?o=sn.delayedCallbacks:ln?o=ln:(o=ln=[],setTimeout(cn,0));for(var i=function(e){o.push(function(){return n[e].apply(null,r)})},a=0;a<n.length;++a)i(a)}}function cn(){var e=ln;ln=null;for(var t=0;t<e.length;++t)e[t]()}function dn(e,t,n,o){for(var r=0;r<t.changes.length;r++){var i=t.changes[r];"text"==i?pn(e,t):"gutter"==i?gn(e,t,n,o):"class"==i?mn(e,t):"widget"==i&&vn(e,t,o)}t.changes=null}function hn(e){return e.node==e.text&&(e.node=D("div",null,null,"position: relative"),e.text.parentNode&&e.text.parentNode.replaceChild(e.node,e.text),e.node.appendChild(e.text),a&&s<8&&(e.node.style.zIndex=2)),e.node}function fn(e,t){var n=e.display.externalMeasured;return n&&n.line==t.line?(e.display.externalMeasured=null,t.measure=n.measure,n.built):$t(e,t)}function pn(e,t){var n=t.text.className,o=fn(e,t);t.text==t.node&&(t.node=o.pre),t.text.parentNode.replaceChild(o.pre,t.text),t.text=o.pre,o.bgClass!=t.bgClass||o.textClass!=t.textClass?(t.bgClass=o.bgClass,t.textClass=o.textClass,mn(e,t)):n&&(t.text.className=n)}function mn(e,t){!function(e,t){var n=t.bgClass?t.bgClass+" "+(t.line.bgClass||""):t.line.bgClass;if(n&&(n+=" CodeMirror-linebackground"),t.background)n?t.background.className=n:(t.background.parentNode.removeChild(t.background),t.background=null);else if(n){var o=hn(t);t.background=o.insertBefore(D("div",null,n),o.firstChild),e.display.input.setUneditable(t.background)}}(e,t),t.line.wrapClass?hn(t).className=t.line.wrapClass:t.node!=t.text&&(t.node.className="");var n=t.textClass?t.textClass+" "+(t.line.textClass||""):t.line.textClass;t.text.className=n||""}function gn(e,t,n,o){if(t.gutter&&(t.node.removeChild(t.gutter),t.gutter=null),t.gutterBackground&&(t.node.removeChild(t.gutterBackground),t.gutterBackground=null),t.line.gutterClass){var r=hn(t);t.gutterBackground=D("div",null,"CodeMirror-gutter-background "+t.line.gutterClass,"left: "+(e.options.fixedGutter?o.fixedPos:-o.gutterTotalWidth)+"px; width: "+o.gutterTotalWidth+"px"),e.display.input.setUneditable(t.gutterBackground),r.insertBefore(t.gutterBackground,t.text)}var i=t.line.gutterMarkers;if(e.options.lineNumbers||i){var a=hn(t),s=t.gutter=D("div",null,"CodeMirror-gutter-wrapper","left: "+(e.options.fixedGutter?o.fixedPos:-o.gutterTotalWidth)+"px");if(e.display.input.setUneditable(s),a.insertBefore(s,t.text),t.line.gutterClass&&(s.className+=" "+t.line.gutterClass),!e.options.lineNumbers||i&&i["CodeMirror-linenumbers"]||(t.lineNumber=s.appendChild(D("div",me(e.options,n),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+o.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+e.display.lineNumInnerWidth+"px"))),i)for(var l=0;l<e.options.gutters.length;++l){var u=e.options.gutters[l],c=i.hasOwnProperty(u)&&i[u];c&&s.appendChild(D("div",[c],"CodeMirror-gutter-elt","left: "+o.gutterLeft[u]+"px; width: "+o.gutterWidth[u]+"px"))}}}function vn(e,t,n){t.alignable&&(t.alignable=null);for(var o=t.node.firstChild,r=void 0;o;o=r)r=o.nextSibling,"CodeMirror-linewidget"==o.className&&t.node.removeChild(o);_n(e,t,n)}function yn(e,t,n,o){var r=fn(e,t);return t.text=t.node=r.pre,r.bgClass&&(t.bgClass=r.bgClass),r.textClass&&(t.textClass=r.textClass),mn(e,t),gn(e,t,n,o),_n(e,t,o),t.node}function _n(e,t,n){if(wn(e,t.line,t,n,!0),t.rest)for(var o=0;o<t.rest.length;o++)wn(e,t.rest[o],t,n,!1)}function wn(e,t,n,o,r){if(t.widgets)for(var i=hn(n),a=0,s=t.widgets;a<s.length;++a){var l=s[a],u=D("div",[l.node],"CodeMirror-linewidget");l.handleMouseEvents||u.setAttribute("cm-ignore-events","true"),bn(l,u,n,o),e.display.input.setUneditable(u),r&&l.above?i.insertBefore(u,n.gutter||n.text):i.appendChild(u),un(l,"redraw")}}function bn(e,t,n,o){if(e.noHScroll){(n.alignable||(n.alignable=[])).push(t);var r=o.wrapperWidth;t.style.left=o.fixedPos+"px",e.coverGutter||(r-=o.gutterTotalWidth,t.style.paddingLeft=o.gutterTotalWidth+"px"),t.style.width=r+"px"}e.coverGutter&&(t.style.zIndex=5,t.style.position="relative",e.noHScroll||(t.style.marginLeft=-o.gutterTotalWidth+"px"))}function Cn(e){if(null!=e.height)return e.height;var t=e.doc.cm;if(!t)return 0;if(!E(document.body,e.node)){var n="position: relative;";e.coverGutter&&(n+="margin-left: -"+t.display.gutters.offsetWidth+"px;"),e.noHScroll&&(n+="width: "+t.display.wrapper.clientWidth+"px;"),x(t.display.measure,D("div",[e.node],null,n))}return e.height=e.node.parentNode.offsetHeight}function Mn(e,t){for(var n=ht(t);n!=e.wrapper;n=n.parentNode)if(!n||1==n.nodeType&&"true"==n.getAttribute("cm-ignore-events")||n.parentNode==e.sizer&&n!=e.mover)return!0}function kn(e){return e.lineSpace.offsetTop}function Sn(e){return e.mover.offsetHeight-e.lineSpace.offsetHeight}function Tn(e){if(e.cachedPaddingH)return e.cachedPaddingH;var t=x(e.measure,D("pre","x")),n=window.getComputedStyle?window.getComputedStyle(t):t.currentStyle,o={left:parseInt(n.paddingLeft),right:parseInt(n.paddingRight)};return isNaN(o.left)||isNaN(o.right)||(e.cachedPaddingH=o),o}function Ln(e){return F-e.display.nativeBarWidth}function xn(e){return e.display.scroller.clientWidth-Ln(e)-e.display.barWidth}function Dn(e){return e.display.scroller.clientHeight-Ln(e)-e.display.barHeight}function On(e,t,n){if(e.line==t)return{map:e.measure.map,cache:e.measure.cache};for(var o=0;o<e.rest.length;o++)if(e.rest[o]==t)return{map:e.measure.maps[o],cache:e.measure.caches[o]};for(var r=0;r<e.rest.length;r++)if(he(e.rest[r])>n)return{map:e.measure.maps[r],cache:e.measure.caches[r],before:!0}}function En(e,t,n,o){return Hn(e,An(e,t),n,o)}function Rn(e,t){if(t>=e.display.viewFrom&&t<e.display.viewTo)return e.display.view[ho(e,t)];var n=e.display.externalMeasured;return n&&t>=n.lineN&&t<n.lineN+n.size?n:void 0}function An(e,t){var n=he(t),o=Rn(e,n);o&&!o.text?o=null:o&&o.changes&&(dn(e,o,n,ao(e)),e.curOp.forceUpdate=!0),o||(o=function(e,t){var n=he(t=Fe(t)),o=e.display.externalMeasured=new rn(e.doc,t,n);o.lineN=n;var r=o.built=$t(e,o);return o.text=r.pre,x(e.display.lineMeasure,r.pre),o}(e,t));var r=On(o,t,n);return{line:t,view:o,rect:null,map:r.map,cache:r.cache,before:r.before,hasHeights:!1}}function Hn(e,t,n,o,r){t.before&&(n=-1);var i,l=n+(o||"");return t.cache.hasOwnProperty(l)?i=t.cache[l]:(t.rect||(t.rect=t.view.text.getBoundingClientRect()),t.hasHeights||(function(e,t,n){var o=e.options.lineWrapping,r=o&&xn(e);if(!t.measure.heights||o&&t.measure.width!=r){var i=t.measure.heights=[];if(o){t.measure.width=r;for(var a=t.text.firstChild.getClientRects(),s=0;s<a.length-1;s++){var l=a[s],u=a[s+1];Math.abs(l.bottom-u.bottom)>2&&i.push((l.bottom+u.top)/2-n.top)}}i.push(n.bottom-n.top)}}(e,t.view,t.rect),t.hasHeights=!0),(i=function(e,t,n,o){var r,i=Nn(t.map,n,o),l=i.node,u=i.start,c=i.end,d=i.collapse;if(3==l.nodeType){for(var h=0;h<4;h++){for(;u&&re(t.line.text.charAt(i.coverStart+u));)--u;for(;i.coverStart+c<i.coverEnd&&re(t.line.text.charAt(i.coverStart+c));)++c;if((r=a&&s<9&&0==u&&c==i.coverEnd-i.coverStart?l.parentNode.getBoundingClientRect():In(S(l,u,c).getClientRects(),o)).left||r.right||0==u)break;c=u,u-=1,d="right"}a&&s<11&&(r=function(e,t){if(!window.screen||null==screen.logicalXDPI||screen.logicalXDPI==screen.deviceXDPI||!function(e){if(null!=Mt)return Mt;var t=x(e,D("span","x")),n=t.getBoundingClientRect(),o=S(t,0,1).getBoundingClientRect();return Mt=Math.abs(n.left-o.left)>1}(e))return t;var n=screen.logicalXDPI/screen.deviceXDPI,o=screen.logicalYDPI/screen.deviceYDPI;return{left:t.left*n,right:t.right*n,top:t.top*o,bottom:t.bottom*o}}(e.display.measure,r))}else{var f;u>0&&(d=o="right"),r=e.options.lineWrapping&&(f=l.getClientRects()).length>1?f["right"==o?f.length-1:0]:l.getBoundingClientRect()}if(a&&s<9&&!u&&(!r||!r.left&&!r.right)){var p=l.parentNode.getClientRects()[0];r=p?{left:p.left,right:p.left+io(e.display),top:p.top,bottom:p.bottom}:Pn}for(var m=r.top-t.rect.top,g=r.bottom-t.rect.top,v=(m+g)/2,y=t.view.measure.heights,_=0;_<y.length-1&&!(v<y[_]);_++);var w=_?y[_-1]:0,b=y[_],C={left:("right"==d?r.right:r.left)-t.rect.left,right:("left"==d?r.left:r.right)-t.rect.left,top:w,bottom:b};return r.left||r.right||(C.bogus=!0),e.options.singleCursorHeightPerLine||(C.rtop=m,C.rbottom=g),C}(e,t,n,o)).bogus||(t.cache[l]=i)),{left:i.left,right:i.right,top:r?i.rtop:i.top,bottom:r?i.rbottom:i.bottom}}var Yn,Pn={left:0,right:0,top:0,bottom:0};function Nn(e,t,n){for(var o,r,i,a,s,l,u=0;u<e.length;u+=3)if(s=e[u],l=e[u+1],t<s?(r=0,i=1,a="left"):t<l?i=1+(r=t-s):(u==e.length-3||t==l&&e[u+3]>t)&&(r=(i=l-s)-1,t>=l&&(a="right")),null!=r){if(o=e[u+2],s==l&&n==(o.insertLeft?"left":"right")&&(a=n),"left"==n&&0==r)for(;u&&e[u-2]==e[u-3]&&e[u-1].insertLeft;)o=e[2+(u-=3)],a="left";if("right"==n&&r==l-s)for(;u<e.length-3&&e[u+3]==e[u+4]&&!e[u+5].insertLeft;)o=e[(u+=3)+2],a="right";break}return{node:o,start:r,end:i,collapse:a,coverStart:s,coverEnd:l}}function In(e,t){var n=Pn;if("left"==t)for(var o=0;o<e.length&&(n=e[o]).left==n.right;o++);else for(var r=e.length-1;r>=0&&(n=e[r]).left==n.right;r--);return n}function Wn(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var t=0;t<e.rest.length;t++)e.measure.caches[t]={}}function jn(e){e.display.externalMeasure=null,L(e.display.lineMeasure);for(var t=0;t<e.display.view.length;t++)Wn(e.display.view[t])}function Fn(e){jn(e),e.display.cachedCharWidth=e.display.cachedTextHeight=e.display.cachedPaddingH=null,e.options.lineWrapping||(e.display.maxLineChanged=!0),e.display.lineNumChars=null}function zn(){return c&&g?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function Bn(){return c&&g?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function Vn(e){var t=0;if(e.widgets)for(var n=0;n<e.widgets.length;++n)e.widgets[n].above&&(t+=Cn(e.widgets[n]));return t}function Un(e,t,n,o,r){if(!r){var i=Vn(t);n.top+=i,n.bottom+=i}if("line"==o)return n;o||(o="local");var a=Ke(t);if("local"==o?a+=kn(e.display):a-=e.display.viewOffset,"page"==o||"window"==o){var s=e.display.lineSpace.getBoundingClientRect();a+=s.top+("window"==o?0:Bn());var l=s.left+("window"==o?0:zn());n.left+=l,n.right+=l}return n.top+=a,n.bottom+=a,n}function Kn(e,t,n){if("div"==n)return t;var o=t.left,r=t.top;if("page"==n)o-=zn(),r-=Bn();else if("local"==n||!n){var i=e.display.sizer.getBoundingClientRect();o+=i.left,r+=i.top}var a=e.display.lineSpace.getBoundingClientRect();return{left:o-a.left,top:r-a.top}}function Gn(e,t,n,o,r){return o||(o=le(e.doc,t.line)),Un(e,o,En(e,o,t.ch,r),n)}function Xn(e,t,n,o,r,i){function a(t,a){var s=Hn(e,r,t,a?"right":"left",i);return a?s.left=s.right:s.right=s.left,Un(e,o,s,n)}o=o||le(e.doc,t.line),r||(r=An(e,o));var s=$e(o,e.doc.direction),l=t.ch,u=t.sticky;if(l>=o.text.length?(l=o.text.length,u="before"):l<=0&&(l=0,u="after"),!s)return a("before"==u?l-1:l,"before"==u);function c(e,t,n){return a(n?e-1:e,1==s[t].level!=n)}var d=qe(s,l,u),h=Je,f=c(l,d,"before"==u);return null!=h&&(f.other=c(l,h,"before"!=u)),f}function Jn(e,t){var n=0;t=Me(e.doc,t),e.options.lineWrapping||(n=io(e.display)*t.ch);var o=le(e.doc,t.line),r=Ke(o)+kn(e.display);return{left:n,right:n,top:r,bottom:r+o.height}}function qn(e,t,n,o,r){var i=ge(e,t,n);return i.xRel=r,o&&(i.outside=!0),i}function Qn(e,t,n){var o=e.doc;if((n+=e.display.viewOffset)<0)return qn(o.first,0,null,!0,-1);var r=fe(o,n),i=o.first+o.size-1;if(r>i)return qn(o.first+o.size-1,le(o,i).text.length,null,!0,1);t<0&&(t=0);for(var a=le(o,r);;){var s=to(e,a,r,t,n),l=We(a),u=l&&l.find(0,!0);if(!l||!(s.ch>u.from.ch||s.ch==u.from.ch&&s.xRel>0))return s;r=he(a=u.to.line)}}function $n(e,t,n,o){o-=Vn(t);var r=t.text.length,i=ae(function(t){return Hn(e,n,t-1).bottom<=o},r,0);return{begin:i,end:r=ae(function(t){return Hn(e,n,t).top>o},i,r)}}function Zn(e,t,n,o){return n||(n=An(e,t)),$n(e,t,n,Un(e,t,Hn(e,n,o),"line").top)}function eo(e,t,n,o){return!(e.bottom<=n)&&(e.top>n||(o?e.left:e.right)>t)}function to(e,t,n,o,r){r-=Ke(t);var i=An(e,t),a=Vn(t),s=0,l=t.text.length,u=!0,c=$e(t,e.doc.direction);if(c){var d=(e.options.lineWrapping?oo:no)(e,t,n,i,c,o,r);s=(u=1!=d.level)?d.from:d.to-1,l=u?d.to:d.from-1}var h,f,p=null,m=null,g=ae(function(t){var n=Hn(e,i,t);return n.top+=a,n.bottom+=a,!!eo(n,o,r,!1)&&(n.top<=r&&n.left<=o&&(p=t,m=n),!0)},s,l),v=!1;if(m){var y=o-m.left<m.right-o,_=y==u;g=p+(_?0:1),f=_?"after":"before",h=y?m.left:m.right}else{u||g!=l&&g!=s||g++,f=0==g?"after":g==t.text.length?"before":Hn(e,i,g-(u?1:0)).bottom+a<=r==u?"after":"before";var w=Xn(e,ge(n,g,f),"line",t,i);h=w.left,v=r<w.top||r>=w.bottom}return qn(n,g=ie(t.text,g,1),f,v,o-h)}function no(e,t,n,o,r,i,a){var s=ae(function(s){var l=r[s],u=1!=l.level;return eo(Xn(e,ge(n,u?l.to:l.from,u?"before":"after"),"line",t,o),i,a,!0)},0,r.length-1),l=r[s];if(s>0){var u=1!=l.level,c=Xn(e,ge(n,u?l.from:l.to,u?"after":"before"),"line",t,o);eo(c,i,a,!0)&&c.top>a&&(l=r[s-1])}return l}function oo(e,t,n,o,r,i,a){var s=$n(e,t,o,a),l=s.begin,u=s.end;/\s/.test(t.text.charAt(u-1))&&u--;for(var c=null,d=null,h=0;h<r.length;h++){var f=r[h];if(!(f.from>=u||f.to<=l)){var p=Hn(e,o,1!=f.level?Math.min(u,f.to)-1:Math.max(l,f.from)).right,m=p<i?i-p+1e9:p-i;(!c||d>m)&&(c=f,d=m)}}return c||(c=r[r.length-1]),c.from<l&&(c={from:l,to:c.to,level:c.level}),c.to>u&&(c={from:c.from,to:u,level:c.level}),c}function ro(e){if(null!=e.cachedTextHeight)return e.cachedTextHeight;if(null==Yn){Yn=D("pre");for(var t=0;t<49;++t)Yn.appendChild(document.createTextNode("x")),Yn.appendChild(D("br"));Yn.appendChild(document.createTextNode("x"))}x(e.measure,Yn);var n=Yn.offsetHeight/50;return n>3&&(e.cachedTextHeight=n),L(e.measure),n||1}function io(e){if(null!=e.cachedCharWidth)return e.cachedCharWidth;var t=D("span","xxxxxxxxxx"),n=D("pre",[t]);x(e.measure,n);var o=t.getBoundingClientRect(),r=(o.right-o.left)/10;return r>2&&(e.cachedCharWidth=r),r||10}function ao(e){for(var t=e.display,n={},o={},r=t.gutters.clientLeft,i=t.gutters.firstChild,a=0;i;i=i.nextSibling,++a)n[e.options.gutters[a]]=i.offsetLeft+i.clientLeft+r,o[e.options.gutters[a]]=i.clientWidth;return{fixedPos:so(t),gutterTotalWidth:t.gutters.offsetWidth,gutterLeft:n,gutterWidth:o,wrapperWidth:t.wrapper.clientWidth}}function so(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function lo(e){var t=ro(e.display),n=e.options.lineWrapping,o=n&&Math.max(5,e.display.scroller.clientWidth/io(e.display)-3);return function(r){if(Ve(e.doc,r))return 0;var i=0;if(r.widgets)for(var a=0;a<r.widgets.length;a++)r.widgets[a].height&&(i+=r.widgets[a].height);return n?i+(Math.ceil(r.text.length/o)||1)*t:i+t}}function uo(e){var t=e.doc,n=lo(e);t.iter(function(e){var t=n(e);t!=e.height&&de(e,t)})}function co(e,t,n,o){var r=e.display;if(!n&&"true"==ht(t).getAttribute("cm-not-content"))return null;var i,a,s=r.lineSpace.getBoundingClientRect();try{i=t.clientX-s.left,a=t.clientY-s.top}catch(t){return null}var l,u=Qn(e,i,a);if(o&&1==u.xRel&&(l=le(e.doc,u.line).text).length==u.ch){var c=I(l,l.length,e.options.tabSize)-l.length;u=ge(u.line,Math.max(0,Math.round((i-Tn(e.display).left)/io(e.display))-c))}return u}function ho(e,t){if(t>=e.display.viewTo)return null;if((t-=e.display.viewFrom)<0)return null;for(var n=e.display.view,o=0;o<n.length;o++)if((t-=n[o].size)<0)return o}function fo(e){e.display.input.showSelection(e.display.input.prepareSelection())}function po(e,t){void 0===t&&(t=!0);for(var n=e.doc,o={},r=o.cursors=document.createDocumentFragment(),i=o.selection=document.createDocumentFragment(),a=0;a<n.sel.ranges.length;a++)if(t||a!=n.sel.primIndex){var s=n.sel.ranges[a];if(!(s.from().line>=e.display.viewTo||s.to().line<e.display.viewFrom)){var l=s.empty();(l||e.options.showCursorWhenSelecting)&&mo(e,s.head,r),l||vo(e,s,i)}}return o}function mo(e,t,n){var o=Xn(e,t,"div",null,null,!e.options.singleCursorHeightPerLine),r=n.appendChild(D("div"," ","CodeMirror-cursor"));if(r.style.left=o.left+"px",r.style.top=o.top+"px",r.style.height=Math.max(0,o.bottom-o.top)*e.options.cursorHeight+"px",o.other){var i=n.appendChild(D("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));i.style.display="",i.style.left=o.other.left+"px",i.style.top=o.other.top+"px",i.style.height=.85*(o.other.bottom-o.other.top)+"px"}}function go(e,t){return e.top-t.top||e.left-t.left}function vo(e,t,n){var o=e.display,r=e.doc,i=document.createDocumentFragment(),a=Tn(e.display),s=a.left,l=Math.max(o.sizerWidth,xn(e)-o.sizer.offsetLeft)-a.right,u="ltr"==r.direction;function c(e,t,n,o){t<0&&(t=0),t=Math.round(t),o=Math.round(o),i.appendChild(D("div",null,"CodeMirror-selected","position: absolute; left: "+e+"px;\n top: "+t+"px; width: "+(null==n?l-e:n)+"px;\n height: "+(o-t)+"px"))}function d(t,n,o){var i,a,d=le(r,t),h=d.text.length;function f(n,o){return Gn(e,ge(t,n),"div",d,o)}function p(t,n,o){var r=Zn(e,d,null,t),i="ltr"==n==("after"==o)?"left":"right";return f("after"==o?r.begin:r.end-(/\s/.test(d.text.charAt(r.end-1))?2:1),i)[i]}var m=$e(d,r.direction);return function(e,t,n,o){if(!e)return o(t,n,"ltr",0);for(var r=!1,i=0;i<e.length;++i){var a=e[i];(a.from<n&&a.to>t||t==n&&a.to==t)&&(o(Math.max(a.from,t),Math.min(a.to,n),1==a.level?"rtl":"ltr",i),r=!0)}r||o(t,n,"ltr")}(m,n||0,null==o?h:o,function(e,t,r,d){var g="ltr"==r,v=f(e,g?"left":"right"),y=f(t-1,g?"right":"left"),_=null==n&&0==e,w=null==o&&t==h,b=0==d,C=!m||d==m.length-1;if(y.top-v.top<=3){var M=(u?w:_)&&C,k=(u?_:w)&&b?s:(g?v:y).left,S=M?l:(g?y:v).right;c(k,v.top,S-k,v.bottom)}else{var T,L,x,D;g?(T=u&&_&&b?s:v.left,L=u?l:p(e,r,"before"),x=u?s:p(t,r,"after"),D=u&&w&&C?l:y.right):(T=u?p(e,r,"before"):s,L=!u&&_&&b?l:v.right,x=!u&&w&&C?s:y.left,D=u?p(t,r,"after"):l),c(T,v.top,L-T,v.bottom),v.bottom<y.top&&c(s,v.bottom,null,y.top),c(x,y.top,D-x,y.bottom)}(!i||go(v,i)<0)&&(i=v),go(y,i)<0&&(i=y),(!a||go(v,a)<0)&&(a=v),go(y,a)<0&&(a=y)}),{start:i,end:a}}var h=t.from(),f=t.to();if(h.line==f.line)d(h.line,h.ch,f.ch);else{var p=le(r,h.line),m=le(r,f.line),g=Fe(p)==Fe(m),v=d(h.line,h.ch,g?p.text.length+1:null).end,y=d(f.line,g?0:null,f.ch).start;g&&(v.top<y.top-2?(c(v.right,v.top,null,v.bottom),c(s,y.top,y.left,y.bottom)):c(v.right,v.top,y.left-v.right,v.bottom)),v.bottom<y.top&&c(s,v.bottom,null,y.top)}n.appendChild(i)}function yo(e){if(e.state.focused){var t=e.display;clearInterval(t.blinker);var n=!0;t.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?t.blinker=setInterval(function(){return t.cursorDiv.style.visibility=(n=!n)?"":"hidden"},e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function _o(e){e.state.focused||(e.display.input.focus(),bo(e))}function wo(e){e.state.delayingBlurEvent=!0,setTimeout(function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,Co(e))},100)}function bo(e,t){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1),"nocursor"!=e.options.readOnly&&(e.state.focused||(ot(e,"focus",e,t),e.state.focused=!0,A(e.display.wrapper,"CodeMirror-focused"),e.curOp||e.display.selForContextMenu==e.doc.sel||(e.display.input.reset(),l&&setTimeout(function(){return e.display.input.reset(!0)},20)),e.display.input.receivedFocus()),yo(e))}function Co(e,t){e.state.delayingBlurEvent||(e.state.focused&&(ot(e,"blur",e,t),e.state.focused=!1,T(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout(function(){e.state.focused||(e.display.shift=!1)},150))}function Mo(e){for(var t=e.display,n=t.lineDiv.offsetTop,o=0;o<t.view.length;o++){var r=t.view[o],i=void 0;if(!r.hidden){if(a&&s<8){var l=r.node.offsetTop+r.node.offsetHeight;i=l-n,n=l}else{var u=r.node.getBoundingClientRect();i=u.bottom-u.top}var c=r.line.height-i;if(i<2&&(i=ro(t)),(c>.005||c<-.005)&&(de(r.line,i),ko(r.line),r.rest))for(var d=0;d<r.rest.length;d++)ko(r.rest[d])}}}function ko(e){if(e.widgets)for(var t=0;t<e.widgets.length;++t){var n=e.widgets[t],o=n.node.parentNode;o&&(n.height=o.offsetHeight)}}function So(e,t,n){var o=n&&null!=n.top?Math.max(0,n.top):e.scroller.scrollTop;o=Math.floor(o-kn(e));var r=n&&null!=n.bottom?n.bottom:o+e.wrapper.clientHeight,i=fe(t,o),a=fe(t,r);if(n&&n.ensure){var s=n.ensure.from.line,l=n.ensure.to.line;s<i?(i=s,a=fe(t,Ke(le(t,s))+e.wrapper.clientHeight)):Math.min(l,t.lastLine())>=a&&(i=fe(t,Ke(le(t,l))-e.wrapper.clientHeight),a=l)}return{from:i,to:Math.max(a,i+1)}}function To(e){var t=e.display,n=t.view;if(t.alignWidgets||t.gutters.firstChild&&e.options.fixedGutter){for(var o=so(t)-t.scroller.scrollLeft+e.doc.scrollLeft,r=t.gutters.offsetWidth,i=o+"px",a=0;a<n.length;a++)if(!n[a].hidden){e.options.fixedGutter&&(n[a].gutter&&(n[a].gutter.style.left=i),n[a].gutterBackground&&(n[a].gutterBackground.style.left=i));var s=n[a].alignable;if(s)for(var l=0;l<s.length;l++)s[l].style.left=i}e.options.fixedGutter&&(t.gutters.style.left=o+r+"px")}}function Lo(e){if(!e.options.lineNumbers)return!1;var t=e.doc,n=me(e.options,t.first+t.size-1),o=e.display;if(n.length!=o.lineNumChars){var r=o.measure.appendChild(D("div",[D("div",n)],"CodeMirror-linenumber CodeMirror-gutter-elt")),i=r.firstChild.offsetWidth,a=r.offsetWidth-i;return o.lineGutter.style.width="",o.lineNumInnerWidth=Math.max(i,o.lineGutter.offsetWidth-a)+1,o.lineNumWidth=o.lineNumInnerWidth+a,o.lineNumChars=o.lineNumInnerWidth?n.length:-1,o.lineGutter.style.width=o.lineNumWidth+"px",hr(e),!0}return!1}function xo(e,t){var n=e.display,o=ro(e.display);t.top<0&&(t.top=0);var r=e.curOp&&null!=e.curOp.scrollTop?e.curOp.scrollTop:n.scroller.scrollTop,i=Dn(e),a={};t.bottom-t.top>i&&(t.bottom=t.top+i);var s=e.doc.height+Sn(n),l=t.top<o,u=t.bottom>s-o;if(t.top<r)a.scrollTop=l?0:t.top;else if(t.bottom>r+i){var c=Math.min(t.top,(u?s:t.bottom)-i);c!=r&&(a.scrollTop=c)}var d=e.curOp&&null!=e.curOp.scrollLeft?e.curOp.scrollLeft:n.scroller.scrollLeft,h=xn(e)-(e.options.fixedGutter?n.gutters.offsetWidth:0),f=t.right-t.left>h;return f&&(t.right=t.left+h),t.left<10?a.scrollLeft=0:t.left<d?a.scrollLeft=Math.max(0,t.left-(f?0:10)):t.right>h+d-3&&(a.scrollLeft=t.right+(f?0:10)-h),a}function Do(e,t){null!=t&&(Ro(e),e.curOp.scrollTop=(null==e.curOp.scrollTop?e.doc.scrollTop:e.curOp.scrollTop)+t)}function Oo(e){Ro(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function Eo(e,t,n){null==t&&null==n||Ro(e),null!=t&&(e.curOp.scrollLeft=t),null!=n&&(e.curOp.scrollTop=n)}function Ro(e){var t=e.curOp.scrollToPos;t&&(e.curOp.scrollToPos=null,Ao(e,Jn(e,t.from),Jn(e,t.to),t.margin))}function Ao(e,t,n,o){var r=xo(e,{left:Math.min(t.left,n.left),top:Math.min(t.top,n.top)-o,right:Math.max(t.right,n.right),bottom:Math.max(t.bottom,n.bottom)+o});Eo(e,r.scrollLeft,r.scrollTop)}function Ho(e,t){Math.abs(e.doc.scrollTop-t)<2||(n||dr(e,{top:t}),Yo(e,t,!0),n&&dr(e),ar(e,100))}function Yo(e,t,n){t=Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t),(e.display.scroller.scrollTop!=t||n)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function Po(e,t,n,o){t=Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth),(n?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!o||(e.doc.scrollLeft=t,To(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function No(e){var t=e.display,n=t.gutters.offsetWidth,o=Math.round(e.doc.height+Sn(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?n:0,docHeight:o,scrollHeight:o+Ln(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:n}}var Io=function(e,t,n){this.cm=n;var o=this.vert=D("div",[D("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),r=this.horiz=D("div",[D("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");e(o),e(r),et(o,"scroll",function(){o.clientHeight&&t(o.scrollTop,"vertical")}),et(r,"scroll",function(){r.clientWidth&&t(r.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,a&&s<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Io.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,n=e.scrollHeight>e.clientHeight+1,o=e.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=t?o+"px":"0";var r=e.viewHeight-(t?o:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+r)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=n?o+"px":"0",this.horiz.style.left=e.barLeft+"px";var i=e.viewWidth-e.barLeft-(n?o:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+i)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(0==o&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?o:0,bottom:t?o:0}},Io.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Io.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Io.prototype.zeroWidthHack=function(){var e=y&&!f?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new W,this.disableVert=new W},Io.prototype.enableZeroWidthBar=function(e,t,n){e.style.pointerEvents="auto",t.set(1e3,function o(){var r=e.getBoundingClientRect();("vert"==n?document.elementFromPoint(r.right-1,(r.top+r.bottom)/2):document.elementFromPoint((r.right+r.left)/2,r.bottom-1))!=e?e.style.pointerEvents="none":t.set(1e3,o)})},Io.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var Wo=function(){};function jo(e,t){t||(t=No(e));var n=e.display.barWidth,o=e.display.barHeight;Fo(e,t);for(var r=0;r<4&&n!=e.display.barWidth||o!=e.display.barHeight;r++)n!=e.display.barWidth&&e.options.lineWrapping&&Mo(e),Fo(e,No(e)),n=e.display.barWidth,o=e.display.barHeight}function Fo(e,t){var n=e.display,o=n.scrollbars.update(t);n.sizer.style.paddingRight=(n.barWidth=o.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=o.bottom)+"px",n.heightForcer.style.borderBottom=o.bottom+"px solid transparent",o.right&&o.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=o.bottom+"px",n.scrollbarFiller.style.width=o.right+"px"):n.scrollbarFiller.style.display="",o.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=o.bottom+"px",n.gutterFiller.style.width=t.gutterWidth+"px"):n.gutterFiller.style.display=""}Wo.prototype.update=function(){return{bottom:0,right:0}},Wo.prototype.setScrollLeft=function(){},Wo.prototype.setScrollTop=function(){},Wo.prototype.clear=function(){};var zo={native:Io,null:Wo};function Bo(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&T(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new zo[e.options.scrollbarStyle](function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),et(t,"mousedown",function(){e.state.focused&&setTimeout(function(){return e.display.input.focus()},0)}),t.setAttribute("cm-not-content","true")},function(t,n){"horizontal"==n?Po(e,t):Ho(e,t)},e),e.display.scrollbars.addClass&&A(e.display.wrapper,e.display.scrollbars.addClass)}var Vo=0;function Uo(e){var t;e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:null,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Vo},t=e.curOp,sn?sn.ops.push(t):t.ownsGroup=sn={ops:[t],delayedCallbacks:[]}}function Ko(e){!function(e,t){var n=e.ownsGroup;if(n)try{!function(e){var t=e.delayedCallbacks,n=0;do{for(;n<t.length;n++)t[n].call(null);for(var o=0;o<e.ops.length;o++){var r=e.ops[o];if(r.cursorActivityHandlers)for(;r.cursorActivityCalled<r.cursorActivityHandlers.length;)r.cursorActivityHandlers[r.cursorActivityCalled++].call(null,r.cm)}}while(n<t.length)}(n)}finally{sn=null,t(n)}}(e.curOp,function(e){for(var t=0;t<e.ops.length;t++)e.ops[t].cm.curOp=null;!function(e){for(var t=e.ops,n=0;n<t.length;n++)Go(t[n]);for(var o=0;o<t.length;o++)(r=t[o]).updatedDisplay=r.mustUpdate&&ur(r.cm,r.update);for(var r,i=0;i<t.length;i++)Xo(t[i]);for(var a=0;a<t.length;a++)Jo(t[a]);for(var s=0;s<t.length;s++)qo(t[s])}(e)})}function Go(e){var t=e.cm,n=t.display;!function(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=Ln(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=Ln(e)+"px",t.scrollbarsClipped=!0)}(t),e.updateMaxLine&&Xe(t),e.mustUpdate=e.viewChanged||e.forceUpdate||null!=e.scrollTop||e.scrollToPos&&(e.scrollToPos.from.line<n.viewFrom||e.scrollToPos.to.line>=n.viewTo)||n.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new lr(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function Xo(e){var t=e.cm,n=t.display;e.updatedDisplay&&Mo(t),e.barMeasure=No(t),n.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=En(t,n.maxLine,n.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+e.adjustWidthTo+Ln(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+e.adjustWidthTo-xn(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=n.input.prepareSelection())}function Jo(e){var t=e.cm;null!=e.adjustWidthTo&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&Po(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1);var n=e.focus&&e.focus==R();e.preparedSelection&&t.display.input.showSelection(e.preparedSelection,n),(e.updatedDisplay||e.startHeight!=t.doc.height)&&jo(t,e.barMeasure),e.updatedDisplay&&fr(t,e.barMeasure),e.selectionChanged&&yo(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),n&&_o(e.cm)}function qo(e){var t=e.cm,n=t.display,o=t.doc;e.updatedDisplay&&cr(t,e.update),null==n.wheelStartX||null==e.scrollTop&&null==e.scrollLeft&&!e.scrollToPos||(n.wheelStartX=n.wheelStartY=null),null!=e.scrollTop&&Yo(t,e.scrollTop,e.forceScroll),null!=e.scrollLeft&&Po(t,e.scrollLeft,!0,!0),e.scrollToPos&&function(e,t){if(!rt(e,"scrollCursorIntoView")){var n=e.display,o=n.sizer.getBoundingClientRect(),r=null;if(t.top+o.top<0?r=!0:t.bottom+o.top>(window.innerHeight||document.documentElement.clientHeight)&&(r=!1),null!=r&&!p){var i=D("div","​",null,"position: absolute;\n top: "+(t.top-n.viewOffset-kn(e.display))+"px;\n height: "+(t.bottom-t.top+Ln(e)+n.barHeight)+"px;\n left: "+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(i),i.scrollIntoView(r),e.display.lineSpace.removeChild(i)}}}(t,function(e,t,n,o){var r;null==o&&(o=0),e.options.lineWrapping||t!=n||(n="before"==(t=t.ch?ge(t.line,"before"==t.sticky?t.ch-1:t.ch,"after"):t).sticky?ge(t.line,t.ch+1,"before"):t);for(var i=0;i<5;i++){var a=!1,s=Xn(e,t),l=n&&n!=t?Xn(e,n):s,u=xo(e,r={left:Math.min(s.left,l.left),top:Math.min(s.top,l.top)-o,right:Math.max(s.left,l.left),bottom:Math.max(s.bottom,l.bottom)+o}),c=e.doc.scrollTop,d=e.doc.scrollLeft;if(null!=u.scrollTop&&(Ho(e,u.scrollTop),Math.abs(e.doc.scrollTop-c)>1&&(a=!0)),null!=u.scrollLeft&&(Po(e,u.scrollLeft),Math.abs(e.doc.scrollLeft-d)>1&&(a=!0)),!a)break}return r}(t,Me(o,e.scrollToPos.from),Me(o,e.scrollToPos.to),e.scrollToPos.margin));var r=e.maybeHiddenMarkers,i=e.maybeUnhiddenMarkers;if(r)for(var a=0;a<r.length;++a)r[a].lines.length||ot(r[a],"hide");if(i)for(var s=0;s<i.length;++s)i[s].lines.length&&ot(i[s],"unhide");n.wrapper.offsetHeight&&(o.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&ot(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function Qo(e,t){if(e.curOp)return t();Uo(e);try{return t()}finally{Ko(e)}}function $o(e,t){return function(){if(e.curOp)return t.apply(e,arguments);Uo(e);try{return t.apply(e,arguments)}finally{Ko(e)}}}function Zo(e){return function(){if(this.curOp)return e.apply(this,arguments);Uo(this);try{return e.apply(this,arguments)}finally{Ko(this)}}}function er(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);Uo(t);try{return e.apply(this,arguments)}finally{Ko(t)}}}function tr(e,t,n,o){null==t&&(t=e.doc.first),null==n&&(n=e.doc.first+e.doc.size),o||(o=0);var r=e.display;if(o&&n<r.viewTo&&(null==r.updateLineNumbers||r.updateLineNumbers>t)&&(r.updateLineNumbers=t),e.curOp.viewChanged=!0,t>=r.viewTo)Te&&ze(e.doc,t)<r.viewTo&&or(e);else if(n<=r.viewFrom)Te&&Be(e.doc,n+o)>r.viewFrom?or(e):(r.viewFrom+=o,r.viewTo+=o);else if(t<=r.viewFrom&&n>=r.viewTo)or(e);else if(t<=r.viewFrom){var i=rr(e,n,n+o,1);i?(r.view=r.view.slice(i.index),r.viewFrom=i.lineN,r.viewTo+=o):or(e)}else if(n>=r.viewTo){var a=rr(e,t,t,-1);a?(r.view=r.view.slice(0,a.index),r.viewTo=a.lineN):or(e)}else{var s=rr(e,t,t,-1),l=rr(e,n,n+o,1);s&&l?(r.view=r.view.slice(0,s.index).concat(an(e,s.lineN,l.lineN)).concat(r.view.slice(l.index)),r.viewTo+=o):or(e)}var u=r.externalMeasured;u&&(n<u.lineN?u.lineN+=o:t<u.lineN+u.size&&(r.externalMeasured=null))}function nr(e,t,n){e.curOp.viewChanged=!0;var o=e.display,r=e.display.externalMeasured;if(r&&t>=r.lineN&&t<r.lineN+r.size&&(o.externalMeasured=null),!(t<o.viewFrom||t>=o.viewTo)){var i=o.view[ho(e,t)];if(null!=i.node){var a=i.changes||(i.changes=[]);-1==j(a,n)&&a.push(n)}}}function or(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function rr(e,t,n,o){var r,i=ho(e,t),a=e.display.view;if(!Te||n==e.doc.first+e.doc.size)return{index:i,lineN:n};for(var s=e.display.viewFrom,l=0;l<i;l++)s+=a[l].size;if(s!=t){if(o>0){if(i==a.length-1)return null;r=s+a[i].size-t,i++}else r=s-t;t+=r,n+=r}for(;ze(e.doc,n)!=n;){if(i==(o<0?0:a.length-1))return null;n+=o*a[i-(o<0?1:0)].size,i+=o}return{index:i,lineN:n}}function ir(e){for(var t=e.display.view,n=0,o=0;o<t.length;o++){var r=t[o];r.hidden||r.node&&!r.changes||++n}return n}function ar(e,t){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(t,P(sr,e))}function sr(e){var t=e.doc;if(!(t.highlightFrontier>=e.display.viewTo)){var n=+new Date+e.options.workTime,o=Wt(e,t.highlightFrontier),r=[];t.iter(o.line,Math.min(t.first+t.size,e.display.viewTo+500),function(i){if(o.line>=e.display.viewFrom){var a=i.styles,s=i.text.length>e.options.maxHighlightLength?Et(t.mode,o.state):null,l=Nt(e,i,o,!0);s&&(o.state=s),i.styles=l.styles;var u=i.styleClasses,c=l.classes;c?i.styleClasses=c:u&&(i.styleClasses=null);for(var d=!a||a.length!=i.styles.length||u!=c&&(!u||!c||u.bgClass!=c.bgClass||u.textClass!=c.textClass),h=0;!d&&h<a.length;++h)d=a[h]!=i.styles[h];d&&r.push(o.line),i.stateAfter=o.save(),o.nextLine()}else i.text.length<=e.options.maxHighlightLength&&jt(e,i.text,o),i.stateAfter=o.line%5==0?o.save():null,o.nextLine();if(+new Date>n)return ar(e,e.options.workDelay),!0}),t.highlightFrontier=o.line,t.modeFrontier=Math.max(t.modeFrontier,o.line),r.length&&Qo(e,function(){for(var t=0;t<r.length;t++)nr(e,r[t],"text")})}}var lr=function(e,t,n){var o=e.display;this.viewport=t,this.visible=So(o,e.doc,t),this.editorIsHidden=!o.wrapper.offsetWidth,this.wrapperHeight=o.wrapper.clientHeight,this.wrapperWidth=o.wrapper.clientWidth,this.oldDisplayWidth=xn(e),this.force=n,this.dims=ao(e),this.events=[]};function ur(e,t){var n=e.display,o=e.doc;if(t.editorIsHidden)return or(e),!1;if(!t.force&&t.visible.from>=n.viewFrom&&t.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==ir(e))return!1;Lo(e)&&(or(e),t.dims=ao(e));var r=o.first+o.size,i=Math.max(t.visible.from-e.options.viewportMargin,o.first),a=Math.min(r,t.visible.to+e.options.viewportMargin);n.viewFrom<i&&i-n.viewFrom<20&&(i=Math.max(o.first,n.viewFrom)),n.viewTo>a&&n.viewTo-a<20&&(a=Math.min(r,n.viewTo)),Te&&(i=ze(e.doc,i),a=Be(e.doc,a));var s=i!=n.viewFrom||a!=n.viewTo||n.lastWrapHeight!=t.wrapperHeight||n.lastWrapWidth!=t.wrapperWidth;!function(e,t,n){var o=e.display;0==o.view.length||t>=o.viewTo||n<=o.viewFrom?(o.view=an(e,t,n),o.viewFrom=t):(o.viewFrom>t?o.view=an(e,t,o.viewFrom).concat(o.view):o.viewFrom<t&&(o.view=o.view.slice(ho(e,t))),o.viewFrom=t,o.viewTo<n?o.view=o.view.concat(an(e,o.viewTo,n)):o.viewTo>n&&(o.view=o.view.slice(0,ho(e,n)))),o.viewTo=n}(e,i,a),n.viewOffset=Ke(le(e.doc,n.viewFrom)),e.display.mover.style.top=n.viewOffset+"px";var u=ir(e);if(!s&&0==u&&!t.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var c=function(e){if(e.hasFocus())return null;var t=R();if(!t||!E(e.display.lineDiv,t))return null;var n={activeElt:t};if(window.getSelection){var o=window.getSelection();o.anchorNode&&o.extend&&E(e.display.lineDiv,o.anchorNode)&&(n.anchorNode=o.anchorNode,n.anchorOffset=o.anchorOffset,n.focusNode=o.focusNode,n.focusOffset=o.focusOffset)}return n}(e);return u>4&&(n.lineDiv.style.display="none"),function(e,t,n){var o=e.display,r=e.options.lineNumbers,i=o.lineDiv,a=i.firstChild;function s(t){var n=t.nextSibling;return l&&y&&e.display.currentWheelTarget==t?t.style.display="none":t.parentNode.removeChild(t),n}for(var u=o.view,c=o.viewFrom,d=0;d<u.length;d++){var h=u[d];if(h.hidden);else if(h.node&&h.node.parentNode==i){for(;a!=h.node;)a=s(a);var f=r&&null!=t&&t<=c&&h.lineNumber;h.changes&&(j(h.changes,"gutter")>-1&&(f=!1),dn(e,h,c,n)),f&&(L(h.lineNumber),h.lineNumber.appendChild(document.createTextNode(me(e.options,c)))),a=h.node.nextSibling}else{var p=yn(e,h,c,n);i.insertBefore(p,a)}c+=h.size}for(;a;)a=s(a)}(e,n.updateLineNumbers,t.dims),u>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,function(e){if(e&&e.activeElt&&e.activeElt!=R()&&(e.activeElt.focus(),e.anchorNode&&E(document.body,e.anchorNode)&&E(document.body,e.focusNode))){var t=window.getSelection(),n=document.createRange();n.setEnd(e.anchorNode,e.anchorOffset),n.collapse(!1),t.removeAllRanges(),t.addRange(n),t.extend(e.focusNode,e.focusOffset)}}(c),L(n.cursorDiv),L(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,s&&(n.lastWrapHeight=t.wrapperHeight,n.lastWrapWidth=t.wrapperWidth,ar(e,400)),n.updateLineNumbers=null,!0}function cr(e,t){for(var n=t.viewport,o=!0;(o&&e.options.lineWrapping&&t.oldDisplayWidth!=xn(e)||(n&&null!=n.top&&(n={top:Math.min(e.doc.height+Sn(e.display)-Dn(e),n.top)}),t.visible=So(e.display,e.doc,n),!(t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)))&&ur(e,t);o=!1){Mo(e);var r=No(e);fo(e),jo(e,r),fr(e,r),t.force=!1}t.signal(e,"update",e),e.display.viewFrom==e.display.reportedViewFrom&&e.display.viewTo==e.display.reportedViewTo||(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function dr(e,t){var n=new lr(e,t);if(ur(e,n)){Mo(e),cr(e,n);var o=No(e);fo(e),jo(e,o),fr(e,o),n.finish()}}function hr(e){var t=e.display.gutters.offsetWidth;e.display.sizer.style.marginLeft=t+"px"}function fr(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Ln(e)+"px"}function pr(e){var t=e.display.gutters,n=e.options.gutters;L(t);for(var o=0;o<n.length;++o){var r=n[o],i=t.appendChild(D("div",null,"CodeMirror-gutter "+r));"CodeMirror-linenumbers"==r&&(e.display.lineGutter=i,i.style.width=(e.display.lineNumWidth||1)+"px")}t.style.display=o?"":"none",hr(e)}function mr(e){var t=j(e.gutters,"CodeMirror-linenumbers");-1==t&&e.lineNumbers?e.gutters=e.gutters.concat(["CodeMirror-linenumbers"]):t>-1&&!e.lineNumbers&&(e.gutters=e.gutters.slice(0),e.gutters.splice(t,1))}lr.prototype.signal=function(e,t){at(e,t)&&this.events.push(arguments)},lr.prototype.finish=function(){for(var e=0;e<this.events.length;e++)ot.apply(null,this.events[e])};var gr=0,vr=null;function yr(e){var t=e.wheelDeltaX,n=e.wheelDeltaY;return null==t&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),null==n&&e.detail&&e.axis==e.VERTICAL_AXIS?n=e.detail:null==n&&(n=e.wheelDelta),{x:t,y:n}}function _r(e){var t=yr(e);return t.x*=vr,t.y*=vr,t}function wr(e,t){var o=yr(t),r=o.x,i=o.y,a=e.display,s=a.scroller,u=s.scrollWidth>s.clientWidth,c=s.scrollHeight>s.clientHeight;if(r&&u||i&&c){if(i&&y&&l)e:for(var h=t.target,f=a.view;h!=s;h=h.parentNode)for(var p=0;p<f.length;p++)if(f[p].node==h){e.display.currentWheelTarget=h;break e}if(r&&!n&&!d&&null!=vr)return i&&c&&Ho(e,Math.max(0,s.scrollTop+i*vr)),Po(e,Math.max(0,s.scrollLeft+r*vr)),(!i||i&&c)&&lt(t),void(a.wheelStartX=null);if(i&&null!=vr){var m=i*vr,g=e.doc.scrollTop,v=g+a.wrapper.clientHeight;m<0?g=Math.max(0,g+m-50):v=Math.min(e.doc.height,v+m+50),dr(e,{top:g,bottom:v})}gr<20&&(null==a.wheelStartX?(a.wheelStartX=s.scrollLeft,a.wheelStartY=s.scrollTop,a.wheelDX=r,a.wheelDY=i,setTimeout(function(){if(null!=a.wheelStartX){var e=s.scrollLeft-a.wheelStartX,t=s.scrollTop-a.wheelStartY,n=t&&a.wheelDY&&t/a.wheelDY||e&&a.wheelDX&&e/a.wheelDX;a.wheelStartX=a.wheelStartY=null,n&&(vr=(vr*gr+n)/(gr+1),++gr)}},200)):(a.wheelDX+=r,a.wheelDY+=i))}}a?vr=-.53:n?vr=15:c?vr=-.7:h&&(vr=-1/3);var br=function(e,t){this.ranges=e,this.primIndex=t};br.prototype.primary=function(){return this.ranges[this.primIndex]},br.prototype.equals=function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var t=0;t<this.ranges.length;t++){var n=this.ranges[t],o=e.ranges[t];if(!ye(n.anchor,o.anchor)||!ye(n.head,o.head))return!1}return!0},br.prototype.deepCopy=function(){for(var e=[],t=0;t<this.ranges.length;t++)e[t]=new Cr(_e(this.ranges[t].anchor),_e(this.ranges[t].head));return new br(e,this.primIndex)},br.prototype.somethingSelected=function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},br.prototype.contains=function(e,t){t||(t=e);for(var n=0;n<this.ranges.length;n++){var o=this.ranges[n];if(ve(t,o.from())>=0&&ve(e,o.to())<=0)return n}return-1};var Cr=function(e,t){this.anchor=e,this.head=t};function Mr(e,t){var n=e[t];e.sort(function(e,t){return ve(e.from(),t.from())}),t=j(e,n);for(var o=1;o<e.length;o++){var r=e[o],i=e[o-1];if(ve(i.to(),r.from())>=0){var a=be(i.from(),r.from()),s=we(i.to(),r.to()),l=i.empty()?r.from()==r.head:i.from()==i.head;o<=t&&--t,e.splice(--o,2,new Cr(l?s:a,l?a:s))}}return new br(e,t)}function kr(e,t){return new br([new Cr(e,t||e)],0)}function Sr(e){return e.text?ge(e.from.line+e.text.length-1,J(e.text).length+(1==e.text.length?e.from.ch:0)):e.to}function Tr(e,t){if(ve(e,t.from)<0)return e;if(ve(e,t.to)<=0)return Sr(t);var n=e.line+t.text.length-(t.to.line-t.from.line)-1,o=e.ch;return e.line==t.to.line&&(o+=Sr(t).ch-t.to.ch),ge(n,o)}function Lr(e,t){for(var n=[],o=0;o<e.sel.ranges.length;o++){var r=e.sel.ranges[o];n.push(new Cr(Tr(r.anchor,t),Tr(r.head,t)))}return Mr(n,e.sel.primIndex)}function xr(e,t,n){return e.line==t.line?ge(n.line,e.ch-t.ch+n.ch):ge(n.line+(e.line-t.line),e.ch)}function Dr(e){e.doc.mode=xt(e.options,e.doc.modeOption),Or(e)}function Or(e){e.doc.iter(function(e){e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null)}),e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,ar(e,100),e.state.modeGen++,e.curOp&&tr(e)}function Er(e,t){return 0==t.from.ch&&0==t.to.ch&&""==J(t.text)&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function Rr(e,t,n,o){function r(e){return n?n[e]:null}function i(e,n,r){!function(e,t,n,o){e.text=t,e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null),null!=e.order&&(e.order=null),Re(e),Ae(e,n);var r=o?o(e):1;r!=e.height&&de(e,r)}(e,n,r,o),un(e,"change",e,t)}function a(e,t){for(var n=[],i=e;i<t;++i)n.push(new Gt(u[i],r(i),o));return n}var s=t.from,l=t.to,u=t.text,c=le(e,s.line),d=le(e,l.line),h=J(u),f=r(u.length-1),p=l.line-s.line;if(t.full)e.insert(0,a(0,u.length)),e.remove(u.length,e.size-u.length);else if(Er(e,t)){var m=a(0,u.length-1);i(d,d.text,f),p&&e.remove(s.line,p),m.length&&e.insert(s.line,m)}else if(c==d)if(1==u.length)i(c,c.text.slice(0,s.ch)+h+c.text.slice(l.ch),f);else{var g=a(1,u.length-1);g.push(new Gt(h+c.text.slice(l.ch),f,o)),i(c,c.text.slice(0,s.ch)+u[0],r(0)),e.insert(s.line+1,g)}else if(1==u.length)i(c,c.text.slice(0,s.ch)+u[0]+d.text.slice(l.ch),r(0)),e.remove(s.line+1,p);else{i(c,c.text.slice(0,s.ch)+u[0],r(0)),i(d,h+d.text.slice(l.ch),f);var v=a(1,u.length-1);p>1&&e.remove(s.line+1,p-1),e.insert(s.line+1,v)}un(e,"change",e,t)}function Ar(e,t,n){!function e(o,r,i){if(o.linked)for(var a=0;a<o.linked.length;++a){var s=o.linked[a];if(s.doc!=r){var l=i&&s.sharedHist;n&&!l||(t(s.doc,l),e(s.doc,o,l))}}}(e,null,!0)}function Hr(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,uo(e),Dr(e),Yr(e),e.options.lineWrapping||Xe(e),e.options.mode=t.modeOption,tr(e)}function Yr(e){("rtl"==e.doc.direction?A:T)(e.display.lineDiv,"CodeMirror-rtl")}function Pr(e){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e||1}function Nr(e,t){var n={from:_e(t.from),to:Sr(t),text:ue(e,t.from,t.to)};return zr(e,n,t.from.line,t.to.line+1),Ar(e,function(e){return zr(e,n,t.from.line,t.to.line+1)},!0),n}function Ir(e){for(;e.length&&J(e).ranges;)e.pop()}function Wr(e,t,n,o){var r=e.history;r.undone.length=0;var i,a,s=+new Date;if((r.lastOp==o||r.lastOrigin==t.origin&&t.origin&&("+"==t.origin.charAt(0)&&r.lastModTime>s-(e.cm?e.cm.options.historyEventDelay:500)||"*"==t.origin.charAt(0)))&&(i=function(e,t){return t?(Ir(e.done),J(e.done)):e.done.length&&!J(e.done).ranges?J(e.done):e.done.length>1&&!e.done[e.done.length-2].ranges?(e.done.pop(),J(e.done)):void 0}(r,r.lastOp==o)))a=J(i.changes),0==ve(t.from,t.to)&&0==ve(t.from,a.to)?a.to=Sr(t):i.changes.push(Nr(e,t));else{var l=J(r.done);for(l&&l.ranges||Fr(e.sel,r.done),i={changes:[Nr(e,t)],generation:r.generation},r.done.push(i);r.done.length>r.undoDepth;)r.done.shift(),r.done[0].ranges||r.done.shift()}r.done.push(n),r.generation=++r.maxGeneration,r.lastModTime=r.lastSelTime=s,r.lastOp=r.lastSelOp=o,r.lastOrigin=r.lastSelOrigin=t.origin,a||ot(e,"historyAdded")}function jr(e,t,n,o){var r=e.history,i=o&&o.origin;n==r.lastSelOp||i&&r.lastSelOrigin==i&&(r.lastModTime==r.lastSelTime&&r.lastOrigin==i||function(e,t,n,o){var r=t.charAt(0);return"*"==r||"+"==r&&n.ranges.length==o.ranges.length&&n.somethingSelected()==o.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}(e,i,J(r.done),t))?r.done[r.done.length-1]=t:Fr(t,r.done),r.lastSelTime=+new Date,r.lastSelOrigin=i,r.lastSelOp=n,o&&!1!==o.clearRedo&&Ir(r.undone)}function Fr(e,t){var n=J(t);n&&n.ranges&&n.equals(e)||t.push(e)}function zr(e,t,n,o){var r=t["spans_"+e.id],i=0;e.iter(Math.max(e.first,n),Math.min(e.first+e.size,o),function(n){n.markedSpans&&((r||(r=t["spans_"+e.id]={}))[i]=n.markedSpans),++i})}function Br(e){if(!e)return null;for(var t,n=0;n<e.length;++n)e[n].marker.explicitlyCleared?t||(t=e.slice(0,n)):t&&t.push(e[n]);return t?t.length?t:null:e}function Vr(e,t){var n=function(e,t){var n=t["spans_"+e.id];if(!n)return null;for(var o=[],r=0;r<t.text.length;++r)o.push(Br(n[r]));return o}(e,t),o=Oe(e,t);if(!n)return o;if(!o)return n;for(var r=0;r<n.length;++r){var i=n[r],a=o[r];if(i&&a)e:for(var s=0;s<a.length;++s){for(var l=a[s],u=0;u<i.length;++u)if(i[u].marker==l.marker)continue e;i.push(l)}else a&&(n[r]=a)}return n}function Ur(e,t,n){for(var o=[],r=0;r<e.length;++r){var i=e[r];if(i.ranges)o.push(n?br.prototype.deepCopy.call(i):i);else{var a=i.changes,s=[];o.push({changes:s});for(var l=0;l<a.length;++l){var u=a[l],c=void 0;if(s.push({from:u.from,to:u.to,text:u.text}),t)for(var d in u)(c=d.match(/^spans_(\d+)$/))&&j(t,Number(c[1]))>-1&&(J(s)[d]=u[d],delete u[d])}}}return o}function Kr(e,t,n,o){if(o){var r=e.anchor;if(n){var i=ve(t,r)<0;i!=ve(n,r)<0?(r=t,t=n):i!=ve(t,n)<0&&(t=n)}return new Cr(r,t)}return new Cr(n||t,t)}function Gr(e,t,n,o,r){null==r&&(r=e.cm&&(e.cm.display.shift||e.extend)),$r(e,new br([Kr(e.sel.primary(),t,n,r)],0),o)}function Xr(e,t,n){for(var o=[],r=e.cm&&(e.cm.display.shift||e.extend),i=0;i<e.sel.ranges.length;i++)o[i]=Kr(e.sel.ranges[i],t[i],null,r);$r(e,Mr(o,e.sel.primIndex),n)}function Jr(e,t,n,o){var r=e.sel.ranges.slice(0);r[t]=n,$r(e,Mr(r,e.sel.primIndex),o)}function qr(e,t,n,o){$r(e,kr(t,n),o)}function Qr(e,t,n){var o=e.history.done,r=J(o);r&&r.ranges?(o[o.length-1]=t,Zr(e,t,n)):$r(e,t,n)}function $r(e,t,n){Zr(e,t,n),jr(e,e.sel,e.cm?e.cm.curOp.id:NaN,n)}function Zr(e,t,n){(at(e,"beforeSelectionChange")||e.cm&&at(e.cm,"beforeSelectionChange"))&&(t=function(e,t,n){var o={ranges:t.ranges,update:function(t){this.ranges=[];for(var n=0;n<t.length;n++)this.ranges[n]=new Cr(Me(e,t[n].anchor),Me(e,t[n].head))},origin:n&&n.origin};return ot(e,"beforeSelectionChange",e,o),e.cm&&ot(e.cm,"beforeSelectionChange",e.cm,o),o.ranges!=t.ranges?Mr(o.ranges,o.ranges.length-1):t}(e,t,n));var o=n&&n.bias||(ve(t.primary().head,e.sel.primary().head)<0?-1:1);ei(e,ni(e,t,o,!0)),n&&!1===n.scroll||!e.cm||Oo(e.cm)}function ei(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=e.cm.curOp.selectionChanged=!0,it(e.cm)),un(e,"cursorActivity",e))}function ti(e){ei(e,ni(e,e.sel,null,!1))}function ni(e,t,n,o){for(var r,i=0;i<t.ranges.length;i++){var a=t.ranges[i],s=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[i],l=ri(e,a.anchor,s&&s.anchor,n,o),u=ri(e,a.head,s&&s.head,n,o);(r||l!=a.anchor||u!=a.head)&&(r||(r=t.ranges.slice(0,i)),r[i]=new Cr(l,u))}return r?Mr(r,t.primIndex):t}function oi(e,t,n,o,r){var i=le(e,t.line);if(i.markedSpans)for(var a=0;a<i.markedSpans.length;++a){var s=i.markedSpans[a],l=s.marker;if((null==s.from||(l.inclusiveLeft?s.from<=t.ch:s.from<t.ch))&&(null==s.to||(l.inclusiveRight?s.to>=t.ch:s.to>t.ch))){if(r&&(ot(l,"beforeCursorEnter"),l.explicitlyCleared)){if(i.markedSpans){--a;continue}break}if(!l.atomic)continue;if(n){var u=l.find(o<0?1:-1),c=void 0;if((o<0?l.inclusiveRight:l.inclusiveLeft)&&(u=ii(e,u,-o,u&&u.line==t.line?i:null)),u&&u.line==t.line&&(c=ve(u,n))&&(o<0?c<0:c>0))return oi(e,u,t,o,r)}var d=l.find(o<0?-1:1);return(o<0?l.inclusiveLeft:l.inclusiveRight)&&(d=ii(e,d,o,d.line==t.line?i:null)),d?oi(e,d,t,o,r):null}}return t}function ri(e,t,n,o,r){var i=o||1,a=oi(e,t,n,i,r)||!r&&oi(e,t,n,i,!0)||oi(e,t,n,-i,r)||!r&&oi(e,t,n,-i,!0);return a||(e.cantEdit=!0,ge(e.first,0))}function ii(e,t,n,o){return n<0&&0==t.ch?t.line>e.first?Me(e,ge(t.line-1)):null:n>0&&t.ch==(o||le(e,t.line)).text.length?t.line<e.first+e.size-1?ge(t.line+1,0):null:new ge(t.line,t.ch+n)}function ai(e){e.setSelection(ge(e.firstLine(),0),ge(e.lastLine()),B)}function si(e,t,n){var o={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){return o.canceled=!0}};return n&&(o.update=function(t,n,r,i){t&&(o.from=Me(e,t)),n&&(o.to=Me(e,n)),r&&(o.text=r),void 0!==i&&(o.origin=i)}),ot(e,"beforeChange",e,o),e.cm&&ot(e.cm,"beforeChange",e.cm,o),o.canceled?null:{from:o.from,to:o.to,text:o.text,origin:o.origin}}function li(e,t,n){if(e.cm){if(!e.cm.curOp)return $o(e.cm,li)(e,t,n);if(e.cm.state.suppressEdits)return}if(!(at(e,"beforeChange")||e.cm&&at(e.cm,"beforeChange"))||(t=si(e,t,!0))){var o=Se&&!n&&function(e,t,n){var o=null;if(e.iter(t.line,n.line+1,function(e){if(e.markedSpans)for(var t=0;t<e.markedSpans.length;++t){var n=e.markedSpans[t].marker;!n.readOnly||o&&-1!=j(o,n)||(o||(o=[])).push(n)}}),!o)return null;for(var r=[{from:t,to:n}],i=0;i<o.length;++i)for(var a=o[i],s=a.find(0),l=0;l<r.length;++l){var u=r[l];if(!(ve(u.to,s.from)<0||ve(u.from,s.to)>0)){var c=[l,1],d=ve(u.from,s.from),h=ve(u.to,s.to);(d<0||!a.inclusiveLeft&&!d)&&c.push({from:u.from,to:s.from}),(h>0||!a.inclusiveRight&&!h)&&c.push({from:s.to,to:u.to}),r.splice.apply(r,c),l+=c.length-3}}return r}(e,t.from,t.to);if(o)for(var r=o.length-1;r>=0;--r)ui(e,{from:o[r].from,to:o[r].to,text:r?[""]:t.text,origin:t.origin});else ui(e,t)}}function ui(e,t){if(1!=t.text.length||""!=t.text[0]||0!=ve(t.from,t.to)){var n=Lr(e,t);Wr(e,t,n,e.cm?e.cm.curOp.id:NaN),hi(e,t,n,Oe(e,t));var o=[];Ar(e,function(e,n){n||-1!=j(o,e.history)||(gi(e.history,t),o.push(e.history)),hi(e,t,null,Oe(e,t))})}}function ci(e,t,n){var o=e.cm&&e.cm.state.suppressEdits;if(!o||n){for(var r,i=e.history,a=e.sel,s="undo"==t?i.done:i.undone,l="undo"==t?i.undone:i.done,u=0;u<s.length&&(r=s[u],n?!r.ranges||r.equals(e.sel):r.ranges);u++);if(u!=s.length){for(i.lastOrigin=i.lastSelOrigin=null;;){if(!(r=s.pop()).ranges){if(o)return void s.push(r);break}if(Fr(r,l),n&&!r.equals(e.sel))return void $r(e,r,{clearRedo:!1});a=r}var c=[];Fr(a,l),l.push({changes:c,generation:i.generation}),i.generation=r.generation||++i.maxGeneration;for(var d=at(e,"beforeChange")||e.cm&&at(e.cm,"beforeChange"),h=function(n){var o=r.changes[n];if(o.origin=t,d&&!si(e,o,!1))return s.length=0,{};c.push(Nr(e,o));var i=n?Lr(e,o):J(s);hi(e,o,i,Vr(e,o)),!n&&e.cm&&e.cm.scrollIntoView({from:o.from,to:Sr(o)});var a=[];Ar(e,function(e,t){t||-1!=j(a,e.history)||(gi(e.history,o),a.push(e.history)),hi(e,o,null,Vr(e,o))})},f=r.changes.length-1;f>=0;--f){var p=h(f);if(p)return p.v}}}}function di(e,t){if(0!=t&&(e.first+=t,e.sel=new br(q(e.sel.ranges,function(e){return new Cr(ge(e.anchor.line+t,e.anchor.ch),ge(e.head.line+t,e.head.ch))}),e.sel.primIndex),e.cm)){tr(e.cm,e.first,e.first-t,t);for(var n=e.cm.display,o=n.viewFrom;o<n.viewTo;o++)nr(e.cm,o,"gutter")}}function hi(e,t,n,o){if(e.cm&&!e.cm.curOp)return $o(e.cm,hi)(e,t,n,o);if(t.to.line<e.first)di(e,t.text.length-1-(t.to.line-t.from.line));else if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var r=t.text.length-1-(e.first-t.from.line);di(e,r),t={from:ge(e.first,0),to:ge(t.to.line+r,t.to.ch),text:[J(t.text)],origin:t.origin}}var i=e.lastLine();t.to.line>i&&(t={from:t.from,to:ge(i,le(e,i).text.length),text:[t.text[0]],origin:t.origin}),t.removed=ue(e,t.from,t.to),n||(n=Lr(e,t)),e.cm?function(e,t,n){var o=e.doc,r=e.display,i=t.from,a=t.to,s=!1,l=i.line;e.options.lineWrapping||(l=he(Fe(le(o,i.line))),o.iter(l,a.line+1,function(e){if(e==r.maxLine)return s=!0,!0})),o.sel.contains(t.from,t.to)>-1&&it(e),Rr(o,t,n,lo(e)),e.options.lineWrapping||(o.iter(l,i.line+t.text.length,function(e){var t=Ge(e);t>r.maxLineLength&&(r.maxLine=e,r.maxLineLength=t,r.maxLineChanged=!0,s=!1)}),s&&(e.curOp.updateMaxLine=!0)),function(e,t){if(e.modeFrontier=Math.min(e.modeFrontier,t),!(e.highlightFrontier<t-10)){for(var n=e.first,o=t-1;o>n;o--){var r=le(e,o).stateAfter;if(r&&(!(r instanceof Yt)||o+r.lookAhead<t)){n=o+1;break}}e.highlightFrontier=Math.min(e.highlightFrontier,n)}}(o,i.line),ar(e,400);var u=t.text.length-(a.line-i.line)-1;t.full?tr(e):i.line!=a.line||1!=t.text.length||Er(e.doc,t)?tr(e,i.line,a.line+1,u):nr(e,i.line,"text");var c=at(e,"changes"),d=at(e,"change");if(d||c){var h={from:i,to:a,text:t.text,removed:t.removed,origin:t.origin};d&&un(e,"change",e,h),c&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(h)}e.display.selForContextMenu=null}(e.cm,t,o):Rr(e,t,o),Zr(e,n,B)}}function fi(e,t,n,o,r){var i;o||(o=n),ve(o,n)<0&&(n=(i=[o,n])[0],o=i[1]),"string"==typeof t&&(t=e.splitLines(t)),li(e,{from:n,to:o,text:t,origin:r})}function pi(e,t,n,o){n<e.line?e.line+=o:t<e.line&&(e.line=t,e.ch=0)}function mi(e,t,n,o){for(var r=0;r<e.length;++r){var i=e[r],a=!0;if(i.ranges){i.copied||((i=e[r]=i.deepCopy()).copied=!0);for(var s=0;s<i.ranges.length;s++)pi(i.ranges[s].anchor,t,n,o),pi(i.ranges[s].head,t,n,o)}else{for(var l=0;l<i.changes.length;++l){var u=i.changes[l];if(n<u.from.line)u.from=ge(u.from.line+o,u.from.ch),u.to=ge(u.to.line+o,u.to.ch);else if(t<=u.to.line){a=!1;break}}a||(e.splice(0,r+1),r=0)}}}function gi(e,t){var n=t.from.line,o=t.to.line,r=t.text.length-(o-n)-1;mi(e.done,n,o,r),mi(e.undone,n,o,r)}function vi(e,t,n,o){var r=t,i=t;return"number"==typeof t?i=le(e,Ce(e,t)):r=he(t),null==r?null:(o(i,r)&&e.cm&&nr(e.cm,r,n),i)}function yi(e){this.lines=e,this.parent=null;for(var t=0,n=0;n<e.length;++n)e[n].parent=this,t+=e[n].height;this.height=t}function _i(e){this.children=e;for(var t=0,n=0,o=0;o<e.length;++o){var r=e[o];t+=r.chunkSize(),n+=r.height,r.parent=this}this.size=t,this.height=n,this.parent=null}Cr.prototype.from=function(){return be(this.anchor,this.head)},Cr.prototype.to=function(){return we(this.anchor,this.head)},Cr.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch},yi.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var n=e,o=e+t;n<o;++n){var r=this.lines[n];this.height-=r.height,Xt(r),un(r,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,n){this.height+=n,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var o=0;o<t.length;++o)t[o].parent=this},iterN:function(e,t,n){for(var o=e+t;e<o;++e)if(n(this.lines[e]))return!0}},_i.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){this.size-=t;for(var n=0;n<this.children.length;++n){var o=this.children[n],r=o.chunkSize();if(e<r){var i=Math.min(t,r-e),a=o.height;if(o.removeInner(e,i),this.height-=a-o.height,r==i&&(this.children.splice(n--,1),o.parent=null),0==(t-=i))break;e=0}else e-=r}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof yi))){var s=[];this.collapse(s),this.children=[new yi(s)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t<this.children.length;++t)this.children[t].collapse(e)},insertInner:function(e,t,n){this.size+=t.length,this.height+=n;for(var o=0;o<this.children.length;++o){var r=this.children[o],i=r.chunkSize();if(e<=i){if(r.insertInner(e,t,n),r.lines&&r.lines.length>50){for(var a=r.lines.length%25+25,s=a;s<r.lines.length;){var l=new yi(r.lines.slice(s,s+=25));r.height-=l.height,this.children.splice(++o,0,l),l.parent=this}r.lines=r.lines.slice(0,a),this.maybeSpill()}break}e-=i}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=new _i(e.children.splice(e.children.length-5,5));if(e.parent){e.size-=t.size,e.height-=t.height;var n=j(e.parent.children,e);e.parent.children.splice(n+1,0,t)}else{var o=new _i(e.children);o.parent=e,e.children=[o,t],e=o}t.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,n){for(var o=0;o<this.children.length;++o){var r=this.children[o],i=r.chunkSize();if(e<i){var a=Math.min(t,i-e);if(r.iterN(e,a,n))return!0;if(0==(t-=a))break;e=0}else e-=i}}};var wi=function(e,t,n){if(n)for(var o in n)n.hasOwnProperty(o)&&(this[o]=n[o]);this.doc=e,this.node=t};function bi(e,t,n){Ke(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&Do(e,n)}wi.prototype.clear=function(){var e=this.doc.cm,t=this.line.widgets,n=this.line,o=he(n);if(null!=o&&t){for(var r=0;r<t.length;++r)t[r]==this&&t.splice(r--,1);t.length||(n.widgets=null);var i=Cn(this);de(n,Math.max(0,n.height-i)),e&&(Qo(e,function(){bi(e,n,-i),nr(e,o,"widget")}),un(e,"lineWidgetCleared",e,this,o))}},wi.prototype.changed=function(){var e=this,t=this.height,n=this.doc.cm,o=this.line;this.height=null;var r=Cn(this)-t;r&&(de(o,o.height+r),n&&Qo(n,function(){n.curOp.forceUpdate=!0,bi(n,o,r),un(n,"lineWidgetChanged",n,e,he(o))}))},st(wi);var Ci=0,Mi=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++Ci};function ki(e,t,n,o,r){if(o&&o.shared)return function(e,t,n,o,r){(o=N(o)).shared=!1;var i=[ki(e,t,n,o,r)],a=i[0],s=o.widgetNode;return Ar(e,function(e){s&&(o.widgetNode=s.cloneNode(!0)),i.push(ki(e,Me(e,t),Me(e,n),o,r));for(var l=0;l<e.linked.length;++l)if(e.linked[l].isParent)return;a=J(i)}),new Si(i,a)}(e,t,n,o,r);if(e.cm&&!e.cm.curOp)return $o(e.cm,ki)(e,t,n,o,r);var i=new Mi(e,r),a=ve(t,n);if(o&&N(o,i,!1),a>0||0==a&&!1!==i.clearWhenEmpty)return i;if(i.replacedWith&&(i.collapsed=!0,i.widgetNode=O("span",[i.replacedWith],"CodeMirror-widget"),o.handleMouseEvents||i.widgetNode.setAttribute("cm-ignore-events","true"),o.insertLeft&&(i.widgetNode.insertLeft=!0)),i.collapsed){if(je(e,t.line,t,n,i)||t.line!=n.line&&je(e,n.line,t,n,i))throw new Error("Inserting collapsed marker partially overlapping an existing one");Te=!0}i.addToHistory&&Wr(e,{from:t,to:n,origin:"markText"},e.sel,NaN);var s,l=t.line,u=e.cm;if(e.iter(l,n.line+1,function(e){u&&i.collapsed&&!u.options.lineWrapping&&Fe(e)==u.display.maxLine&&(s=!0),i.collapsed&&l!=t.line&&de(e,0),function(e,t){e.markedSpans=e.markedSpans?e.markedSpans.concat([t]):[t],t.marker.attachLine(e)}(e,new Le(i,l==t.line?t.ch:null,l==n.line?n.ch:null)),++l}),i.collapsed&&e.iter(t.line,n.line+1,function(t){Ve(e,t)&&de(t,0)}),i.clearOnEnter&&et(i,"beforeCursorEnter",function(){return i.clear()}),i.readOnly&&(Se=!0,(e.history.done.length||e.history.undone.length)&&e.clearHistory()),i.collapsed&&(i.id=++Ci,i.atomic=!0),u){if(s&&(u.curOp.updateMaxLine=!0),i.collapsed)tr(u,t.line,n.line+1);else if(i.className||i.title||i.startStyle||i.endStyle||i.css)for(var c=t.line;c<=n.line;c++)nr(u,c,"text");i.atomic&&ti(u.doc),un(u,"markerAdded",u,i)}return i}Mi.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&Uo(e),at(this,"clear")){var n=this.find();n&&un(this,"clear",n.from,n.to)}for(var o=null,r=null,i=0;i<this.lines.length;++i){var a=this.lines[i],s=xe(a.markedSpans,this);e&&!this.collapsed?nr(e,he(a),"text"):e&&(null!=s.to&&(r=he(a)),null!=s.from&&(o=he(a))),a.markedSpans=De(a.markedSpans,s),null==s.from&&this.collapsed&&!Ve(this.doc,a)&&e&&de(a,ro(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var l=0;l<this.lines.length;++l){var u=Fe(this.lines[l]),c=Ge(u);c>e.display.maxLineLength&&(e.display.maxLine=u,e.display.maxLineLength=c,e.display.maxLineChanged=!0)}null!=o&&e&&this.collapsed&&tr(e,o,r+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&ti(e.doc)),e&&un(e,"markerCleared",e,this,o,r),t&&Ko(e),this.parent&&this.parent.clear()}},Mi.prototype.find=function(e,t){var n,o;null==e&&"bookmark"==this.type&&(e=1);for(var r=0;r<this.lines.length;++r){var i=this.lines[r],a=xe(i.markedSpans,this);if(null!=a.from&&(n=ge(t?i:he(i),a.from),-1==e))return n;if(null!=a.to&&(o=ge(t?i:he(i),a.to),1==e))return o}return n&&{from:n,to:o}},Mi.prototype.changed=function(){var e=this,t=this.find(-1,!0),n=this,o=this.doc.cm;t&&o&&Qo(o,function(){var r=t.line,i=he(t.line),a=Rn(o,i);if(a&&(Wn(a),o.curOp.selectionChanged=o.curOp.forceUpdate=!0),o.curOp.updateMaxLine=!0,!Ve(n.doc,r)&&null!=n.height){var s=n.height;n.height=null;var l=Cn(n)-s;l&&de(r,r.height+l)}un(o,"markerChanged",o,e)})},Mi.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;t.maybeHiddenMarkers&&-1!=j(t.maybeHiddenMarkers,this)||(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},Mi.prototype.detachLine=function(e){if(this.lines.splice(j(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}},st(Mi);var Si=function(e,t){this.markers=e,this.primary=t;for(var n=0;n<e.length;++n)e[n].parent=this};function Ti(e){return e.findMarks(ge(e.first,0),e.clipPos(ge(e.lastLine())),function(e){return e.parent})}function Li(e){for(var t=function(t){var n=e[t],o=[n.primary.doc];Ar(n.primary.doc,function(e){return o.push(e)});for(var r=0;r<n.markers.length;r++){var i=n.markers[r];-1==j(o,i.doc)&&(i.parent=null,n.markers.splice(r--,1))}},n=0;n<e.length;n++)t(n)}Si.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();un(this,"clear")}},Si.prototype.find=function(e,t){return this.primary.find(e,t)},st(Si);var xi=0,Di=function(e,t,n,o,r){if(!(this instanceof Di))return new Di(e,t,n,o,r);null==n&&(n=0),_i.call(this,[new yi([new Gt("",null)])]),this.first=n,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=n;var i=ge(n,0);this.sel=kr(i),this.history=new Pr(null),this.id=++xi,this.modeOption=t,this.lineSep=o,this.direction="rtl"==r?"rtl":"ltr",this.extend=!1,"string"==typeof e&&(e=this.splitLines(e)),Rr(this,{from:i,to:i,text:e}),$r(this,kr(i),B)};Di.prototype=$(_i.prototype,{constructor:Di,iter:function(e,t,n){n?this.iterN(e-this.first,t-e,n):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var n=0,o=0;o<t.length;++o)n+=t[o].height;this.insertInner(e-this.first,t,n)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=ce(this,this.first,this.first+this.size);return!1===e?t:t.join(e||this.lineSeparator())},setValue:er(function(e){var t=ge(this.first,0),n=this.first+this.size-1;li(this,{from:t,to:ge(n,le(this,n).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&Eo(this.cm,0,0),$r(this,kr(t),B)}),replaceRange:function(e,t,n,o){fi(this,e,t=Me(this,t),n=n?Me(this,n):t,o)},getRange:function(e,t,n){var o=ue(this,Me(this,e),Me(this,t));return!1===n?o:o.join(n||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){if(pe(this,e))return le(this,e)},getLineNumber:function(e){return he(e)},getLineHandleVisualStart:function(e){return"number"==typeof e&&(e=le(this,e)),Fe(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return Me(this,e)},getCursor:function(e){var t=this.sel.primary();return null==e||"head"==e?t.head:"anchor"==e?t.anchor:"end"==e||"to"==e||!1===e?t.to():t.from()},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:er(function(e,t,n){qr(this,Me(this,"number"==typeof e?ge(e,t||0):e),null,n)}),setSelection:er(function(e,t,n){qr(this,Me(this,e),Me(this,t||e),n)}),extendSelection:er(function(e,t,n){Gr(this,Me(this,e),t&&Me(this,t),n)}),extendSelections:er(function(e,t){Xr(this,ke(this,e),t)}),extendSelectionsBy:er(function(e,t){Xr(this,ke(this,q(this.sel.ranges,e)),t)}),setSelections:er(function(e,t,n){if(e.length){for(var o=[],r=0;r<e.length;r++)o[r]=new Cr(Me(this,e[r].anchor),Me(this,e[r].head));null==t&&(t=Math.min(e.length-1,this.sel.primIndex)),$r(this,Mr(o,t),n)}}),addSelection:er(function(e,t,n){var o=this.sel.ranges.slice(0);o.push(new Cr(Me(this,e),Me(this,t||e))),$r(this,Mr(o,o.length-1),n)}),getSelection:function(e){for(var t,n=this.sel.ranges,o=0;o<n.length;o++){var r=ue(this,n[o].from(),n[o].to());t=t?t.concat(r):r}return!1===e?t:t.join(e||this.lineSeparator())},getSelections:function(e){for(var t=[],n=this.sel.ranges,o=0;o<n.length;o++){var r=ue(this,n[o].from(),n[o].to());!1!==e&&(r=r.join(e||this.lineSeparator())),t[o]=r}return t},replaceSelection:function(e,t,n){for(var o=[],r=0;r<this.sel.ranges.length;r++)o[r]=e;this.replaceSelections(o,t,n||"+input")},replaceSelections:er(function(e,t,n){for(var o=[],r=this.sel,i=0;i<r.ranges.length;i++){var a=r.ranges[i];o[i]={from:a.from(),to:a.to(),text:this.splitLines(e[i]),origin:n}}for(var s=t&&"end"!=t&&function(e,t,n){for(var o=[],r=ge(e.first,0),i=r,a=0;a<t.length;a++){var s=t[a],l=xr(s.from,r,i),u=xr(Sr(s),r,i);if(r=s.to,i=u,"around"==n){var c=e.sel.ranges[a],d=ve(c.head,c.anchor)<0;o[a]=new Cr(d?u:l,d?l:u)}else o[a]=new Cr(l,l)}return new br(o,e.sel.primIndex)}(this,o,t),l=o.length-1;l>=0;l--)li(this,o[l]);s?Qr(this,s):this.cm&&Oo(this.cm)}),undo:er(function(){ci(this,"undo")}),redo:er(function(){ci(this,"redo")}),undoSelection:er(function(){ci(this,"undo",!0)}),redoSelection:er(function(){ci(this,"redo",!0)}),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,n=0,o=0;o<e.done.length;o++)e.done[o].ranges||++t;for(var r=0;r<e.undone.length;r++)e.undone[r].ranges||++n;return{undo:t,redo:n}},clearHistory:function(){this.history=new Pr(this.history.maxGeneration)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:Ur(this.history.done),undone:Ur(this.history.undone)}},setHistory:function(e){var t=this.history=new Pr(this.history.maxGeneration);t.done=Ur(e.done.slice(0),null,!0),t.undone=Ur(e.undone.slice(0),null,!0)},setGutterMarker:er(function(e,t,n){return vi(this,e,"gutter",function(e){var o=e.gutterMarkers||(e.gutterMarkers={});return o[t]=n,!n&&ne(o)&&(e.gutterMarkers=null),!0})}),clearGutter:er(function(e){var t=this;this.iter(function(n){n.gutterMarkers&&n.gutterMarkers[e]&&vi(t,n,"gutter",function(){return n.gutterMarkers[e]=null,ne(n.gutterMarkers)&&(n.gutterMarkers=null),!0})})}),lineInfo:function(e){var t;if("number"==typeof e){if(!pe(this,e))return null;if(t=e,!(e=le(this,e)))return null}else if(null==(t=he(e)))return null;return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:er(function(e,t,n){return vi(this,e,"gutter"==t?"gutter":"class",function(e){var o="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass";if(e[o]){if(k(n).test(e[o]))return!1;e[o]+=" "+n}else e[o]=n;return!0})}),removeLineClass:er(function(e,t,n){return vi(this,e,"gutter"==t?"gutter":"class",function(e){var o="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass",r=e[o];if(!r)return!1;if(null==n)e[o]=null;else{var i=r.match(k(n));if(!i)return!1;var a=i.index+i[0].length;e[o]=r.slice(0,i.index)+(i.index&&a!=r.length?" ":"")+r.slice(a)||null}return!0})}),addLineWidget:er(function(e,t,n){return function(e,t,n,o){var r=new wi(e,n,o),i=e.cm;return i&&r.noHScroll&&(i.display.alignWidgets=!0),vi(e,t,"widget",function(t){var n=t.widgets||(t.widgets=[]);if(null==r.insertAt?n.push(r):n.splice(Math.min(n.length-1,Math.max(0,r.insertAt)),0,r),r.line=t,i&&!Ve(e,t)){var o=Ke(t)<e.scrollTop;de(t,t.height+Cn(r)),o&&Do(i,r.height),i.curOp.forceUpdate=!0}return!0}),i&&un(i,"lineWidgetAdded",i,r,"number"==typeof t?t:he(t)),r}(this,e,t,n)}),removeLineWidget:function(e){e.clear()},markText:function(e,t,n){return ki(this,Me(this,e),Me(this,t),n,n&&n.type||"range")},setBookmark:function(e,t){var n={replacedWith:t&&(null==t.nodeType?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return ki(this,e=Me(this,e),e,n,"bookmark")},findMarksAt:function(e){var t=[],n=le(this,(e=Me(this,e)).line).markedSpans;if(n)for(var o=0;o<n.length;++o){var r=n[o];(null==r.from||r.from<=e.ch)&&(null==r.to||r.to>=e.ch)&&t.push(r.marker.parent||r.marker)}return t},findMarks:function(e,t,n){e=Me(this,e),t=Me(this,t);var o=[],r=e.line;return this.iter(e.line,t.line+1,function(i){var a=i.markedSpans;if(a)for(var s=0;s<a.length;s++){var l=a[s];null!=l.to&&r==e.line&&e.ch>=l.to||null==l.from&&r!=e.line||null!=l.from&&r==t.line&&l.from>=t.ch||n&&!n(l.marker)||o.push(l.marker.parent||l.marker)}++r}),o},getAllMarks:function(){var e=[];return this.iter(function(t){var n=t.markedSpans;if(n)for(var o=0;o<n.length;++o)null!=n[o].from&&e.push(n[o].marker)}),e},posFromIndex:function(e){var t,n=this.first,o=this.lineSeparator().length;return this.iter(function(r){var i=r.text.length+o;if(i>e)return t=e,!0;e-=i,++n}),Me(this,ge(n,t))},indexFromPos:function(e){var t=(e=Me(this,e)).ch;if(e.line<this.first||e.ch<0)return 0;var n=this.lineSeparator().length;return this.iter(this.first,e.line,function(e){t+=e.text.length+n}),t},copy:function(e){var t=new Di(ce(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,n=this.first+this.size;null!=e.from&&e.from>t&&(t=e.from),null!=e.to&&e.to<n&&(n=e.to);var o=new Di(ce(this,t,n),e.mode||this.modeOption,t,this.lineSep,this.direction);return e.sharedHist&&(o.history=this.history),(this.linked||(this.linked=[])).push({doc:o,sharedHist:e.sharedHist}),o.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],function(e,t){for(var n=0;n<t.length;n++){var o=t[n],r=o.find(),i=e.clipPos(r.from),a=e.clipPos(r.to);if(ve(i,a)){var s=ki(e,i,a,o.primary,o.primary.type);o.markers.push(s),s.parent=o}}}(o,Ti(this)),o},unlinkDoc:function(e){if(e instanceof Ta&&(e=e.doc),this.linked)for(var t=0;t<this.linked.length;++t)if(this.linked[t].doc==e){this.linked.splice(t,1),e.unlinkDoc(this),Li(Ti(this));break}if(e.history==this.history){var n=[e.id];Ar(e,function(e){return n.push(e.id)},!0),e.history=new Pr(null),e.history.done=Ur(this.history.done,n),e.history.undone=Ur(this.history.undone,n)}},iterLinkedDocs:function(e){Ar(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):wt(e)},lineSeparator:function(){return this.lineSep||"\n"},setDirection:er(function(e){var t;"rtl"!=e&&(e="ltr"),e!=this.direction&&(this.direction=e,this.iter(function(e){return e.order=null}),this.cm&&Qo(t=this.cm,function(){Yr(t),tr(t)}))})}),Di.prototype.eachLine=Di.prototype.iter;var Oi=0;function Ei(e){var t=this;if(Ri(t),!rt(t,e)&&!Mn(t.display,e)){lt(e),a&&(Oi=+new Date);var n=co(t,e,!0),o=e.dataTransfer.files;if(n&&!t.isReadOnly())if(o&&o.length&&window.FileReader&&window.File)for(var r=o.length,i=Array(r),s=0,l=function(e,o){if(!t.options.allowDropFileTypes||-1!=j(t.options.allowDropFileTypes,e.type)){var a=new FileReader;a.onload=$o(t,function(){var e=a.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(e)&&(e=""),i[o]=e,++s==r){var l={from:n=Me(t.doc,n),to:n,text:t.doc.splitLines(i.join(t.doc.lineSeparator())),origin:"paste"};li(t.doc,l),Qr(t.doc,kr(n,Sr(l)))}}),a.readAsText(e)}},u=0;u<r;++u)l(o[u],u);else{if(t.state.draggingText&&t.doc.sel.contains(n)>-1)return t.state.draggingText(e),void setTimeout(function(){return t.display.input.focus()},20);try{var c=e.dataTransfer.getData("Text");if(c){var d;if(t.state.draggingText&&!t.state.draggingText.copy&&(d=t.listSelections()),Zr(t.doc,kr(n,n)),d)for(var h=0;h<d.length;++h)fi(t.doc,"",d[h].anchor,d[h].head,"drag");t.replaceSelection(c,"around","paste"),t.display.input.focus()}}catch(e){}}}}function Ri(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function Ai(e){if(document.getElementsByClassName)for(var t=document.getElementsByClassName("CodeMirror"),n=0;n<t.length;n++){var o=t[n].CodeMirror;o&&e(o)}}var Hi=!1;function Yi(){var e;Hi||(et(window,"resize",function(){null==e&&(e=setTimeout(function(){e=null,Ai(Pi)},100))}),et(window,"blur",function(){return Ai(Co)}),Hi=!0)}function Pi(e){var t=e.display;t.lastWrapHeight==t.wrapper.clientHeight&&t.lastWrapWidth==t.wrapper.clientWidth||(t.cachedCharWidth=t.cachedTextHeight=t.cachedPaddingH=null,t.scrollbarsClipped=!1,e.setSize())}for(var Ni={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",127:"Delete",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},Ii=0;Ii<10;Ii++)Ni[Ii+48]=Ni[Ii+96]=String(Ii);for(var Wi=65;Wi<=90;Wi++)Ni[Wi]=String.fromCharCode(Wi);for(var ji=1;ji<=12;ji++)Ni[ji+111]=Ni[ji+63235]="F"+ji;var Fi={};function zi(e){var t,n,o,r,i=e.split(/-(?!$)/);e=i[i.length-1];for(var a=0;a<i.length-1;a++){var s=i[a];if(/^(cmd|meta|m)$/i.test(s))r=!0;else if(/^a(lt)?$/i.test(s))t=!0;else if(/^(c|ctrl|control)$/i.test(s))n=!0;else{if(!/^s(hift)?$/i.test(s))throw new Error("Unrecognized modifier name: "+s);o=!0}}return t&&(e="Alt-"+e),n&&(e="Ctrl-"+e),r&&(e="Cmd-"+e),o&&(e="Shift-"+e),e}function Bi(e){var t={};for(var n in e)if(e.hasOwnProperty(n)){var o=e[n];if(/^(name|fallthrough|(de|at)tach)$/.test(n))continue;if("..."==o){delete e[n];continue}for(var r=q(n.split(" "),zi),i=0;i<r.length;i++){var a=void 0,s=void 0;i==r.length-1?(s=r.join(" "),a=o):(s=r.slice(0,i+1).join(" "),a="...");var l=t[s];if(l){if(l!=a)throw new Error("Inconsistent bindings for "+s)}else t[s]=a}delete e[n]}for(var u in t)e[u]=t[u];return e}function Vi(e,t,n,o){var r=(t=Xi(t)).call?t.call(e,o):t[e];if(!1===r)return"nothing";if("..."===r)return"multi";if(null!=r&&n(r))return"handled";if(t.fallthrough){if("[object Array]"!=Object.prototype.toString.call(t.fallthrough))return Vi(e,t.fallthrough,n,o);for(var i=0;i<t.fallthrough.length;i++){var a=Vi(e,t.fallthrough[i],n,o);if(a)return a}}}function Ui(e){var t="string"==typeof e?e:Ni[e.keyCode];return"Ctrl"==t||"Alt"==t||"Shift"==t||"Mod"==t}function Ki(e,t,n){var o=e;return t.altKey&&"Alt"!=o&&(e="Alt-"+e),(C?t.metaKey:t.ctrlKey)&&"Ctrl"!=o&&(e="Ctrl-"+e),(C?t.ctrlKey:t.metaKey)&&"Cmd"!=o&&(e="Cmd-"+e),!n&&t.shiftKey&&"Shift"!=o&&(e="Shift-"+e),e}function Gi(e,t){if(d&&34==e.keyCode&&e.char)return!1;var n=Ni[e.keyCode];return null!=n&&!e.altGraphKey&&(3==e.keyCode&&e.code&&(n=e.code),Ki(n,e,t))}function Xi(e){return"string"==typeof e?Fi[e]:e}function Ji(e,t){for(var n=e.doc.sel.ranges,o=[],r=0;r<n.length;r++){for(var i=t(n[r]);o.length&&ve(i.from,J(o).to)<=0;){var a=o.pop();if(ve(a.from,i.from)<0){i.from=a.from;break}}o.push(i)}Qo(e,function(){for(var t=o.length-1;t>=0;t--)fi(e.doc,"",o[t].from,o[t].to,"+delete");Oo(e)})}function qi(e,t,n){var o=ie(e.text,t+n,n);return o<0||o>e.text.length?null:o}function Qi(e,t,n){var o=qi(e,t.ch,n);return null==o?null:new ge(t.line,o,n<0?"after":"before")}function $i(e,t,n,o,r){if(e){var i=$e(n,t.doc.direction);if(i){var a,s=r<0?J(i):i[0],l=r<0==(1==s.level)?"after":"before";if(s.level>0||"rtl"==t.doc.direction){var u=An(t,n);a=r<0?n.text.length-1:0;var c=Hn(t,u,a).top;a=ae(function(e){return Hn(t,u,e).top==c},r<0==(1==s.level)?s.from:s.to-1,a),"before"==l&&(a=qi(n,a,1))}else a=r<0?s.to:s.from;return new ge(o,a,l)}}return new ge(o,r<0?n.text.length:0,r<0?"before":"after")}Fi.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Fi.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Fi.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Fi.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Fi.default=y?Fi.macDefault:Fi.pcDefault;var Zi={selectAll:ai,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),B)},killLine:function(e){return Ji(e,function(t){if(t.empty()){var n=le(e.doc,t.head.line).text.length;return t.head.ch==n&&t.head.line<e.lastLine()?{from:t.head,to:ge(t.head.line+1,0)}:{from:t.head,to:ge(t.head.line,n)}}return{from:t.from(),to:t.to()}})},deleteLine:function(e){return Ji(e,function(t){return{from:ge(t.from().line,0),to:Me(e.doc,ge(t.to().line+1,0))}})},delLineLeft:function(e){return Ji(e,function(e){return{from:ge(e.from().line,0),to:e.from()}})},delWrappedLineLeft:function(e){return Ji(e,function(t){var n=e.charCoords(t.head,"div").top+5;return{from:e.coordsChar({left:0,top:n},"div"),to:t.from()}})},delWrappedLineRight:function(e){return Ji(e,function(t){var n=e.charCoords(t.head,"div").top+5,o=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div");return{from:t.from(),to:o}})},undo:function(e){return e.undo()},redo:function(e){return e.redo()},undoSelection:function(e){return e.undoSelection()},redoSelection:function(e){return e.redoSelection()},goDocStart:function(e){return e.extendSelection(ge(e.firstLine(),0))},goDocEnd:function(e){return e.extendSelection(ge(e.lastLine()))},goLineStart:function(e){return e.extendSelectionsBy(function(t){return ea(e,t.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(e){return e.extendSelectionsBy(function(t){return ta(e,t.head)},{origin:"+move",bias:1})},goLineEnd:function(e){return e.extendSelectionsBy(function(t){return function(e,t){var n=le(e.doc,t),o=function(e){for(var t;t=We(e);)e=t.find(1,!0).line;return e}(n);return o!=n&&(t=he(o)),$i(!0,e,n,t,-1)}(e,t.head.line)},{origin:"+move",bias:-1})},goLineRight:function(e){return e.extendSelectionsBy(function(t){var n=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div")},U)},goLineLeft:function(e){return e.extendSelectionsBy(function(t){var n=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:0,top:n},"div")},U)},goLineLeftSmart:function(e){return e.extendSelectionsBy(function(t){var n=e.cursorCoords(t.head,"div").top+5,o=e.coordsChar({left:0,top:n},"div");return o.ch<e.getLine(o.line).search(/\S/)?ta(e,t.head):o},U)},goLineUp:function(e){return e.moveV(-1,"line")},goLineDown:function(e){return e.moveV(1,"line")},goPageUp:function(e){return e.moveV(-1,"page")},goPageDown:function(e){return e.moveV(1,"page")},goCharLeft:function(e){return e.moveH(-1,"char")},goCharRight:function(e){return e.moveH(1,"char")},goColumnLeft:function(e){return e.moveH(-1,"column")},goColumnRight:function(e){return e.moveH(1,"column")},goWordLeft:function(e){return e.moveH(-1,"word")},goGroupRight:function(e){return e.moveH(1,"group")},goGroupLeft:function(e){return e.moveH(-1,"group")},goWordRight:function(e){return e.moveH(1,"word")},delCharBefore:function(e){return e.deleteH(-1,"char")},delCharAfter:function(e){return e.deleteH(1,"char")},delWordBefore:function(e){return e.deleteH(-1,"word")},delWordAfter:function(e){return e.deleteH(1,"word")},delGroupBefore:function(e){return e.deleteH(-1,"group")},delGroupAfter:function(e){return e.deleteH(1,"group")},indentAuto:function(e){return e.indentSelection("smart")},indentMore:function(e){return e.indentSelection("add")},indentLess:function(e){return e.indentSelection("subtract")},insertTab:function(e){return e.replaceSelection("\t")},insertSoftTab:function(e){for(var t=[],n=e.listSelections(),o=e.options.tabSize,r=0;r<n.length;r++){var i=n[r].from(),a=I(e.getLine(i.line),i.ch,o);t.push(X(o-a%o))}e.replaceSelections(t)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){return Qo(e,function(){for(var t=e.listSelections(),n=[],o=0;o<t.length;o++)if(t[o].empty()){var r=t[o].head,i=le(e.doc,r.line).text;if(i)if(r.ch==i.length&&(r=new ge(r.line,r.ch-1)),r.ch>0)r=new ge(r.line,r.ch+1),e.replaceRange(i.charAt(r.ch-1)+i.charAt(r.ch-2),ge(r.line,r.ch-2),r,"+transpose");else if(r.line>e.doc.first){var a=le(e.doc,r.line-1).text;a&&(r=new ge(r.line,1),e.replaceRange(i.charAt(0)+e.doc.lineSeparator()+a.charAt(a.length-1),ge(r.line-1,a.length-1),r,"+transpose"))}n.push(new Cr(r,r))}e.setSelections(n)})},newlineAndIndent:function(e){return Qo(e,function(){for(var t=e.listSelections(),n=t.length-1;n>=0;n--)e.replaceRange(e.doc.lineSeparator(),t[n].anchor,t[n].head,"+input");t=e.listSelections();for(var o=0;o<t.length;o++)e.indentLine(t[o].from().line,null,!0);Oo(e)})},openLine:function(e){return e.replaceSelection("\n","start")},toggleOverwrite:function(e){return e.toggleOverwrite()}};function ea(e,t){var n=le(e.doc,t),o=Fe(n);return o!=n&&(t=he(o)),$i(!0,e,o,t,1)}function ta(e,t){var n=ea(e,t.line),o=le(e.doc,n.line),r=$e(o,e.doc.direction);if(!r||0==r[0].level){var i=Math.max(0,o.text.search(/\S/)),a=t.line==n.line&&t.ch<=i&&t.ch;return ge(n.line,a?0:i,n.sticky)}return n}function na(e,t,n){if("string"==typeof t&&!(t=Zi[t]))return!1;e.display.input.ensurePolled();var o=e.display.shift,r=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),n&&(e.display.shift=!1),r=t(e)!=z}finally{e.display.shift=o,e.state.suppressEdits=!1}return r}var oa=new W;function ra(e,t,n,o){var r=e.state.keySeq;if(r){if(Ui(t))return"handled";if(/\'$/.test(t)?e.state.keySeq=null:oa.set(50,function(){e.state.keySeq==r&&(e.state.keySeq=null,e.display.input.reset())}),ia(e,r+" "+t,n,o))return!0}return ia(e,t,n,o)}function ia(e,t,n,o){var r=function(e,t,n){for(var o=0;o<e.state.keyMaps.length;o++){var r=Vi(t,e.state.keyMaps[o],n,e);if(r)return r}return e.options.extraKeys&&Vi(t,e.options.extraKeys,n,e)||Vi(t,e.options.keyMap,n,e)}(e,t,o);return"multi"==r&&(e.state.keySeq=t),"handled"==r&&un(e,"keyHandled",e,t,n),"handled"!=r&&"multi"!=r||(lt(n),yo(e)),!!r}function aa(e,t){var n=Gi(t,!0);return!!n&&(t.shiftKey&&!e.state.keySeq?ra(e,"Shift-"+n,t,function(t){return na(e,t,!0)})||ra(e,n,t,function(t){if("string"==typeof t?/^go[A-Z]/.test(t):t.motion)return na(e,t)}):ra(e,n,t,function(t){return na(e,t)}))}var sa=null;function la(e){var t=this;if(t.curOp.focus=R(),!rt(t,e)){a&&s<11&&27==e.keyCode&&(e.returnValue=!1);var n=e.keyCode;t.display.shift=16==n||e.shiftKey;var o=aa(t,e);d&&(sa=o?n:null,!o&&88==n&&!Ct&&(y?e.metaKey:e.ctrlKey)&&t.replaceSelection("",null,"cut")),18!=n||/\bCodeMirror-crosshair\b/.test(t.display.lineDiv.className)||function(e){var t=e.display.lineDiv;function n(e){18!=e.keyCode&&e.altKey||(T(t,"CodeMirror-crosshair"),nt(document,"keyup",n),nt(document,"mouseover",n))}A(t,"CodeMirror-crosshair"),et(document,"keyup",n),et(document,"mouseover",n)}(t)}}function ua(e){16==e.keyCode&&(this.doc.sel.shift=!1),rt(this,e)}function ca(e){var t=this;if(!(Mn(t.display,e)||rt(t,e)||e.ctrlKey&&!e.altKey||y&&e.metaKey)){var n=e.keyCode,o=e.charCode;if(d&&n==sa)return sa=null,void lt(e);if(!d||e.which&&!(e.which<10)||!aa(t,e)){var r=String.fromCharCode(null==o?n:o);"\b"!=r&&(function(e,t,n){return ra(e,"'"+n+"'",t,function(t){return na(e,t,!0)})}(t,e,r)||t.display.input.onKeyPress(e))}}}var da,ha,fa=function(e,t,n){this.time=e,this.pos=t,this.button=n};function pa(e){var t=this,n=t.display;if(!(rt(t,e)||n.activeTouch&&n.input.supportsTouch()))if(n.input.ensurePolled(),n.shift=e.shiftKey,Mn(n,e))l||(n.scroller.draggable=!1,setTimeout(function(){return n.scroller.draggable=!0},100));else if(!va(t,e)){var o=co(t,e),r=ft(e),i=o?function(e,t){var n=+new Date;return ha&&ha.compare(n,e,t)?(da=ha=null,"triple"):da&&da.compare(n,e,t)?(ha=new fa(n,e,t),da=null,"double"):(da=new fa(n,e,t),ha=null,"single")}(o,r):"single";window.focus(),1==r&&t.state.selectingText&&t.state.selectingText(e),o&&function(e,t,n,o,r){var i="Click";return"double"==o?i="Double"+i:"triple"==o&&(i="Triple"+i),ra(e,Ki(i=(1==t?"Left":2==t?"Middle":"Right")+i,r),r,function(t){if("string"==typeof t&&(t=Zi[t]),!t)return!1;var o=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),o=t(e,n)!=z}finally{e.state.suppressEdits=!1}return o})}(t,r,o,i,e)||(1==r?o?function(e,t,n,o){a?setTimeout(P(_o,e),0):e.curOp.focus=R();var r,i=function(e,t,n){var o=e.getOption("configureMouse"),r=o?o(e,t,n):{};if(null==r.unit){var i=_?n.shiftKey&&n.metaKey:n.altKey;r.unit=i?"rectangle":"single"==t?"char":"double"==t?"word":"line"}return(null==r.extend||e.doc.extend)&&(r.extend=e.doc.extend||n.shiftKey),null==r.addNew&&(r.addNew=y?n.metaKey:n.ctrlKey),null==r.moveOnDrag&&(r.moveOnDrag=!(y?n.altKey:n.ctrlKey)),r}(e,n,o),u=e.doc.sel;e.options.dragDrop&&gt&&!e.isReadOnly()&&"single"==n&&(r=u.contains(t))>-1&&(ve((r=u.ranges[r]).from(),t)<0||t.xRel>0)&&(ve(r.to(),t)>0||t.xRel<0)?function(e,t,n,o){var r=e.display,i=!1,u=$o(e,function(t){l&&(r.scroller.draggable=!1),e.state.draggingText=!1,nt(r.wrapper.ownerDocument,"mouseup",u),nt(r.wrapper.ownerDocument,"mousemove",c),nt(r.scroller,"dragstart",d),nt(r.scroller,"drop",u),i||(lt(t),o.addNew||Gr(e.doc,n,null,null,o.extend),l||a&&9==s?setTimeout(function(){r.wrapper.ownerDocument.body.focus(),r.input.focus()},20):r.input.focus())}),c=function(e){i=i||Math.abs(t.clientX-e.clientX)+Math.abs(t.clientY-e.clientY)>=10},d=function(){return i=!0};l&&(r.scroller.draggable=!0),e.state.draggingText=u,u.copy=!o.moveOnDrag,r.scroller.dragDrop&&r.scroller.dragDrop(),et(r.wrapper.ownerDocument,"mouseup",u),et(r.wrapper.ownerDocument,"mousemove",c),et(r.scroller,"dragstart",d),et(r.scroller,"drop",u),wo(e),setTimeout(function(){return r.input.focus()},20)}(e,o,t,i):function(e,t,n,o){var r=e.display,i=e.doc;lt(t);var a,s,l=i.sel,u=l.ranges;if(o.addNew&&!o.extend?(s=i.sel.contains(n),a=s>-1?u[s]:new Cr(n,n)):(a=i.sel.primary(),s=i.sel.primIndex),"rectangle"==o.unit)o.addNew||(a=new Cr(n,n)),n=co(e,t,!0,!0),s=-1;else{var c=ma(e,n,o.unit);a=o.extend?Kr(a,c.anchor,c.head,o.extend):c}o.addNew?-1==s?(s=u.length,$r(i,Mr(u.concat([a]),s),{scroll:!1,origin:"*mouse"})):u.length>1&&u[s].empty()&&"char"==o.unit&&!o.extend?($r(i,Mr(u.slice(0,s).concat(u.slice(s+1)),0),{scroll:!1,origin:"*mouse"}),l=i.sel):Jr(i,s,a,V):(s=0,$r(i,new br([a],0),V),l=i.sel);var d=n;function h(t){if(0!=ve(d,t))if(d=t,"rectangle"==o.unit){for(var r=[],u=e.options.tabSize,c=I(le(i,n.line).text,n.ch,u),h=I(le(i,t.line).text,t.ch,u),f=Math.min(c,h),p=Math.max(c,h),m=Math.min(n.line,t.line),g=Math.min(e.lastLine(),Math.max(n.line,t.line));m<=g;m++){var v=le(i,m).text,y=K(v,f,u);f==p?r.push(new Cr(ge(m,y),ge(m,y))):v.length>y&&r.push(new Cr(ge(m,y),ge(m,K(v,p,u))))}r.length||r.push(new Cr(n,n)),$r(i,Mr(l.ranges.slice(0,s).concat(r),s),{origin:"*mouse",scroll:!1}),e.scrollIntoView(t)}else{var _,w=a,b=ma(e,t,o.unit),C=w.anchor;ve(b.anchor,C)>0?(_=b.head,C=be(w.from(),b.anchor)):(_=b.anchor,C=we(w.to(),b.head));var M=l.ranges.slice(0);M[s]=function(e,t){var n=t.anchor,o=t.head,r=le(e.doc,n.line);if(0==ve(n,o)&&n.sticky==o.sticky)return t;var i=$e(r);if(!i)return t;var a=qe(i,n.ch,n.sticky),s=i[a];if(s.from!=n.ch&&s.to!=n.ch)return t;var l,u=a+(s.from==n.ch==(1!=s.level)?0:1);if(0==u||u==i.length)return t;if(o.line!=n.line)l=(o.line-n.line)*("ltr"==e.doc.direction?1:-1)>0;else{var c=qe(i,o.ch,o.sticky),d=c-a||(o.ch-n.ch)*(1==s.level?-1:1);l=c==u-1||c==u?d<0:d>0}var h=i[u+(l?-1:0)],f=l==(1==h.level),p=f?h.from:h.to,m=f?"after":"before";return n.ch==p&&n.sticky==m?t:new Cr(new ge(n.line,p,m),o)}(e,new Cr(Me(i,C),_)),$r(i,Mr(M,s),V)}}var f=r.wrapper.getBoundingClientRect(),p=0;function m(t){e.state.selectingText=!1,p=1/0,lt(t),r.input.focus(),nt(r.wrapper.ownerDocument,"mousemove",g),nt(r.wrapper.ownerDocument,"mouseup",v),i.history.lastSelOrigin=null}var g=$o(e,function(t){ft(t)?function t(n){var a=++p,s=co(e,n,!0,"rectangle"==o.unit);if(s)if(0!=ve(s,d)){e.curOp.focus=R(),h(s);var l=So(r,i);(s.line>=l.to||s.line<l.from)&&setTimeout($o(e,function(){p==a&&t(n)}),150)}else{var u=n.clientY<f.top?-20:n.clientY>f.bottom?20:0;u&&setTimeout($o(e,function(){p==a&&(r.scroller.scrollTop+=u,t(n))}),50)}}(t):m(t)}),v=$o(e,m);e.state.selectingText=v,et(r.wrapper.ownerDocument,"mousemove",g),et(r.wrapper.ownerDocument,"mouseup",v)}(e,o,t,i)}(t,o,i,e):ht(e)==n.scroller&&lt(e):2==r?(o&&Gr(t.doc,o),setTimeout(function(){return n.input.focus()},20)):3==r&&(M?ya(t,e):wo(t)))}}function ma(e,t,n){if("char"==n)return new Cr(t,t);if("word"==n)return e.findWordAt(t);if("line"==n)return new Cr(ge(t.line,0),Me(e.doc,ge(t.line+1,0)));var o=n(e,t);return new Cr(o.from,o.to)}function ga(e,t,n,o){var r,i;if(t.touches)r=t.touches[0].clientX,i=t.touches[0].clientY;else try{r=t.clientX,i=t.clientY}catch(t){return!1}if(r>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;o&&lt(t);var a=e.display,s=a.lineDiv.getBoundingClientRect();if(i>s.bottom||!at(e,n))return ct(t);i-=s.top-a.viewOffset;for(var l=0;l<e.options.gutters.length;++l){var u=a.gutters.childNodes[l];if(u&&u.getBoundingClientRect().right>=r)return ot(e,n,e,fe(e.doc,i),e.options.gutters[l],t),ct(t)}}function va(e,t){return ga(e,t,"gutterClick",!0)}function ya(e,t){Mn(e.display,t)||function(e,t){return!!at(e,"gutterContextMenu")&&ga(e,t,"gutterContextMenu",!1)}(e,t)||rt(e,t,"contextmenu")||e.display.input.onContextMenu(t)}function _a(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),Fn(e)}fa.prototype.compare=function(e,t,n){return this.time+400>e&&0==ve(t,this.pos)&&n==this.button};var wa={toString:function(){return"CodeMirror.Init"}},ba={},Ca={};function Ma(e){pr(e),tr(e),To(e)}function ka(e,t,n){if(!t!=!(n&&n!=wa)){var o=e.display.dragFunctions,r=t?et:nt;r(e.display.scroller,"dragstart",o.start),r(e.display.scroller,"dragenter",o.enter),r(e.display.scroller,"dragover",o.over),r(e.display.scroller,"dragleave",o.leave),r(e.display.scroller,"drop",o.drop)}}function Sa(e){e.options.lineWrapping?(A(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(T(e.display.wrapper,"CodeMirror-wrap"),Xe(e)),uo(e),tr(e),Fn(e),setTimeout(function(){return jo(e)},100)}function Ta(e,t){var n=this;if(!(this instanceof Ta))return new Ta(e,t);this.options=t=t?N(t):{},N(ba,t,!1),mr(t);var o=t.value;"string"==typeof o&&(o=new Di(o,t.mode,null,t.lineSeparator,t.direction)),this.doc=o;var r=new Ta.inputStyles[t.inputStyle](this),i=this.display=new se(e,o,r);for(var u in i.wrapper.CodeMirror=this,pr(this),_a(this),t.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),Bo(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:!1,cutIncoming:!1,selectingText:!1,draggingText:!1,highlight:new W,keySeq:null,specialChars:null},t.autofocus&&!v&&i.input.focus(),a&&s<11&&setTimeout(function(){return n.display.input.reset(!0)},20),function(e){var t=e.display;et(t.scroller,"mousedown",$o(e,pa)),et(t.scroller,"dblclick",a&&s<11?$o(e,function(t){if(!rt(e,t)){var n=co(e,t);if(n&&!va(e,t)&&!Mn(e.display,t)){lt(t);var o=e.findWordAt(n);Gr(e.doc,o.anchor,o.head)}}}):function(t){return rt(e,t)||lt(t)}),M||et(t.scroller,"contextmenu",function(t){return ya(e,t)});var n,o={end:0};function r(){t.activeTouch&&(n=setTimeout(function(){return t.activeTouch=null},1e3),(o=t.activeTouch).end=+new Date)}function i(e,t){if(null==t.left)return!0;var n=t.left-e.left,o=t.top-e.top;return n*n+o*o>400}et(t.scroller,"touchstart",function(r){if(!rt(e,r)&&!function(e){if(1!=e.touches.length)return!1;var t=e.touches[0];return t.radiusX<=1&&t.radiusY<=1}(r)&&!va(e,r)){t.input.ensurePolled(),clearTimeout(n);var i=+new Date;t.activeTouch={start:i,moved:!1,prev:i-o.end<=300?o:null},1==r.touches.length&&(t.activeTouch.left=r.touches[0].pageX,t.activeTouch.top=r.touches[0].pageY)}}),et(t.scroller,"touchmove",function(){t.activeTouch&&(t.activeTouch.moved=!0)}),et(t.scroller,"touchend",function(n){var o=t.activeTouch;if(o&&!Mn(t,n)&&null!=o.left&&!o.moved&&new Date-o.start<300){var a,s=e.coordsChar(t.activeTouch,"page");a=!o.prev||i(o,o.prev)?new Cr(s,s):!o.prev.prev||i(o,o.prev.prev)?e.findWordAt(s):new Cr(ge(s.line,0),Me(e.doc,ge(s.line+1,0))),e.setSelection(a.anchor,a.head),e.focus(),lt(n)}r()}),et(t.scroller,"touchcancel",r),et(t.scroller,"scroll",function(){t.scroller.clientHeight&&(Ho(e,t.scroller.scrollTop),Po(e,t.scroller.scrollLeft,!0),ot(e,"scroll",e))}),et(t.scroller,"mousewheel",function(t){return wr(e,t)}),et(t.scroller,"DOMMouseScroll",function(t){return wr(e,t)}),et(t.wrapper,"scroll",function(){return t.wrapper.scrollTop=t.wrapper.scrollLeft=0}),t.dragFunctions={enter:function(t){rt(e,t)||dt(t)},over:function(t){rt(e,t)||(function(e,t){var n=co(e,t);if(n){var o=document.createDocumentFragment();mo(e,n,o),e.display.dragCursor||(e.display.dragCursor=D("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),x(e.display.dragCursor,o)}}(e,t),dt(t))},start:function(t){return function(e,t){if(a&&(!e.state.draggingText||+new Date-Oi<100))dt(t);else if(!rt(e,t)&&!Mn(e.display,t)&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!h)){var n=D("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",d&&(n.width=n.height=1,e.display.wrapper.appendChild(n),n._top=n.offsetTop),t.dataTransfer.setDragImage(n,0,0),d&&n.parentNode.removeChild(n)}}(e,t)},drop:$o(e,Ei),leave:function(t){rt(e,t)||Ri(e)}};var l=t.input.getField();et(l,"keyup",function(t){return ua.call(e,t)}),et(l,"keydown",$o(e,la)),et(l,"keypress",$o(e,ca)),et(l,"focus",function(t){return bo(e,t)}),et(l,"blur",function(t){return Co(e,t)})}(this),Yi(),Uo(this),this.curOp.forceUpdate=!0,Hr(this,o),t.autofocus&&!v||this.hasFocus()?setTimeout(P(bo,this),20):Co(this),Ca)Ca.hasOwnProperty(u)&&Ca[u](n,t[u],wa);Lo(this),t.finishInit&&t.finishInit(this);for(var c=0;c<La.length;++c)La[c](n);Ko(this),l&&t.lineWrapping&&"optimizelegibility"==getComputedStyle(i.lineDiv).textRendering&&(i.lineDiv.style.textRendering="auto")}Ta.defaults=ba,Ta.optionHandlers=Ca;var La=[];function xa(e,t,n,o){var r,i=e.doc;null==n&&(n="add"),"smart"==n&&(i.mode.indent?r=Wt(e,t).state:n="prev");var a=e.options.tabSize,s=le(i,t),l=I(s.text,null,a);s.stateAfter&&(s.stateAfter=null);var u,c=s.text.match(/^\s*/)[0];if(o||/\S/.test(s.text)){if("smart"==n&&((u=i.mode.indent(r,s.text.slice(c.length),s.text))==z||u>150)){if(!o)return;n="prev"}}else u=0,n="not";"prev"==n?u=t>i.first?I(le(i,t-1).text,null,a):0:"add"==n?u=l+e.options.indentUnit:"subtract"==n?u=l-e.options.indentUnit:"number"==typeof n&&(u=l+n),u=Math.max(0,u);var d="",h=0;if(e.options.indentWithTabs)for(var f=Math.floor(u/a);f;--f)h+=a,d+="\t";if(h<u&&(d+=X(u-h)),d!=c)return fi(i,d,ge(t,0),ge(t,c.length),"+input"),s.stateAfter=null,!0;for(var p=0;p<i.sel.ranges.length;p++){var m=i.sel.ranges[p];if(m.head.line==t&&m.head.ch<c.length){var g=ge(t,c.length);Jr(i,p,new Cr(g,g));break}}}Ta.defineInitHook=function(e){return La.push(e)};var Da=null;function Oa(e){Da=e}function Ea(e,t,n,o,r){var i=e.doc;e.display.shift=!1,o||(o=i.sel);var a,s=e.state.pasteIncoming||"paste"==r,l=wt(t),u=null;if(s&&o.ranges.length>1)if(Da&&Da.text.join("\n")==t){if(o.ranges.length%Da.text.length==0){u=[];for(var c=0;c<Da.text.length;c++)u.push(i.splitLines(Da.text[c]))}}else l.length==o.ranges.length&&e.options.pasteLinesPerSelection&&(u=q(l,function(e){return[e]}));for(var d=o.ranges.length-1;d>=0;d--){var h=o.ranges[d],f=h.from(),p=h.to();h.empty()&&(n&&n>0?f=ge(f.line,f.ch-n):e.state.overwrite&&!s?p=ge(p.line,Math.min(le(i,p.line).text.length,p.ch+J(l).length)):Da&&Da.lineWise&&Da.text.join("\n")==t&&(f=p=ge(f.line,0))),a=e.curOp.updateInput;var m={from:f,to:p,text:u?u[d%u.length]:l,origin:r||(s?"paste":e.state.cutIncoming?"cut":"+input")};li(e.doc,m),un(e,"inputRead",e,m)}t&&!s&&Aa(e,t),Oo(e),e.curOp.updateInput=a,e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=!1}function Ra(e,t){var n=e.clipboardData&&e.clipboardData.getData("Text");if(n)return e.preventDefault(),t.isReadOnly()||t.options.disableInput||Qo(t,function(){return Ea(t,n,0,null,"paste")}),!0}function Aa(e,t){if(e.options.electricChars&&e.options.smartIndent)for(var n=e.doc.sel,o=n.ranges.length-1;o>=0;o--){var r=n.ranges[o];if(!(r.head.ch>100||o&&n.ranges[o-1].head.line==r.head.line)){var i=e.getModeAt(r.head),a=!1;if(i.electricChars){for(var s=0;s<i.electricChars.length;s++)if(t.indexOf(i.electricChars.charAt(s))>-1){a=xa(e,r.head.line,"smart");break}}else i.electricInput&&i.electricInput.test(le(e.doc,r.head.line).text.slice(0,r.head.ch))&&(a=xa(e,r.head.line,"smart"));a&&un(e,"electricInput",e,r.head.line)}}}function Ha(e){for(var t=[],n=[],o=0;o<e.doc.sel.ranges.length;o++){var r=e.doc.sel.ranges[o].head.line,i={anchor:ge(r,0),head:ge(r+1,0)};n.push(i),t.push(e.getRange(i.anchor,i.head))}return{text:t,ranges:n}}function Ya(e,t){e.setAttribute("autocorrect","off"),e.setAttribute("autocapitalize","off"),e.setAttribute("spellcheck",!!t)}function Pa(){var e=D("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),t=D("div",[e],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return l?e.style.width="1000px":e.setAttribute("wrap","off"),m&&(e.style.border="1px solid black"),Ya(e),t}function Na(e,t,n,o,r){var i=t,a=n,s=le(e,t.line);function l(o){var i,a;if(null==(i=r?function(e,t,n,o){var r=$e(t,e.doc.direction);if(!r)return Qi(t,n,o);n.ch>=t.text.length?(n.ch=t.text.length,n.sticky="before"):n.ch<=0&&(n.ch=0,n.sticky="after");var i=qe(r,n.ch,n.sticky),a=r[i];if("ltr"==e.doc.direction&&a.level%2==0&&(o>0?a.to>n.ch:a.from<n.ch))return Qi(t,n,o);var s,l=function(e,n){return qi(t,e instanceof ge?e.ch:e,n)},u=function(n){return e.options.lineWrapping?(s=s||An(e,t),Zn(e,t,s,n)):{begin:0,end:t.text.length}},c=u("before"==n.sticky?l(n,-1):n.ch);if("rtl"==e.doc.direction||1==a.level){var d=1==a.level==o<0,h=l(n,d?1:-1);if(null!=h&&(d?h<=a.to&&h<=c.end:h>=a.from&&h>=c.begin)){var f=d?"before":"after";return new ge(n.line,h,f)}}var p=function(e,t,o){for(var i=function(e,t){return t?new ge(n.line,l(e,1),"before"):new ge(n.line,e,"after")};e>=0&&e<r.length;e+=t){var a=r[e],s=t>0==(1!=a.level),u=s?o.begin:l(o.end,-1);if(a.from<=u&&u<a.to)return i(u,s);if(u=s?a.from:l(a.to,-1),o.begin<=u&&u<o.end)return i(u,s)}},m=p(i+o,o,c);if(m)return m;var g=o>0?c.end:l(c.begin,-1);return null==g||o>0&&g==t.text.length||!(m=p(o>0?0:r.length-1,o,u(g)))?null:m}(e.cm,s,t,n):Qi(s,t,n))){if(o||(a=t.line+n)<e.first||a>=e.first+e.size||(t=new ge(a,t.ch,t.sticky),!(s=le(e,a))))return!1;t=$i(r,e.cm,s,t.line,n)}else t=i;return!0}if("char"==o)l();else if("column"==o)l(!0);else if("word"==o||"group"==o)for(var u=null,c="group"==o,d=e.cm&&e.cm.getHelper(t,"wordChars"),h=!0;!(n<0)||l(!h);h=!1){var f=s.text.charAt(t.ch)||"\n",p=te(f,d)?"w":c&&"\n"==f?"n":!c||/\s/.test(f)?null:"p";if(!c||h||p||(p="s"),u&&u!=p){n<0&&(n=1,l(),t.sticky="after");break}if(p&&(u=p),n>0&&!l(!h))break}var m=ri(e,t,i,a,!0);return ye(i,m)&&(m.hitSide=!0),m}function Ia(e,t,n,o){var r,i,a=e.doc,s=t.left;if("page"==o){var l=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),u=Math.max(l-.5*ro(e.display),3);r=(n>0?t.bottom:t.top)+n*u}else"line"==o&&(r=n>0?t.bottom+3:t.top-3);for(;(i=Qn(e,s,r)).outside;){if(n<0?r<=0:r>=a.height){i.hitSide=!0;break}r+=5*n}return i}var Wa=function(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new W,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function ja(e,t){var n=Rn(e,t.line);if(!n||n.hidden)return null;var o=le(e.doc,t.line),r=On(n,o,t.line),i=$e(o,e.doc.direction),a="left";i&&(a=qe(i,t.ch)%2?"right":"left");var s=Nn(r.map,t.ch,a);return s.offset="right"==s.collapse?s.end:s.start,s}function Fa(e,t){return t&&(e.bad=!0),e}function za(e,t,n){var o;if(t==e.display.lineDiv){if(!(o=e.display.lineDiv.childNodes[n]))return Fa(e.clipPos(ge(e.display.viewTo-1)),!0);t=null,n=0}else for(o=t;;o=o.parentNode){if(!o||o==e.display.lineDiv)return null;if(o.parentNode&&o.parentNode==e.display.lineDiv)break}for(var r=0;r<e.display.view.length;r++){var i=e.display.view[r];if(i.node==o)return Ba(i,t,n)}}function Ba(e,t,n){var o=e.text.firstChild,r=!1;if(!t||!E(o,t))return Fa(ge(he(e.line),0),!0);if(t==o&&(r=!0,t=o.childNodes[n],n=0,!t)){var i=e.rest?J(e.rest):e.line;return Fa(ge(he(i),i.text.length),r)}var a=3==t.nodeType?t:null,s=t;for(a||1!=t.childNodes.length||3!=t.firstChild.nodeType||(a=t.firstChild,n&&(n=a.nodeValue.length));s.parentNode!=o;)s=s.parentNode;var l=e.measure,u=l.maps;function c(t,n,o){for(var r=-1;r<(u?u.length:0);r++)for(var i=r<0?l.map:u[r],a=0;a<i.length;a+=3){var s=i[a+2];if(s==t||s==n){var c=he(r<0?e.line:e.rest[r]),d=i[a]+o;return(o<0||s!=t)&&(d=i[a+(o?1:0)]),ge(c,d)}}}var d=c(a,s,n);if(d)return Fa(d,r);for(var h=s.nextSibling,f=a?a.nodeValue.length-n:0;h;h=h.nextSibling){if(d=c(h,h.firstChild,0))return Fa(ge(d.line,d.ch-f),r);f+=h.textContent.length}for(var p=s.previousSibling,m=n;p;p=p.previousSibling){if(d=c(p,p.firstChild,-1))return Fa(ge(d.line,d.ch+m),r);m+=p.textContent.length}}Wa.prototype.init=function(e){var t=this,n=this,o=n.cm,r=n.div=e.lineDiv;function i(e){if(!rt(o,e)){if(o.somethingSelected())Oa({lineWise:!1,text:o.getSelections()}),"cut"==e.type&&o.replaceSelection("",null,"cut");else{if(!o.options.lineWiseCopyCut)return;var t=Ha(o);Oa({lineWise:!0,text:t.text}),"cut"==e.type&&o.operation(function(){o.setSelections(t.ranges,0,B),o.replaceSelection("",null,"cut")})}if(e.clipboardData){e.clipboardData.clearData();var i=Da.text.join("\n");if(e.clipboardData.setData("Text",i),e.clipboardData.getData("Text")==i)return void e.preventDefault()}var a=Pa(),s=a.firstChild;o.display.lineSpace.insertBefore(a,o.display.lineSpace.firstChild),s.value=Da.text.join("\n");var l=document.activeElement;Y(s),setTimeout(function(){o.display.lineSpace.removeChild(a),l.focus(),l==r&&n.showPrimarySelection()},50)}}Ya(r,o.options.spellcheck),et(r,"paste",function(e){rt(o,e)||Ra(e,o)||s<=11&&setTimeout($o(o,function(){return t.updateFromDOM()}),20)}),et(r,"compositionstart",function(e){t.composing={data:e.data,done:!1}}),et(r,"compositionupdate",function(e){t.composing||(t.composing={data:e.data,done:!1})}),et(r,"compositionend",function(e){t.composing&&(e.data!=t.composing.data&&t.readFromDOMSoon(),t.composing.done=!0)}),et(r,"touchstart",function(){return n.forceCompositionEnd()}),et(r,"input",function(){t.composing||t.readFromDOMSoon()}),et(r,"copy",i),et(r,"cut",i)},Wa.prototype.prepareSelection=function(){var e=po(this.cm,!1);return e.focus=this.cm.state.focused,e},Wa.prototype.showSelection=function(e,t){e&&this.cm.display.view.length&&((e.focus||t)&&this.showPrimarySelection(),this.showMultipleSelections(e))},Wa.prototype.showPrimarySelection=function(){var e=window.getSelection(),t=this.cm,o=t.doc.sel.primary(),r=o.from(),i=o.to();if(t.display.viewTo==t.display.viewFrom||r.line>=t.display.viewTo||i.line<t.display.viewFrom)e.removeAllRanges();else{var a=za(t,e.anchorNode,e.anchorOffset),s=za(t,e.focusNode,e.focusOffset);if(!a||a.bad||!s||s.bad||0!=ve(be(a,s),r)||0!=ve(we(a,s),i)){var l=t.display.view,u=r.line>=t.display.viewFrom&&ja(t,r)||{node:l[0].measure.map[2],offset:0},c=i.line<t.display.viewTo&&ja(t,i);if(!c){var d=l[l.length-1].measure,h=d.maps?d.maps[d.maps.length-1]:d.map;c={node:h[h.length-1],offset:h[h.length-2]-h[h.length-3]}}if(u&&c){var f,p=e.rangeCount&&e.getRangeAt(0);try{f=S(u.node,u.offset,c.offset,c.node)}catch(e){}f&&(!n&&t.state.focused?(e.collapse(u.node,u.offset),f.collapsed||(e.removeAllRanges(),e.addRange(f))):(e.removeAllRanges(),e.addRange(f)),p&&null==e.anchorNode?e.addRange(p):n&&this.startGracePeriod()),this.rememberSelection()}else e.removeAllRanges()}}},Wa.prototype.startGracePeriod=function(){var e=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){e.gracePeriod=!1,e.selectionChanged()&&e.cm.operation(function(){return e.cm.curOp.selectionChanged=!0})},20)},Wa.prototype.showMultipleSelections=function(e){x(this.cm.display.cursorDiv,e.cursors),x(this.cm.display.selectionDiv,e.selection)},Wa.prototype.rememberSelection=function(){var e=window.getSelection();this.lastAnchorNode=e.anchorNode,this.lastAnchorOffset=e.anchorOffset,this.lastFocusNode=e.focusNode,this.lastFocusOffset=e.focusOffset},Wa.prototype.selectionInEditor=function(){var e=window.getSelection();if(!e.rangeCount)return!1;var t=e.getRangeAt(0).commonAncestorContainer;return E(this.div,t)},Wa.prototype.focus=function(){"nocursor"!=this.cm.options.readOnly&&(this.selectionInEditor()||this.showSelection(this.prepareSelection(),!0),this.div.focus())},Wa.prototype.blur=function(){this.div.blur()},Wa.prototype.getField=function(){return this.div},Wa.prototype.supportsTouch=function(){return!0},Wa.prototype.receivedFocus=function(){var e=this;this.selectionInEditor()?this.pollSelection():Qo(this.cm,function(){return e.cm.curOp.selectionChanged=!0}),this.polling.set(this.cm.options.pollInterval,function t(){e.cm.state.focused&&(e.pollSelection(),e.polling.set(e.cm.options.pollInterval,t))})},Wa.prototype.selectionChanged=function(){var e=window.getSelection();return e.anchorNode!=this.lastAnchorNode||e.anchorOffset!=this.lastAnchorOffset||e.focusNode!=this.lastFocusNode||e.focusOffset!=this.lastFocusOffset},Wa.prototype.pollSelection=function(){if(null==this.readDOMTimeout&&!this.gracePeriod&&this.selectionChanged()){var e=window.getSelection(),t=this.cm;if(g&&c&&this.cm.options.gutters.length&&function(e){for(var t=e;t;t=t.parentNode)if(/CodeMirror-gutter-wrapper/.test(t.className))return!0;return!1}(e.anchorNode))return this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),void this.focus();if(!this.composing){this.rememberSelection();var n=za(t,e.anchorNode,e.anchorOffset),o=za(t,e.focusNode,e.focusOffset);n&&o&&Qo(t,function(){$r(t.doc,kr(n,o),B),(n.bad||o.bad)&&(t.curOp.selectionChanged=!0)})}}},Wa.prototype.pollContent=function(){null!=this.readDOMTimeout&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var e,t,n,o=this.cm,r=o.display,i=o.doc.sel.primary(),a=i.from(),s=i.to();if(0==a.ch&&a.line>o.firstLine()&&(a=ge(a.line-1,le(o.doc,a.line-1).length)),s.ch==le(o.doc,s.line).text.length&&s.line<o.lastLine()&&(s=ge(s.line+1,0)),a.line<r.viewFrom||s.line>r.viewTo-1)return!1;a.line==r.viewFrom||0==(e=ho(o,a.line))?(t=he(r.view[0].line),n=r.view[0].node):(t=he(r.view[e].line),n=r.view[e-1].node.nextSibling);var l,u,c=ho(o,s.line);if(c==r.view.length-1?(l=r.viewTo-1,u=r.lineDiv.lastChild):(l=he(r.view[c+1].line)-1,u=r.view[c+1].node.previousSibling),!n)return!1;for(var d=o.doc.splitLines(function(e,t,n,o,r){var i="",a=!1,s=e.doc.lineSeparator();function l(){a&&(i+=s,a=!1)}function u(e){e&&(l(),i+=e)}function c(t){if(1==t.nodeType){var n=t.getAttribute("cm-text");if(null!=n)return void u(n||t.textContent.replace(/\u200b/g,""));var i,d=t.getAttribute("cm-marker");if(d){var h=e.findMarks(ge(o,0),ge(r+1,0),(m=+d,function(e){return e.id==m}));return void(h.length&&(i=h[0].find(0))&&u(ue(e.doc,i.from,i.to).join(s)))}if("false"==t.getAttribute("contenteditable"))return;var f=/^(pre|div|p)$/i.test(t.nodeName);f&&l();for(var p=0;p<t.childNodes.length;p++)c(t.childNodes[p]);f&&(a=!0)}else 3==t.nodeType&&u(t.nodeValue);var m}for(;c(t),t!=n;)t=t.nextSibling;return i}(o,n,u,t,l)),h=ue(o.doc,ge(t,0),ge(l,le(o.doc,l).text.length));d.length>1&&h.length>1;)if(J(d)==J(h))d.pop(),h.pop(),l--;else{if(d[0]!=h[0])break;d.shift(),h.shift(),t++}for(var f=0,p=0,m=d[0],g=h[0],v=Math.min(m.length,g.length);f<v&&m.charCodeAt(f)==g.charCodeAt(f);)++f;for(var y=J(d),_=J(h),w=Math.min(y.length-(1==d.length?f:0),_.length-(1==h.length?f:0));p<w&&y.charCodeAt(y.length-p-1)==_.charCodeAt(_.length-p-1);)++p;if(1==d.length&&1==h.length&&t==a.line)for(;f&&f>a.ch&&y.charCodeAt(y.length-p-1)==_.charCodeAt(_.length-p-1);)f--,p++;d[d.length-1]=y.slice(0,y.length-p).replace(/^\u200b+/,""),d[0]=d[0].slice(f).replace(/\u200b+$/,"");var b=ge(t,f),C=ge(l,h.length?J(h).length-p:0);return d.length>1||d[0]||ve(b,C)?(fi(o.doc,d,b,C,"+input"),!0):void 0},Wa.prototype.ensurePolled=function(){this.forceCompositionEnd()},Wa.prototype.reset=function(){this.forceCompositionEnd()},Wa.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Wa.prototype.readFromDOMSoon=function(){var e=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout(function(){if(e.readDOMTimeout=null,e.composing){if(!e.composing.done)return;e.composing=null}e.updateFromDOM()},80))},Wa.prototype.updateFromDOM=function(){var e=this;!this.cm.isReadOnly()&&this.pollContent()||Qo(this.cm,function(){return tr(e.cm)})},Wa.prototype.setUneditable=function(e){e.contentEditable="false"},Wa.prototype.onKeyPress=function(e){0!=e.charCode&&(e.preventDefault(),this.cm.isReadOnly()||$o(this.cm,Ea)(this.cm,String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),0))},Wa.prototype.readOnlyChanged=function(e){this.div.contentEditable=String("nocursor"!=e)},Wa.prototype.onContextMenu=function(){},Wa.prototype.resetPosition=function(){},Wa.prototype.needsContentAttribute=!0;var Va=function(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new W,this.hasSelection=!1,this.composing=null};Va.prototype.init=function(e){var t=this,n=this,o=this.cm;this.createField(e);var r=this.textarea;function i(e){if(!rt(o,e)){if(o.somethingSelected())Oa({lineWise:!1,text:o.getSelections()});else{if(!o.options.lineWiseCopyCut)return;var t=Ha(o);Oa({lineWise:!0,text:t.text}),"cut"==e.type?o.setSelections(t.ranges,null,B):(n.prevInput="",r.value=t.text.join("\n"),Y(r))}"cut"==e.type&&(o.state.cutIncoming=!0)}}e.wrapper.insertBefore(this.wrapper,e.wrapper.firstChild),m&&(r.style.width="0px"),et(r,"input",function(){a&&s>=9&&t.hasSelection&&(t.hasSelection=null),n.poll()}),et(r,"paste",function(e){rt(o,e)||Ra(e,o)||(o.state.pasteIncoming=!0,n.fastPoll())}),et(r,"cut",i),et(r,"copy",i),et(e.scroller,"paste",function(t){Mn(e,t)||rt(o,t)||(o.state.pasteIncoming=!0,n.focus())}),et(e.lineSpace,"selectstart",function(t){Mn(e,t)||lt(t)}),et(r,"compositionstart",function(){var e=o.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:e,range:o.markText(e,o.getCursor("to"),{className:"CodeMirror-composing"})}}),et(r,"compositionend",function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)})},Va.prototype.createField=function(e){this.wrapper=Pa(),this.textarea=this.wrapper.firstChild},Va.prototype.prepareSelection=function(){var e=this.cm,t=e.display,n=e.doc,o=po(e);if(e.options.moveInputWithCursor){var r=Xn(e,n.sel.primary().head,"div"),i=t.wrapper.getBoundingClientRect(),a=t.lineDiv.getBoundingClientRect();o.teTop=Math.max(0,Math.min(t.wrapper.clientHeight-10,r.top+a.top-i.top)),o.teLeft=Math.max(0,Math.min(t.wrapper.clientWidth-10,r.left+a.left-i.left))}return o},Va.prototype.showSelection=function(e){var t=this.cm.display;x(t.cursorDiv,e.cursors),x(t.selectionDiv,e.selection),null!=e.teTop&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},Va.prototype.reset=function(e){if(!this.contextMenuPending&&!this.composing){var t=this.cm;if(t.somethingSelected()){this.prevInput="";var n=t.getSelection();this.textarea.value=n,t.state.focused&&Y(this.textarea),a&&s>=9&&(this.hasSelection=n)}else e||(this.prevInput=this.textarea.value="",a&&s>=9&&(this.hasSelection=null))}},Va.prototype.getField=function(){return this.textarea},Va.prototype.supportsTouch=function(){return!1},Va.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!v||R()!=this.textarea))try{this.textarea.focus()}catch(e){}},Va.prototype.blur=function(){this.textarea.blur()},Va.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Va.prototype.receivedFocus=function(){this.slowPoll()},Va.prototype.slowPoll=function(){var e=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){e.poll(),e.cm.state.focused&&e.slowPoll()})},Va.prototype.fastPoll=function(){var e=!1,t=this;t.pollingFast=!0,t.polling.set(20,function n(){t.poll()||e?(t.pollingFast=!1,t.slowPoll()):(e=!0,t.polling.set(60,n))})},Va.prototype.poll=function(){var e=this,t=this.cm,n=this.textarea,o=this.prevInput;if(this.contextMenuPending||!t.state.focused||bt(n)&&!o&&!this.composing||t.isReadOnly()||t.options.disableInput||t.state.keySeq)return!1;var r=n.value;if(r==o&&!t.somethingSelected())return!1;if(a&&s>=9&&this.hasSelection===r||y&&/[\uf700-\uf7ff]/.test(r))return t.display.input.reset(),!1;if(t.doc.sel==t.display.selForContextMenu){var i=r.charCodeAt(0);if(8203!=i||o||(o="​"),8666==i)return this.reset(),this.cm.execCommand("undo")}for(var l=0,u=Math.min(o.length,r.length);l<u&&o.charCodeAt(l)==r.charCodeAt(l);)++l;return Qo(t,function(){Ea(t,r.slice(l),o.length-l,null,e.composing?"*compose":null),r.length>1e3||r.indexOf("\n")>-1?n.value=e.prevInput="":e.prevInput=r,e.composing&&(e.composing.range.clear(),e.composing.range=t.markText(e.composing.start,t.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Va.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Va.prototype.onKeyPress=function(){a&&s>=9&&(this.hasSelection=null),this.fastPoll()},Va.prototype.onContextMenu=function(e){var t=this,n=t.cm,o=n.display,r=t.textarea,i=co(n,e),u=o.scroller.scrollTop;if(i&&!d){n.options.resetSelectionOnContextMenu&&-1==n.doc.sel.contains(i)&&$o(n,$r)(n.doc,kr(i),B);var c=r.style.cssText,h=t.wrapper.style.cssText;t.wrapper.style.cssText="position: absolute";var f,p=t.wrapper.getBoundingClientRect();if(r.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(e.clientY-p.top-5)+"px; left: "+(e.clientX-p.left-5)+"px;\n z-index: 1000; background: "+(a?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",l&&(f=window.scrollY),o.input.focus(),l&&window.scrollTo(null,f),o.input.reset(),n.somethingSelected()||(r.value=t.prevInput=" "),t.contextMenuPending=!0,o.selForContextMenu=n.doc.sel,clearTimeout(o.detectingSelectAll),a&&s>=9&&g(),M){dt(e);var m=function(){nt(window,"mouseup",m),setTimeout(v,20)};et(window,"mouseup",m)}else setTimeout(v,50)}function g(){if(null!=r.selectionStart){var e=n.somethingSelected(),i="​"+(e?r.value:"");r.value="⇚",r.value=i,t.prevInput=e?"":"​",r.selectionStart=1,r.selectionEnd=i.length,o.selForContextMenu=n.doc.sel}}function v(){if(t.contextMenuPending=!1,t.wrapper.style.cssText=h,r.style.cssText=c,a&&s<9&&o.scrollbars.setScrollTop(o.scroller.scrollTop=u),null!=r.selectionStart){(!a||a&&s<9)&&g();var e=0,i=function(){o.selForContextMenu==n.doc.sel&&0==r.selectionStart&&r.selectionEnd>0&&"​"==t.prevInput?$o(n,ai)(n):e++<10?o.detectingSelectAll=setTimeout(i,500):(o.selForContextMenu=null,o.input.reset())};o.detectingSelectAll=setTimeout(i,200)}}},Va.prototype.readOnlyChanged=function(e){e||this.reset(),this.textarea.disabled="nocursor"==e},Va.prototype.setUneditable=function(){},Va.prototype.needsContentAttribute=!1,function(e){var t=e.optionHandlers;function n(n,o,r,i){e.defaults[n]=o,r&&(t[n]=i?function(e,t,n){n!=wa&&r(e,t,n)}:r)}e.defineOption=n,e.Init=wa,n("value","",function(e,t){return e.setValue(t)},!0),n("mode",null,function(e,t){e.doc.modeOption=t,Dr(e)},!0),n("indentUnit",2,Dr,!0),n("indentWithTabs",!1),n("smartIndent",!0),n("tabSize",4,function(e){Or(e),Fn(e),tr(e)},!0),n("lineSeparator",null,function(e,t){if(e.doc.lineSep=t,t){var n=[],o=e.doc.first;e.doc.iter(function(e){for(var r=0;;){var i=e.text.indexOf(t,r);if(-1==i)break;r=i+t.length,n.push(ge(o,i))}o++});for(var r=n.length-1;r>=0;r--)fi(e.doc,t,n[r],ge(n[r].line,n[r].ch+t.length))}}),n("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200f\u2028\u2029\ufeff]/g,function(e,t,n){e.state.specialChars=new RegExp(t.source+(t.test("\t")?"":"|\t"),"g"),n!=wa&&e.refresh()}),n("specialCharPlaceholder",Zt,function(e){return e.refresh()},!0),n("electricChars",!0),n("inputStyle",v?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),n("spellcheck",!1,function(e,t){return e.getInputField().spellcheck=t},!0),n("rtlMoveVisually",!w),n("wholeLineUpdateBefore",!0),n("theme","default",function(e){_a(e),Ma(e)},!0),n("keyMap","default",function(e,t,n){var o=Xi(t),r=n!=wa&&Xi(n);r&&r.detach&&r.detach(e,o),o.attach&&o.attach(e,r||null)}),n("extraKeys",null),n("configureMouse",null),n("lineWrapping",!1,Sa,!0),n("gutters",[],function(e){mr(e.options),Ma(e)},!0),n("fixedGutter",!0,function(e,t){e.display.gutters.style.left=t?so(e.display)+"px":"0",e.refresh()},!0),n("coverGutterNextToScrollbar",!1,function(e){return jo(e)},!0),n("scrollbarStyle","native",function(e){Bo(e),jo(e),e.display.scrollbars.setScrollTop(e.doc.scrollTop),e.display.scrollbars.setScrollLeft(e.doc.scrollLeft)},!0),n("lineNumbers",!1,function(e){mr(e.options),Ma(e)},!0),n("firstLineNumber",1,Ma,!0),n("lineNumberFormatter",function(e){return e},Ma,!0),n("showCursorWhenSelecting",!1,fo,!0),n("resetSelectionOnContextMenu",!0),n("lineWiseCopyCut",!0),n("pasteLinesPerSelection",!0),n("readOnly",!1,function(e,t){"nocursor"==t&&(Co(e),e.display.input.blur()),e.display.input.readOnlyChanged(t)}),n("disableInput",!1,function(e,t){t||e.display.input.reset()},!0),n("dragDrop",!0,ka),n("allowDropFileTypes",null),n("cursorBlinkRate",530),n("cursorScrollMargin",0),n("cursorHeight",1,fo,!0),n("singleCursorHeightPerLine",!0,fo,!0),n("workTime",100),n("workDelay",100),n("flattenSpans",!0,Or,!0),n("addModeClass",!1,Or,!0),n("pollInterval",100),n("undoDepth",200,function(e,t){return e.doc.history.undoDepth=t}),n("historyEventDelay",1250),n("viewportMargin",10,function(e){return e.refresh()},!0),n("maxHighlightLength",1e4,Or,!0),n("moveInputWithCursor",!0,function(e,t){t||e.display.input.resetPosition()}),n("tabindex",null,function(e,t){return e.display.input.getField().tabIndex=t||""}),n("autofocus",null),n("direction","ltr",function(e,t){return e.doc.setDirection(t)},!0)}(Ta),function(e){var t=e.optionHandlers,n=e.helpers={};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(e,n){var o=this.options,r=o[e];o[e]==n&&"mode"!=e||(o[e]=n,t.hasOwnProperty(e)&&$o(this,t[e])(this,n,r),ot(this,"optionChange",this,e))},getOption:function(e){return this.options[e]},getDoc:function(){return this.doc},addKeyMap:function(e,t){this.state.keyMaps[t?"push":"unshift"](Xi(e))},removeKeyMap:function(e){for(var t=this.state.keyMaps,n=0;n<t.length;++n)if(t[n]==e||t[n].name==e)return t.splice(n,1),!0},addOverlay:Zo(function(t,n){var o=t.token?t:e.getMode(this.options,t);if(o.startState)throw new Error("Overlays may not be stateful.");!function(e,t,n){for(var o=0,r=n(t);o<e.length&&n(e[o])<=r;)o++;e.splice(o,0,t)}(this.state.overlays,{mode:o,modeSpec:t,opaque:n&&n.opaque,priority:n&&n.priority||0},function(e){return e.priority}),this.state.modeGen++,tr(this)}),removeOverlay:Zo(function(e){for(var t=this.state.overlays,n=0;n<t.length;++n){var o=t[n].modeSpec;if(o==e||"string"==typeof e&&o.name==e)return t.splice(n,1),this.state.modeGen++,void tr(this)}}),indentLine:Zo(function(e,t,n){"string"!=typeof t&&"number"!=typeof t&&(t=null==t?this.options.smartIndent?"smart":"prev":t?"add":"subtract"),pe(this.doc,e)&&xa(this,e,t,n)}),indentSelection:Zo(function(e){for(var t=this.doc.sel.ranges,n=-1,o=0;o<t.length;o++){var r=t[o];if(r.empty())r.head.line>n&&(xa(this,r.head.line,e,!0),n=r.head.line,o==this.doc.sel.primIndex&&Oo(this));else{var i=r.from(),a=r.to(),s=Math.max(n,i.line);n=Math.min(this.lastLine(),a.line-(a.ch?0:1))+1;for(var l=s;l<n;++l)xa(this,l,e);var u=this.doc.sel.ranges;0==i.ch&&t.length==u.length&&u[o].from().ch>0&&Jr(this.doc,o,new Cr(i,u[o].to()),B)}}}),getTokenAt:function(e,t){return Vt(this,e,t)},getLineTokens:function(e,t){return Vt(this,ge(e),t,!0)},getTokenTypeAt:function(e){e=Me(this.doc,e);var t,n=It(this,le(this.doc,e.line)),o=0,r=(n.length-1)/2,i=e.ch;if(0==i)t=n[2];else for(;;){var a=o+r>>1;if((a?n[2*a-1]:0)>=i)r=a;else{if(!(n[2*a+1]<i)){t=n[2*a+2];break}o=a+1}}var s=t?t.indexOf("overlay "):-1;return s<0?t:0==s?null:t.slice(0,s-1)},getModeAt:function(t){var n=this.doc.mode;return n.innerMode?e.innerMode(n,this.getTokenAt(t).state).mode:n},getHelper:function(e,t){return this.getHelpers(e,t)[0]},getHelpers:function(e,t){var o=[];if(!n.hasOwnProperty(t))return o;var r=n[t],i=this.getModeAt(e);if("string"==typeof i[t])r[i[t]]&&o.push(r[i[t]]);else if(i[t])for(var a=0;a<i[t].length;a++){var s=r[i[t][a]];s&&o.push(s)}else i.helperType&&r[i.helperType]?o.push(r[i.helperType]):r[i.name]&&o.push(r[i.name]);for(var l=0;l<r._global.length;l++){var u=r._global[l];u.pred(i,this)&&-1==j(o,u.val)&&o.push(u.val)}return o},getStateAfter:function(e,t){var n=this.doc;return Wt(this,(e=Ce(n,null==e?n.first+n.size-1:e))+1,t).state},cursorCoords:function(e,t){var n=this.doc.sel.primary();return Xn(this,null==e?n.head:"object"==typeof e?Me(this.doc,e):e?n.from():n.to(),t||"page")},charCoords:function(e,t){return Gn(this,Me(this.doc,e),t||"page")},coordsChar:function(e,t){return Qn(this,(e=Kn(this,e,t||"page")).left,e.top)},lineAtHeight:function(e,t){return e=Kn(this,{top:e,left:0},t||"page").top,fe(this.doc,e+this.display.viewOffset)},heightAtLine:function(e,t,n){var o,r=!1;if("number"==typeof e){var i=this.doc.first+this.doc.size-1;e<this.doc.first?e=this.doc.first:e>i&&(e=i,r=!0),o=le(this.doc,e)}else o=e;return Un(this,o,{top:0,left:0},t||"page",n||r).top+(r?this.doc.height-Ke(o):0)},defaultTextHeight:function(){return ro(this.display)},defaultCharWidth:function(){return io(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(e,t,n,o,r){var i,a,s,l=this.display,u=(e=Xn(this,Me(this.doc,e))).bottom,c=e.left;if(t.style.position="absolute",t.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(t),l.sizer.appendChild(t),"over"==o)u=e.top;else if("above"==o||"near"==o){var d=Math.max(l.wrapper.clientHeight,this.doc.height),h=Math.max(l.sizer.clientWidth,l.lineSpace.clientWidth);("above"==o||e.bottom+t.offsetHeight>d)&&e.top>t.offsetHeight?u=e.top-t.offsetHeight:e.bottom+t.offsetHeight<=d&&(u=e.bottom),c+t.offsetWidth>h&&(c=h-t.offsetWidth)}t.style.top=u+"px",t.style.left=t.style.right="","right"==r?(c=l.sizer.clientWidth-t.offsetWidth,t.style.right="0px"):("left"==r?c=0:"middle"==r&&(c=(l.sizer.clientWidth-t.offsetWidth)/2),t.style.left=c+"px"),n&&(i=this,a={left:c,top:u,right:c+t.offsetWidth,bottom:u+t.offsetHeight},null!=(s=xo(i,a)).scrollTop&&Ho(i,s.scrollTop),null!=s.scrollLeft&&Po(i,s.scrollLeft))},triggerOnKeyDown:Zo(la),triggerOnKeyPress:Zo(ca),triggerOnKeyUp:ua,triggerOnMouseDown:Zo(pa),execCommand:function(e){if(Zi.hasOwnProperty(e))return Zi[e].call(null,this)},triggerElectric:Zo(function(e){Aa(this,e)}),findPosH:function(e,t,n,o){var r=1;t<0&&(r=-1,t=-t);for(var i=Me(this.doc,e),a=0;a<t&&!(i=Na(this.doc,i,r,n,o)).hitSide;++a);return i},moveH:Zo(function(e,t){var n=this;this.extendSelectionsBy(function(o){return n.display.shift||n.doc.extend||o.empty()?Na(n.doc,o.head,e,t,n.options.rtlMoveVisually):e<0?o.from():o.to()},U)}),deleteH:Zo(function(e,t){var n=this.doc.sel,o=this.doc;n.somethingSelected()?o.replaceSelection("",null,"+delete"):Ji(this,function(n){var r=Na(o,n.head,e,t,!1);return e<0?{from:r,to:n.head}:{from:n.head,to:r}})}),findPosV:function(e,t,n,o){var r=1,i=o;t<0&&(r=-1,t=-t);for(var a=Me(this.doc,e),s=0;s<t;++s){var l=Xn(this,a,"div");if(null==i?i=l.left:l.left=i,(a=Ia(this,l,r,n)).hitSide)break}return a},moveV:Zo(function(e,t){var n=this,o=this.doc,r=[],i=!this.display.shift&&!o.extend&&o.sel.somethingSelected();if(o.extendSelectionsBy(function(a){if(i)return e<0?a.from():a.to();var s=Xn(n,a.head,"div");null!=a.goalColumn&&(s.left=a.goalColumn),r.push(s.left);var l=Ia(n,s,e,t);return"page"==t&&a==o.sel.primary()&&Do(n,Gn(n,l,"div").top-s.top),l},U),r.length)for(var a=0;a<o.sel.ranges.length;a++)o.sel.ranges[a].goalColumn=r[a]}),findWordAt:function(e){var t=le(this.doc,e.line).text,n=e.ch,o=e.ch;if(t){var r=this.getHelper(e,"wordChars");"before"!=e.sticky&&o!=t.length||!n?++o:--n;for(var i=t.charAt(n),a=te(i,r)?function(e){return te(e,r)}:/\s/.test(i)?function(e){return/\s/.test(e)}:function(e){return!/\s/.test(e)&&!te(e)};n>0&&a(t.charAt(n-1));)--n;for(;o<t.length&&a(t.charAt(o));)++o}return new Cr(ge(e.line,n),ge(e.line,o))},toggleOverwrite:function(e){null!=e&&e==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?A(this.display.cursorDiv,"CodeMirror-overwrite"):T(this.display.cursorDiv,"CodeMirror-overwrite"),ot(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==R()},isReadOnly:function(){return!(!this.options.readOnly&&!this.doc.cantEdit)},scrollTo:Zo(function(e,t){Eo(this,e,t)}),getScrollInfo:function(){var e=this.display.scroller;return{left:e.scrollLeft,top:e.scrollTop,height:e.scrollHeight-Ln(this)-this.display.barHeight,width:e.scrollWidth-Ln(this)-this.display.barWidth,clientHeight:Dn(this),clientWidth:xn(this)}},scrollIntoView:Zo(function(e,t){null==e?(e={from:this.doc.sel.primary().head,to:null},null==t&&(t=this.options.cursorScrollMargin)):"number"==typeof e?e={from:ge(e,0),to:null}:null==e.from&&(e={from:e,to:null}),e.to||(e.to=e.from),e.margin=t||0,null!=e.from.line?function(e,t){Ro(e),e.curOp.scrollToPos=t}(this,e):Ao(this,e.from,e.to,e.margin)}),setSize:Zo(function(e,t){var n=this,o=function(e){return"number"==typeof e||/^\d+$/.test(String(e))?e+"px":e};null!=e&&(this.display.wrapper.style.width=o(e)),null!=t&&(this.display.wrapper.style.height=o(t)),this.options.lineWrapping&&jn(this);var r=this.display.viewFrom;this.doc.iter(r,this.display.viewTo,function(e){if(e.widgets)for(var t=0;t<e.widgets.length;t++)if(e.widgets[t].noHScroll){nr(n,r,"widget");break}++r}),this.curOp.forceUpdate=!0,ot(this,"refresh",this)}),operation:function(e){return Qo(this,e)},startOperation:function(){return Uo(this)},endOperation:function(){return Ko(this)},refresh:Zo(function(){var e=this.display.cachedTextHeight;tr(this),this.curOp.forceUpdate=!0,Fn(this),Eo(this,this.doc.scrollLeft,this.doc.scrollTop),hr(this),(null==e||Math.abs(e-ro(this.display))>.5)&&uo(this),ot(this,"refresh",this)}),swapDoc:Zo(function(e){var t=this.doc;return t.cm=null,Hr(this,e),Fn(this),this.display.input.reset(),Eo(this,e.scrollLeft,e.scrollTop),this.curOp.forceScroll=!0,un(this,"swapDoc",this,t),t}),getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},st(e),e.registerHelper=function(t,o,r){n.hasOwnProperty(t)||(n[t]=e[t]={_global:[]}),n[t][o]=r},e.registerGlobalHelper=function(t,o,r,i){e.registerHelper(t,o,i),n[t]._global.push({pred:r,val:i})}}(Ta);var Ua,Ka="iter insert remove copy getEditor constructor".split(" ");for(var Ga in Di.prototype)Di.prototype.hasOwnProperty(Ga)&&j(Ka,Ga)<0&&(Ta.prototype[Ga]=function(e){return function(){return e.apply(this.doc,arguments)}}(Di.prototype[Ga]));return st(Di),Ta.inputStyles={textarea:Va,contenteditable:Wa},Ta.defineMode=function(e){Ta.defaults.mode||"null"==e||(Ta.defaults.mode=e),Tt.apply(this,arguments)},Ta.defineMIME=function(e,t){St[e]=t},Ta.defineMode("null",function(){return{token:function(e){return e.skipToEnd()}}}),Ta.defineMIME("text/plain","null"),Ta.defineExtension=function(e,t){Ta.prototype[e]=t},Ta.defineDocExtension=function(e,t){Di.prototype[e]=t},Ta.fromTextArea=function(e,t){if((t=t?N(t):{}).value=e.value,!t.tabindex&&e.tabIndex&&(t.tabindex=e.tabIndex),!t.placeholder&&e.placeholder&&(t.placeholder=e.placeholder),null==t.autofocus){var n=R();t.autofocus=n==e||null!=e.getAttribute("autofocus")&&n==document.body}function o(){e.value=s.getValue()}var r;if(e.form&&(et(e.form,"submit",o),!t.leaveSubmitMethodAlone)){var i=e.form;r=i.submit;try{var a=i.submit=function(){o(),i.submit=r,i.submit(),i.submit=a}}catch(e){}}t.finishInit=function(t){t.save=o,t.getTextArea=function(){return e},t.toTextArea=function(){t.toTextArea=isNaN,o(),e.parentNode.removeChild(t.getWrapperElement()),e.style.display="",e.form&&(nt(e.form,"submit",o),"function"==typeof e.form.submit&&(e.form.submit=r))}},e.style.display="none";var s=Ta(function(t){return e.parentNode.insertBefore(t,e.nextSibling)},t);return s},(Ua=Ta).off=nt,Ua.on=et,Ua.wheelEventPixels=_r,Ua.Doc=Di,Ua.splitLines=wt,Ua.countColumn=I,Ua.findColumn=K,Ua.isWordChar=ee,Ua.Pass=z,Ua.signal=ot,Ua.Line=Gt,Ua.changeEnd=Sr,Ua.scrollbarModel=zo,Ua.Pos=ge,Ua.cmpPos=ve,Ua.modes=kt,Ua.mimeModes=St,Ua.resolveMode=Lt,Ua.getMode=xt,Ua.modeExtensions=Dt,Ua.extendMode=Ot,Ua.copyState=Et,Ua.startState=At,Ua.innerMode=Rt,Ua.commands=Zi,Ua.keyMap=Fi,Ua.keyName=Gi,Ua.isModifierKey=Ui,Ua.lookupKey=Vi,Ua.normalizeKeyMap=Bi,Ua.StringStream=Ht,Ua.SharedTextMarker=Si,Ua.TextMarker=Mi,Ua.LineWidget=wi,Ua.e_preventDefault=lt,Ua.e_stopPropagation=ut,Ua.e_stop=dt,Ua.addClass=A,Ua.contains=E,Ua.rmClass=T,Ua.keyNames=Ni,Ta.version="5.36.0",Ta}()},function(e,t,n){"use strict";var o=n(66),r=n(6);var i=function(e){r.extend(this,e),this.initialize.apply(this,arguments)};r.extend(i.prototype,{initialize:function(){this.hidden=!1},pivot:function(){var e=this;return e._view||(e._view=r.clone(e._model)),e._start={},e},transition:function(e){var t=this,n=t._model,r=t._start,i=t._view;return n&&1!==e?(i||(i=t._view={}),r||(r=t._start={}),function(e,t,n,r){var i,a,s,l,u,c,d,h,f,p=Object.keys(n);for(i=0,a=p.length;i<a;++i)if(c=n[s=p[i]],t.hasOwnProperty(s)||(t[s]=c),(l=t[s])!==c&&"_"!==s[0]){if(e.hasOwnProperty(s)||(e[s]=l),(d=typeof c)===typeof(u=e[s]))if("string"===d){if((h=o(u)).valid&&(f=o(c)).valid){t[s]=f.mix(h,r).rgbString();continue}}else if("number"===d&&isFinite(u)&&isFinite(c)){t[s]=u+(c-u)*r;continue}t[s]=c}}(r,i,n,e),t):(t._view=n,t._start=null,t)},tooltipPosition:function(){return{x:this._model.x,y:this._model.y}},hasValue:function(){return r.isNumber(this._model.x)&&r.isNumber(this._model.y)}}),i.extend=r.inherits,e.exports=i},,,,function(e,t,n){"use strict";e.exports={},e.exports.Arc=n(370),e.exports.Line=n(371),e.exports.Point=n(372),e.exports.Rectangle=n(373)},,,,,,function(e,t,n){"use strict";var o=n(6);function r(e,t){return o.where(e,function(e){return e.position===t})}function i(e,t){e.forEach(function(e,t){return e._tmpIndex_=t,e}),e.sort(function(e,n){var o=t?n:e,r=t?e:n;return o.weight===r.weight?o._tmpIndex_-r._tmpIndex_:o.weight-r.weight}),e.forEach(function(e){delete e._tmpIndex_})}e.exports={defaults:{},addBox:function(e,t){e.boxes||(e.boxes=[]),t.fullWidth=t.fullWidth||!1,t.position=t.position||"top",t.weight=t.weight||0,e.boxes.push(t)},removeBox:function(e,t){var n=e.boxes?e.boxes.indexOf(t):-1;-1!==n&&e.boxes.splice(n,1)},configure:function(e,t,n){for(var o,r=["fullWidth","position","weight"],i=r.length,a=0;a<i;++a)o=r[a],n.hasOwnProperty(o)&&(t[o]=n[o])},update:function(e,t,n){if(e){var a=e.options.layout||{},s=o.options.toPadding(a.padding),l=s.left,u=s.right,c=s.top,d=s.bottom,h=r(e.boxes,"left"),f=r(e.boxes,"right"),p=r(e.boxes,"top"),m=r(e.boxes,"bottom"),g=r(e.boxes,"chartArea");i(h,!0),i(f,!1),i(p,!0),i(m,!1);var v=t-l-u,y=n-c-d,_=y/2,w=(t-v/2)/(h.length+f.length),b=(n-_)/(p.length+m.length),C=v,M=y,k=[];o.each(h.concat(f,p,m),function(e){var t,n=e.isHorizontal();n?(t=e.update(e.fullWidth?v:C,b),M-=t.height):(t=e.update(w,M),C-=t.width),k.push({horizontal:n,minSize:t,box:e})});var S=0,T=0,L=0,x=0;o.each(p.concat(m),function(e){if(e.getPadding){var t=e.getPadding();S=Math.max(S,t.left),T=Math.max(T,t.right)}}),o.each(h.concat(f),function(e){if(e.getPadding){var t=e.getPadding();L=Math.max(L,t.top),x=Math.max(x,t.bottom)}});var D=l,O=u,E=c,R=d;o.each(h.concat(f),W),o.each(h,function(e){D+=e.width}),o.each(f,function(e){O+=e.width}),o.each(p.concat(m),W),o.each(p,function(e){E+=e.height}),o.each(m,function(e){R+=e.height}),o.each(h.concat(f),function(e){var t=o.findNextWhere(k,function(t){return t.box===e}),n={left:0,right:0,top:E,bottom:R};t&&e.update(t.minSize.width,M,n)}),D=l,O=u,E=c,R=d,o.each(h,function(e){D+=e.width}),o.each(f,function(e){O+=e.width}),o.each(p,function(e){E+=e.height}),o.each(m,function(e){R+=e.height});var A=Math.max(S-D,0);D+=A,O+=Math.max(T-O,0);var H=Math.max(L-E,0);E+=H,R+=Math.max(x-R,0);var Y=n-E-R,P=t-D-O;P===C&&Y===M||(o.each(h,function(e){e.height=Y}),o.each(f,function(e){e.height=Y}),o.each(p,function(e){e.fullWidth||(e.width=P)}),o.each(m,function(e){e.fullWidth||(e.width=P)}),M=Y,C=P);var N=l+A,I=c+H;o.each(h.concat(p),j),N+=C,I+=M,o.each(f,j),o.each(m,j),e.chartArea={left:D,top:E,right:D+C,bottom:E+M},o.each(g,function(t){t.left=e.chartArea.left,t.top=e.chartArea.top,t.right=e.chartArea.right,t.bottom=e.chartArea.bottom,t.update(C,M)})}function W(e){var t=o.findNextWhere(k,function(t){return t.box===e});if(t)if(e.isHorizontal()){var n={left:Math.max(D,S),right:Math.max(O,T),top:0,bottom:0};e.update(e.fullWidth?v:C,y/2,n)}else e.update(t.minSize.width,M)}function j(e){e.isHorizontal()?(e.left=e.fullWidth?l:D,e.right=e.fullWidth?t-u:D+C,e.top=I,e.bottom=I+e.height,I=e.bottom):(e.left=N,e.right=N+e.width,e.top=E,e.bottom=E+M,N=e.right)}}}},function(e,t,n){"use strict";var o=n(6);e.exports={formatters:{values:function(e){return o.isArray(e)?e:""+e},linear:function(e,t,n){var r=n.length>3?n[2]-n[1]:n[1]-n[0];Math.abs(r)>1&&e!==Math.floor(e)&&(r=e-Math.floor(e));var i=o.log10(Math.abs(r)),a="";if(0!==e){var s=-1*Math.floor(i);s=Math.max(Math.min(s,20),0),a=e.toFixed(s)}else a="0";return a},logarithmic:function(e,t,n){var r=e/Math.pow(10,Math.floor(o.log10(e)));return 0===e?"0":1===r||2===r||5===r||0===t||t===n.length-1?e.toExponential():""}}}},,,,,,,,function(e,t,n){"use strict";var o,r={noop:function(){},uid:(o=0,function(){return o++}),isNullOrUndef:function(e){return null==e},isArray:Array.isArray?Array.isArray:function(e){return"[object Array]"===Object.prototype.toString.call(e)},isObject:function(e){return null!==e&&"[object Object]"===Object.prototype.toString.call(e)},valueOrDefault:function(e,t){return void 0===e?t:e},valueAtIndexOrDefault:function(e,t,n){return r.valueOrDefault(r.isArray(e)?e[t]:e,n)},callback:function(e,t,n){if(e&&"function"==typeof e.call)return e.apply(n,t)},each:function(e,t,n,o){var i,a,s;if(r.isArray(e))if(a=e.length,o)for(i=a-1;i>=0;i--)t.call(n,e[i],i);else for(i=0;i<a;i++)t.call(n,e[i],i);else if(r.isObject(e))for(a=(s=Object.keys(e)).length,i=0;i<a;i++)t.call(n,e[s[i]],s[i])},arrayEquals:function(e,t){var n,o,i,a;if(!e||!t||e.length!==t.length)return!1;for(n=0,o=e.length;n<o;++n)if(i=e[n],a=t[n],i instanceof Array&&a instanceof Array){if(!r.arrayEquals(i,a))return!1}else if(i!==a)return!1;return!0},clone:function(e){if(r.isArray(e))return e.map(r.clone);if(r.isObject(e)){for(var t={},n=Object.keys(e),o=n.length,i=0;i<o;++i)t[n[i]]=r.clone(e[n[i]]);return t}return e},_merger:function(e,t,n,o){var i=t[e],a=n[e];r.isObject(i)&&r.isObject(a)?r.merge(i,a,o):t[e]=r.clone(a)},_mergerIf:function(e,t,n){var o=t[e],i=n[e];r.isObject(o)&&r.isObject(i)?r.mergeIf(o,i):t.hasOwnProperty(e)||(t[e]=r.clone(i))},merge:function(e,t,n){var o,i,a,s,l,u=r.isArray(t)?t:[t],c=u.length;if(!r.isObject(e))return e;for(o=(n=n||{}).merger||r._merger,i=0;i<c;++i)if(t=u[i],r.isObject(t))for(l=0,s=(a=Object.keys(t)).length;l<s;++l)o(a[l],e,t,n);return e},mergeIf:function(e,t){return r.merge(e,t,{merger:r._mergerIf})},extend:function(e){for(var t=function(t,n){e[n]=t},n=1,o=arguments.length;n<o;++n)r.each(arguments[n],t);return e},inherits:function(e){var t=this,n=e&&e.hasOwnProperty("constructor")?e.constructor:function(){return t.apply(this,arguments)},o=function(){this.constructor=n};return o.prototype=t.prototype,n.prototype=new o,n.extend=r.inherits,e&&r.extend(n.prototype,e),n.__super__=t.prototype,n}};e.exports=r,r.callCallback=r.callback,r.indexOf=function(e,t,n){return Array.prototype.indexOf.call(e,t,n)},r.getValueOrDefault=r.valueOrDefault,r.getValueAtIndexOrDefault=r.valueAtIndexOrDefault},,,,,,function(e,t,n){!function(e){"use strict";var t="CodeMirror-hint",n="CodeMirror-hint-active";function o(e,t){this.cm=e,this.options=t,this.widget=null,this.debounce=0,this.tick=0,this.startPos=this.cm.getCursor("start"),this.startLen=this.cm.getLine(this.startPos.line).length-this.cm.getSelection().length;var n=this;e.on("cursorActivity",this.activityFunc=function(){n.cursorActivity()})}e.showHint=function(e,t,n){if(!t)return e.showHint(n);n&&n.async&&(t.async=!0);var o={hint:t};if(n)for(var r in n)o[r]=n[r];return e.showHint(o)},e.defineExtension("showHint",function(t){t=function(e,t,n){var o=e.options.hintOptions,r={};for(var i in c)r[i]=c[i];if(o)for(var i in o)void 0!==o[i]&&(r[i]=o[i]);if(n)for(var i in n)void 0!==n[i]&&(r[i]=n[i]);return r.hint.resolve&&(r.hint=r.hint.resolve(e,t)),r}(this,this.getCursor("start"),t);var n=this.listSelections();if(!(n.length>1)){if(this.somethingSelected()){if(!t.hint.supportsSelection)return;for(var r=0;r<n.length;r++)if(n[r].head.line!=n[r].anchor.line)return}this.state.completionActive&&this.state.completionActive.close();var i=this.state.completionActive=new o(this,t);i.options.hint&&(e.signal(this,"startCompletion",this),i.update(!0))}});var r=window.requestAnimationFrame||function(e){return setTimeout(e,1e3/60)},i=window.cancelAnimationFrame||clearTimeout;function a(e){return"string"==typeof e?e:e.text}function s(e,t){for(;t&&t!=e;){if("LI"===t.nodeName.toUpperCase()&&t.parentNode==e)return t;t=t.parentNode}}function l(o,r){this.completion=o,this.data=r,this.picked=!1;var i=this,l=o.cm,u=this.hints=document.createElement("ul");u.className="CodeMirror-hints",this.selectedHint=r.selectedHint||0;for(var c=r.list,d=0;d<c.length;++d){var h=u.appendChild(document.createElement("li")),f=c[d],p=t+(d!=this.selectedHint?"":" "+n);null!=f.className&&(p=f.className+" "+p),h.className=p,f.render?f.render(h,r,f):h.appendChild(document.createTextNode(f.displayText||a(f))),h.hintId=d}var m=l.cursorCoords(o.options.alignWithWord?r.from:null),g=m.left,v=m.bottom,y=!0;u.style.left=g+"px",u.style.top=v+"px";var _=window.innerWidth||Math.max(document.body.offsetWidth,document.documentElement.offsetWidth),w=window.innerHeight||Math.max(document.body.offsetHeight,document.documentElement.offsetHeight);(o.options.container||document.body).appendChild(u);var b=u.getBoundingClientRect(),C=b.bottom-w,M=u.scrollHeight>u.clientHeight+1,k=l.getScrollInfo();if(C>0){var S=b.bottom-b.top;if(m.top-(m.bottom-b.top)-S>0)u.style.top=(v=m.top-S)+"px",y=!1;else if(S>w){u.style.height=w-5+"px",u.style.top=(v=m.bottom-b.top)+"px";var T=l.getCursor();r.from.ch!=T.ch&&(m=l.cursorCoords(T),u.style.left=(g=m.left)+"px",b=u.getBoundingClientRect())}}var L,x=b.right-_;if(x>0&&(b.right-b.left>_&&(u.style.width=_-5+"px",x-=b.right-b.left-_),u.style.left=(g=m.left-x)+"px"),M)for(var D=u.firstChild;D;D=D.nextSibling)D.style.paddingRight=l.display.nativeBarWidth+"px";return l.addKeyMap(this.keyMap=function(e,t){var n={Up:function(){t.moveFocus(-1)},Down:function(){t.moveFocus(1)},PageUp:function(){t.moveFocus(1-t.menuSize(),!0)},PageDown:function(){t.moveFocus(t.menuSize()-1,!0)},Home:function(){t.setFocus(0)},End:function(){t.setFocus(t.length-1)},Enter:t.pick,Tab:t.pick,Esc:t.close},o=e.options.customKeys,r=o?{}:n;function i(e,o){var i;i="string"!=typeof o?function(e){return o(e,t)}:n.hasOwnProperty(o)?n[o]:o,r[e]=i}if(o)for(var a in o)o.hasOwnProperty(a)&&i(a,o[a]);var s=e.options.extraKeys;if(s)for(var a in s)s.hasOwnProperty(a)&&i(a,s[a]);return r}(o,{moveFocus:function(e,t){i.changeActive(i.selectedHint+e,t)},setFocus:function(e){i.changeActive(e)},menuSize:function(){return i.screenAmount()},length:c.length,close:function(){o.close()},pick:function(){i.pick()},data:r})),o.options.closeOnUnfocus&&(l.on("blur",this.onBlur=function(){L=setTimeout(function(){o.close()},100)}),l.on("focus",this.onFocus=function(){clearTimeout(L)})),l.on("scroll",this.onScroll=function(){var e=l.getScrollInfo(),t=l.getWrapperElement().getBoundingClientRect(),n=v+k.top-e.top,r=n-(window.pageYOffset||(document.documentElement||document.body).scrollTop);if(y||(r+=u.offsetHeight),r<=t.top||r>=t.bottom)return o.close();u.style.top=n+"px",u.style.left=g+k.left-e.left+"px"}),e.on(u,"dblclick",function(e){var t=s(u,e.target||e.srcElement);t&&null!=t.hintId&&(i.changeActive(t.hintId),i.pick())}),e.on(u,"click",function(e){var t=s(u,e.target||e.srcElement);t&&null!=t.hintId&&(i.changeActive(t.hintId),o.options.completeOnSingleClick&&i.pick())}),e.on(u,"mousedown",function(){setTimeout(function(){l.focus()},20)}),e.signal(r,"select",c[this.selectedHint],u.childNodes[this.selectedHint]),!0}function u(e,t,n,o){if(e.async)e(t,o,n);else{var r=e(t,n);r&&r.then?r.then(o):o(r)}}o.prototype={close:function(){this.active()&&(this.cm.state.completionActive=null,this.tick=null,this.cm.off("cursorActivity",this.activityFunc),this.widget&&this.data&&e.signal(this.data,"close"),this.widget&&this.widget.close(),e.signal(this.cm,"endCompletion",this.cm))},active:function(){return this.cm.state.completionActive==this},pick:function(t,n){var o=t.list[n];o.hint?o.hint(this.cm,t,o):this.cm.replaceRange(a(o),o.from||t.from,o.to||t.to,"complete"),e.signal(t,"pick",o),this.close()},cursorActivity:function(){this.debounce&&(i(this.debounce),this.debounce=0);var e=this.cm.getCursor(),t=this.cm.getLine(e.line);if(e.line!=this.startPos.line||t.length-e.ch!=this.startLen-this.startPos.ch||e.ch<this.startPos.ch||this.cm.somethingSelected()||e.ch&&this.options.closeCharacters.test(t.charAt(e.ch-1)))this.close();else{var n=this;this.debounce=r(function(){n.update()}),this.widget&&this.widget.disable()}},update:function(e){if(null!=this.tick){var t=this,n=++this.tick;u(this.options.hint,this.cm,this.options,function(o){t.tick==n&&t.finishUpdate(o,e)})}},finishUpdate:function(t,n){this.data&&e.signal(this.data,"update");var o=this.widget&&this.widget.picked||n&&this.options.completeSingle;this.widget&&this.widget.close(),this.data=t,t&&t.list.length&&(o&&1==t.list.length?this.pick(t,0):(this.widget=new l(this,t),e.signal(t,"shown")))}},l.prototype={close:function(){if(this.completion.widget==this){this.completion.widget=null,this.hints.parentNode.removeChild(this.hints),this.completion.cm.removeKeyMap(this.keyMap);var e=this.completion.cm;this.completion.options.closeOnUnfocus&&(e.off("blur",this.onBlur),e.off("focus",this.onFocus)),e.off("scroll",this.onScroll)}},disable:function(){this.completion.cm.removeKeyMap(this.keyMap);var e=this;this.keyMap={Enter:function(){e.picked=!0}},this.completion.cm.addKeyMap(this.keyMap)},pick:function(){this.completion.pick(this.data,this.selectedHint)},changeActive:function(t,o){if(t>=this.data.list.length?t=o?this.data.list.length-1:0:t<0&&(t=o?0:this.data.list.length-1),this.selectedHint!=t){var r=this.hints.childNodes[this.selectedHint];r.className=r.className.replace(" "+n,""),(r=this.hints.childNodes[this.selectedHint=t]).className+=" "+n,r.offsetTop<this.hints.scrollTop?this.hints.scrollTop=r.offsetTop-3:r.offsetTop+r.offsetHeight>this.hints.scrollTop+this.hints.clientHeight&&(this.hints.scrollTop=r.offsetTop+r.offsetHeight-this.hints.clientHeight+3),e.signal(this.data,"select",this.data.list[this.selectedHint],r)}},screenAmount:function(){return Math.floor(this.hints.clientHeight/this.hints.firstChild.offsetHeight)||1}},e.registerHelper("hint","auto",{resolve:function(t,n){var o,r=t.getHelpers(n,"hint");if(r.length){var i=function(e,t,n){var o=function(e,t){if(!e.somethingSelected())return t;for(var n=[],o=0;o<t.length;o++)t[o].supportsSelection&&n.push(t[o]);return n}(e,r);!function r(i){if(i==o.length)return t(null);u(o[i],e,n,function(e){e&&e.list.length>0?t(e):r(i+1)})}(0)};return i.async=!0,i.supportsSelection=!0,i}return(o=t.getHelper(t.getCursor(),"hintWords"))?function(t){return e.hint.fromList(t,{words:o})}:e.hint.anyword?function(t,n){return e.hint.anyword(t,n)}:function(){}}}),e.registerHelper("hint","fromList",function(t,n){var o,r=t.getCursor(),i=t.getTokenAt(r),a=e.Pos(r.line,i.start),s=r;i.start<r.ch&&/\w/.test(i.string.charAt(r.ch-i.start-1))?o=i.string.substr(0,r.ch-i.start):(o="",a=r);for(var l=[],u=0;u<n.words.length;u++){var c=n.words[u];c.slice(0,o.length)==o&&l.push(c)}if(l.length)return{list:l,from:a,to:s}}),e.commands.autocomplete=e.showHint;var c={hint:e.hint.auto,completeSingle:!0,alignWithWord:!0,closeCharacters:/[\s()\[\]{};:>,]/,closeOnUnfocus:!0,completeOnSingleClick:!0,container:null,customKeys:null,extraKeys:null};e.defineOption("hintOptions",null)}(n(16))},function(e,t,n){!function(e){"use strict";var t="CodeMirror-lint-markers";function n(e){e.parentNode&&e.parentNode.removeChild(e)}function o(t,o,r){var i=function(t,n){var o=document.createElement("div");function r(t){if(!o.parentNode)return e.off(document,"mousemove",r);o.style.top=Math.max(0,t.clientY-o.offsetHeight-5)+"px",o.style.left=t.clientX+5+"px"}return o.className="CodeMirror-lint-tooltip",o.appendChild(n.cloneNode(!0)),document.body.appendChild(o),e.on(document,"mousemove",r),r(t),null!=o.style.opacity&&(o.style.opacity=1),o}(t,o);function a(){var t;e.off(r,"mouseout",a),i&&((t=i).parentNode&&(null==t.style.opacity&&n(t),t.style.opacity=0,setTimeout(function(){n(t)},600)),i=null)}var s=setInterval(function(){if(i)for(var e=r;;e=e.parentNode){if(e&&11==e.nodeType&&(e=e.host),e==document.body)return;if(!e){a();break}}if(!i)return clearInterval(s)},400);e.on(r,"mouseout",a)}function r(e,t,n){this.marked=[],this.options=t,this.timeout=null,this.hasGutter=n,this.onMouseOver=function(t){!function(e,t){var n=t.target||t.srcElement;if(/\bCodeMirror-lint-mark-/.test(n.className)){for(var r=n.getBoundingClientRect(),i=(r.left+r.right)/2,a=(r.top+r.bottom)/2,l=e.findMarksAt(e.coordsChar({left:i,top:a},"client")),u=[],c=0;c<l.length;++c){var d=l[c].__annotation;d&&u.push(d)}u.length&&function(e,t){for(var n=t.target||t.srcElement,r=document.createDocumentFragment(),i=0;i<e.length;i++){var a=e[i];r.appendChild(s(a))}o(t,r,n)}(u,t)}}(e,t)},this.waitingFor=0}function i(e){var n=e.state.lint;n.hasGutter&&e.clearGutter(t);for(var o=0;o<n.marked.length;++o)n.marked[o].clear();n.marked.length=0}function a(t,n,r,i){var a=document.createElement("div"),s=a;return a.className="CodeMirror-lint-marker-"+n,r&&((s=a.appendChild(document.createElement("div"))).className="CodeMirror-lint-marker-multiple"),0!=i&&e.on(s,"mouseover",function(e){o(e,t,s)}),a}function s(e){var t=e.severity;t||(t="error");var n=document.createElement("div");return n.className="CodeMirror-lint-message-"+t,void 0!==e.messageHTML?n.innerHTML=e.messageHTML:n.appendChild(document.createTextNode(e.message)),n}function l(t){var n=t.state.lint.options,o=n.options||n,r=n.getAnnotations||t.getHelper(e.Pos(0,0),"lint");if(r)if(n.async||r.async)!function(t,n,o){var r=t.state.lint,i=++r.waitingFor;function a(){i=-1,t.off("change",a)}t.on("change",a),n(t.getValue(),function(n,o){t.off("change",a),r.waitingFor==i&&(o&&n instanceof e&&(n=o),t.operation(function(){u(t,n)}))},o,t)}(t,r,o);else{var i=r(t.getValue(),o,t);if(!i)return;i.then?i.then(function(e){t.operation(function(){u(t,e)})}):t.operation(function(){u(t,i)})}}function u(e,n){i(e);for(var o,r,l=e.state.lint,u=l.options,c=function(e){for(var t=[],n=0;n<e.length;++n){var o=e[n],r=o.from.line;(t[r]||(t[r]=[])).push(o)}return t}(n),d=0;d<c.length;++d){var h=c[d];if(h){for(var f=null,p=l.hasGutter&&document.createDocumentFragment(),m=0;m<h.length;++m){var g=h[m],v=g.severity;v||(v="error"),r=v,f="error"==(o=f)?o:r,u.formatAnnotation&&(g=u.formatAnnotation(g)),l.hasGutter&&p.appendChild(s(g)),g.to&&l.marked.push(e.markText(g.from,g.to,{className:"CodeMirror-lint-mark-"+v,__annotation:g}))}l.hasGutter&&e.setGutterMarker(d,t,a(p,f,h.length>1,l.options.tooltips))}}u.onUpdateLinting&&u.onUpdateLinting(n,c,e)}function c(e){var t=e.state.lint;t&&(clearTimeout(t.timeout),t.timeout=setTimeout(function(){l(e)},t.options.delay||500))}e.defineOption("lint",!1,function(n,o,a){if(a&&a!=e.Init&&(i(n),!1!==n.state.lint.options.lintOnChange&&n.off("change",c),e.off(n.getWrapperElement(),"mouseover",n.state.lint.onMouseOver),clearTimeout(n.state.lint.timeout),delete n.state.lint),o){for(var s=n.getOption("gutters"),u=!1,d=0;d<s.length;++d)s[d]==t&&(u=!0);var h=n.state.lint=new r(n,(f=o)instanceof Function?{getAnnotations:f}:(f&&!0!==f||(f={}),f),u);!1!==h.options.lintOnChange&&n.on("change",c),0!=h.options.tooltips&&"gutter"!=h.options.tooltips&&e.on(n.getWrapperElement(),"mouseover",h.onMouseOver),l(n)}var f}),e.defineExtension("performLint",function(){this.state.lint&&l(this)})}(n(16))},,,,,,,,,,,,,,,,,,,,,function(e,t,n){var o=n(361)();o.helpers=n(6),n(365)(o),o.defaults=n(8),o.Element=n(17),o.elements=n(21),o.Interaction=n(67),o.layouts=n(27),o.platform=n(68),o.plugins=n(69),o.Ticks=n(28),n(376)(o),n(377)(o),n(378)(o),n(379)(o),n(380)(o),n(381)(o),n(382)(o),n(383)(o),n(384)(o),n(385)(o),n(386)(o),n(387)(o),n(389)(o),n(390)(o),n(391)(o),n(392)(o),n(393)(o),n(394)(o),n(395)(o),n(396)(o),n(397)(o),n(398)(o),n(399)(o),n(400)(o),n(401)(o),n(402)(o);var r=n(403);for(var i in r)r.hasOwnProperty(i)&&o.plugins.register(r[i]);o.platform.initialize(),e.exports=o,"undefined"!=typeof window&&(window.Chart=o),o.Legend=r.legend._element,o.Title=r.title._element,o.pluginService=o.plugins,o.PluginBase=o.Element.extend({}),o.canvasHelpers=o.helpers.canvas,o.layoutService=o.layouts},,,function(e,t,n){"use strict";var o=n(6);function r(e,t){return e.native?{x:e.x,y:e.y}:o.getRelativePosition(e,t)}function i(e,t){var n,o,r,i,a;for(o=0,i=e.data.datasets.length;o<i;++o)if(e.isDatasetVisible(o))for(r=0,a=(n=e.getDatasetMeta(o)).data.length;r<a;++r){var s=n.data[r];s._view.skip||t(s)}}function a(e,t){var n=[];return i(e,function(e){e.inRange(t.x,t.y)&&n.push(e)}),n}function s(e,t,n,o){var r=Number.POSITIVE_INFINITY,a=[];return i(e,function(e){if(!n||e.inRange(t.x,t.y)){var i=e.getCenterPoint(),s=o(t,i);s<r?(a=[e],r=s):s===r&&a.push(e)}}),a}function l(e){var t=-1!==e.indexOf("x"),n=-1!==e.indexOf("y");return function(e,o){var r=t?Math.abs(e.x-o.x):0,i=n?Math.abs(e.y-o.y):0;return Math.sqrt(Math.pow(r,2)+Math.pow(i,2))}}function u(e,t,n){var o=r(t,e);n.axis=n.axis||"x";var i=l(n.axis),u=n.intersect?a(e,o):s(e,o,!1,i),c=[];return u.length?(e.data.datasets.forEach(function(t,n){if(e.isDatasetVisible(n)){var o=e.getDatasetMeta(n).data[u[0]._index];o&&!o._view.skip&&c.push(o)}}),c):[]}e.exports={modes:{single:function(e,t){var n=r(t,e),o=[];return i(e,function(e){if(e.inRange(n.x,n.y))return o.push(e),o}),o.slice(0,1)},label:u,index:u,dataset:function(e,t,n){var o=r(t,e);n.axis=n.axis||"xy";var i=l(n.axis),u=n.intersect?a(e,o):s(e,o,!1,i);return u.length>0&&(u=e.getDatasetMeta(u[0]._datasetIndex).data),u},"x-axis":function(e,t){return u(e,t,{intersect:!1})},point:function(e,t){return a(e,r(t,e))},nearest:function(e,t,n){var o=r(t,e);n.axis=n.axis||"xy";var i=l(n.axis),a=s(e,o,n.intersect,i);return a.length>1&&a.sort(function(e,t){var n=e.getArea()-t.getArea();return 0===n&&(n=e._datasetIndex-t._datasetIndex),n}),a.slice(0,1)},x:function(e,t,n){var o=r(t,e),a=[],s=!1;return i(e,function(e){e.inXRange(o.x)&&a.push(e),e.inRange(o.x,o.y)&&(s=!0)}),n.intersect&&!s&&(a=[]),a},y:function(e,t,n){var o=r(t,e),a=[],s=!1;return i(e,function(e){e.inYRange(o.y)&&a.push(e),e.inRange(o.x,o.y)&&(s=!0)}),n.intersect&&!s&&(a=[]),a}}}},function(e,t,n){"use strict";var o=n(6),r=n(374),i=n(375),a=i._enabled?i:r;e.exports=o.extend({initialize:function(){},acquireContext:function(){},releaseContext:function(){},addEventListener:function(){},removeEventListener:function(){}},a)},function(e,t,n){"use strict";var o=n(8),r=n(6);o._set("global",{plugins:{}}),e.exports={_plugins:[],_cacheId:0,register:function(e){var t=this._plugins;[].concat(e).forEach(function(e){-1===t.indexOf(e)&&t.push(e)}),this._cacheId++},unregister:function(e){var t=this._plugins;[].concat(e).forEach(function(e){var n=t.indexOf(e);-1!==n&&t.splice(n,1)}),this._cacheId++},clear:function(){this._plugins=[],this._cacheId++},count:function(){return this._plugins.length},getAll:function(){return this._plugins},notify:function(e,t,n){var o,r,i,a,s,l=this.descriptors(e),u=l.length;for(o=0;o<u;++o)if("function"==typeof(s=(i=(r=l[o]).plugin)[t])&&((a=[e].concat(n||[])).push(r.options),!1===s.apply(i,a)))return!1;return!0},descriptors:function(e){var t=e.$plugins||(e.$plugins={});if(t.id===this._cacheId)return t.descriptors;var n=[],i=[],a=e&&e.config||{},s=a.options&&a.options.plugins||{};return this._plugins.concat(a.plugins||[]).forEach(function(e){if(-1===n.indexOf(e)){var t=e.id,a=s[t];!1!==a&&(!0===a&&(a=r.clone(o.global.plugins[t])),n.push(e),i.push({plugin:e,options:a||{}}))}}),t.descriptors=i,t.id=this._cacheId,i},_invalidate:function(e){delete e.$plugins}}},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){!function(e){"use strict";e.defineLocale("af",{months:"Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des".split("_"),weekdays:"Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag".split("_"),weekdaysShort:"Son_Maa_Din_Woe_Don_Vry_Sat".split("_"),weekdaysMin:"So_Ma_Di_Wo_Do_Vr_Sa".split("_"),meridiemParse:/vm|nm/i,isPM:function(e){return/^nm$/i.test(e)},meridiem:function(e,t,n){return e<12?n?"vm":"VM":n?"nm":"NM"},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:"[Vandag om] LT",nextDay:"[Môre om] LT",nextWeek:"dddd [om] LT",lastDay:"[Gister om] LT",lastWeek:"[Laas] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oor %s",past:"%s gelede",s:"'n paar sekondes",m:"'n minuut",mm:"%d minute",h:"'n uur",hh:"%d ure",d:"'n dag",dd:"%d dae",M:"'n maand",MM:"%d maande",y:"'n jaar",yy:"%d jaar"},ordinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"},o=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5},r={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},i=function(e){return function(t,n,i,a){var s=o(t),l=r[e][o(t)];return 2===s&&(l=l[n?0:1]),l.replace(/%d/i,t)}},a=["كانون الثاني يناير","شباط فبراير","آذار مارس","نيسان أبريل","أيار مايو","حزيران يونيو","تموز يوليو","آب أغسطس","أيلول سبتمبر","تشرين الأول أكتوبر","تشرين الثاني نوفمبر","كانون الأول ديسمبر"];e.defineLocale("ar",{months:a,monthsShort:a,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/‏M/‏YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:i("s"),m:i("m"),mm:i("m"),h:i("h"),hh:i("h"),d:i("d"),dd:i("d"),M:i("M"),MM:i("M"),y:i("y"),yy:i("y")},preparse:function(e){return e.replace(/\u200f/g,"").replace(/[١٢٣٤٥٦٧٨٩٠]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ar-ma",{months:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),weekdays:"الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".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:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:6,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"};e.defineLocale("ar-sa",{months:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".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"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ar-tn",{months:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".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:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"-inci",5:"-inci",8:"-inci",70:"-inci",80:"-inci",2:"-nci",7:"-nci",20:"-nci",50:"-nci",3:"-üncü",4:"-üncü",100:"-üncü",6:"-ncı",9:"-uncu",10:"-uncu",30:"-uncu",60:"-ıncı",90:"-ıncı"};e.defineLocale("az",{months:"yanvar_fevral_mart_aprel_may_iyun_iyul_avqust_sentyabr_oktyabr_noyabr_dekabr".split("_"),monthsShort:"yan_fev_mar_apr_may_iyn_iyl_avq_sen_okt_noy_dek".split("_"),weekdays:"Bazar_Bazar ertəsi_Çərşənbə axşamı_Çərşənbə_Cümə axşamı_Cümə_Şənbə".split("_"),weekdaysShort:"Baz_BzE_ÇAx_Çər_CAx_Cüm_Şən".split("_"),weekdaysMin:"Bz_BE_ÇA_Çə_CA_Cü_Şə".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:"[bugün saat] LT",nextDay:"[sabah saat] LT",nextWeek:"[gələn həftə] dddd [saat] LT",lastDay:"[dünən] LT",lastWeek:"[keçən həftə] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s əvvəl",s:"birneçə saniyyə",m:"bir dəqiqə",mm:"%d dəqiqə",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir il",yy:"%d il"},meridiemParse:/gecə|səhər|gündüz|axşam/,isPM:function(e){return/^(gündüz|axşam)$/.test(e)},meridiem:function(e,t,n){return e<4?"gecə":e<12?"səhər":e<17?"gündüz":"axşam"},ordinalParse:/\d{1,2}-(ıncı|inci|nci|üncü|ncı|uncu)/,ordinal:function(e){if(0===e)return e+"-ıncı";var n=e%10;return e+(t[n]||t[e%100-n]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var o,r;return"m"===n?t?"хвіліна":"хвіліну":"h"===n?t?"гадзіна":"гадзіну":e+" "+(o=+e,r={mm:t?"хвіліна_хвіліны_хвілін":"хвіліну_хвіліны_хвілін",hh:t?"гадзіна_гадзіны_гадзін":"гадзіну_гадзіны_гадзін",dd:"дзень_дні_дзён",MM:"месяц_месяцы_месяцаў",yy:"год_гады_гадоў"}[n].split("_"),o%10==1&&o%100!=11?r[0]:o%10>=2&&o%10<=4&&(o%100<10||o%100>=20)?r[1]:r[2])}e.defineLocale("be",{months:{format:"студзеня_лютага_сакавіка_красавіка_траўня_чэрвеня_ліпеня_жніўня_верасня_кастрычніка_лістапада_снежня".split("_"),standalone:"студзень_люты_сакавік_красавік_травень_чэрвень_ліпень_жнівень_верасень_кастрычнік_лістапад_снежань".split("_")},monthsShort:"студ_лют_сак_крас_трав_чэрв_ліп_жнів_вер_каст_ліст_снеж".split("_"),weekdays:{format:"нядзелю_панядзелак_аўторак_сераду_чацвер_пятніцу_суботу".split("_"),standalone:"нядзеля_панядзелак_аўторак_серада_чацвер_пятніца_субота".split("_"),isFormat:/\[ ?[Вв] ?(?:мінулую|наступную)? ?\] ?dddd/},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:"[Сёння ў] LT",nextDay:"[Заўтра ў] LT",lastDay:"[Учора ў] LT",nextWeek:function(){return"[У] dddd [ў] LT"},lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return"[У мінулую] dddd [ў] LT";case 1:case 2:case 4:return"[У мінулы] dddd [ў] LT"}},sameElse:"L"},relativeTime:{future:"праз %s",past:"%s таму",s:"некалькі секунд",m:t,mm:t,h:t,hh:t,d:"дзень",dd:t,M:"месяц",MM:t,y:"год",yy:t},meridiemParse:/ночы|раніцы|дня|вечара/,isPM:function(e){return/^(дня|вечара)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночы":e<12?"раніцы":e<17?"дня":"вечара"},ordinalParse:/\d{1,2}-(і|ы|га)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e%10!=2&&e%10!=3||e%100==12||e%100==13?e+"-ы":e+"-і";case"D":return e+"-га";default:return e}},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("bg",{months:"януари_февруари_март_април_май_юни_юли_август_септември_октомври_ноември_декември".split("_"),monthsShort:"янр_фев_мар_апр_май_юни_юли_авг_сеп_окт_ное_дек".split("_"),weekdays:"неделя_понеделник_вторник_сряда_четвъртък_петък_събота".split("_"),weekdaysShort:"нед_пон_вто_сря_чет_пет_съб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[Днес в] LT",nextDay:"[Утре в] LT",nextWeek:"dddd [в] LT",lastDay:"[Вчера в] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[В изминалата] dddd [в] LT";case 1:case 2:case 4:case 5:return"[В изминалия] dddd [в] LT"}},sameElse:"L"},relativeTime:{future:"след %s",past:"преди %s",s:"няколко секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дни",M:"месец",MM:"%d месеца",y:"година",yy:"%d години"},ordinalParse:/\d{1,2}-(ев|ен|ти|ви|ри|ми)/,ordinal:function(e){var t=e%10,n=e%100;return 0===e?e+"-ев":0===n?e+"-ен":n>10&&n<20?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"১",2:"২",3:"৩",4:"৪",5:"৫",6:"৬",7:"৭",8:"৮",9:"৯",0:"০"},n={"১":"1","২":"2","৩":"3","৪":"4","৫":"5","৬":"6","৭":"7","৮":"8","৯":"9","০":"0"};e.defineLocale("bn",{months:"জানুয়ারী_ফেবুয়ারী_মার্চ_এপ্রিল_মে_জুন_জুলাই_অগাস্ট_সেপ্টেম্বর_অক্টোবর_নভেম্বর_ডিসেম্বর".split("_"),monthsShort:"জানু_ফেব_মার্চ_এপর_মে_জুন_জুল_অগ_সেপ্ট_অক্টো_নভ_ডিসেম্".split("_"),weekdays:"রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পত্তিবার_শুক্রবার_শনিবার".split("_"),weekdaysShort:"রবি_সোম_মঙ্গল_বুধ_বৃহস্পত্তি_শুক্র_শনি".split("_"),weekdaysMin:"রব_সম_মঙ্গ_বু_ব্রিহ_শু_শনি".split("_"),longDateFormat:{LT:"A h:mm সময়",LTS:"A h:mm:ss সময়",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm সময়",LLLL:"dddd, D MMMM YYYY, A h:mm সময়"},calendar:{sameDay:"[আজ] LT",nextDay:"[আগামীকাল] LT",nextWeek:"dddd, LT",lastDay:"[গতকাল] LT",lastWeek:"[গত] dddd, LT",sameElse:"L"},relativeTime:{future:"%s পরে",past:"%s আগে",s:"কয়েক সেকেন্ড",m:"এক মিনিট",mm:"%d মিনিট",h:"এক ঘন্টা",hh:"%d ঘন্টা",d:"এক দিন",dd:"%d দিন",M:"এক মাস",MM:"%d মাস",y:"এক বছর",yy:"%d বছর"},preparse:function(e){return e.replace(/[১২৩৪৫৬৭৮৯০]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/রাত|সকাল|দুপুর|বিকাল|রাত/,meridiemHour:function(e,t){return 12===e&&(e=0),"রাত"===t&&e>=4||"দুপুর"===t&&e<5||"বিকাল"===t?e+12:e},meridiem:function(e,t,n){return e<4?"রাত":e<10?"সকাল":e<17?"দুপুর":e<20?"বিকাল":"রাত"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"༡",2:"༢",3:"༣",4:"༤",5:"༥",6:"༦",7:"༧",8:"༨",9:"༩",0:"༠"},n={"༡":"1","༢":"2","༣":"3","༤":"4","༥":"5","༦":"6","༧":"7","༨":"8","༩":"9","༠":"0"};e.defineLocale("bo",{months:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),monthsShort:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),weekdays:"གཟའ་ཉི་མ་_གཟའ་ཟླ་བ་_གཟའ་མིག་དམར་_གཟའ་ལྷག་པ་_གཟའ་ཕུར་བུ_གཟའ་པ་སངས་_གཟའ་སྤེན་པ་".split("_"),weekdaysShort:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),weekdaysMin:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[དི་རིང] LT",nextDay:"[སང་ཉིན] LT",nextWeek:"[བདུན་ཕྲག་རྗེས་མ], LT",lastDay:"[ཁ་སང] LT",lastWeek:"[བདུན་ཕྲག་མཐའ་མ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ལ་",past:"%s སྔན་ལ",s:"ལམ་སང",m:"སྐར་མ་གཅིག",mm:"%d སྐར་མ",h:"ཆུ་ཚོད་གཅིག",hh:"%d ཆུ་ཚོད",d:"ཉིན་གཅིག",dd:"%d ཉིན་",M:"ཟླ་བ་གཅིག",MM:"%d ཟླ་བ",y:"ལོ་གཅིག",yy:"%d ལོ"},preparse:function(e){return e.replace(/[༡༢༣༤༥༦༧༨༩༠]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/མཚན་མོ|ཞོགས་ཀས|ཉིན་གུང|དགོང་དག|མཚན་མོ/,meridiemHour:function(e,t){return 12===e&&(e=0),"མཚན་མོ"===t&&e>=4||"ཉིན་གུང"===t&&e<5||"དགོང་དག"===t?e+12:e},meridiem:function(e,t,n){return e<4?"མཚན་མོ":e<10?"ཞོགས་ཀས":e<17?"ཉིན་གུང":e<20?"དགོང་དག":"མཚན་མོ"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){return e+" "+function(e,t){return 2===t?function(e){var t={m:"v",b:"v",d:"z"};return void 0===t[e.charAt(0)]?e:t[e.charAt(0)]+e.substring(1)}(e):e}({mm:"munutenn",MM:"miz",dd:"devezh"}[n],e)}e.defineLocale("br",{months:"Genver_C'hwevrer_Meurzh_Ebrel_Mae_Mezheven_Gouere_Eost_Gwengolo_Here_Du_Kerzu".split("_"),monthsShort:"Gen_C'hwe_Meu_Ebr_Mae_Eve_Gou_Eos_Gwe_Her_Du_Ker".split("_"),weekdays:"Sul_Lun_Meurzh_Merc'her_Yaou_Gwener_Sadorn".split("_"),weekdaysShort:"Sul_Lun_Meu_Mer_Yao_Gwe_Sad".split("_"),weekdaysMin:"Su_Lu_Me_Mer_Ya_Gw_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h[e]mm A",LTS:"h[e]mm:ss A",L:"DD/MM/YYYY",LL:"D [a viz] MMMM YYYY",LLL:"D [a viz] MMMM YYYY h[e]mm A",LLLL:"dddd, D [a viz] MMMM YYYY h[e]mm A"},calendar:{sameDay:"[Hiziv da] LT",nextDay:"[Warc'hoazh da] LT",nextWeek:"dddd [da] LT",lastDay:"[Dec'h da] LT",lastWeek:"dddd [paset da] LT",sameElse:"L"},relativeTime:{future:"a-benn %s",past:"%s 'zo",s:"un nebeud segondennoù",m:"ur vunutenn",mm:t,h:"un eur",hh:"%d eur",d:"un devezh",dd:t,M:"ur miz",MM:t,y:"ur bloaz",yy:function(e){switch(function e(t){return t>9?e(t%10):t}(e)){case 1:case 3:case 4:case 5:case 9:return e+" bloaz";default:return e+" vloaz"}}},ordinalParse:/\d{1,2}(añ|vet)/,ordinal:function(e){return e+(1===e?"añ":"vet")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var o=e+" ";switch(n){case"m":return t?"jedna minuta":"jedne minute";case"mm":return o+=1===e?"minuta":2===e||3===e||4===e?"minute":"minuta";case"h":return t?"jedan sat":"jednog sata";case"hh":return o+=1===e?"sat":2===e||3===e||4===e?"sata":"sati";case"dd":return o+=1===e?"dan":"dana";case"MM":return o+=1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci";case"yy":return o+=1===e?"godina":2===e||3===e||4===e?"godine":"godina"}}e.defineLocale("bs",{months:"januar_februar_mart_april_maj_juni_juli_august_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._aug._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,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:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ca",{months:"gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre".split("_"),monthsShort:"gen._febr._mar._abr._mai._jun._jul._ag._set._oct._nov._des.".split("_"),monthsParseExact:!0,weekdays:"diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte".split("_"),weekdaysShort:"dg._dl._dt._dc._dj._dv._ds.".split("_"),weekdaysMin:"Dg_Dl_Dt_Dc_Dj_Dv_Ds".split("_"),weekdaysParseExact:!0,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:function(){return"[avui a "+(1!==this.hours()?"les":"la")+"] LT"},nextDay:function(){return"[demà a "+(1!==this.hours()?"les":"la")+"] LT"},nextWeek:function(){return"dddd [a "+(1!==this.hours()?"les":"la")+"] LT"},lastDay:function(){return"[ahir a "+(1!==this.hours()?"les":"la")+"] LT"},lastWeek:function(){return"[el] dddd [passat a "+(1!==this.hours()?"les":"la")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"fa %s",s:"uns segons",m:"un minut",mm:"%d minuts",h:"una hora",hh:"%d hores",d:"un dia",dd:"%d dies",M:"un mes",MM:"%d mesos",y:"un any",yy:"%d anys"},ordinalParse:/\d{1,2}(r|n|t|è|a)/,ordinal:function(e,t){var n=1===e?"r":2===e?"n":3===e?"r":4===e?"t":"è";return"w"!==t&&"W"!==t||(n="a"),e+n},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="leden_únor_březen_duben_květen_červen_červenec_srpen_září_říjen_listopad_prosinec".split("_"),n="led_úno_bře_dub_kvě_čvn_čvc_srp_zář_říj_lis_pro".split("_");function o(e){return e>1&&e<5&&1!=~~(e/10)}function r(e,t,n,r){var i=e+" ";switch(n){case"s":return t||r?"pár sekund":"pár sekundami";case"m":return t?"minuta":r?"minutu":"minutou";case"mm":return t||r?i+(o(e)?"minuty":"minut"):i+"minutami";case"h":return t?"hodina":r?"hodinu":"hodinou";case"hh":return t||r?i+(o(e)?"hodiny":"hodin"):i+"hodinami";case"d":return t||r?"den":"dnem";case"dd":return t||r?i+(o(e)?"dny":"dní"):i+"dny";case"M":return t||r?"měsíc":"měsícem";case"MM":return t||r?i+(o(e)?"měsíce":"měsíců"):i+"měsíci";case"y":return t||r?"rok":"rokem";case"yy":return t||r?i+(o(e)?"roky":"let"):i+"lety"}}e.defineLocale("cs",{months:t,monthsShort:n,monthsParse:function(e,t){var n,o=[];for(n=0;n<12;n++)o[n]=new RegExp("^"+e[n]+"$|^"+t[n]+"$","i");return o}(t,n),shortMonthsParse:function(e){var t,n=[];for(t=0;t<12;t++)n[t]=new RegExp("^"+e[t]+"$","i");return n}(n),longMonthsParse:function(e){var t,n=[];for(t=0;t<12;t++)n[t]=new RegExp("^"+e[t]+"$","i");return n}(t),weekdays:"neděle_pondělí_úterý_středa_čtvrtek_pátek_sobota".split("_"),weekdaysShort:"ne_po_út_st_čt_pá_so".split("_"),weekdaysMin:"ne_po_út_st_čt_pá_so".split("_"),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:"[dnes v] LT",nextDay:"[zítra v] LT",nextWeek:function(){switch(this.day()){case 0:return"[v neděli v] LT";case 1:case 2:return"[v] dddd [v] LT";case 3:return"[ve středu v] LT";case 4:return"[ve čtvrtek v] LT";case 5:return"[v pátek v] LT";case 6:return"[v sobotu v] LT"}},lastDay:"[včera v] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulou neděli v] LT";case 1:case 2:return"[minulé] dddd [v] LT";case 3:return"[minulou středu v] LT";case 4:case 5:return"[minulý] dddd [v] LT";case 6:return"[minulou sobotu v] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"před %s",s:r,m:r,mm:r,h:r,hh:r,d:r,dd:r,M:r,MM:r,y:r,yy:r},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("cv",{months:"кӑрлач_нарӑс_пуш_ака_май_ҫӗртме_утӑ_ҫурла_авӑн_юпа_чӳк_раштав".split("_"),monthsShort:"кӑр_нар_пуш_ака_май_ҫӗр_утӑ_ҫур_авн_юпа_чӳк_раш".split("_"),weekdays:"вырсарникун_тунтикун_ытларикун_юнкун_кӗҫнерникун_эрнекун_шӑматкун".split("_"),weekdaysShort:"выр_тун_ытл_юн_кӗҫ_эрн_шӑм".split("_"),weekdaysMin:"вр_тн_ыт_юн_кҫ_эр_шм".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ]",LLL:"YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm",LLLL:"dddd, YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm"},calendar:{sameDay:"[Паян] LT [сехетре]",nextDay:"[Ыран] LT [сехетре]",lastDay:"[Ӗнер] LT [сехетре]",nextWeek:"[Ҫитес] dddd LT [сехетре]",lastWeek:"[Иртнӗ] dddd LT [сехетре]",sameElse:"L"},relativeTime:{future:function(e){return e+(/сехет$/i.exec(e)?"рен":/ҫул$/i.exec(e)?"тан":"ран")},past:"%s каялла",s:"пӗр-ик ҫеккунт",m:"пӗр минут",mm:"%d минут",h:"пӗр сехет",hh:"%d сехет",d:"пӗр кун",dd:"%d кун",M:"пӗр уйӑх",MM:"%d уйӑх",y:"пӗр ҫул",yy:"%d ҫул"},ordinalParse:/\d{1,2}-мӗш/,ordinal:"%d-мӗш",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("cy",{months:"Ionawr_Chwefror_Mawrth_Ebrill_Mai_Mehefin_Gorffennaf_Awst_Medi_Hydref_Tachwedd_Rhagfyr".split("_"),monthsShort:"Ion_Chwe_Maw_Ebr_Mai_Meh_Gor_Aws_Med_Hyd_Tach_Rhag".split("_"),weekdays:"Dydd Sul_Dydd Llun_Dydd Mawrth_Dydd Mercher_Dydd Iau_Dydd Gwener_Dydd Sadwrn".split("_"),weekdaysShort:"Sul_Llun_Maw_Mer_Iau_Gwe_Sad".split("_"),weekdaysMin:"Su_Ll_Ma_Me_Ia_Gw_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:"[Heddiw am] LT",nextDay:"[Yfory am] LT",nextWeek:"dddd [am] LT",lastDay:"[Ddoe am] LT",lastWeek:"dddd [diwethaf am] LT",sameElse:"L"},relativeTime:{future:"mewn %s",past:"%s yn ôl",s:"ychydig eiliadau",m:"munud",mm:"%d munud",h:"awr",hh:"%d awr",d:"diwrnod",dd:"%d diwrnod",M:"mis",MM:"%d mis",y:"blwyddyn",yy:"%d flynedd"},ordinalParse:/\d{1,2}(fed|ain|af|il|ydd|ed|eg)/,ordinal:function(e){var t="";return e>20?t=40===e||50===e||60===e||80===e||100===e?"fed":"ain":e>0&&(t=["","af","il","ydd","ydd","ed","ed","ed","fed","fed","fed","eg","fed","eg","eg","fed","eg","eg","fed","eg","fed"][e]),e+t},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("da",{months:"januar_februar_marts_april_maj_juni_juli_august_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"søn_man_tir_ons_tor_fre_lør".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".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.] D. MMMM YYYY HH:mm"},calendar:{sameDay:"[I dag kl.] LT",nextDay:"[I morgen kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[I går kl.] LT",lastWeek:"[sidste] dddd [kl] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"få sekunder",m:"et minut",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dage",M:"en måned",MM:"%d måneder",y:"et år",yy:"%d år"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n,o){var r={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?r[n][0]:r[n][1]}e.defineLocale("de",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Febr._Mrz._Apr._Mai_Jun._Jul._Aug._Sept._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",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n,o){var r={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?r[n][0]:r[n][1]}e.defineLocale("de-at",{months:"Jänner_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jän._Febr._Mrz._Apr._Mai_Jun._Jul._Aug._Sept._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",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t=["ޖެނުއަރީ","ފެބްރުއަރީ","މާރިޗު","އޭޕްރީލު","މޭ","ޖޫން","ޖުލައި","އޯގަސްޓު","ސެޕްޓެމްބަރު","އޮކްޓޯބަރު","ނޮވެމްބަރު","ޑިސެމްބަރު"],n=["އާދިއްތަ","ހޯމަ","އަންގާރަ","ބުދަ","ބުރާސްފަތި","ހުކުރު","ހޮނިހިރު"];e.defineLocale("dv",{months:t,monthsShort:t,weekdays:n,weekdaysShort:n,weekdaysMin:"އާދި_ހޯމަ_އަން_ބުދަ_ބުރާ_ހުކު_ހޮނި".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/M/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/މކ|މފ/,isPM:function(e){return"މފ"===e},meridiem:function(e,t,n){return e<12?"މކ":"މފ"},calendar:{sameDay:"[މިއަދު] LT",nextDay:"[މާދަމާ] LT",nextWeek:"dddd LT",lastDay:"[އިއްޔެ] LT",lastWeek:"[ފާއިތުވި] dddd LT",sameElse:"L"},relativeTime:{future:"ތެރޭގައި %s",past:"ކުރިން %s",s:"ސިކުންތުކޮޅެއް",m:"މިނިޓެއް",mm:"މިނިޓު %d",h:"ގަޑިއިރެއް",hh:"ގަޑިއިރު %d",d:"ދުވަހެއް",dd:"ދުވަސް %d",M:"މަހެއް",MM:"މަސް %d",y:"އަހަރެއް",yy:"އަހަރު %d"},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:7,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("el",{monthsNominativeEl:"Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος".split("_"),monthsGenitiveEl:"Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου".split("_"),months:function(e,t){return/D/.test(t.substring(0,t.indexOf("MMMM")))?this._monthsGenitiveEl[e.month()]:this._monthsNominativeEl[e.month()]},monthsShort:"Ιαν_Φεβ_Μαρ_Απρ_Μαϊ_Ιουν_Ιουλ_Αυγ_Σεπ_Οκτ_Νοε_Δεκ".split("_"),weekdays:"Κυριακή_Δευτέρα_Τρίτη_Τετάρτη_Πέμπτη_Παρασκευή_Σάββατο".split("_"),weekdaysShort:"Κυρ_Δευ_Τρι_Τετ_Πεμ_Παρ_Σαβ".split("_"),weekdaysMin:"Κυ_Δε_Τρ_Τε_Πε_Πα_Σα".split("_"),meridiem:function(e,t,n){return e>11?n?"μμ":"ΜΜ":n?"πμ":"ΠΜ"},isPM:function(e){return"μ"===(e+"").toLowerCase()[0]},meridiemParse:/[ΠΜ]\.?Μ?\.?/i,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendarEl:{sameDay:"[Σήμερα {}] LT",nextDay:"[Αύριο {}] LT",nextWeek:"dddd [{}] LT",lastDay:"[Χθες {}] LT",lastWeek:function(){switch(this.day()){case 6:return"[το προηγούμενο] dddd [{}] LT";default:return"[την προηγούμενη] dddd [{}] LT"}},sameElse:"L"},calendar:function(e,t){var n,o=this._calendarEl[e],r=t&&t.hours();return((n=o)instanceof Function||"[object Function]"===Object.prototype.toString.call(n))&&(o=o.apply(t)),o.replace("{}",r%12==1?"στη":"στις")},relativeTime:{future:"σε %s",past:"%s πριν",s:"λίγα δευτερόλεπτα",m:"ένα λεπτό",mm:"%d λεπτά",h:"μία ώρα",hh:"%d ώρες",d:"μία μέρα",dd:"%d μέρες",M:"ένας μήνας",MM:"%d μήνες",y:"ένας χρόνος",yy:"%d χρόνια"},ordinalParse:/\d{1,2}η/,ordinal:"%dη",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-au",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few 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"},ordinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-ca",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"YYYY-MM-DD",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few 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"},ordinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-gb",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_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:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few 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"},ordinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-ie",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_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:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few 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"},ordinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("en-nz",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few 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"},ordinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("eo",{months:"januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aŭg_sep_okt_nov_dec".split("_"),weekdays:"Dimanĉo_Lundo_Mardo_Merkredo_Ĵaŭdo_Vendredo_Sabato".split("_"),weekdaysShort:"Dim_Lun_Mard_Merk_Ĵaŭ_Ven_Sab".split("_"),weekdaysMin:"Di_Lu_Ma_Me_Ĵa_Ve_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D[-an de] MMMM, YYYY",LLL:"D[-an de] MMMM, YYYY HH:mm",LLLL:"dddd, [la] D[-an de] MMMM, YYYY HH:mm"},meridiemParse:/[ap]\.t\.m/i,isPM:function(e){return"p"===e.charAt(0).toLowerCase()},meridiem:function(e,t,n){return e>11?n?"p.t.m.":"P.T.M.":n?"a.t.m.":"A.T.M."},calendar:{sameDay:"[Hodiaŭ je] LT",nextDay:"[Morgaŭ je] LT",nextWeek:"dddd [je] LT",lastDay:"[Hieraŭ je] LT",lastWeek:"[pasinta] dddd [je] LT",sameElse:"L"},relativeTime:{future:"je %s",past:"antaŭ %s",s:"sekundoj",m:"minuto",mm:"%d minutoj",h:"horo",hh:"%d horoj",d:"tago",dd:"%d tagoj",M:"monato",MM:"%d monatoj",y:"jaro",yy:"%d jaroj"},ordinalParse:/\d{1,2}a/,ordinal:"%da",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_");e.defineLocale("es",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,o){return/-MMM-/.test(o)?n[e.month()]:t[e.month()]},monthsParseExact:!0,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",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"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n,o){var r={s:["mõne sekundi","mõni sekund","paar sekundit"],m:["ühe minuti","üks minut"],mm:[e+" minuti",e+" minutit"],h:["ühe tunni","tund aega","üks tund"],hh:[e+" tunni",e+" tundi"],d:["ühe päeva","üks päev"],M:["kuu aja","kuu aega","üks kuu"],MM:[e+" kuu",e+" kuud"],y:["ühe aasta","aasta","üks aasta"],yy:[e+" aasta",e+" aastat"]};return t?r[n][2]?r[n][2]:r[n][1]:o?r[n][0]:r[n][1]}e.defineLocale("et",{months:"jaanuar_veebruar_märts_aprill_mai_juuni_juuli_august_september_oktoober_november_detsember".split("_"),monthsShort:"jaan_veebr_märts_apr_mai_juuni_juuli_aug_sept_okt_nov_dets".split("_"),weekdays:"pühapäev_esmaspäev_teisipäev_kolmapäev_neljapäev_reede_laupäev".split("_"),weekdaysShort:"P_E_T_K_N_R_L".split("_"),weekdaysMin:"P_E_T_K_N_R_L".split("_"),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:"[Täna,] LT",nextDay:"[Homme,] LT",nextWeek:"[Järgmine] dddd LT",lastDay:"[Eile,] LT",lastWeek:"[Eelmine] dddd LT",sameElse:"L"},relativeTime:{future:"%s pärast",past:"%s tagasi",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:"%d päeva",M:t,MM:t,y:t,yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("eu",{months:"urtarrila_otsaila_martxoa_apirila_maiatza_ekaina_uztaila_abuztua_iraila_urria_azaroa_abendua".split("_"),monthsShort:"urt._ots._mar._api._mai._eka._uzt._abu._ira._urr._aza._abe.".split("_"),monthsParseExact:!0,weekdays:"igandea_astelehena_asteartea_asteazkena_osteguna_ostirala_larunbata".split("_"),weekdaysShort:"ig._al._ar._az._og._ol._lr.".split("_"),weekdaysMin:"ig_al_ar_az_og_ol_lr".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY[ko] MMMM[ren] D[a]",LLL:"YYYY[ko] MMMM[ren] D[a] HH:mm",LLLL:"dddd, YYYY[ko] MMMM[ren] D[a] HH:mm",l:"YYYY-M-D",ll:"YYYY[ko] MMM D[a]",lll:"YYYY[ko] MMM D[a] HH:mm",llll:"ddd, YYYY[ko] MMM D[a] HH:mm"},calendar:{sameDay:"[gaur] LT[etan]",nextDay:"[bihar] LT[etan]",nextWeek:"dddd LT[etan]",lastDay:"[atzo] LT[etan]",lastWeek:"[aurreko] dddd LT[etan]",sameElse:"L"},relativeTime:{future:"%s barru",past:"duela %s",s:"segundo batzuk",m:"minutu bat",mm:"%d minutu",h:"ordu bat",hh:"%d ordu",d:"egun bat",dd:"%d egun",M:"hilabete bat",MM:"%d hilabete",y:"urte bat",yy:"%d urte"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"۱",2:"۲",3:"۳",4:"۴",5:"۵",6:"۶",7:"۷",8:"۸",9:"۹",0:"۰"},n={"۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9","۰":"0"};e.defineLocale("fa",{months:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),monthsShort:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),weekdays:"یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"),weekdaysShort:"یک‌شنبه_دوشنبه_سه‌شنبه_چهارشنبه_پنج‌شنبه_جمعه_شنبه".split("_"),weekdaysMin:"ی_د_س_چ_پ_ج_ش".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"},meridiemParse:/قبل از ظهر|بعد از ظهر/,isPM:function(e){return/بعد از ظهر/.test(e)},meridiem:function(e,t,n){return e<12?"قبل از ظهر":"بعد از ظهر"},calendar:{sameDay:"[امروز ساعت] LT",nextDay:"[فردا ساعت] LT",nextWeek:"dddd [ساعت] LT",lastDay:"[دیروز ساعت] LT",lastWeek:"dddd [پیش] [ساعت] LT",sameElse:"L"},relativeTime:{future:"در %s",past:"%s پیش",s:"چندین ثانیه",m:"یک دقیقه",mm:"%d دقیقه",h:"یک ساعت",hh:"%d ساعت",d:"یک روز",dd:"%d روز",M:"یک ماه",MM:"%d ماه",y:"یک سال",yy:"%d سال"},preparse:function(e){return e.replace(/[۰-۹]/g,function(e){return n[e]}).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]}).replace(/,/g,"،")},ordinalParse:/\d{1,2}م/,ordinal:"%dم",week:{dow:6,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="nolla yksi kaksi kolme neljä viisi kuusi seitsemän kahdeksan yhdeksän".split(" "),n=["nolla","yhden","kahden","kolmen","neljän","viiden","kuuden",t[7],t[8],t[9]];function o(e,o,r,i){var a="";switch(r){case"s":return i?"muutaman sekunnin":"muutama sekunti";case"m":return i?"minuutin":"minuutti";case"mm":a=i?"minuutin":"minuuttia";break;case"h":return i?"tunnin":"tunti";case"hh":a=i?"tunnin":"tuntia";break;case"d":return i?"päivän":"päivä";case"dd":a=i?"päivän":"päivää";break;case"M":return i?"kuukauden":"kuukausi";case"MM":a=i?"kuukauden":"kuukautta";break;case"y":return i?"vuoden":"vuosi";case"yy":a=i?"vuoden":"vuotta"}return a=function(e,o){return e<10?o?n[e]:t[e]:e}(e,i)+" "+a}e.defineLocale("fi",{months:"tammikuu_helmikuu_maaliskuu_huhtikuu_toukokuu_kesäkuu_heinäkuu_elokuu_syyskuu_lokakuu_marraskuu_joulukuu".split("_"),monthsShort:"tammi_helmi_maalis_huhti_touko_kesä_heinä_elo_syys_loka_marras_joulu".split("_"),weekdays:"sunnuntai_maanantai_tiistai_keskiviikko_torstai_perjantai_lauantai".split("_"),weekdaysShort:"su_ma_ti_ke_to_pe_la".split("_"),weekdaysMin:"su_ma_ti_ke_to_pe_la".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD.MM.YYYY",LL:"Do MMMM[ta] YYYY",LLL:"Do MMMM[ta] YYYY, [klo] HH.mm",LLLL:"dddd, Do MMMM[ta] YYYY, [klo] HH.mm",l:"D.M.YYYY",ll:"Do MMM YYYY",lll:"Do MMM YYYY, [klo] HH.mm",llll:"ddd, Do MMM YYYY, [klo] HH.mm"},calendar:{sameDay:"[tänään] [klo] LT",nextDay:"[huomenna] [klo] LT",nextWeek:"dddd [klo] LT",lastDay:"[eilen] [klo] LT",lastWeek:"[viime] dddd[na] [klo] LT",sameElse:"L"},relativeTime:{future:"%s päästä",past:"%s sitten",s:o,m:o,mm:o,h:o,hh:o,d:o,dd:o,M:o,MM:o,y:o,yy:o},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("fo",{months:"januar_februar_mars_apríl_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sunnudagur_mánadagur_týsdagur_mikudagur_hósdagur_fríggjadagur_leygardagur".split("_"),weekdaysShort:"sun_mán_týs_mik_hós_frí_ley".split("_"),weekdaysMin:"su_má_tý_mi_hó_fr_le".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:"[Í dag kl.] LT",nextDay:"[Í morgin kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[Í gjár kl.] LT",lastWeek:"[síðstu] dddd [kl] LT",sameElse:"L"},relativeTime:{future:"um %s",past:"%s síðani",s:"fá sekund",m:"ein minutt",mm:"%d minuttir",h:"ein tími",hh:"%d tímar",d:"ein dagur",dd:"%d dagar",M:"ein mánaði",MM:"%d mánaðir",y:"eitt ár",yy:"%d ár"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.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",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"},ordinalParse:/\d{1,2}(er|)/,ordinal:function(e){return e+(1===e?"er":"")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("fr-ca",{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:"YYYY-MM-DD",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",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"},ordinalParse:/\d{1,2}(er|e)/,ordinal:function(e){return e+(1===e?"er":"e")}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("fr-ch",{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",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"},ordinalParse:/\d{1,2}(er|e)/,ordinal:function(e){return e+(1===e?"er":"e")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mai_jun._jul._aug._sep._okt._nov._des.".split("_"),n="jan_feb_mrt_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_");e.defineLocale("fy",{months:"jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber".split("_"),monthsShort:function(e,o){return/-MMM-/.test(o)?n[e.month()]:t[e.month()]},monthsParseExact:!0,weekdays:"snein_moandei_tiisdei_woansdei_tongersdei_freed_sneon".split("_"),weekdaysShort:"si._mo._ti._wo._to._fr._so.".split("_"),weekdaysMin:"Si_Mo_Ti_Wo_To_Fr_So".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:"[hjoed om] LT",nextDay:"[moarn om] LT",nextWeek:"dddd [om] LT",lastDay:"[juster om] LT",lastWeek:"[ôfrûne] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oer %s",past:"%s lyn",s:"in pear sekonden",m:"ien minút",mm:"%d minuten",h:"ien oere",hh:"%d oeren",d:"ien dei",dd:"%d dagen",M:"ien moanne",MM:"%d moannen",y:"ien jier",yy:"%d jierren"},ordinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("gd",{months:["Am Faoilleach","An Gearran","Am Màrt","An Giblean","An Cèitean","An t-Ògmhios","An t-Iuchar","An Lùnastal","An t-Sultain","An Dàmhair","An t-Samhain","An Dùbhlachd"],monthsShort:["Faoi","Gear","Màrt","Gibl","Cèit","Ògmh","Iuch","Lùn","Sult","Dàmh","Samh","Dùbh"],monthsParseExact:!0,weekdays:["Didòmhnaich","Diluain","Dimàirt","Diciadain","Diardaoin","Dihaoine","Disathairne"],weekdaysShort:["Did","Dil","Dim","Dic","Dia","Dih","Dis"],weekdaysMin:["Dò","Lu","Mà","Ci","Ar","Ha","Sa"],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:"[An-diugh aig] LT",nextDay:"[A-màireach aig] LT",nextWeek:"dddd [aig] LT",lastDay:"[An-dè aig] LT",lastWeek:"dddd [seo chaidh] [aig] LT",sameElse:"L"},relativeTime:{future:"ann an %s",past:"bho chionn %s",s:"beagan diogan",m:"mionaid",mm:"%d mionaidean",h:"uair",hh:"%d uairean",d:"latha",dd:"%d latha",M:"mìos",MM:"%d mìosan",y:"bliadhna",yy:"%d bliadhna"},ordinalParse:/\d{1,2}(d|na|mh)/,ordinal:function(e){return e+(1===e?"d":e%10==2?"na":"mh")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("gl",{months:"Xaneiro_Febreiro_Marzo_Abril_Maio_Xuño_Xullo_Agosto_Setembro_Outubro_Novembro_Decembro".split("_"),monthsShort:"Xan._Feb._Mar._Abr._Mai._Xuñ._Xul._Ago._Set._Out._Nov._Dec.".split("_"),monthsParseExact:!0,weekdays:"Domingo_Luns_Martes_Mércores_Xoves_Venres_Sábado".split("_"),weekdaysShort:"Dom._Lun._Mar._Mér._Xov._Ven._Sáb.".split("_"),weekdaysMin:"Do_Lu_Ma_Mé_Xo_Ve_Sá".split("_"),weekdaysParseExact:!0,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:function(){return"[hoxe "+(1!==this.hours()?"ás":"á")+"] LT"},nextDay:function(){return"[mañá "+(1!==this.hours()?"ás":"á")+"] LT"},nextWeek:function(){return"dddd ["+(1!==this.hours()?"ás":"a")+"] LT"},lastDay:function(){return"[onte "+(1!==this.hours()?"á":"a")+"] LT"},lastWeek:function(){return"[o] dddd [pasado "+(1!==this.hours()?"ás":"a")+"] LT"},sameElse:"L"},relativeTime:{future:function(e){return"uns segundos"===e?"nuns segundos":"en "+e},past:"hai %s",s:"uns segundos",m:"un minuto",mm:"%d minutos",h:"unha hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un ano",yy:"%d anos"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("he",{months:"ינואר_פברואר_מרץ_אפריל_מאי_יוני_יולי_אוגוסט_ספטמבר_אוקטובר_נובמבר_דצמבר".split("_"),monthsShort:"ינו׳_פבר׳_מרץ_אפר׳_מאי_יוני_יולי_אוג׳_ספט׳_אוק׳_נוב׳_דצמ׳".split("_"),weekdays:"ראשון_שני_שלישי_רביעי_חמישי_שישי_שבת".split("_"),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",l:"D/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY HH:mm",llll:"ddd, D MMM YYYY HH:mm"},calendar:{sameDay:"[היום ב־]LT",nextDay:"[מחר ב־]LT",nextWeek:"dddd [בשעה] LT",lastDay:"[אתמול ב־]LT",lastWeek:"[ביום] dddd [האחרון בשעה] LT",sameElse:"L"},relativeTime:{future:"בעוד %s",past:"לפני %s",s:"מספר שניות",m:"דקה",mm:"%d דקות",h:"שעה",hh:function(e){return 2===e?"שעתיים":e+" שעות"},d:"יום",dd:function(e){return 2===e?"יומיים":e+" ימים"},M:"חודש",MM:function(e){return 2===e?"חודשיים":e+" חודשים"},y:"שנה",yy:function(e){return 2===e?"שנתיים":e%10==0&&10!==e?e+" שנה":e+" שנים"}},meridiemParse:/אחה"צ|לפנה"צ|אחרי הצהריים|לפני הצהריים|לפנות בוקר|בבוקר|בערב/i,isPM:function(e){return/^(אחה"צ|אחרי הצהריים|בערב)$/.test(e)},meridiem:function(e,t,n){return e<5?"לפנות בוקר":e<10?"בבוקר":e<12?n?'לפנה"צ':"לפני הצהריים":e<18?n?'אחה"צ':"אחרי הצהריים":"בערב"}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};e.defineLocale("hi",{months:"जनवरी_फ़रवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितम्बर_अक्टूबर_नवम्बर_दिसम्बर".split("_"),monthsShort:"जन._फ़र._मार्च_अप्रै._मई_जून_जुल._अग._सित._अक्टू._नव._दिस.".split("_"),monthsParseExact:!0,weekdays:"रविवार_सोमवार_मंगलवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगल_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm बजे",LTS:"A h:mm:ss बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm बजे",LLLL:"dddd, D MMMM YYYY, A h:mm बजे"},calendar:{sameDay:"[आज] LT",nextDay:"[कल] LT",nextWeek:"dddd, LT",lastDay:"[कल] LT",lastWeek:"[पिछले] dddd, LT",sameElse:"L"},relativeTime:{future:"%s में",past:"%s पहले",s:"कुछ ही क्षण",m:"एक मिनट",mm:"%d मिनट",h:"एक घंटा",hh:"%d घंटे",d:"एक दिन",dd:"%d दिन",M:"एक महीने",MM:"%d महीने",y:"एक वर्ष",yy:"%d वर्ष"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/रात|सुबह|दोपहर|शाम/,meridiemHour:function(e,t){return 12===e&&(e=0),"रात"===t?e<4?e:e+12:"सुबह"===t?e:"दोपहर"===t?e>=10?e:e+12:"शाम"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"रात":e<10?"सुबह":e<17?"दोपहर":e<20?"शाम":"रात"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var o=e+" ";switch(n){case"m":return t?"jedna minuta":"jedne minute";case"mm":return o+=1===e?"minuta":2===e||3===e||4===e?"minute":"minuta";case"h":return t?"jedan sat":"jednog sata";case"hh":return o+=1===e?"sat":2===e||3===e||4===e?"sata":"sati";case"dd":return o+=1===e?"dan":"dana";case"MM":return o+=1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci";case"yy":return o+=1===e?"godina":2===e||3===e||4===e?"godine":"godina"}}e.defineLocale("hr",{months:{format:"siječnja_veljače_ožujka_travnja_svibnja_lipnja_srpnja_kolovoza_rujna_listopada_studenoga_prosinca".split("_"),standalone:"siječanj_veljača_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac".split("_")},monthsShort:"sij._velj._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,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:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="vasárnap hétfőn kedden szerdán csütörtökön pénteken szombaton".split(" ");function n(e,t,n,o){var r=e;switch(n){case"s":return o||t?"néhány másodperc":"néhány másodperce";case"m":return"egy"+(o||t?" perc":" perce");case"mm":return r+(o||t?" perc":" perce");case"h":return"egy"+(o||t?" óra":" órája");case"hh":return r+(o||t?" óra":" órája");case"d":return"egy"+(o||t?" nap":" napja");case"dd":return r+(o||t?" nap":" napja");case"M":return"egy"+(o||t?" hónap":" hónapja");case"MM":return r+(o||t?" hónap":" hónapja");case"y":return"egy"+(o||t?" év":" éve");case"yy":return r+(o||t?" év":" éve")}return""}function o(e){return(e?"":"[múlt] ")+"["+t[this.day()]+"] LT[-kor]"}e.defineLocale("hu",{months:"január_február_március_április_május_június_július_augusztus_szeptember_október_november_december".split("_"),monthsShort:"jan_feb_márc_ápr_máj_jún_júl_aug_szept_okt_nov_dec".split("_"),weekdays:"vasárnap_hétfő_kedd_szerda_csütörtök_péntek_szombat".split("_"),weekdaysShort:"vas_hét_kedd_sze_csüt_pén_szo".split("_"),weekdaysMin:"v_h_k_sze_cs_p_szo".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"YYYY.MM.DD.",LL:"YYYY. MMMM D.",LLL:"YYYY. MMMM D. H:mm",LLLL:"YYYY. MMMM D., dddd H:mm"},meridiemParse:/de|du/i,isPM:function(e){return"u"===e.charAt(1).toLowerCase()},meridiem:function(e,t,n){return e<12?!0===n?"de":"DE":!0===n?"du":"DU"},calendar:{sameDay:"[ma] LT[-kor]",nextDay:"[holnap] LT[-kor]",nextWeek:function(){return o.call(this,!0)},lastDay:"[tegnap] LT[-kor]",lastWeek:function(){return o.call(this,!1)},sameElse:"L"},relativeTime:{future:"%s múlva",past:"%s",s:n,m:n,mm:n,h:n,hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("hy-am",{months:{format:"հունվարի_փետրվարի_մարտի_ապրիլի_մայիսի_հունիսի_հուլիսի_օգոստոսի_սեպտեմբերի_հոկտեմբերի_նոյեմբերի_դեկտեմբերի".split("_"),standalone:"հունվար_փետրվար_մարտ_ապրիլ_մայիս_հունիս_հուլիս_օգոստոս_սեպտեմբեր_հոկտեմբեր_նոյեմբեր_դեկտեմբեր".split("_")},monthsShort:"հնվ_փտր_մրտ_ապր_մյս_հնս_հլս_օգս_սպտ_հկտ_նմբ_դկտ".split("_"),weekdays:"կիրակի_երկուշաբթի_երեքշաբթի_չորեքշաբթի_հինգշաբթի_ուրբաթ_շաբաթ".split("_"),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:"[այսօր] LT",nextDay:"[վաղը] LT",lastDay:"[երեկ] LT",nextWeek:function(){return"dddd [օրը ժամը] LT"},lastWeek:function(){return"[անցած] dddd [օրը ժամը] LT"},sameElse:"L"},relativeTime:{future:"%s հետո",past:"%s առաջ",s:"մի քանի վայրկյան",m:"րոպե",mm:"%d րոպե",h:"ժամ",hh:"%d ժամ",d:"օր",dd:"%d օր",M:"ամիս",MM:"%d ամիս",y:"տարի",yy:"%d տարի"},meridiemParse:/գիշերվա|առավոտվա|ցերեկվա|երեկոյան/,isPM:function(e){return/^(ցերեկվա|երեկոյան)$/.test(e)},meridiem:function(e){return e<4?"գիշերվա":e<12?"առավոտվա":e<17?"ցերեկվա":"երեկոյան"},ordinalParse:/\d{1,2}|\d{1,2}-(ին|րդ)/,ordinal:function(e,t){switch(t){case"DDD":case"w":case"W":case"DDDo":return 1===e?e+"-ին":e+"-րդ";default:return e}},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("id",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nov_Des".split("_"),weekdays:"Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),weekdaysShort:"Min_Sen_Sel_Rab_Kam_Jum_Sab".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|siang|sore|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"siang"===t?e>=11?e:e+12:"sore"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"siang":e<19?"sore":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Besok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kemarin pukul] LT",lastWeek:"dddd [lalu pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lalu",s:"beberapa detik",m:"semenit",mm:"%d menit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e){return e%100==11||e%10!=1}function n(e,n,o,r){var i=e+" ";switch(o){case"s":return n||r?"nokkrar sekúndur":"nokkrum sekúndum";case"m":return n?"mínúta":"mínútu";case"mm":return t(e)?i+(n||r?"mínútur":"mínútum"):n?i+"mínúta":i+"mínútu";case"hh":return t(e)?i+(n||r?"klukkustundir":"klukkustundum"):i+"klukkustund";case"d":return n?"dagur":r?"dag":"degi";case"dd":return t(e)?n?i+"dagar":i+(r?"daga":"dögum"):n?i+"dagur":i+(r?"dag":"degi");case"M":return n?"mánuður":r?"mánuð":"mánuði";case"MM":return t(e)?n?i+"mánuðir":i+(r?"mánuði":"mánuðum"):n?i+"mánuður":i+(r?"mánuð":"mánuði");case"y":return n||r?"ár":"ári";case"yy":return t(e)?i+(n||r?"ár":"árum"):i+(n||r?"ár":"ári")}}e.defineLocale("is",{months:"janúar_febrúar_mars_apríl_maí_júní_júlí_ágúst_september_október_nóvember_desember".split("_"),monthsShort:"jan_feb_mar_apr_maí_jún_júl_ágú_sep_okt_nóv_des".split("_"),weekdays:"sunnudagur_mánudagur_þriðjudagur_miðvikudagur_fimmtudagur_föstudagur_laugardagur".split("_"),weekdaysShort:"sun_mán_þri_mið_fim_fös_lau".split("_"),weekdaysMin:"Su_Má_Þr_Mi_Fi_Fö_La".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] H:mm",LLLL:"dddd, D. MMMM YYYY [kl.] H:mm"},calendar:{sameDay:"[í dag kl.] LT",nextDay:"[á morgun kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[í gær kl.] LT",lastWeek:"[síðasta] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"eftir %s",past:"fyrir %s síðan",s:n,m:n,mm:n,h:"klukkustund",hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.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(e){return(/^[0-9].+$/.test(e)?"tra":"in")+" "+e},past:"%s fa",s:"alcuni 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"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ja",{months:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),weekdaysShort:"日_月_火_水_木_金_土".split("_"),weekdaysMin:"日_月_火_水_木_金_土".split("_"),longDateFormat:{LT:"Ah時m分",LTS:"Ah時m分s秒",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日Ah時m分",LLLL:"YYYY年M月D日Ah時m分 dddd"},meridiemParse:/午前|午後/i,isPM:function(e){return"午後"===e},meridiem:function(e,t,n){return e<12?"午前":"午後"},calendar:{sameDay:"[今日] LT",nextDay:"[明日] LT",nextWeek:"[来週]dddd LT",lastDay:"[昨日] LT",lastWeek:"[前週]dddd LT",sameElse:"L"},ordinalParse:/\d{1,2}日/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";default:return e}},relativeTime:{future:"%s後",past:"%s前",s:"数秒",m:"1分",mm:"%d分",h:"1時間",hh:"%d時間",d:"1日",dd:"%d日",M:"1ヶ月",MM:"%dヶ月",y:"1年",yy:"%d年"}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("jv",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_Nopember_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nop_Des".split("_"),weekdays:"Minggu_Senen_Seloso_Rebu_Kemis_Jemuwah_Septu".split("_"),weekdaysShort:"Min_Sen_Sel_Reb_Kem_Jem_Sep".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sp".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/enjing|siyang|sonten|ndalu/,meridiemHour:function(e,t){return 12===e&&(e=0),"enjing"===t?e:"siyang"===t?e>=11?e:e+12:"sonten"===t||"ndalu"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"enjing":e<15?"siyang":e<19?"sonten":"ndalu"},calendar:{sameDay:"[Dinten puniko pukul] LT",nextDay:"[Mbenjang pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kala wingi pukul] LT",lastWeek:"dddd [kepengker pukul] LT",sameElse:"L"},relativeTime:{future:"wonten ing %s",past:"%s ingkang kepengker",s:"sawetawis detik",m:"setunggal menit",mm:"%d menit",h:"setunggal jam",hh:"%d jam",d:"sedinten",dd:"%d dinten",M:"sewulan",MM:"%d wulan",y:"setaun",yy:"%d taun"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ka",{months:{standalone:"იანვარი_თებერვალი_მარტი_აპრილი_მაისი_ივნისი_ივლისი_აგვისტო_სექტემბერი_ოქტომბერი_ნოემბერი_დეკემბერი".split("_"),format:"იანვარს_თებერვალს_მარტს_აპრილის_მაისს_ივნისს_ივლისს_აგვისტს_სექტემბერს_ოქტომბერს_ნოემბერს_დეკემბერს".split("_")},monthsShort:"იან_თებ_მარ_აპრ_მაი_ივნ_ივლ_აგვ_სექ_ოქტ_ნოე_დეკ".split("_"),weekdays:{standalone:"კვირა_ორშაბათი_სამშაბათი_ოთხშაბათი_ხუთშაბათი_პარასკევი_შაბათი".split("_"),format:"კვირას_ორშაბათს_სამშაბათს_ოთხშაბათს_ხუთშაბათს_პარასკევს_შაბათს".split("_"),isFormat:/(წინა|შემდეგ)/},weekdaysShort:"კვი_ორშ_სამ_ოთხ_ხუთ_პარ_შაბ".split("_"),weekdaysMin:"კვ_ორ_სა_ოთ_ხუ_პა_შა".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[დღეს] LT[-ზე]",nextDay:"[ხვალ] LT[-ზე]",lastDay:"[გუშინ] LT[-ზე]",nextWeek:"[შემდეგ] dddd LT[-ზე]",lastWeek:"[წინა] dddd LT-ზე",sameElse:"L"},relativeTime:{future:function(e){return/(წამი|წუთი|საათი|წელი)/.test(e)?e.replace(/ი$/,"ში"):e+"ში"},past:function(e){return/(წამი|წუთი|საათი|დღე|თვე)/.test(e)?e.replace(/(ი|ე)$/,"ის წინ"):/წელი/.test(e)?e.replace(/წელი$/,"წლის წინ"):void 0},s:"რამდენიმე წამი",m:"წუთი",mm:"%d წუთი",h:"საათი",hh:"%d საათი",d:"დღე",dd:"%d დღე",M:"თვე",MM:"%d თვე",y:"წელი",yy:"%d წელი"},ordinalParse:/0|1-ლი|მე-\d{1,2}|\d{1,2}-ე/,ordinal:function(e){return 0===e?e:1===e?e+"-ლი":e<20||e<=100&&e%20==0||e%100==0?"მე-"+e:e+"-ე"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={0:"-ші",1:"-ші",2:"-ші",3:"-ші",4:"-ші",5:"-ші",6:"-шы",7:"-ші",8:"-ші",9:"-шы",10:"-шы",20:"-шы",30:"-шы",40:"-шы",50:"-ші",60:"-шы",70:"-ші",80:"-ші",90:"-шы",100:"-ші"};e.defineLocale("kk",{months:"қаңтар_ақпан_наурыз_сәуір_мамыр_маусым_шілде_тамыз_қыркүйек_қазан_қараша_желтоқсан".split("_"),monthsShort:"қаң_ақп_нау_сәу_мам_мау_шіл_там_қыр_қаз_қар_жел".split("_"),weekdays:"жексенбі_дүйсенбі_сейсенбі_сәрсенбі_бейсенбі_жұма_сенбі".split("_"),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:"[Бүгін сағат] LT",nextDay:"[Ертең сағат] LT",nextWeek:"dddd [сағат] LT",lastDay:"[Кеше сағат] LT",lastWeek:"[Өткен аптаның] dddd [сағат] LT",sameElse:"L"},relativeTime:{future:"%s ішінде",past:"%s бұрын",s:"бірнеше секунд",m:"бір минут",mm:"%d минут",h:"бір сағат",hh:"%d сағат",d:"бір күн",dd:"%d күн",M:"бір ай",MM:"%d ай",y:"бір жыл",yy:"%d жыл"},ordinalParse:/\d{1,2}-(ші|шы)/,ordinal:function(e){return e+(t[e]||t[e%10]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("km",{months:"មករា_កុម្ភៈ_មីនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),monthsShort:"មករា_កុម្ភៈ_មីនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),weekdays:"អាទិត្យ_ច័ន្ទ_អង្គារ_ពុធ_ព្រហស្បតិ៍_សុក្រ_សៅរ៍".split("_"),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:"[ថ្ងៃនេះ ម៉ោង] LT",nextDay:"[ស្អែក ម៉ោង] LT",nextWeek:"dddd [ម៉ោង] LT",lastDay:"[ម្សិលមិញ ម៉ោង] LT",lastWeek:"dddd [សប្តាហ៍មុន] [ម៉ោង] LT",sameElse:"L"},relativeTime:{future:"%sទៀត",past:"%sមុន",s:"ប៉ុន្មានវិនាទី",m:"មួយនាទី",mm:"%d នាទី",h:"មួយម៉ោង",hh:"%d ម៉ោង",d:"មួយថ្ងៃ",dd:"%d ថ្ងៃ",M:"មួយខែ",MM:"%d ខែ",y:"មួយឆ្នាំ",yy:"%d ឆ្នាំ"},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ko",{months:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),monthsShort:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),weekdays:"일요일_월요일_화요일_수요일_목요일_금요일_토요일".split("_"),weekdaysShort:"일_월_화_수_목_금_토".split("_"),weekdaysMin:"일_월_화_수_목_금_토".split("_"),longDateFormat:{LT:"A h시 m분",LTS:"A h시 m분 s초",L:"YYYY.MM.DD",LL:"YYYY년 MMMM D일",LLL:"YYYY년 MMMM D일 A h시 m분",LLLL:"YYYY년 MMMM D일 dddd A h시 m분"},calendar:{sameDay:"오늘 LT",nextDay:"내일 LT",nextWeek:"dddd LT",lastDay:"어제 LT",lastWeek:"지난주 dddd LT",sameElse:"L"},relativeTime:{future:"%s 후",past:"%s 전",s:"몇 초",ss:"%d초",m:"일분",mm:"%d분",h:"한 시간",hh:"%d시간",d:"하루",dd:"%d일",M:"한 달",MM:"%d달",y:"일 년",yy:"%d년"},ordinalParse:/\d{1,2}일/,ordinal:"%d일",meridiemParse:/오전|오후/,isPM:function(e){return"오후"===e},meridiem:function(e,t,n){return e<12?"오전":"오후"}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={0:"-чү",1:"-чи",2:"-чи",3:"-чү",4:"-чү",5:"-чи",6:"-чы",7:"-чи",8:"-чи",9:"-чу",10:"-чу",20:"-чы",30:"-чу",40:"-чы",50:"-чү",60:"-чы",70:"-чи",80:"-чи",90:"-чу",100:"-чү"};e.defineLocale("ky",{months:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_"),monthsShort:"янв_фев_март_апр_май_июнь_июль_авг_сен_окт_ноя_дек".split("_"),weekdays:"Жекшемби_Дүйшөмбү_Шейшемби_Шаршемби_Бейшемби_Жума_Ишемби".split("_"),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:"[Бүгүн саат] LT",nextDay:"[Эртең саат] LT",nextWeek:"dddd [саат] LT",lastDay:"[Кече саат] LT",lastWeek:"[Өткен аптанын] dddd [күнү] [саат] LT",sameElse:"L"},relativeTime:{future:"%s ичинде",past:"%s мурун",s:"бирнече секунд",m:"бир мүнөт",mm:"%d мүнөт",h:"бир саат",hh:"%d саат",d:"бир күн",dd:"%d күн",M:"бир ай",MM:"%d ай",y:"бир жыл",yy:"%d жыл"},ordinalParse:/\d{1,2}-(чи|чы|чү|чу)/,ordinal:function(e){return e+(t[e]||t[e%10]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n,o){var r={m:["eng Minutt","enger Minutt"],h:["eng Stonn","enger Stonn"],d:["een Dag","engem Dag"],M:["ee Mount","engem Mount"],y:["ee Joer","engem Joer"]};return t?r[n][0]:r[n][1]}function n(e){if(e=parseInt(e,10),isNaN(e))return!1;if(e<0)return!0;if(e<10)return 4<=e&&e<=7;if(e<100){var t=e%10;return n(0===t?e/10:t)}if(e<1e4){for(;e>=10;)e/=10;return n(e)}return n(e/=1e3)}e.defineLocale("lb",{months:"Januar_Februar_Mäerz_Abrëll_Mee_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Febr._Mrz._Abr._Mee_Jun._Jul._Aug._Sept._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonndeg_Méindeg_Dënschdeg_Mëttwoch_Donneschdeg_Freideg_Samschdeg".split("_"),weekdaysShort:"So._Mé._Dë._Më._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mé_Dë_Më_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm [Auer]",LTS:"H:mm:ss [Auer]",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm [Auer]",LLLL:"dddd, D. MMMM YYYY H:mm [Auer]"},calendar:{sameDay:"[Haut um] LT",sameElse:"L",nextDay:"[Muer um] LT",nextWeek:"dddd [um] LT",lastDay:"[Gëschter um] LT",lastWeek:function(){switch(this.day()){case 2:case 4:return"[Leschten] dddd [um] LT";default:return"[Leschte] dddd [um] LT"}}},relativeTime:{future:function(e){return n(e.substr(0,e.indexOf(" ")))?"a "+e:"an "+e},past:function(e){return n(e.substr(0,e.indexOf(" ")))?"viru "+e:"virun "+e},s:"e puer Sekonnen",m:t,mm:"%d Minutten",h:t,hh:"%d Stonnen",d:t,dd:"%d Deeg",M:t,MM:"%d Méint",y:t,yy:"%d Joer"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("lo",{months:"ມັງກອນ_ກຸມພາ_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_ກໍລະກົດ_ສິງຫາ_ກັນຍາ_ຕຸລາ_ພະຈິກ_ທັນວາ".split("_"),monthsShort:"ມັງກອນ_ກຸມພາ_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_ກໍລະກົດ_ສິງຫາ_ກັນຍາ_ຕຸລາ_ພະຈິກ_ທັນວາ".split("_"),weekdays:"ອາທິດ_ຈັນ_ອັງຄານ_ພຸດ_ພະຫັດ_ສຸກ_ເສົາ".split("_"),weekdaysShort:"ທິດ_ຈັນ_ອັງຄານ_ພຸດ_ພະຫັດ_ສຸກ_ເສົາ".split("_"),weekdaysMin:"ທ_ຈ_ອຄ_ພ_ພຫ_ສກ_ສ".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"},meridiemParse:/ຕອນເຊົ້າ|ຕອນແລງ/,isPM:function(e){return"ຕອນແລງ"===e},meridiem:function(e,t,n){return e<12?"ຕອນເຊົ້າ":"ຕອນແລງ"},calendar:{sameDay:"[ມື້ນີ້ເວລາ] LT",nextDay:"[ມື້ອື່ນເວລາ] LT",nextWeek:"[ວັນ]dddd[ໜ້າເວລາ] LT",lastDay:"[ມື້ວານນີ້ເວລາ] LT",lastWeek:"[ວັນ]dddd[ແລ້ວນີ້ເວລາ] LT",sameElse:"L"},relativeTime:{future:"ອີກ %s",past:"%sຜ່ານມາ",s:"ບໍ່ເທົ່າໃດວິນາທີ",m:"1 ນາທີ",mm:"%d ນາທີ",h:"1 ຊົ່ວໂມງ",hh:"%d ຊົ່ວໂມງ",d:"1 ມື້",dd:"%d ມື້",M:"1 ເດືອນ",MM:"%d ເດືອນ",y:"1 ປີ",yy:"%d ປີ"},ordinalParse:/(ທີ່)\d{1,2}/,ordinal:function(e){return"ທີ່"+e}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={m:"minutė_minutės_minutę",mm:"minutės_minučių_minutes",h:"valanda_valandos_valandą",hh:"valandos_valandų_valandas",d:"diena_dienos_dieną",dd:"dienos_dienų_dienas",M:"mėnuo_mėnesio_mėnesį",MM:"mėnesiai_mėnesių_mėnesius",y:"metai_metų_metus",yy:"metai_metų_metus"};function n(e,t,n,o){return t?r(n)[0]:o?r(n)[1]:r(n)[2]}function o(e){return e%10==0||e>10&&e<20}function r(e){return t[e].split("_")}function i(e,t,i,a){var s=e+" ";return 1===e?s+n(0,t,i[0],a):t?s+(o(e)?r(i)[1]:r(i)[0]):a?s+r(i)[1]:s+(o(e)?r(i)[1]:r(i)[2])}e.defineLocale("lt",{months:{format:"sausio_vasario_kovo_balandžio_gegužės_birželio_liepos_rugpjūčio_rugsėjo_spalio_lapkričio_gruodžio".split("_"),standalone:"sausis_vasaris_kovas_balandis_gegužė_birželis_liepa_rugpjūtis_rugsėjis_spalis_lapkritis_gruodis".split("_")},monthsShort:"sau_vas_kov_bal_geg_bir_lie_rgp_rgs_spa_lap_grd".split("_"),weekdays:{format:"sekmadienį_pirmadienį_antradienį_trečiadienį_ketvirtadienį_penktadienį_šeštadienį".split("_"),standalone:"sekmadienis_pirmadienis_antradienis_trečiadienis_ketvirtadienis_penktadienis_šeštadienis".split("_"),isFormat:/dddd HH:mm/},weekdaysShort:"Sek_Pir_Ant_Tre_Ket_Pen_Šeš".split("_"),weekdaysMin:"S_P_A_T_K_Pn_Š".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY [m.] MMMM D [d.]",LLL:"YYYY [m.] MMMM D [d.], HH:mm [val.]",LLLL:"YYYY [m.] MMMM D [d.], dddd, HH:mm [val.]",l:"YYYY-MM-DD",ll:"YYYY [m.] MMMM D [d.]",lll:"YYYY [m.] MMMM D [d.], HH:mm [val.]",llll:"YYYY [m.] MMMM D [d.], ddd, HH:mm [val.]"},calendar:{sameDay:"[Šiandien] LT",nextDay:"[Rytoj] LT",nextWeek:"dddd LT",lastDay:"[Vakar] LT",lastWeek:"[Praėjusį] dddd LT",sameElse:"L"},relativeTime:{future:"po %s",past:"prieš %s",s:function(e,t,n,o){return t?"kelios sekundės":o?"kelių sekundžių":"kelias sekundes"},m:n,mm:i,h:n,hh:i,d:n,dd:i,M:n,MM:i,y:n,yy:i},ordinalParse:/\d{1,2}-oji/,ordinal:function(e){return e+"-oji"},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={m:"minūtes_minūtēm_minūte_minūtes".split("_"),mm:"minūtes_minūtēm_minūte_minūtes".split("_"),h:"stundas_stundām_stunda_stundas".split("_"),hh:"stundas_stundām_stunda_stundas".split("_"),d:"dienas_dienām_diena_dienas".split("_"),dd:"dienas_dienām_diena_dienas".split("_"),M:"mēneša_mēnešiem_mēnesis_mēneši".split("_"),MM:"mēneša_mēnešiem_mēnesis_mēneši".split("_"),y:"gada_gadiem_gads_gadi".split("_"),yy:"gada_gadiem_gads_gadi".split("_")};function n(e,t,n){return n?t%10==1&&11!==t?e[2]:e[3]:t%10==1&&11!==t?e[0]:e[1]}function o(e,o,r){return e+" "+n(t[r],e,o)}function r(e,o,r){return n(t[r],e,o)}e.defineLocale("lv",{months:"janvāris_februāris_marts_aprīlis_maijs_jūnijs_jūlijs_augusts_septembris_oktobris_novembris_decembris".split("_"),monthsShort:"jan_feb_mar_apr_mai_jūn_jūl_aug_sep_okt_nov_dec".split("_"),weekdays:"svētdiena_pirmdiena_otrdiena_trešdiena_ceturtdiena_piektdiena_sestdiena".split("_"),weekdaysShort:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysMin:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY.",LL:"YYYY. [gada] D. MMMM",LLL:"YYYY. [gada] D. MMMM, HH:mm",LLLL:"YYYY. [gada] D. MMMM, dddd, HH:mm"},calendar:{sameDay:"[Šodien pulksten] LT",nextDay:"[Rīt pulksten] LT",nextWeek:"dddd [pulksten] LT",lastDay:"[Vakar pulksten] LT",lastWeek:"[Pagājušā] dddd [pulksten] LT",sameElse:"L"},relativeTime:{future:"pēc %s",past:"pirms %s",s:function(e,t){return t?"dažas sekundes":"dažām sekundēm"},m:r,mm:o,h:r,hh:o,d:r,dd:o,M:r,MM:o,y:r,yy:o},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={words:{m:["jedan minut","jednog minuta"],mm:["minut","minuta","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],dd:["dan","dana","dana"],MM:["mjesec","mjeseca","mjeseci"],yy:["godina","godine","godina"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,o){var r=t.words[o];return 1===o.length?n?r[0]:r[1]:e+" "+t.correctGrammaticalCase(e,r)}};e.defineLocale("me",{months:"januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,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:"[danas u] LT",nextDay:"[sjutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){return["[prošle] [nedjelje] [u] LT","[prošlog] [ponedjeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srijede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"nekoliko sekundi",m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"dan",dd:t.translate,M:"mjesec",MM:t.translate,y:"godinu",yy:t.translate},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("mk",{months:"јануари_февруари_март_април_мај_јуни_јули_август_септември_октомври_ноември_декември".split("_"),monthsShort:"јан_фев_мар_апр_мај_јун_јул_авг_сеп_окт_ное_дек".split("_"),weekdays:"недела_понеделник_вторник_среда_четврток_петок_сабота".split("_"),weekdaysShort:"нед_пон_вто_сре_чет_пет_саб".split("_"),weekdaysMin:"нe_пo_вт_ср_че_пе_сa".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[Денес во] LT",nextDay:"[Утре во] LT",nextWeek:"[Во] dddd [во] LT",lastDay:"[Вчера во] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[Изминатата] dddd [во] LT";case 1:case 2:case 4:case 5:return"[Изминатиот] dddd [во] LT"}},sameElse:"L"},relativeTime:{future:"после %s",past:"пред %s",s:"неколку секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дена",M:"месец",MM:"%d месеци",y:"година",yy:"%d години"},ordinalParse:/\d{1,2}-(ев|ен|ти|ви|ри|ми)/,ordinal:function(e){var t=e%10,n=e%100;return 0===e?e+"-ев":0===n?e+"-ен":n>10&&n<20?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ml",{months:"ജനുവരി_ഫെബ്രുവരി_മാർച്ച്_ഏപ്രിൽ_മേയ്_ജൂൺ_ജൂലൈ_ഓഗസ്റ്റ്_സെപ്റ്റംബർ_ഒക്ടോബർ_നവംബർ_ഡിസംബർ".split("_"),monthsShort:"ജനു._ഫെബ്രു._മാർ._ഏപ്രി._മേയ്_ജൂൺ_ജൂലൈ._ഓഗ._സെപ്റ്റ._ഒക്ടോ._നവം._ഡിസം.".split("_"),monthsParseExact:!0,weekdays:"ഞായറാഴ്ച_തിങ്കളാഴ്ച_ചൊവ്വാഴ്ച_ബുധനാഴ്ച_വ്യാഴാഴ്ച_വെള്ളിയാഴ്ച_ശനിയാഴ്ച".split("_"),weekdaysShort:"ഞായർ_തിങ്കൾ_ചൊവ്വ_ബുധൻ_വ്യാഴം_വെള്ളി_ശനി".split("_"),weekdaysMin:"ഞാ_തി_ചൊ_ബു_വ്യാ_വെ_ശ".split("_"),longDateFormat:{LT:"A h:mm -നു",LTS:"A h:mm:ss -നു",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm -നു",LLLL:"dddd, D MMMM YYYY, A h:mm -നു"},calendar:{sameDay:"[ഇന്ന്] LT",nextDay:"[നാളെ] LT",nextWeek:"dddd, LT",lastDay:"[ഇന്നലെ] LT",lastWeek:"[കഴിഞ്ഞ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s കഴിഞ്ഞ്",past:"%s മുൻപ്",s:"അൽപ നിമിഷങ്ങൾ",m:"ഒരു മിനിറ്റ്",mm:"%d മിനിറ്റ്",h:"ഒരു മണിക്കൂർ",hh:"%d മണിക്കൂർ",d:"ഒരു ദിവസം",dd:"%d ദിവസം",M:"ഒരു മാസം",MM:"%d മാസം",y:"ഒരു വർഷം",yy:"%d വർഷം"},meridiemParse:/രാത്രി|രാവിലെ|ഉച്ച കഴിഞ്ഞ്|വൈകുന്നേരം|രാത്രി/i,meridiemHour:function(e,t){return 12===e&&(e=0),"രാത്രി"===t&&e>=4||"ഉച്ച കഴിഞ്ഞ്"===t||"വൈകുന്നേരം"===t?e+12:e},meridiem:function(e,t,n){return e<4?"രാത്രി":e<12?"രാവിലെ":e<17?"ഉച്ച കഴിഞ്ഞ്":e<20?"വൈകുന്നേരം":"രാത്രി"}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};function o(e,t,n,o){var r="";if(t)switch(n){case"s":r="काही सेकंद";break;case"m":r="एक मिनिट";break;case"mm":r="%d मिनिटे";break;case"h":r="एक तास";break;case"hh":r="%d तास";break;case"d":r="एक दिवस";break;case"dd":r="%d दिवस";break;case"M":r="एक महिना";break;case"MM":r="%d महिने";break;case"y":r="एक वर्ष";break;case"yy":r="%d वर्षे"}else switch(n){case"s":r="काही सेकंदां";break;case"m":r="एका मिनिटा";break;case"mm":r="%d मिनिटां";break;case"h":r="एका तासा";break;case"hh":r="%d तासां";break;case"d":r="एका दिवसा";break;case"dd":r="%d दिवसां";break;case"M":r="एका महिन्या";break;case"MM":r="%d महिन्यां";break;case"y":r="एका वर्षा";break;case"yy":r="%d वर्षां"}return r.replace(/%d/i,e)}e.defineLocale("mr",{months:"जानेवारी_फेब्रुवारी_मार्च_एप्रिल_मे_जून_जुलै_ऑगस्ट_सप्टेंबर_ऑक्टोबर_नोव्हेंबर_डिसेंबर".split("_"),monthsShort:"जाने._फेब्रु._मार्च._एप्रि._मे._जून._जुलै._ऑग._सप्टें._ऑक्टो._नोव्हें._डिसें.".split("_"),monthsParseExact:!0,weekdays:"रविवार_सोमवार_मंगळवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगळ_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm वाजता",LTS:"A h:mm:ss वाजता",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm वाजता",LLLL:"dddd, D MMMM YYYY, A h:mm वाजता"},calendar:{sameDay:"[आज] LT",nextDay:"[उद्या] LT",nextWeek:"dddd, LT",lastDay:"[काल] LT",lastWeek:"[मागील] dddd, LT",sameElse:"L"},relativeTime:{future:"%sमध्ये",past:"%sपूर्वी",s:o,m:o,mm:o,h:o,hh:o,d:o,dd:o,M:o,MM:o,y:o,yy:o},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/रात्री|सकाळी|दुपारी|सायंकाळी/,meridiemHour:function(e,t){return 12===e&&(e=0),"रात्री"===t?e<4?e:e+12:"सकाळी"===t?e:"दुपारी"===t?e>=10?e:e+12:"सायंकाळी"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"रात्री":e<10?"सकाळी":e<17?"दुपारी":e<20?"सायंकाळी":"रात्री"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ms",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|tengahari|petang|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"tengahari"===t?e>=11?e:e+12:"petang"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"tengahari":e<19?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ms-my",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|tengahari|petang|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"tengahari"===t?e>=11?e:e+12:"petang"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"tengahari":e<19?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"၁",2:"၂",3:"၃",4:"၄",5:"၅",6:"၆",7:"၇",8:"၈",9:"၉",0:"၀"},n={"၁":"1","၂":"2","၃":"3","၄":"4","၅":"5","၆":"6","၇":"7","၈":"8","၉":"9","၀":"0"};e.defineLocale("my",{months:"ဇန်နဝါရီ_ဖေဖော်ဝါရီ_မတ်_ဧပြီ_မေ_ဇွန်_ဇူလိုင်_သြဂုတ်_စက်တင်ဘာ_အောက်တိုဘာ_နိုဝင်ဘာ_ဒီဇင်ဘာ".split("_"),monthsShort:"ဇန်_ဖေ_မတ်_ပြီ_မေ_ဇွန်_လိုင်_သြ_စက်_အောက်_နို_ဒီ".split("_"),weekdays:"တနင်္ဂနွေ_တနင်္လာ_အင်္ဂါ_ဗုဒ္ဓဟူး_ကြာသပတေး_သောကြာ_စနေ".split("_"),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:"[ယနေ.] LT [မှာ]",nextDay:"[မနက်ဖြန်] LT [မှာ]",nextWeek:"dddd LT [မှာ]",lastDay:"[မနေ.က] LT [မှာ]",lastWeek:"[ပြီးခဲ့သော] dddd LT [မှာ]",sameElse:"L"},relativeTime:{future:"လာမည့် %s မှာ",past:"လွန်ခဲ့သော %s က",s:"စက္ကန်.အနည်းငယ်",m:"တစ်မိနစ်",mm:"%d မိနစ်",h:"တစ်နာရီ",hh:"%d နာရီ",d:"တစ်ရက်",dd:"%d ရက်",M:"တစ်လ",MM:"%d လ",y:"တစ်နှစ်",yy:"%d နှစ်"},preparse:function(e){return e.replace(/[၁၂၃၄၅၆၇၈၉၀]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("nb",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan._feb._mars_april_mai_juni_juli_aug._sep._okt._nov._des.".split("_"),monthsParseExact:!0,weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"sø._ma._ti._on._to._fr._lø.".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] HH:mm",LLLL:"dddd D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[i dag kl.] LT",nextDay:"[i morgen kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[i går kl.] LT",lastWeek:"[forrige] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"noen sekunder",m:"ett minutt",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dager",M:"en måned",MM:"%d måneder",y:"ett år",yy:"%d år"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};e.defineLocale("ne",{months:"जनवरी_फेब्रुवरी_मार्च_अप्रिल_मई_जुन_जुलाई_अगष्ट_सेप्टेम्बर_अक्टोबर_नोभेम्बर_डिसेम्बर".split("_"),monthsShort:"जन._फेब्रु._मार्च_अप्रि._मई_जुन_जुलाई._अग._सेप्ट._अक्टो._नोभे._डिसे.".split("_"),monthsParseExact:!0,weekdays:"आइतबार_सोमबार_मङ्गलबार_बुधबार_बिहिबार_शुक्रबार_शनिबार".split("_"),weekdaysShort:"आइत._सोम._मङ्गल._बुध._बिहि._शुक्र._शनि.".split("_"),weekdaysMin:"आ._सो._मं._बु._बि._शु._श.".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"Aको h:mm बजे",LTS:"Aको h:mm:ss बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, Aको h:mm बजे",LLLL:"dddd, D MMMM YYYY, Aको h:mm बजे"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/राति|बिहान|दिउँसो|साँझ/,meridiemHour:function(e,t){return 12===e&&(e=0),"राति"===t?e<4?e:e+12:"बिहान"===t?e:"दिउँसो"===t?e>=10?e:e+12:"साँझ"===t?e+12:void 0},meridiem:function(e,t,n){return e<3?"राति":e<12?"बिहान":e<16?"दिउँसो":e<20?"साँझ":"राति"},calendar:{sameDay:"[आज] LT",nextDay:"[भोलि] LT",nextWeek:"[आउँदो] dddd[,] LT",lastDay:"[हिजो] LT",lastWeek:"[गएको] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%sमा",past:"%s अगाडि",s:"केही क्षण",m:"एक मिनेट",mm:"%d मिनेट",h:"एक घण्टा",hh:"%d घण्टा",d:"एक दिन",dd:"%d दिन",M:"एक महिना",MM:"%d महिना",y:"एक बर्ष",yy:"%d बर्ष"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),n="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_");e.defineLocale("nl",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(e,o){return/-MMM-/.test(o)?n[e.month()]:t[e.month()]},monthsParseExact:!0,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",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"},ordinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("nn",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sundag_måndag_tysdag_onsdag_torsdag_fredag_laurdag".split("_"),weekdaysShort:"sun_mån_tys_ons_tor_fre_lau".split("_"),weekdaysMin:"su_må_ty_on_to_fr_lø".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] H:mm",LLLL:"dddd D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[I dag klokka] LT",nextDay:"[I morgon klokka] LT",nextWeek:"dddd [klokka] LT",lastDay:"[I går klokka] LT",lastWeek:"[Føregåande] dddd [klokka] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s sidan",s:"nokre sekund",m:"eit minutt",mm:"%d minutt",h:"ein time",hh:"%d timar",d:"ein dag",dd:"%d dagar",M:"ein månad",MM:"%d månader",y:"eit år",yy:"%d år"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"੧",2:"੨",3:"੩",4:"੪",5:"੫",6:"੬",7:"੭",8:"੮",9:"੯",0:"੦"},n={"੧":"1","੨":"2","੩":"3","੪":"4","੫":"5","੬":"6","੭":"7","੮":"8","੯":"9","੦":"0"};e.defineLocale("pa-in",{months:"ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪ੍ਰੈਲ_ਮਈ_ਜੂਨ_ਜੁਲਾਈ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ".split("_"),monthsShort:"ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪ੍ਰੈਲ_ਮਈ_ਜੂਨ_ਜੁਲਾਈ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ".split("_"),weekdays:"ਐਤਵਾਰ_ਸੋਮਵਾਰ_ਮੰਗਲਵਾਰ_ਬੁਧਵਾਰ_ਵੀਰਵਾਰ_ਸ਼ੁੱਕਰਵਾਰ_ਸ਼ਨੀਚਰਵਾਰ".split("_"),weekdaysShort:"ਐਤ_ਸੋਮ_ਮੰਗਲ_ਬੁਧ_ਵੀਰ_ਸ਼ੁਕਰ_ਸ਼ਨੀ".split("_"),weekdaysMin:"ਐਤ_ਸੋਮ_ਮੰਗਲ_ਬੁਧ_ਵੀਰ_ਸ਼ੁਕਰ_ਸ਼ਨੀ".split("_"),longDateFormat:{LT:"A h:mm ਵਜੇ",LTS:"A h:mm:ss ਵਜੇ",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm ਵਜੇ",LLLL:"dddd, D MMMM YYYY, A h:mm ਵਜੇ"},calendar:{sameDay:"[ਅਜ] LT",nextDay:"[ਕਲ] LT",nextWeek:"dddd, LT",lastDay:"[ਕਲ] LT",lastWeek:"[ਪਿਛਲੇ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ਵਿੱਚ",past:"%s ਪਿਛਲੇ",s:"ਕੁਝ ਸਕਿੰਟ",m:"ਇਕ ਮਿੰਟ",mm:"%d ਮਿੰਟ",h:"ਇੱਕ ਘੰਟਾ",hh:"%d ਘੰਟੇ",d:"ਇੱਕ ਦਿਨ",dd:"%d ਦਿਨ",M:"ਇੱਕ ਮਹੀਨਾ",MM:"%d ਮਹੀਨੇ",y:"ਇੱਕ ਸਾਲ",yy:"%d ਸਾਲ"},preparse:function(e){return e.replace(/[੧੨੩੪੫੬੭੮੯੦]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/ਰਾਤ|ਸਵੇਰ|ਦੁਪਹਿਰ|ਸ਼ਾਮ/,meridiemHour:function(e,t){return 12===e&&(e=0),"ਰਾਤ"===t?e<4?e:e+12:"ਸਵੇਰ"===t?e:"ਦੁਪਹਿਰ"===t?e>=10?e:e+12:"ਸ਼ਾਮ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"ਰਾਤ":e<10?"ਸਵੇਰ":e<17?"ਦੁਪਹਿਰ":e<20?"ਸ਼ਾਮ":"ਰਾਤ"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień".split("_"),n="stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia".split("_");function o(e){return e%10<5&&e%10>1&&~~(e/10)%10!=1}function r(e,t,n){var r=e+" ";switch(n){case"m":return t?"minuta":"minutę";case"mm":return r+(o(e)?"minuty":"minut");case"h":return t?"godzina":"godzinę";case"hh":return r+(o(e)?"godziny":"godzin");case"MM":return r+(o(e)?"miesiące":"miesięcy");case"yy":return r+(o(e)?"lata":"lat")}}e.defineLocale("pl",{months:function(e,o){return""===o?"("+n[e.month()]+"|"+t[e.month()]+")":/D MMMM/.test(o)?n[e.month()]:t[e.month()]},monthsShort:"sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru".split("_"),weekdays:"niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota".split("_"),weekdaysShort:"nie_pon_wt_śr_czw_pt_sb".split("_"),weekdaysMin:"Nd_Pn_Wt_Śr_Cz_Pt_So".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:"[Dziś o] LT",nextDay:"[Jutro o] LT",nextWeek:"[W] dddd [o] LT",lastDay:"[Wczoraj o] LT",lastWeek:function(){switch(this.day()){case 0:return"[W zeszłą niedzielę o] LT";case 3:return"[W zeszłą środę o] LT";case 6:return"[W zeszłą sobotę o] LT";default:return"[W zeszły] dddd [o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"%s temu",s:"kilka sekund",m:r,mm:r,h:r,hh:r,d:"1 dzień",dd:"%d dni",M:"miesiąc",MM:r,y:"rok",yy:r},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("pt",{months:"Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingo_Segunda-Feira_Terça-Feira_Quarta-Feira_Quinta-Feira_Sexta-Feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Dom_2ª_3ª_4ª_5ª_6ª_Sáb".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},ordinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("pt-br",{months:"Janeiro_Fevereiro_Março_Abril_Maio_Junho_Julho_Agosto_Setembro_Outubro_Novembro_Dezembro".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Dom_2ª_3ª_4ª_5ª_6ª_Sáb".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY [às] HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"%s atrás",s:"poucos segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},ordinalParse:/\d{1,2}º/,ordinal:"%dº"})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var o=" ";return(e%100>=20||e>=100&&e%100==0)&&(o=" de "),e+o+{mm:"minute",hh:"ore",dd:"zile",MM:"luni",yy:"ani"}[n]}e.defineLocale("ro",{months:"ianuarie_februarie_martie_aprilie_mai_iunie_iulie_august_septembrie_octombrie_noiembrie_decembrie".split("_"),monthsShort:"ian._febr._mart._apr._mai_iun._iul._aug._sept._oct._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"duminică_luni_marți_miercuri_joi_vineri_sâmbătă".split("_"),weekdaysShort:"Dum_Lun_Mar_Mie_Joi_Vin_Sâm".split("_"),weekdaysMin:"Du_Lu_Ma_Mi_Jo_Vi_Sâ".split("_"),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:"[azi la] LT",nextDay:"[mâine la] LT",nextWeek:"dddd [la] LT",lastDay:"[ieri la] LT",lastWeek:"[fosta] dddd [la] LT",sameElse:"L"},relativeTime:{future:"peste %s",past:"%s în urmă",s:"câteva secunde",m:"un minut",mm:t,h:"o oră",hh:t,d:"o zi",dd:t,M:"o lună",MM:t,y:"un an",yy:t},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var o,r;return"m"===n?t?"минута":"минуту":e+" "+(o=+e,r={mm:t?"минута_минуты_минут":"минуту_минуты_минут",hh:"час_часа_часов",dd:"день_дня_дней",MM:"месяц_месяца_месяцев",yy:"год_года_лет"}[n].split("_"),o%10==1&&o%100!=11?r[0]:o%10>=2&&o%10<=4&&(o%100<10||o%100>=20)?r[1]:r[2])}var n=[/^янв/i,/^фев/i,/^мар/i,/^апр/i,/^ма[йя]/i,/^июн/i,/^июл/i,/^авг/i,/^сен/i,/^окт/i,/^ноя/i,/^дек/i];e.defineLocale("ru",{months:{format:"января_февраля_марта_апреля_мая_июня_июля_августа_сентября_октября_ноября_декабря".split("_"),standalone:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_")},monthsShort:{format:"янв._февр._мар._апр._мая_июня_июля_авг._сент._окт._нояб._дек.".split("_"),standalone:"янв._февр._март_апр._май_июнь_июль_авг._сент._окт._нояб._дек.".split("_")},weekdays:{standalone:"воскресенье_понедельник_вторник_среда_четверг_пятница_суббота".split("_"),format:"воскресенье_понедельник_вторник_среду_четверг_пятницу_субботу".split("_"),isFormat:/\[ ?[Вв] ?(?:прошлую|следующую|эту)? ?\] ?dddd/},weekdaysShort:"вс_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"вс_пн_вт_ср_чт_пт_сб".split("_"),monthsParse:n,longMonthsParse:n,shortMonthsParse:n,monthsRegex:/^(сентябр[яь]|октябр[яь]|декабр[яь]|феврал[яь]|январ[яь]|апрел[яь]|августа?|ноябр[яь]|сент\.|февр\.|нояб\.|июнь|янв.|июль|дек.|авг.|апр.|марта|мар[.т]|окт.|июн[яь]|июл[яь]|ма[яй])/i,monthsShortRegex:/^(сентябр[яь]|октябр[яь]|декабр[яь]|феврал[яь]|январ[яь]|апрел[яь]|августа?|ноябр[яь]|сент\.|февр\.|нояб\.|июнь|янв.|июль|дек.|авг.|апр.|марта|мар[.т]|окт.|июн[яь]|июл[яь]|ма[яй])/i,monthsStrictRegex:/^(сентябр[яь]|октябр[яь]|декабр[яь]|феврал[яь]|январ[яь]|апрел[яь]|августа?|ноябр[яь]|марта?|июн[яь]|июл[яь]|ма[яй])/i,monthsShortStrictRegex:/^(нояб\.|февр\.|сент\.|июль|янв\.|июн[яь]|мар[.т]|авг\.|апр\.|окт\.|дек\.|ма[яй])/i,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:"[Сегодня в] LT",nextDay:"[Завтра в] LT",lastDay:"[Вчера в] LT",nextWeek:function(e){if(e.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(e){if(e.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:"несколько секунд",m:t,mm:t,h:"час",hh:t,d:"день",dd:t,M:"месяц",MM:t,y:"год",yy:t},meridiemParse:/ночи|утра|дня|вечера/i,isPM:function(e){return/^(дня|вечера)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночи":e<12?"утра":e<17?"дня":"вечера"},ordinalParse:/\d{1,2}-(й|го|я)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":return e+"-й";case"D":return e+"-го";case"w":case"W":return e+"-я";default:return e}},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("se",{months:"ođđajagemánnu_guovvamánnu_njukčamánnu_cuoŋománnu_miessemánnu_geassemánnu_suoidnemánnu_borgemánnu_čakčamánnu_golggotmánnu_skábmamánnu_juovlamánnu".split("_"),monthsShort:"ođđj_guov_njuk_cuo_mies_geas_suoi_borg_čakč_golg_skáb_juov".split("_"),weekdays:"sotnabeaivi_vuossárga_maŋŋebárga_gaskavahkku_duorastat_bearjadat_lávvardat".split("_"),weekdaysShort:"sotn_vuos_maŋ_gask_duor_bear_láv".split("_"),weekdaysMin:"s_v_m_g_d_b_L".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"MMMM D. [b.] YYYY",LLL:"MMMM D. [b.] YYYY [ti.] HH:mm",LLLL:"dddd, MMMM D. [b.] YYYY [ti.] HH:mm"},calendar:{sameDay:"[otne ti] LT",nextDay:"[ihttin ti] LT",nextWeek:"dddd [ti] LT",lastDay:"[ikte ti] LT",lastWeek:"[ovddit] dddd [ti] LT",sameElse:"L"},relativeTime:{future:"%s geažes",past:"maŋit %s",s:"moadde sekunddat",m:"okta minuhta",mm:"%d minuhtat",h:"okta diimmu",hh:"%d diimmut",d:"okta beaivi",dd:"%d beaivvit",M:"okta mánnu",MM:"%d mánut",y:"okta jahki",yy:"%d jagit"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("si",{months:"ජනවාරි_පෙබරවාරි_මාර්තු_අප්‍රේල්_මැයි_ජූනි_ජූලි_අගෝස්තු_සැප්තැම්බර්_ඔක්තෝබර්_නොවැම්බර්_දෙසැම්බර්".split("_"),monthsShort:"ජන_පෙබ_මාර්_අප්_මැයි_ජූනි_ජූලි_අගෝ_සැප්_ඔක්_නොවැ_දෙසැ".split("_"),weekdays:"ඉරිදා_සඳුදා_අඟහරුවාදා_බදාදා_බ්‍රහස්පතින්දා_සිකුරාදා_සෙනසුරාදා".split("_"),weekdaysShort:"ඉරි_සඳු_අඟ_බදා_බ්‍රහ_සිකු_සෙන".split("_"),weekdaysMin:"ඉ_ස_අ_බ_බ්‍ර_සි_සෙ".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"a h:mm",LTS:"a h:mm:ss",L:"YYYY/MM/DD",LL:"YYYY MMMM D",LLL:"YYYY MMMM D, a h:mm",LLLL:"YYYY MMMM D [වැනි] dddd, a h:mm:ss"},calendar:{sameDay:"[අද] LT[ට]",nextDay:"[හෙට] LT[ට]",nextWeek:"dddd LT[ට]",lastDay:"[ඊයේ] LT[ට]",lastWeek:"[පසුගිය] dddd LT[ට]",sameElse:"L"},relativeTime:{future:"%sකින්",past:"%sකට පෙර",s:"තත්පර කිහිපය",m:"මිනිත්තුව",mm:"මිනිත්තු %d",h:"පැය",hh:"පැය %d",d:"දිනය",dd:"දින %d",M:"මාසය",MM:"මාස %d",y:"වසර",yy:"වසර %d"},ordinalParse:/\d{1,2} වැනි/,ordinal:function(e){return e+" වැනි"},meridiemParse:/පෙර වරු|පස් වරු|පෙ.ව|ප.ව./,isPM:function(e){return"ප.ව."===e||"පස් වරු"===e},meridiem:function(e,t,n){return e>11?n?"ප.ව.":"පස් වරු":n?"පෙ.ව.":"පෙර වරු"}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="január_február_marec_apríl_máj_jún_júl_august_september_október_november_december".split("_"),n="jan_feb_mar_apr_máj_jún_júl_aug_sep_okt_nov_dec".split("_");function o(e){return e>1&&e<5}function r(e,t,n,r){var i=e+" ";switch(n){case"s":return t||r?"pár sekúnd":"pár sekundami";case"m":return t?"minúta":r?"minútu":"minútou";case"mm":return t||r?i+(o(e)?"minúty":"minút"):i+"minútami";case"h":return t?"hodina":r?"hodinu":"hodinou";case"hh":return t||r?i+(o(e)?"hodiny":"hodín"):i+"hodinami";case"d":return t||r?"deň":"dňom";case"dd":return t||r?i+(o(e)?"dni":"dní"):i+"dňami";case"M":return t||r?"mesiac":"mesiacom";case"MM":return t||r?i+(o(e)?"mesiace":"mesiacov"):i+"mesiacmi";case"y":return t||r?"rok":"rokom";case"yy":return t||r?i+(o(e)?"roky":"rokov"):i+"rokmi"}}e.defineLocale("sk",{months:t,monthsShort:n,weekdays:"nedeľa_pondelok_utorok_streda_štvrtok_piatok_sobota".split("_"),weekdaysShort:"ne_po_ut_st_št_pi_so".split("_"),weekdaysMin:"ne_po_ut_st_št_pi_so".split("_"),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:"[dnes o] LT",nextDay:"[zajtra o] LT",nextWeek:function(){switch(this.day()){case 0:return"[v nedeľu o] LT";case 1:case 2:return"[v] dddd [o] LT";case 3:return"[v stredu o] LT";case 4:return"[vo štvrtok o] LT";case 5:return"[v piatok o] LT";case 6:return"[v sobotu o] LT"}},lastDay:"[včera o] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulú nedeľu o] LT";case 1:case 2:return"[minulý] dddd [o] LT";case 3:return"[minulú stredu o] LT";case 4:case 5:return"[minulý] dddd [o] LT";case 6:return"[minulú sobotu o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"pred %s",s:r,m:r,mm:r,h:r,hh:r,d:r,dd:r,M:r,MM:r,y:r,yy:r},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n,o){var r=e+" ";switch(n){case"s":return t||o?"nekaj sekund":"nekaj sekundami";case"m":return t?"ena minuta":"eno minuto";case"mm":return r+=1===e?t?"minuta":"minuto":2===e?t||o?"minuti":"minutama":e<5?t||o?"minute":"minutami":t||o?"minut":"minutami";case"h":return t?"ena ura":"eno uro";case"hh":return r+=1===e?t?"ura":"uro":2===e?t||o?"uri":"urama":e<5?t||o?"ure":"urami":t||o?"ur":"urami";case"d":return t||o?"en dan":"enim dnem";case"dd":return r+=1===e?t||o?"dan":"dnem":2===e?t||o?"dni":"dnevoma":t||o?"dni":"dnevi";case"M":return t||o?"en mesec":"enim mesecem";case"MM":return r+=1===e?t||o?"mesec":"mesecem":2===e?t||o?"meseca":"mesecema":e<5?t||o?"mesece":"meseci":t||o?"mesecev":"meseci";case"y":return t||o?"eno leto":"enim letom";case"yy":return r+=1===e?t||o?"leto":"letom":2===e?t||o?"leti":"letoma":e<5?t||o?"leta":"leti":t||o?"let":"leti"}}e.defineLocale("sl",{months:"januar_februar_marec_april_maj_junij_julij_avgust_september_oktober_november_december".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedelja_ponedeljek_torek_sreda_četrtek_petek_sobota".split("_"),weekdaysShort:"ned._pon._tor._sre._čet._pet._sob.".split("_"),weekdaysMin:"ne_po_to_sr_če_pe_so".split("_"),weekdaysParseExact:!0,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:"[danes ob] LT",nextDay:"[jutri ob] LT",nextWeek:function(){switch(this.day()){case 0:return"[v] [nedeljo] [ob] LT";case 3:return"[v] [sredo] [ob] LT";case 6:return"[v] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[v] dddd [ob] LT"}},lastDay:"[včeraj ob] LT",lastWeek:function(){switch(this.day()){case 0:return"[prejšnjo] [nedeljo] [ob] LT";case 3:return"[prejšnjo] [sredo] [ob] LT";case 6:return"[prejšnjo] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[prejšnji] dddd [ob] LT"}},sameElse:"L"},relativeTime:{future:"čez %s",past:"pred %s",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("sq",{months:"Janar_Shkurt_Mars_Prill_Maj_Qershor_Korrik_Gusht_Shtator_Tetor_Nëntor_Dhjetor".split("_"),monthsShort:"Jan_Shk_Mar_Pri_Maj_Qer_Kor_Gus_Sht_Tet_Nën_Dhj".split("_"),weekdays:"E Diel_E Hënë_E Martë_E Mërkurë_E Enjte_E Premte_E Shtunë".split("_"),weekdaysShort:"Die_Hën_Mar_Mër_Enj_Pre_Sht".split("_"),weekdaysMin:"D_H_Ma_Më_E_P_Sh".split("_"),weekdaysParseExact:!0,meridiemParse:/PD|MD/,isPM:function(e){return"M"===e.charAt(0)},meridiem:function(e,t,n){return e<12?"PD":"MD"},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:"[Sot në] LT",nextDay:"[Nesër në] LT",nextWeek:"dddd [në] LT",lastDay:"[Dje në] LT",lastWeek:"dddd [e kaluar në] LT",sameElse:"L"},relativeTime:{future:"në %s",past:"%s më parë",s:"disa sekonda",m:"një minutë",mm:"%d minuta",h:"një orë",hh:"%d orë",d:"një ditë",dd:"%d ditë",M:"një muaj",MM:"%d muaj",y:"një vit",yy:"%d vite"},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={words:{m:["jedan minut","jedne minute"],mm:["minut","minute","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],dd:["dan","dana","dana"],MM:["mesec","meseca","meseci"],yy:["godina","godine","godina"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,o){var r=t.words[o];return 1===o.length?n?r[0]:r[1]:e+" "+t.correctGrammaticalCase(e,r)}};e.defineLocale("sr",{months:"januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sre._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,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:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedelju] [u] LT";case 3:return"[u] [sredu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){return["[prošle] [nedelje] [u] LT","[prošlog] [ponedeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"pre %s",s:"nekoliko sekundi",m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"dan",dd:t.translate,M:"mesec",MM:t.translate,y:"godinu",yy:t.translate},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={words:{m:["један минут","једне минуте"],mm:["минут","минуте","минута"],h:["један сат","једног сата"],hh:["сат","сата","сати"],dd:["дан","дана","дана"],MM:["месец","месеца","месеци"],yy:["година","године","година"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,o){var r=t.words[o];return 1===o.length?n?r[0]:r[1]:e+" "+t.correctGrammaticalCase(e,r)}};e.defineLocale("sr-cyrl",{months:"јануар_фебруар_март_април_мај_јун_јул_август_септембар_октобар_новембар_децембар".split("_"),monthsShort:"јан._феб._мар._апр._мај_јун_јул_авг._сеп._окт._нов._дец.".split("_"),monthsParseExact:!0,weekdays:"недеља_понедељак_уторак_среда_четвртак_петак_субота".split("_"),weekdaysShort:"нед._пон._уто._сре._чет._пет._суб.".split("_"),weekdaysMin:"не_по_ут_ср_че_пе_су".split("_"),weekdaysParseExact:!0,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",nextWeek:function(){switch(this.day()){case 0:return"[у] [недељу] [у] LT";case 3:return"[у] [среду] [у] LT";case 6:return"[у] [суботу] [у] LT";case 1:case 2:case 4:case 5:return"[у] dddd [у] LT"}},lastDay:"[јуче у] LT",lastWeek:function(){return["[прошле] [недеље] [у] LT","[прошлог] [понедељка] [у] LT","[прошлог] [уторка] [у] LT","[прошле] [среде] [у] LT","[прошлог] [четвртка] [у] LT","[прошлог] [петка] [у] LT","[прошле] [суботе] [у] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"за %s",past:"пре %s",s:"неколико секунди",m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"дан",dd:t.translate,M:"месец",MM:t.translate,y:"годину",yy:t.translate},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("ss",{months:"Bhimbidvwane_Indlovana_Indlov'lenkhulu_Mabasa_Inkhwekhweti_Inhlaba_Kholwane_Ingci_Inyoni_Imphala_Lweti_Ingongoni".split("_"),monthsShort:"Bhi_Ina_Inu_Mab_Ink_Inh_Kho_Igc_Iny_Imp_Lwe_Igo".split("_"),weekdays:"Lisontfo_Umsombuluko_Lesibili_Lesitsatfu_Lesine_Lesihlanu_Umgcibelo".split("_"),weekdaysShort:"Lis_Umb_Lsb_Les_Lsi_Lsh_Umg".split("_"),weekdaysMin:"Li_Us_Lb_Lt_Ls_Lh_Ug".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Namuhla nga] LT",nextDay:"[Kusasa nga] LT",nextWeek:"dddd [nga] LT",lastDay:"[Itolo nga] LT",lastWeek:"dddd [leliphelile] [nga] LT",sameElse:"L"},relativeTime:{future:"nga %s",past:"wenteka nga %s",s:"emizuzwana lomcane",m:"umzuzu",mm:"%d emizuzu",h:"lihora",hh:"%d emahora",d:"lilanga",dd:"%d emalanga",M:"inyanga",MM:"%d tinyanga",y:"umnyaka",yy:"%d iminyaka"},meridiemParse:/ekuseni|emini|entsambama|ebusuku/,meridiem:function(e,t,n){return e<11?"ekuseni":e<15?"emini":e<19?"entsambama":"ebusuku"},meridiemHour:function(e,t){return 12===e&&(e=0),"ekuseni"===t?e:"emini"===t?e>=11?e:e+12:"entsambama"===t||"ebusuku"===t?0===e?0:e+12:void 0},ordinalParse:/\d{1,2}/,ordinal:"%d",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("sv",{months:"januari_februari_mars_april_maj_juni_juli_augusti_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"söndag_måndag_tisdag_onsdag_torsdag_fredag_lördag".split("_"),weekdaysShort:"sön_mån_tis_ons_tor_fre_lör".split("_"),weekdaysMin:"sö_må_ti_on_to_fr_lö".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [kl.] HH:mm",LLLL:"dddd D MMMM YYYY [kl.] HH:mm",lll:"D MMM YYYY HH:mm",llll:"ddd D MMM YYYY HH:mm"},calendar:{sameDay:"[Idag] LT",nextDay:"[Imorgon] LT",lastDay:"[Igår] LT",nextWeek:"[På] dddd LT",lastWeek:"[I] dddd[s] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"för %s sedan",s:"några sekunder",m:"en minut",mm:"%d minuter",h:"en timme",hh:"%d timmar",d:"en dag",dd:"%d dagar",M:"en månad",MM:"%d månader",y:"ett år",yy:"%d år"},ordinalParse:/\d{1,2}(e|a)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"e":1===t?"a":2===t?"a":"e")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("sw",{months:"Januari_Februari_Machi_Aprili_Mei_Juni_Julai_Agosti_Septemba_Oktoba_Novemba_Desemba".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ago_Sep_Okt_Nov_Des".split("_"),weekdays:"Jumapili_Jumatatu_Jumanne_Jumatano_Alhamisi_Ijumaa_Jumamosi".split("_"),weekdaysShort:"Jpl_Jtat_Jnne_Jtan_Alh_Ijm_Jmos".split("_"),weekdaysMin:"J2_J3_J4_J5_Al_Ij_J1".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:"[leo saa] LT",nextDay:"[kesho saa] LT",nextWeek:"[wiki ijayo] dddd [saat] LT",lastDay:"[jana] LT",lastWeek:"[wiki iliyopita] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s baadaye",past:"tokea %s",s:"hivi punde",m:"dakika moja",mm:"dakika %d",h:"saa limoja",hh:"masaa %d",d:"siku moja",dd:"masiku %d",M:"mwezi mmoja",MM:"miezi %d",y:"mwaka mmoja",yy:"miaka %d"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"௧",2:"௨",3:"௩",4:"௪",5:"௫",6:"௬",7:"௭",8:"௮",9:"௯",0:"௦"},n={"௧":"1","௨":"2","௩":"3","௪":"4","௫":"5","௬":"6","௭":"7","௮":"8","௯":"9","௦":"0"};e.defineLocale("ta",{months:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),monthsShort:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),weekdays:"ஞாயிற்றுக்கிழமை_திங்கட்கிழமை_செவ்வாய்கிழமை_புதன்கிழமை_வியாழக்கிழமை_வெள்ளிக்கிழமை_சனிக்கிழமை".split("_"),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:"[இன்று] LT",nextDay:"[நாளை] LT",nextWeek:"dddd, LT",lastDay:"[நேற்று] LT",lastWeek:"[கடந்த வாரம்] dddd, LT",sameElse:"L"},relativeTime:{future:"%s இல்",past:"%s முன்",s:"ஒரு சில விநாடிகள்",m:"ஒரு நிமிடம்",mm:"%d நிமிடங்கள்",h:"ஒரு மணி நேரம்",hh:"%d மணி நேரம்",d:"ஒரு நாள்",dd:"%d நாட்கள்",M:"ஒரு மாதம்",MM:"%d மாதங்கள்",y:"ஒரு வருடம்",yy:"%d ஆண்டுகள்"},ordinalParse:/\d{1,2}வது/,ordinal:function(e){return e+"வது"},preparse:function(e){return e.replace(/[௧௨௩௪௫௬௭௮௯௦]/g,function(e){return n[e]})},postformat:function(e){return e.replace(/\d/g,function(e){return t[e]})},meridiemParse:/யாமம்|வைகறை|காலை|நண்பகல்|எற்பாடு|மாலை/,meridiem:function(e,t,n){return e<2?" யாமம்":e<6?" வைகறை":e<10?" காலை":e<14?" நண்பகல்":e<18?" எற்பாடு":e<22?" மாலை":" யாமம்"},meridiemHour:function(e,t){return 12===e&&(e=0),"யாமம்"===t?e<2?e:e+12:"வைகறை"===t||"காலை"===t?e:"நண்பகல்"===t&&e>=10?e:e+12},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("te",{months:"జనవరి_ఫిబ్రవరి_మార్చి_ఏప్రిల్_మే_జూన్_జూలై_ఆగస్టు_సెప్టెంబర్_అక్టోబర్_నవంబర్_డిసెంబర్".split("_"),monthsShort:"జన._ఫిబ్ర._మార్చి_ఏప్రి._మే_జూన్_జూలై_ఆగ._సెప్._అక్టో._నవ._డిసె.".split("_"),monthsParseExact:!0,weekdays:"ఆదివారం_సోమవారం_మంగళవారం_బుధవారం_గురువారం_శుక్రవారం_శనివారం".split("_"),weekdaysShort:"ఆది_సోమ_మంగళ_బుధ_గురు_శుక్ర_శని".split("_"),weekdaysMin:"ఆ_సో_మం_బు_గు_శు_శ".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[నేడు] LT",nextDay:"[రేపు] LT",nextWeek:"dddd, LT",lastDay:"[నిన్న] LT",lastWeek:"[గత] dddd, LT",sameElse:"L"},relativeTime:{future:"%s లో",past:"%s క్రితం",s:"కొన్ని క్షణాలు",m:"ఒక నిమిషం",mm:"%d నిమిషాలు",h:"ఒక గంట",hh:"%d గంటలు",d:"ఒక రోజు",dd:"%d రోజులు",M:"ఒక నెల",MM:"%d నెలలు",y:"ఒక సంవత్సరం",yy:"%d సంవత్సరాలు"},ordinalParse:/\d{1,2}వ/,ordinal:"%dవ",meridiemParse:/రాత్రి|ఉదయం|మధ్యాహ్నం|సాయంత్రం/,meridiemHour:function(e,t){return 12===e&&(e=0),"రాత్రి"===t?e<4?e:e+12:"ఉదయం"===t?e:"మధ్యాహ్నం"===t?e>=10?e:e+12:"సాయంత్రం"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"రాత్రి":e<10?"ఉదయం":e<17?"మధ్యాహ్నం":e<20?"సాయంత్రం":"రాత్రి"},week:{dow:0,doy:6}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("th",{months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"มกรา_กุมภา_มีนา_เมษา_พฤษภา_มิถุนา_กรกฎา_สิงหา_กันยา_ตุลา_พฤศจิกา_ธันวา".split("_"),monthsParseExact:!0,weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H นาฬิกา m นาที",LTS:"H นาฬิกา m นาที s วินาที",L:"YYYY/MM/DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา H นาฬิกา m นาที",LLLL:"วันddddที่ D MMMM YYYY เวลา H นาฬิกา m นาที"},meridiemParse:/ก่อนเที่ยง|หลังเที่ยง/,isPM:function(e){return"หลังเที่ยง"===e},meridiem:function(e,t,n){return e<12?"ก่อนเที่ยง":"หลังเที่ยง"},calendar:{sameDay:"[วันนี้ เวลา] LT",nextDay:"[พรุ่งนี้ เวลา] LT",nextWeek:"dddd[หน้า เวลา] LT",lastDay:"[เมื่อวานนี้ เวลา] LT",lastWeek:"[วัน]dddd[ที่แล้ว เวลา] LT",sameElse:"L"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("tl-ph",{months:"Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre".split("_"),monthsShort:"Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis".split("_"),weekdays:"Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado".split("_"),weekdaysShort:"Lin_Lun_Mar_Miy_Huw_Biy_Sab".split("_"),weekdaysMin:"Li_Lu_Ma_Mi_Hu_Bi_Sab".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"MM/D/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY HH:mm",LLLL:"dddd, MMMM DD, YYYY HH:mm"},calendar:{sameDay:"[Ngayon sa] LT",nextDay:"[Bukas sa] LT",nextWeek:"dddd [sa] LT",lastDay:"[Kahapon sa] LT",lastWeek:"dddd [huling linggo] LT",sameElse:"L"},relativeTime:{future:"sa loob ng %s",past:"%s ang nakalipas",s:"ilang segundo",m:"isang minuto",mm:"%d minuto",h:"isang oras",hh:"%d oras",d:"isang araw",dd:"%d araw",M:"isang buwan",MM:"%d buwan",y:"isang taon",yy:"%d taon"},ordinalParse:/\d{1,2}/,ordinal:function(e){return e},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t="pagh_wa’_cha’_wej_loS_vagh_jav_Soch_chorgh_Hut".split("_");function n(e,n,o,r){var i=function(e){var n=Math.floor(e%1e3/100),o=Math.floor(e%100/10),r=e%10,i="";return n>0&&(i+=t[n]+"vatlh"),o>0&&(i+=(""!==i?" ":"")+t[o]+"maH"),r>0&&(i+=(""!==i?" ":"")+t[r]),""===i?"pagh":i}(e);switch(o){case"mm":return i+" tup";case"hh":return i+" rep";case"dd":return i+" jaj";case"MM":return i+" jar";case"yy":return i+" DIS"}}e.defineLocale("tlh",{months:"tera’ jar wa’_tera’ jar cha’_tera’ jar wej_tera’ jar loS_tera’ jar vagh_tera’ jar jav_tera’ jar Soch_tera’ jar chorgh_tera’ jar Hut_tera’ jar wa’maH_tera’ jar wa’maH wa’_tera’ jar wa’maH cha’".split("_"),monthsShort:"jar wa’_jar cha’_jar wej_jar loS_jar vagh_jar jav_jar Soch_jar chorgh_jar Hut_jar wa’maH_jar wa’maH wa’_jar wa’maH cha’".split("_"),monthsParseExact:!0,weekdays:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),weekdaysShort:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),weekdaysMin:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".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:"[DaHjaj] LT",nextDay:"[wa’leS] LT",nextWeek:"LLL",lastDay:"[wa’Hu’] LT",lastWeek:"LLL",sameElse:"L"},relativeTime:{future:function(e){var t=e;return t=-1!==e.indexOf("jaj")?t.slice(0,-3)+"leS":-1!==e.indexOf("jar")?t.slice(0,-3)+"waQ":-1!==e.indexOf("DIS")?t.slice(0,-3)+"nem":t+" pIq"},past:function(e){var t=e;return t=-1!==e.indexOf("jaj")?t.slice(0,-3)+"Hu’":-1!==e.indexOf("jar")?t.slice(0,-3)+"wen":-1!==e.indexOf("DIS")?t.slice(0,-3)+"ben":t+" ret"},s:"puS lup",m:"wa’ tup",mm:n,h:"wa’ rep",hh:n,d:"wa’ jaj",dd:n,M:"wa’ jar",MM:n,y:"wa’ DIS",yy:n},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";var t={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"};e.defineLocale("tr",{months:"Ocak_Şubat_Mart_Nisan_Mayıs_Haziran_Temmuz_Ağustos_Eylül_Ekim_Kasım_Aralık".split("_"),monthsShort:"Oca_Şub_Mar_Nis_May_Haz_Tem_Ağu_Eyl_Eki_Kas_Ara".split("_"),weekdays:"Pazar_Pazartesi_Salı_Çarşamba_Perşembe_Cuma_Cumartesi".split("_"),weekdaysShort:"Paz_Pts_Sal_Çar_Per_Cum_Cts".split("_"),weekdaysMin:"Pz_Pt_Sa_Ça_Pe_Cu_Ct".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:"[bugün saat] LT",nextDay:"[yarın saat] LT",nextWeek:"[haftaya] dddd [saat] LT",lastDay:"[dün] LT",lastWeek:"[geçen hafta] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s önce",s:"birkaç saniye",m:"bir dakika",mm:"%d dakika",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir yıl",yy:"%d yıl"},ordinalParse:/\d{1,2}'(inci|nci|üncü|ncı|uncu|ıncı)/,ordinal:function(e){if(0===e)return e+"'ıncı";var n=e%10;return e+(t[n]||t[e%100-n]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n,o){var r={s:["viensas secunds","'iensas secunds"],m:["'n míut","'iens míut"],mm:[e+" míuts",e+" míuts"],h:["'n þora","'iensa þora"],hh:[e+" þoras",e+" þoras"],d:["'n ziua","'iensa ziua"],dd:[e+" ziuas",e+" ziuas"],M:["'n mes","'iens mes"],MM:[e+" mesen",e+" mesen"],y:["'n ar","'iens ar"],yy:[e+" ars",e+" ars"]};return o?r[n][0]:t?r[n][0]:r[n][1]}e.defineLocale("tzl",{months:"Januar_Fevraglh_Març_Avrïu_Mai_Gün_Julia_Guscht_Setemvar_Listopäts_Noemvar_Zecemvar".split("_"),monthsShort:"Jan_Fev_Mar_Avr_Mai_Gün_Jul_Gus_Set_Lis_Noe_Zec".split("_"),weekdays:"Súladi_Lúneçi_Maitzi_Márcuri_Xhúadi_Viénerçi_Sáturi".split("_"),weekdaysShort:"Súl_Lún_Mai_Már_Xhú_Vié_Sát".split("_"),weekdaysMin:"Sú_Lú_Ma_Má_Xh_Vi_Sá".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD.MM.YYYY",LL:"D. MMMM [dallas] YYYY",LLL:"D. MMMM [dallas] YYYY HH.mm",LLLL:"dddd, [li] D. MMMM [dallas] YYYY HH.mm"},meridiemParse:/d\'o|d\'a/i,isPM:function(e){return"d'o"===e.toLowerCase()},meridiem:function(e,t,n){return e>11?n?"d'o":"D'O":n?"d'a":"D'A"},calendar:{sameDay:"[oxhi à] LT",nextDay:"[demà à] LT",nextWeek:"dddd [à] LT",lastDay:"[ieiri à] LT",lastWeek:"[sür el] dddd [lasteu à] LT",sameElse:"L"},relativeTime:{future:"osprei %s",past:"ja%s",s:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},ordinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("tzm",{months:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),monthsShort:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),weekdays:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),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:"[ⴰⵙⴷⵅ ⴴ] LT",nextDay:"[ⴰⵙⴽⴰ ⴴ] LT",nextWeek:"dddd [ⴴ] LT",lastDay:"[ⴰⵚⴰⵏⵜ ⴴ] LT",lastWeek:"dddd [ⴴ] LT",sameElse:"L"},relativeTime:{future:"ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s",past:"ⵢⴰⵏ %s",s:"ⵉⵎⵉⴽ",m:"ⵎⵉⵏⵓⴺ",mm:"%d ⵎⵉⵏⵓⴺ",h:"ⵙⴰⵄⴰ",hh:"%d ⵜⴰⵙⵙⴰⵄⵉⵏ",d:"ⴰⵙⵙ",dd:"%d oⵙⵙⴰⵏ",M:"ⴰⵢoⵓⵔ",MM:"%d ⵉⵢⵢⵉⵔⵏ",y:"ⴰⵙⴳⴰⵙ",yy:"%d ⵉⵙⴳⴰⵙⵏ"},week:{dow:6,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("tzm-latn",{months:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),monthsShort:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),weekdays:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysShort:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysMin:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".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:"[asdkh g] LT",nextDay:"[aska g] LT",nextWeek:"dddd [g] LT",lastDay:"[assant g] LT",lastWeek:"dddd [g] LT",sameElse:"L"},relativeTime:{future:"dadkh s yan %s",past:"yan %s",s:"imik",m:"minuḍ",mm:"%d minuḍ",h:"saɛa",hh:"%d tassaɛin",d:"ass",dd:"%d ossan",M:"ayowr",MM:"%d iyyirn",y:"asgas",yy:"%d isgasn"},week:{dow:6,doy:12}})}(n(3))},function(e,t,n){!function(e){"use strict";function t(e,t,n){var o,r;return"m"===n?t?"хвилина":"хвилину":"h"===n?t?"година":"годину":e+" "+(o=+e,r={mm:t?"хвилина_хвилини_хвилин":"хвилину_хвилини_хвилин",hh:t?"година_години_годин":"годину_години_годин",dd:"день_дні_днів",MM:"місяць_місяці_місяців",yy:"рік_роки_років"}[n].split("_"),o%10==1&&o%100!=11?r[0]:o%10>=2&&o%10<=4&&(o%100<10||o%100>=20)?r[1]:r[2])}function n(e){return function(){return e+"о"+(11===this.hours()?"б":"")+"] LT"}}e.defineLocale("uk",{months:{format:"січня_лютого_березня_квітня_травня_червня_липня_серпня_вересня_жовтня_листопада_грудня".split("_"),standalone:"січень_лютий_березень_квітень_травень_червень_липень_серпень_вересень_жовтень_листопад_грудень".split("_")},monthsShort:"січ_лют_бер_квіт_трав_черв_лип_серп_вер_жовт_лист_груд".split("_"),weekdays:function(e,t){return{nominative:"неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота".split("_"),accusative:"неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу".split("_"),genitive:"неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи".split("_")}[/(\[[ВвУу]\]) ?dddd/.test(t)?"accusative":/\[?(?:минулої|наступної)? ?\] ?dddd/.test(t)?"genitive":"nominative"][e.day()]},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:n("[Сьогодні "),nextDay:n("[Завтра "),lastDay:n("[Вчора "),nextWeek:n("[У] dddd ["),lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return n("[Минулої] dddd [").call(this);case 1:case 2:case 4:return n("[Минулого] dddd [").call(this)}},sameElse:"L"},relativeTime:{future:"за %s",past:"%s тому",s:"декілька секунд",m:t,mm:t,h:"годину",hh:t,d:"день",dd:t,M:"місяць",MM:t,y:"рік",yy:t},meridiemParse:/ночі|ранку|дня|вечора/,isPM:function(e){return/^(дня|вечора)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночі":e<12?"ранку":e<17?"дня":"вечора"},ordinalParse:/\d{1,2}-(й|го)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e+"-й";case"D":return e+"-го";default:return e}},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("uz",{months:"январ_феврал_март_апрел_май_июн_июл_август_сентябр_октябр_ноябр_декабр".split("_"),monthsShort:"янв_фев_мар_апр_май_июн_июл_авг_сен_окт_ноя_дек".split("_"),weekdays:"Якшанба_Душанба_Сешанба_Чоршанба_Пайшанба_Жума_Шанба".split("_"),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:"D MMMM YYYY, dddd HH:mm"},calendar:{sameDay:"[Бугун соат] LT [да]",nextDay:"[Эртага] LT [да]",nextWeek:"dddd [куни соат] LT [да]",lastDay:"[Кеча соат] LT [да]",lastWeek:"[Утган] dddd [куни соат] LT [да]",sameElse:"L"},relativeTime:{future:"Якин %s ичида",past:"Бир неча %s олдин",s:"фурсат",m:"бир дакика",mm:"%d дакика",h:"бир соат",hh:"%d соат",d:"бир кун",dd:"%d кун",M:"бир ой",MM:"%d ой",y:"бир йил",yy:"%d йил"},week:{dow:1,doy:7}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("vi",{months:"tháng 1_tháng 2_tháng 3_tháng 4_tháng 5_tháng 6_tháng 7_tháng 8_tháng 9_tháng 10_tháng 11_tháng 12".split("_"),monthsShort:"Th01_Th02_Th03_Th04_Th05_Th06_Th07_Th08_Th09_Th10_Th11_Th12".split("_"),monthsParseExact:!0,weekdays:"chủ nhật_thứ hai_thứ ba_thứ tư_thứ năm_thứ sáu_thứ bảy".split("_"),weekdaysShort:"CN_T2_T3_T4_T5_T6_T7".split("_"),weekdaysMin:"CN_T2_T3_T4_T5_T6_T7".split("_"),weekdaysParseExact:!0,meridiemParse:/sa|ch/i,isPM:function(e){return/^ch$/i.test(e)},meridiem:function(e,t,n){return e<12?n?"sa":"SA":n?"ch":"CH"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM [năm] YYYY",LLL:"D MMMM [năm] YYYY HH:mm",LLLL:"dddd, D MMMM [năm] YYYY HH:mm",l:"DD/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY HH:mm",llll:"ddd, D MMM YYYY HH:mm"},calendar:{sameDay:"[Hôm nay lúc] LT",nextDay:"[Ngày mai lúc] LT",nextWeek:"dddd [tuần tới lúc] LT",lastDay:"[Hôm qua lúc] LT",lastWeek:"dddd [tuần rồi lúc] LT",sameElse:"L"},relativeTime:{future:"%s tới",past:"%s trước",s:"vài giây",m:"một phút",mm:"%d phút",h:"một giờ",hh:"%d giờ",d:"một ngày",dd:"%d ngày",M:"một tháng",MM:"%d tháng",y:"một năm",yy:"%d năm"},ordinalParse:/\d{1,2}/,ordinal:function(e){return e},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("x-pseudo",{months:"J~áñúá~rý_F~ébrú~árý_~Márc~h_Áp~ríl_~Máý_~Júñé~_Júl~ý_Áú~gúst~_Sép~témb~ér_Ó~ctób~ér_Ñ~óvém~bér_~Décé~mbér".split("_"),monthsShort:"J~áñ_~Féb_~Már_~Ápr_~Máý_~Júñ_~Júl_~Áúg_~Sép_~Óct_~Ñóv_~Déc".split("_"),monthsParseExact:!0,weekdays:"S~úñdá~ý_Mó~ñdáý~_Túé~sdáý~_Wéd~ñésd~áý_T~húrs~dáý_~Fríd~áý_S~átúr~dáý".split("_"),weekdaysShort:"S~úñ_~Móñ_~Túé_~Wéd_~Thú_~Frí_~Sát".split("_"),weekdaysMin:"S~ú_Mó~_Tú_~Wé_T~h_Fr~_Sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[T~ódá~ý át] LT",nextDay:"[T~ómó~rró~w át] LT",nextWeek:"dddd [át] LT",lastDay:"[Ý~ést~érdá~ý át] LT",lastWeek:"[L~ást] dddd [át] LT",sameElse:"L"},relativeTime:{future:"í~ñ %s",past:"%s á~gó",s:"á ~féw ~sécó~ñds",m:"á ~míñ~úté",mm:"%d m~íñú~tés",h:"á~ñ hó~úr",hh:"%d h~óúrs",d:"á ~dáý",dd:"%d d~áýs",M:"á ~móñ~th",MM:"%d m~óñt~hs",y:"á ~ýéár",yy:"%d ý~éárs"},ordinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("zh-cn",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"周日_周一_周二_周三_周四_周五_周六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"Ah点mm分",LTS:"Ah点m分s秒",L:"YYYY-MM-DD",LL:"YYYY年MMMD日",LLL:"YYYY年MMMD日Ah点mm分",LLLL:"YYYY年MMMD日ddddAh点mm分",l:"YYYY-MM-DD",ll:"YYYY年MMMD日",lll:"YYYY年MMMD日Ah点mm分",llll:"YYYY年MMMD日ddddAh点mm分"},meridiemParse:/凌晨|早上|上午|中午|下午|晚上/,meridiemHour:function(e,t){return 12===e&&(e=0),"凌晨"===t||"早上"===t||"上午"===t?e:"下午"===t||"晚上"===t?e+12:e>=11?e:e+12},meridiem:function(e,t,n){var o=100*e+t;return o<600?"凌晨":o<900?"早上":o<1130?"上午":o<1230?"中午":o<1800?"下午":"晚上"},calendar:{sameDay:function(){return 0===this.minutes()?"[今天]Ah[点整]":"[今天]LT"},nextDay:function(){return 0===this.minutes()?"[明天]Ah[点整]":"[明天]LT"},lastDay:function(){return 0===this.minutes()?"[昨天]Ah[点整]":"[昨天]LT"},nextWeek:function(){var t,n;return t=e().startOf("week"),n=this.diff(t,"days")>=7?"[下]":"[本]",0===this.minutes()?n+"dddAh点整":n+"dddAh点mm"},lastWeek:function(){var t,n;return t=e().startOf("week"),n=this.unix()<t.unix()?"[上]":"[本]",0===this.minutes()?n+"dddAh点整":n+"dddAh点mm"},sameElse:"LL"},ordinalParse:/\d{1,2}(日|月|周)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"周";default:return e}},relativeTime:{future:"%s内",past:"%s前",s:"几秒",m:"1 分钟",mm:"%d 分钟",h:"1 小时",hh:"%d 小时",d:"1 天",dd:"%d 天",M:"1 个月",MM:"%d 个月",y:"1 年",yy:"%d 年"},week:{dow:1,doy:4}})}(n(3))},function(e,t,n){!function(e){"use strict";e.defineLocale("zh-tw",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"週日_週一_週二_週三_週四_週五_週六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"Ah點mm分",LTS:"Ah點m分s秒",L:"YYYY年MMMD日",LL:"YYYY年MMMD日",LLL:"YYYY年MMMD日Ah點mm分",LLLL:"YYYY年MMMD日ddddAh點mm分",l:"YYYY年MMMD日",ll:"YYYY年MMMD日",lll:"YYYY年MMMD日Ah點mm分",llll:"YYYY年MMMD日ddddAh點mm分"},meridiemParse:/早上|上午|中午|下午|晚上/,meridiemHour:function(e,t){return 12===e&&(e=0),"早上"===t||"上午"===t?e:"中午"===t?e>=11?e:e+12:"下午"===t||"晚上"===t?e+12:void 0},meridiem:function(e,t,n){var o=100*e+t;return o<900?"早上":o<1130?"上午":o<1230?"中午":o<1800?"下午":"晚上"},calendar:{sameDay:"[今天]LT",nextDay:"[明天]LT",nextWeek:"[下]ddddLT",lastDay:"[昨天]LT",lastWeek:"[上]ddddLT",sameElse:"L"},ordinalParse:/\d{1,2}(日|月|週)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"週";default:return e}},relativeTime:{future:"%s內",past:"%s前",s:"幾秒",m:"1分鐘",mm:"%d分鐘",h:"1小時",hh:"%d小時",d:"1天",dd:"%d天",M:"1個月",MM:"%d個月",y:"1年",yy:"%d年"}})}(n(3))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,n){var o=n(346);"string"==typeof o&&(o=[[e.i,o,""]]);n(13)(o,{});o.locals&&(e.exports=o.locals)},function(e,t,n){(e.exports=n(12)(!1)).push([e.i,"/* BASICS */\n\n.CodeMirror {\n /* Set height, width, borders, and global font properties here */\n font-family: monospace;\n height: 300px;\n color: black;\n direction: ltr;\n}\n\n/* PADDING */\n\n.CodeMirror-lines {\n padding: 4px 0; /* Vertical padding around content */\n}\n.CodeMirror pre {\n padding: 0 4px; /* Horizontal padding of content */\n}\n\n.CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {\n background-color: white; /* The little square between H and V scrollbars */\n}\n\n/* GUTTER */\n\n.CodeMirror-gutters {\n border-right: 1px solid #ddd;\n background-color: #f7f7f7;\n white-space: nowrap;\n}\n.CodeMirror-linenumbers {}\n.CodeMirror-linenumber {\n padding: 0 3px 0 5px;\n min-width: 20px;\n text-align: right;\n color: #999;\n white-space: nowrap;\n}\n\n.CodeMirror-guttermarker { color: black; }\n.CodeMirror-guttermarker-subtle { color: #999; }\n\n/* CURSOR */\n\n.CodeMirror-cursor {\n border-left: 1px solid black;\n border-right: none;\n width: 0;\n}\n/* Shown when moving in bi-directional text */\n.CodeMirror div.CodeMirror-secondarycursor {\n border-left: 1px solid silver;\n}\n.cm-fat-cursor .CodeMirror-cursor {\n width: auto;\n border: 0 !important;\n background: #7e7;\n}\n.cm-fat-cursor div.CodeMirror-cursors {\n z-index: 1;\n}\n.cm-fat-cursor-mark {\n background-color: rgba(20, 255, 20, 0.5);\n -webkit-animation: blink 1.06s steps(1) infinite;\n -moz-animation: blink 1.06s steps(1) infinite;\n animation: blink 1.06s steps(1) infinite;\n}\n.cm-animate-fat-cursor {\n width: auto;\n border: 0;\n -webkit-animation: blink 1.06s steps(1) infinite;\n -moz-animation: blink 1.06s steps(1) infinite;\n animation: blink 1.06s steps(1) infinite;\n background-color: #7e7;\n}\n@-moz-keyframes blink {\n 0% {}\n 50% { background-color: transparent; }\n 100% {}\n}\n@-webkit-keyframes blink {\n 0% {}\n 50% { background-color: transparent; }\n 100% {}\n}\n@keyframes blink {\n 0% {}\n 50% { background-color: transparent; }\n 100% {}\n}\n\n/* Can style cursor different in overwrite (non-insert) mode */\n.CodeMirror-overwrite .CodeMirror-cursor {}\n\n.cm-tab { display: inline-block; text-decoration: inherit; }\n\n.CodeMirror-rulers {\n position: absolute;\n left: 0; right: 0; top: -50px; bottom: -20px;\n overflow: hidden;\n}\n.CodeMirror-ruler {\n border-left: 1px solid #ccc;\n top: 0; bottom: 0;\n position: absolute;\n}\n\n/* DEFAULT THEME */\n\n.cm-s-default .cm-header {color: blue;}\n.cm-s-default .cm-quote {color: #090;}\n.cm-negative {color: #d44;}\n.cm-positive {color: #292;}\n.cm-header, .cm-strong {font-weight: bold;}\n.cm-em {font-style: italic;}\n.cm-link {text-decoration: underline;}\n.cm-strikethrough {text-decoration: line-through;}\n\n.cm-s-default .cm-keyword {color: #708;}\n.cm-s-default .cm-atom {color: #219;}\n.cm-s-default .cm-number {color: #164;}\n.cm-s-default .cm-def {color: #00f;}\n.cm-s-default .cm-variable,\n.cm-s-default .cm-punctuation,\n.cm-s-default .cm-property,\n.cm-s-default .cm-operator {}\n.cm-s-default .cm-variable-2 {color: #05a;}\n.cm-s-default .cm-variable-3, .cm-s-default .cm-type {color: #085;}\n.cm-s-default .cm-comment {color: #a50;}\n.cm-s-default .cm-string {color: #a11;}\n.cm-s-default .cm-string-2 {color: #f50;}\n.cm-s-default .cm-meta {color: #555;}\n.cm-s-default .cm-qualifier {color: #555;}\n.cm-s-default .cm-builtin {color: #30a;}\n.cm-s-default .cm-bracket {color: #997;}\n.cm-s-default .cm-tag {color: #170;}\n.cm-s-default .cm-attribute {color: #00c;}\n.cm-s-default .cm-hr {color: #999;}\n.cm-s-default .cm-link {color: #00c;}\n\n.cm-s-default .cm-error {color: #f00;}\n.cm-invalidchar {color: #f00;}\n\n.CodeMirror-composing { border-bottom: 2px solid; }\n\n/* Default styles for common addons */\n\ndiv.CodeMirror span.CodeMirror-matchingbracket {color: #0b0;}\ndiv.CodeMirror span.CodeMirror-nonmatchingbracket {color: #a22;}\n.CodeMirror-matchingtag { background: rgba(255, 150, 0, .3); }\n.CodeMirror-activeline-background {background: #e8f2ff;}\n\n/* STOP */\n\n/* The rest of this file contains styles related to the mechanics of\n the editor. You probably shouldn't touch them. */\n\n.CodeMirror {\n position: relative;\n overflow: hidden;\n background: white;\n}\n\n.CodeMirror-scroll {\n overflow: scroll !important; /* Things will break if this is overridden */\n /* 30px is the magic margin used to hide the element's real scrollbars */\n /* See overflow: hidden in .CodeMirror */\n margin-bottom: -30px; margin-right: -30px;\n padding-bottom: 30px;\n height: 100%;\n outline: none; /* Prevent dragging from highlighting the element */\n position: relative;\n}\n.CodeMirror-sizer {\n position: relative;\n border-right: 30px solid transparent;\n}\n\n/* The fake, visible scrollbars. Used to force redraw during scrolling\n before actual scrolling happens, thus preventing shaking and\n flickering artifacts. */\n.CodeMirror-vscrollbar, .CodeMirror-hscrollbar, .CodeMirror-scrollbar-filler, .CodeMirror-gutter-filler {\n position: absolute;\n z-index: 6;\n display: none;\n}\n.CodeMirror-vscrollbar {\n right: 0; top: 0;\n overflow-x: hidden;\n overflow-y: scroll;\n}\n.CodeMirror-hscrollbar {\n bottom: 0; left: 0;\n overflow-y: hidden;\n overflow-x: scroll;\n}\n.CodeMirror-scrollbar-filler {\n right: 0; bottom: 0;\n}\n.CodeMirror-gutter-filler {\n left: 0; bottom: 0;\n}\n\n.CodeMirror-gutters {\n position: absolute; left: 0; top: 0;\n min-height: 100%;\n z-index: 3;\n}\n.CodeMirror-gutter {\n white-space: normal;\n height: 100%;\n display: inline-block;\n vertical-align: top;\n margin-bottom: -30px;\n}\n.CodeMirror-gutter-wrapper {\n position: absolute;\n z-index: 4;\n background: none !important;\n border: none !important;\n}\n.CodeMirror-gutter-background {\n position: absolute;\n top: 0; bottom: 0;\n z-index: 4;\n}\n.CodeMirror-gutter-elt {\n position: absolute;\n cursor: default;\n z-index: 4;\n}\n.CodeMirror-gutter-wrapper ::selection { background-color: transparent }\n.CodeMirror-gutter-wrapper ::-moz-selection { background-color: transparent }\n\n.CodeMirror-lines {\n cursor: text;\n min-height: 1px; /* prevents collapsing before first draw */\n}\n.CodeMirror pre {\n /* Reset some styles that the rest of the page might have set */\n -moz-border-radius: 0; -webkit-border-radius: 0; border-radius: 0;\n border-width: 0;\n background: transparent;\n font-family: inherit;\n font-size: inherit;\n margin: 0;\n white-space: pre;\n word-wrap: normal;\n line-height: inherit;\n color: inherit;\n z-index: 2;\n position: relative;\n overflow: visible;\n -webkit-tap-highlight-color: transparent;\n -webkit-font-variant-ligatures: contextual;\n font-variant-ligatures: contextual;\n}\n.CodeMirror-wrap pre {\n word-wrap: break-word;\n white-space: pre-wrap;\n word-break: normal;\n}\n\n.CodeMirror-linebackground {\n position: absolute;\n left: 0; right: 0; top: 0; bottom: 0;\n z-index: 0;\n}\n\n.CodeMirror-linewidget {\n position: relative;\n z-index: 2;\n padding: 0.1px; /* Force widget margins to stay inside of the container */\n}\n\n.CodeMirror-widget {}\n\n.CodeMirror-rtl pre { direction: rtl; }\n\n.CodeMirror-code {\n outline: none;\n}\n\n/* Force content-box sizing for the elements where we expect it */\n.CodeMirror-scroll,\n.CodeMirror-sizer,\n.CodeMirror-gutter,\n.CodeMirror-gutters,\n.CodeMirror-linenumber {\n -moz-box-sizing: content-box;\n box-sizing: content-box;\n}\n\n.CodeMirror-measure {\n position: absolute;\n width: 100%;\n height: 0;\n overflow: hidden;\n visibility: hidden;\n}\n\n.CodeMirror-cursor {\n position: absolute;\n pointer-events: none;\n}\n.CodeMirror-measure pre { position: static; }\n\ndiv.CodeMirror-cursors {\n visibility: hidden;\n position: relative;\n z-index: 3;\n}\ndiv.CodeMirror-dragcursors {\n visibility: visible;\n}\n\n.CodeMirror-focused div.CodeMirror-cursors {\n visibility: visible;\n}\n\n.CodeMirror-selected { background: #d9d9d9; }\n.CodeMirror-focused .CodeMirror-selected { background: #d7d4f0; }\n.CodeMirror-crosshair { cursor: crosshair; }\n.CodeMirror-line::selection, .CodeMirror-line > span::selection, .CodeMirror-line > span > span::selection { background: #d7d4f0; }\n.CodeMirror-line::-moz-selection, .CodeMirror-line > span::-moz-selection, .CodeMirror-line > span > span::-moz-selection { background: #d7d4f0; }\n\n.cm-searching {\n background-color: #ffa;\n background-color: rgba(255, 255, 0, .4);\n}\n\n/* Used to force a border model for a node */\n.cm-force-border { padding-right: .1px; }\n\n@media print {\n /* Hide the cursor when printing */\n .CodeMirror div.CodeMirror-cursors {\n visibility: hidden;\n }\n}\n\n/* See issue #2901 */\n.cm-tab-wrap-hack:after { content: ''; }\n\n/* Help users use markselection to safely style text background */\nspan.CodeMirror-selectedtext { background: none; }\n",""])},function(e,t,n){var o=n(348);"string"==typeof o&&(o=[[e.i,o,""]]);n(13)(o,{});o.locals&&(e.exports=o.locals)},function(e,t,n){(e.exports=n(12)(!1)).push([e.i,".CodeMirror-hints {\n position: absolute;\n z-index: 10;\n overflow: hidden;\n list-style: none;\n\n margin: 0;\n padding: 2px;\n\n -webkit-box-shadow: 2px 3px 5px rgba(0,0,0,.2);\n -moz-box-shadow: 2px 3px 5px rgba(0,0,0,.2);\n box-shadow: 2px 3px 5px rgba(0,0,0,.2);\n border-radius: 3px;\n border: 1px solid silver;\n\n background: white;\n font-size: 90%;\n font-family: monospace;\n\n max-height: 20em;\n overflow-y: auto;\n}\n\n.CodeMirror-hint {\n margin: 0;\n padding: 0 4px;\n border-radius: 2px;\n white-space: pre;\n color: black;\n cursor: pointer;\n}\n\nli.CodeMirror-hint-active {\n background: #08f;\n color: white;\n}\n",""])},function(e,t,n){var o=n(350);"string"==typeof o&&(o=[[e.i,o,""]]);n(13)(o,{});o.locals&&(e.exports=o.locals)},function(e,t,n){(e.exports=n(12)(!1)).push([e.i,'/* The lint marker gutter */\n.CodeMirror-lint-markers {\n width: 16px;\n}\n\n.CodeMirror-lint-tooltip {\n background-color: #ffd;\n border: 1px solid black;\n border-radius: 4px 4px 4px 4px;\n color: black;\n font-family: monospace;\n font-size: 10pt;\n overflow: hidden;\n padding: 2px 5px;\n position: fixed;\n white-space: pre;\n white-space: pre-wrap;\n z-index: 100;\n max-width: 600px;\n opacity: 0;\n transition: opacity .4s;\n -moz-transition: opacity .4s;\n -webkit-transition: opacity .4s;\n -o-transition: opacity .4s;\n -ms-transition: opacity .4s;\n}\n\n.CodeMirror-lint-mark-error, .CodeMirror-lint-mark-warning {\n background-position: left bottom;\n background-repeat: repeat-x;\n}\n\n.CodeMirror-lint-mark-error {\n background-image:\n url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAADCAYAAAC09K7GAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB9sJDw4cOCW1/KIAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAHElEQVQI12NggIL/DAz/GdA5/xkY/qPKMDAwAADLZwf5rvm+LQAAAABJRU5ErkJggg==")\n ;\n}\n\n.CodeMirror-lint-mark-warning {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAADCAYAAAC09K7GAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAAd0SU1FB9sJFhQXEbhTg7YAAAAZdEVYdENvbW1lbnQAQ3JlYXRlZCB3aXRoIEdJTVBXgQ4XAAAAMklEQVQI12NkgIIvJ3QXMjAwdDN+OaEbysDA4MPAwNDNwMCwiOHLCd1zX07o6kBVGQEAKBANtobskNMAAAAASUVORK5CYII=");\n}\n\n.CodeMirror-lint-marker-error, .CodeMirror-lint-marker-warning {\n background-position: center center;\n background-repeat: no-repeat;\n cursor: pointer;\n display: inline-block;\n height: 16px;\n width: 16px;\n vertical-align: middle;\n position: relative;\n}\n\n.CodeMirror-lint-message-error, .CodeMirror-lint-message-warning {\n padding-left: 18px;\n background-position: top left;\n background-repeat: no-repeat;\n}\n\n.CodeMirror-lint-marker-error, .CodeMirror-lint-message-error {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAAHlBMVEW7AAC7AACxAAC7AAC7AAAAAAC4AAC5AAD///+7AAAUdclpAAAABnRSTlMXnORSiwCK0ZKSAAAATUlEQVR42mWPOQ7AQAgDuQLx/z8csYRmPRIFIwRGnosRrpamvkKi0FTIiMASR3hhKW+hAN6/tIWhu9PDWiTGNEkTtIOucA5Oyr9ckPgAWm0GPBog6v4AAAAASUVORK5CYII=");\n}\n\n.CodeMirror-lint-marker-warning, .CodeMirror-lint-message-warning {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAMAAAAoLQ9TAAAANlBMVEX/uwDvrwD/uwD/uwD/uwD/uwD/uwD/uwD/uwD6twD/uwAAAADurwD2tQD7uAD+ugAAAAD/uwDhmeTRAAAADHRSTlMJ8mN1EYcbmiixgACm7WbuAAAAVklEQVR42n3PUQqAIBBFUU1LLc3u/jdbOJoW1P08DA9Gba8+YWJ6gNJoNYIBzAA2chBth5kLmG9YUoG0NHAUwFXwO9LuBQL1giCQb8gC9Oro2vp5rncCIY8L8uEx5ZkAAAAASUVORK5CYII=");\n}\n\n.CodeMirror-lint-marker-multiple {\n background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAcAAAAHCAMAAADzjKfhAAAACVBMVEUAAAAAAAC/v7914kyHAAAAAXRSTlMAQObYZgAAACNJREFUeNo1ioEJAAAIwmz/H90iFFSGJgFMe3gaLZ0od+9/AQZ0ADosbYraAAAAAElFTkSuQmCC");\n background-repeat: no-repeat;\n background-position: right bottom;\n width: 100%; height: 100%;\n}\n',""])},,,,,,,,,,function(e,t,n){!function(e){"use strict";e.defineMode("javascript",function(t,n){var o,r,i=t.indentUnit,a=n.statementIndent,s=n.jsonld,l=n.json||s,u=n.typescript,c=n.wordCharacters||/[\w$\xa1-\uffff]/,d=function(){function e(e){return{type:e,style:"keyword"}}var t=e("keyword a"),n=e("keyword b"),o=e("keyword c"),r=e("keyword d"),i=e("operator"),a={type:"atom",style:"atom"};return{if:e("if"),while:t,with:t,else:n,do:n,try:n,finally:n,return:r,break:r,continue:r,new:e("new"),delete:o,void:o,throw:o,debugger:e("debugger"),var:e("var"),const:e("var"),let:e("var"),function:e("function"),catch:e("catch"),for:e("for"),switch:e("switch"),case:e("case"),default:e("default"),in:i,typeof:i,instanceof:i,true:a,false:a,null:a,undefined:a,NaN:a,Infinity:a,this:e("this"),class:e("class"),super:e("atom"),yield:o,export:e("export"),import:e("import"),extends:o,await:o}}(),h=/[+\-*&%=<>!?|~^@]/,f=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function p(e,t,n){return o=e,r=n,t}function m(e,t){var n,o=e.next();if('"'==o||"'"==o)return t.tokenize=(n=o,function(e,t){var o,r=!1;if(s&&"@"==e.peek()&&e.match(f))return t.tokenize=m,p("jsonld-keyword","meta");for(;null!=(o=e.next())&&(o!=n||r);)r=!r&&"\\"==o;return r||(t.tokenize=m),p("string","string")}),t.tokenize(e,t);if("."==o&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return p("number","number");if("."==o&&e.match(".."))return p("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(o))return p(o);if("="==o&&e.eat(">"))return p("=>","operator");if("0"==o&&e.eat(/x/i))return e.eatWhile(/[\da-f]/i),p("number","number");if("0"==o&&e.eat(/o/i))return e.eatWhile(/[0-7]/i),p("number","number");if("0"==o&&e.eat(/b/i))return e.eatWhile(/[01]/i),p("number","number");if(/\d/.test(o))return e.match(/^\d*(?:\.\d*)?(?:[eE][+\-]?\d+)?/),p("number","number");if("/"==o)return e.eat("*")?(t.tokenize=g,g(e,t)):e.eat("/")?(e.skipToEnd(),p("comment","comment")):Fe(e,t,1)?(function(e){for(var t,n=!1,o=!1;null!=(t=e.next());){if(!n){if("/"==t&&!o)return;"["==t?o=!0:o&&"]"==t&&(o=!1)}n=!n&&"\\"==t}}(e),e.match(/^\b(([gimyu])(?![gimyu]*\2))+\b/),p("regexp","string-2")):(e.eat("="),p("operator","operator",e.current()));if("`"==o)return t.tokenize=v,v(e,t);if("#"==o)return e.skipToEnd(),p("error","error");if(h.test(o))return">"==o&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=o&&"="!=o||e.eat("="):/[<>*+\-]/.test(o)&&(e.eat(o),">"==o&&e.eat(o))),p("operator","operator",e.current());if(c.test(o)){e.eatWhile(c);var r=e.current();if("."!=t.lastType){if(d.propertyIsEnumerable(r)){var i=d[r];return p(i.type,i.style,r)}if("async"==r&&e.match(/^(\s|\/\*.*?\*\/)*[\(\w]/,!1))return p("async","keyword",r)}return p("variable","variable",r)}}function g(e,t){for(var n,o=!1;n=e.next();){if("/"==n&&o){t.tokenize=m;break}o="*"==n}return p("comment","comment")}function v(e,t){for(var n,o=!1;null!=(n=e.next());){if(!o&&("`"==n||"$"==n&&e.eat("{"))){t.tokenize=m;break}o=!o&&"\\"==n}return p("quasi","string-2",e.current())}var y="([{}])";function _(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var n=e.string.indexOf("=>",e.start);if(!(n<0)){if(u){var o=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,n));o&&(n=o.index)}for(var r=0,i=!1,a=n-1;a>=0;--a){var s=e.string.charAt(a),l=y.indexOf(s);if(l>=0&&l<3){if(!r){++a;break}if(0==--r){"("==s&&(i=!0);break}}else if(l>=3&&l<6)++r;else if(c.test(s))i=!0;else{if(/["'\/]/.test(s))return;if(i&&!r){++a;break}}}i&&!r&&(t.fatArrowAt=a)}}var w={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,"jsonld-keyword":!0};function b(e,t,n,o,r,i){this.indented=e,this.column=t,this.type=n,this.prev=r,this.info=i,null!=o&&(this.align=o)}function C(e,t){for(var n=e.localVars;n;n=n.next)if(n.name==t)return!0;for(var o=e.context;o;o=o.prev)for(n=o.vars;n;n=n.next)if(n.name==t)return!0}var M={state:null,column:null,marked:null,cc:null};function k(){for(var e=arguments.length-1;e>=0;e--)M.cc.push(arguments[e])}function S(){return k.apply(null,arguments),!0}function T(e){function t(t){for(var n=t;n;n=n.next)if(n.name==e)return!0;return!1}var o=M.state;if(M.marked="def",o.context){if(t(o.localVars))return;o.localVars={name:e,next:o.localVars}}else{if(t(o.globalVars))return;n.globalVars&&(o.globalVars={name:e,next:o.globalVars})}}function L(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}var x={name:"this",next:{name:"arguments"}};function D(){M.state.context={prev:M.state.context,vars:M.state.localVars},M.state.localVars=x}function O(){M.state.localVars=M.state.context.vars,M.state.context=M.state.context.prev}function E(e,t){var n=function(){var n=M.state,o=n.indented;if("stat"==n.lexical.type)o=n.lexical.indented;else for(var r=n.lexical;r&&")"==r.type&&r.align;r=r.prev)o=r.indented;n.lexical=new b(o,M.stream.column(),e,null,n.lexical,t)};return n.lex=!0,n}function R(){var e=M.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function A(e){return function t(n){return n==e?S():";"==e?k():S(t)}}function H(e,t){return"var"==e?S(E("vardef",t.length),fe,A(";"),R):"keyword a"==e?S(E("form"),N,H,R):"keyword b"==e?S(E("form"),H,R):"keyword d"==e?M.stream.match(/^\s*$/,!1)?S():S(E("stat"),W,A(";"),R):"debugger"==e?S(A(";")):"{"==e?S(E("}"),te,R):";"==e?S():"if"==e?("else"==M.state.lexical.info&&M.state.cc[M.state.cc.length-1]==R&&M.state.cc.pop()(),S(E("form"),N,H,R,ye)):"function"==e?S(ke):"for"==e?S(E("form"),_e,H,R):"class"==e||u&&"interface"==t?(M.marked="keyword",S(E("form"),Le,R)):"variable"==e?u&&"declare"==t?(M.marked="keyword",S(H)):u&&("module"==t||"enum"==t||"type"==t)&&M.stream.match(/^\s*\w/,!1)?(M.marked="keyword","enum"==t?S(We):"type"==t?S(ie,A("operator"),ie,A(";")):S(E("form"),pe,A("{"),E("}"),te,R,R)):u&&"namespace"==t?(M.marked="keyword",S(E("form"),Y,te,R)):S(E("stat"),X):"switch"==e?S(E("form"),N,A("{"),E("}","switch"),te,R,R):"case"==e?S(Y,A(":")):"default"==e?S(A(":")):"catch"==e?S(E("form"),D,A("("),Se,A(")"),H,R,O):"export"==e?S(E("stat"),Ee,R):"import"==e?S(E("stat"),Ae,R):"async"==e?S(H):"@"==t?S(Y,H):k(E("stat"),Y,A(";"),R)}function Y(e,t){return I(e,t,!1)}function P(e,t){return I(e,t,!0)}function N(e){return"("!=e?k():S(E(")"),Y,A(")"),R)}function I(e,t,n){if(M.state.fatArrowAt==M.stream.start){var o=n?U:V;if("("==e)return S(D,E(")"),Z(Se,")"),R,A("=>"),o,O);if("variable"==e)return k(D,pe,A("=>"),o,O)}var r=n?F:j;return w.hasOwnProperty(e)?S(r):"function"==e?S(ke,r):"class"==e||u&&"interface"==t?(M.marked="keyword",S(E("form"),Te,R)):"keyword c"==e||"async"==e?S(n?P:Y):"("==e?S(E(")"),W,A(")"),R,r):"operator"==e||"spread"==e?S(n?P:Y):"["==e?S(E("]"),Ie,R,r):"{"==e?ee(q,"}",null,r):"quasi"==e?k(z,r):"new"==e?S(function(e){return function(t){return"."==t?S(e?G:K):"variable"==t&&u?S(ce,e?F:j):k(e?P:Y)}}(n)):"import"==e?S(Y):S()}function W(e){return e.match(/[;\}\)\],]/)?k():k(Y)}function j(e,t){return","==e?S(Y):F(e,t,!1)}function F(e,t,n){var o=0==n?j:F,r=0==n?Y:P;return"=>"==e?S(D,n?U:V,O):"operator"==e?/\+\+|--/.test(t)||u&&"!"==t?S(o):u&&"<"==t&&M.stream.match(/^([^>]|<.*?>)*>\s*\(/,!1)?S(E(">"),Z(ie,">"),R,o):"?"==t?S(Y,A(":"),r):S(r):"quasi"==e?k(z,o):";"!=e?"("==e?ee(P,")","call",o):"."==e?S(J,o):"["==e?S(E("]"),W,A("]"),R,o):u&&"as"==t?(M.marked="keyword",S(ie,o)):"regexp"==e?(M.state.lastType=M.marked="operator",M.stream.backUp(M.stream.pos-M.stream.start-1),S(r)):void 0:void 0}function z(e,t){return"quasi"!=e?k():"${"!=t.slice(t.length-2)?S(z):S(Y,B)}function B(e){if("}"==e)return M.marked="string-2",M.state.tokenize=v,S(z)}function V(e){return _(M.stream,M.state),k("{"==e?H:Y)}function U(e){return _(M.stream,M.state),k("{"==e?H:P)}function K(e,t){if("target"==t)return M.marked="keyword",S(j)}function G(e,t){if("target"==t)return M.marked="keyword",S(F)}function X(e){return":"==e?S(R,H):k(j,A(";"),R)}function J(e){if("variable"==e)return M.marked="property",S()}function q(e,t){return"async"==e?(M.marked="property",S(q)):"variable"==e||"keyword"==M.style?(M.marked="property","get"==t||"set"==t?S(Q):(u&&M.state.fatArrowAt==M.stream.start&&(n=M.stream.match(/^\s*:\s*/,!1))&&(M.state.fatArrowAt=M.stream.pos+n[0].length),S($))):"number"==e||"string"==e?(M.marked=s?"property":M.style+" property",S($)):"jsonld-keyword"==e?S($):u&&L(t)?(M.marked="keyword",S(q)):"["==e?S(Y,ne,A("]"),$):"spread"==e?S(P,$):"*"==t?(M.marked="keyword",S(q)):":"==e?k($):void 0;var n}function Q(e){return"variable"!=e?k($):(M.marked="property",S(ke))}function $(e){return":"==e?S(P):"("==e?k(ke):void 0}function Z(e,t,n){function o(r,i){if(n?n.indexOf(r)>-1:","==r){var a=M.state.lexical;return"call"==a.info&&(a.pos=(a.pos||0)+1),S(function(n,o){return n==t||o==t?k():k(e)},o)}return r==t||i==t?S():S(A(t))}return function(n,r){return n==t||r==t?S():k(e,o)}}function ee(e,t,n){for(var o=3;o<arguments.length;o++)M.cc.push(arguments[o]);return S(E(t,n),Z(e,t),R)}function te(e){return"}"==e?S():k(H,te)}function ne(e,t){if(u){if(":"==e)return S(ie);if("?"==t)return S(ne)}}function oe(e){if(u&&":"==e)return M.stream.match(/^\s*\w+\s+is\b/,!1)?S(Y,re,ie):S(ie)}function re(e,t){if("is"==t)return M.marked="keyword",S()}function ie(e,t){return"keyof"==t||"typeof"==t?(M.marked="keyword",S("keyof"==t?ie:Y)):"variable"==e||"void"==t?(M.marked="type",S(ue)):"string"==e||"number"==e||"atom"==e?S(ue):"["==e?S(E("]"),Z(ie,"]",","),R,ue):"{"==e?S(E("}"),Z(se,"}",",;"),R,ue):"("==e?S(Z(le,")"),ae):void 0}function ae(e){if("=>"==e)return S(ie)}function se(e,t){return"variable"==e||"keyword"==M.style?(M.marked="property",S(se)):"?"==t?S(se):":"==e?S(ie):"["==e?S(Y,ne,A("]"),se):void 0}function le(e){return"variable"==e?S(le):":"==e?S(ie):void 0}function ue(e,t){return"<"==t?S(E(">"),Z(ie,">"),R,ue):"|"==t||"."==e||"&"==t?S(ie):"["==e?S(A("]"),ue):"extends"==t||"implements"==t?(M.marked="keyword",S(ie)):void 0}function ce(e,t){if("<"==t)return S(E(">"),Z(ie,">"),R,ue)}function de(){return k(ie,he)}function he(e,t){if("="==t)return S(ie)}function fe(e,t){return"enum"==t?(M.marked="keyword",S(We)):k(pe,ne,ge,ve)}function pe(e,t){return u&&L(t)?(M.marked="keyword",S(pe)):"variable"==e?(T(t),S()):"spread"==e?S(pe):"["==e?ee(pe,"]"):"{"==e?ee(me,"}"):void 0}function me(e,t){return"variable"!=e||M.stream.match(/^\s*:/,!1)?("variable"==e&&(M.marked="property"),"spread"==e?S(pe):"}"==e?k():S(A(":"),pe,ge)):(T(t),S(ge))}function ge(e,t){if("="==t)return S(P)}function ve(e){if(","==e)return S(fe)}function ye(e,t){if("keyword b"==e&&"else"==t)return S(E("form","else"),H,R)}function _e(e,t){return"await"==t?S(_e):"("==e?S(E(")"),we,A(")"),R):void 0}function we(e){return"var"==e?S(fe,A(";"),Ce):";"==e?S(Ce):"variable"==e?S(be):k(Y,A(";"),Ce)}function be(e,t){return"in"==t||"of"==t?(M.marked="keyword",S(Y)):S(j,Ce)}function Ce(e,t){return";"==e?S(Me):"in"==t||"of"==t?(M.marked="keyword",S(Y)):k(Y,A(";"),Me)}function Me(e){")"!=e&&S(Y)}function ke(e,t){return"*"==t?(M.marked="keyword",S(ke)):"variable"==e?(T(t),S(ke)):"("==e?S(D,E(")"),Z(Se,")"),R,oe,H,O):u&&"<"==t?S(E(">"),Z(de,">"),R,ke):void 0}function Se(e,t){return"@"==t&&S(Y,Se),"spread"==e?S(Se):u&&L(t)?(M.marked="keyword",S(Se)):k(pe,ne,ge)}function Te(e,t){return"variable"==e?Le(e,t):xe(e,t)}function Le(e,t){if("variable"==e)return T(t),S(xe)}function xe(e,t){return"<"==t?S(E(">"),Z(de,">"),R,xe):"extends"==t||"implements"==t||u&&","==e?("implements"==t&&(M.marked="keyword"),S(u?ie:Y,xe)):"{"==e?S(E("}"),De,R):void 0}function De(e,t){return"async"==e||"variable"==e&&("static"==t||"get"==t||"set"==t||u&&L(t))&&M.stream.match(/^\s+[\w$\xa1-\uffff]/,!1)?(M.marked="keyword",S(De)):"variable"==e||"keyword"==M.style?(M.marked="property",S(u?Oe:ke,De)):"["==e?S(Y,ne,A("]"),u?Oe:ke,De):"*"==t?(M.marked="keyword",S(De)):";"==e?S(De):"}"==e?S():"@"==t?S(Y,De):void 0}function Oe(e,t){return"?"==t?S(Oe):":"==e?S(ie,ge):"="==t?S(P):k(ke)}function Ee(e,t){return"*"==t?(M.marked="keyword",S(Ne,A(";"))):"default"==t?(M.marked="keyword",S(Y,A(";"))):"{"==e?S(Z(Re,"}"),Ne,A(";")):k(H)}function Re(e,t){return"as"==t?(M.marked="keyword",S(A("variable"))):"variable"==e?k(P,Re):void 0}function Ae(e){return"string"==e?S():"("==e?k(Y):k(He,Ye,Ne)}function He(e,t){return"{"==e?ee(He,"}"):("variable"==e&&T(t),"*"==t&&(M.marked="keyword"),S(Pe))}function Ye(e){if(","==e)return S(He,Ye)}function Pe(e,t){if("as"==t)return M.marked="keyword",S(He)}function Ne(e,t){if("from"==t)return M.marked="keyword",S(Y)}function Ie(e){return"]"==e?S():k(Z(P,"]"))}function We(){return k(E("form"),pe,A("{"),E("}"),Z(je,"}"),R,R)}function je(){return k(pe,ge)}function Fe(e,t,n){return t.tokenize==m&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(t.lastType)||"quasi"==t.lastType&&/\{\s*$/.test(e.string.slice(0,e.pos-(n||0)))}return R.lex=!0,{startState:function(e){var t={tokenize:m,lastType:"sof",cc:[],lexical:new b((e||0)-i,0,"block",!1),localVars:n.localVars,context:n.localVars&&{vars:n.localVars},indented:e||0};return n.globalVars&&"object"==typeof n.globalVars&&(t.globalVars=n.globalVars),t},token:function(e,t){if(e.sol()&&(t.lexical.hasOwnProperty("align")||(t.lexical.align=!1),t.indented=e.indentation(),_(e,t)),t.tokenize!=g&&e.eatSpace())return null;var n=t.tokenize(e,t);return"comment"==o?n:(t.lastType="operator"!=o||"++"!=r&&"--"!=r?o:"incdec",function(e,t,n,o,r){var i=e.cc;for(M.state=e,M.stream=r,M.marked=null,M.cc=i,M.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;)if((i.length?i.pop():l?Y:H)(n,o)){for(;i.length&&i[i.length-1].lex;)i.pop()();return M.marked?M.marked:"variable"==n&&C(e,o)?"variable-2":t}}(t,n,o,r,e))},indent:function(t,o){if(t.tokenize==g)return e.Pass;if(t.tokenize!=m)return 0;var r,s=o&&o.charAt(0),l=t.lexical;if(!/^\s*else\b/.test(o))for(var u=t.cc.length-1;u>=0;--u){var c=t.cc[u];if(c==R)l=l.prev;else if(c!=ye)break}for(;("stat"==l.type||"form"==l.type)&&("}"==s||(r=t.cc[t.cc.length-1])&&(r==j||r==F)&&!/^[,\.=+\-*:?[\(]/.test(o));)l=l.prev;a&&")"==l.type&&"stat"==l.prev.type&&(l=l.prev);var d=l.type,f=s==d;return"vardef"==d?l.indented+("operator"==t.lastType||","==t.lastType?l.info+1:0):"form"==d&&"{"==s?l.indented:"form"==d?l.indented+i:"stat"==d?l.indented+(function(e,t){return"operator"==e.lastType||","==e.lastType||h.test(t.charAt(0))||/[,.]/.test(t.charAt(0))}(t,o)?a||i:0):"switch"!=l.info||f||0==n.doubleIndentSwitch?l.align?l.column+(f?0:1):l.indented+(f?0:i):l.indented+(/^(?:case|default)\b/.test(o)?i:2*i)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:l?null:"/*",blockCommentEnd:l?null:"*/",blockCommentContinue:l?null:" * ",lineComment:l?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:l?"json":"javascript",jsonldMode:s,jsonMode:l,expressionAllowed:Fe,skipExpression:function(e){var t=e.cc[e.cc.length-1];t!=Y&&t!=P||e.cc.pop()}}}),e.registerHelper("wordChars","javascript",/[\w$]/),e.defineMIME("text/javascript","javascript"),e.defineMIME("text/ecmascript","javascript"),e.defineMIME("application/javascript","javascript"),e.defineMIME("application/x-javascript","javascript"),e.defineMIME("application/ecmascript","javascript"),e.defineMIME("application/json",{name:"javascript",json:!0}),e.defineMIME("application/x-json",{name:"javascript",json:!0}),e.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),e.defineMIME("text/typescript",{name:"javascript",typescript:!0}),e.defineMIME("application/typescript",{name:"javascript",typescript:!0})}(n(16))},function(e,t,n){"use strict";n(8)._set("global",{responsive:!0,responsiveAnimationDuration:0,maintainAspectRatio:!0,events:["mousemove","mouseout","click","touchstart","touchmove"],hover:{onHover:null,mode:"nearest",intersect:!0,animationDuration:400},onClick:null,defaultColor:"rgba(0,0,0,0.1)",defaultFontColor:"#666",defaultFontFamily:"'Helvetica Neue', 'Helvetica', 'Arial', sans-serif",defaultFontSize:12,defaultFontStyle:"normal",showLines:!0,elements:{},layout:{padding:{top:0,right:0,bottom:0,left:0}}}),e.exports=function(){var e=function(e,t){return this.construct(e,t),this};return e.Chart=e,e}},function(e,t,n){"use strict";var o=n(36),r={linear:function(e){return e},easeInQuad:function(e){return e*e},easeOutQuad:function(e){return-e*(e-2)},easeInOutQuad:function(e){return(e/=.5)<1?.5*e*e:-.5*(--e*(e-2)-1)},easeInCubic:function(e){return e*e*e},easeOutCubic:function(e){return(e-=1)*e*e+1},easeInOutCubic:function(e){return(e/=.5)<1?.5*e*e*e:.5*((e-=2)*e*e+2)},easeInQuart:function(e){return e*e*e*e},easeOutQuart:function(e){return-((e-=1)*e*e*e-1)},easeInOutQuart:function(e){return(e/=.5)<1?.5*e*e*e*e:-.5*((e-=2)*e*e*e-2)},easeInQuint:function(e){return e*e*e*e*e},easeOutQuint:function(e){return(e-=1)*e*e*e*e+1},easeInOutQuint:function(e){return(e/=.5)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2)},easeInSine:function(e){return 1-Math.cos(e*(Math.PI/2))},easeOutSine:function(e){return Math.sin(e*(Math.PI/2))},easeInOutSine:function(e){return-.5*(Math.cos(Math.PI*e)-1)},easeInExpo:function(e){return 0===e?0:Math.pow(2,10*(e-1))},easeOutExpo:function(e){return 1===e?1:1-Math.pow(2,-10*e)},easeInOutExpo:function(e){return 0===e?0:1===e?1:(e/=.5)<1?.5*Math.pow(2,10*(e-1)):.5*(2-Math.pow(2,-10*--e))},easeInCirc:function(e){return e>=1?e:-(Math.sqrt(1-e*e)-1)},easeOutCirc:function(e){return Math.sqrt(1-(e-=1)*e)},easeInOutCirc:function(e){return(e/=.5)<1?-.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1)},easeInElastic:function(e){var t=1.70158,n=0,o=1;return 0===e?0:1===e?1:(n||(n=.3),o<1?(o=1,t=n/4):t=n/(2*Math.PI)*Math.asin(1/o),-o*Math.pow(2,10*(e-=1))*Math.sin((e-t)*(2*Math.PI)/n))},easeOutElastic:function(e){var t=1.70158,n=0,o=1;return 0===e?0:1===e?1:(n||(n=.3),o<1?(o=1,t=n/4):t=n/(2*Math.PI)*Math.asin(1/o),o*Math.pow(2,-10*e)*Math.sin((e-t)*(2*Math.PI)/n)+1)},easeInOutElastic:function(e){var t=1.70158,n=0,o=1;return 0===e?0:2==(e/=.5)?1:(n||(n=.45),o<1?(o=1,t=n/4):t=n/(2*Math.PI)*Math.asin(1/o),e<1?o*Math.pow(2,10*(e-=1))*Math.sin((e-t)*(2*Math.PI)/n)*-.5:o*Math.pow(2,-10*(e-=1))*Math.sin((e-t)*(2*Math.PI)/n)*.5+1)},easeInBack:function(e){var t=1.70158;return e*e*((t+1)*e-t)},easeOutBack:function(e){var t=1.70158;return(e-=1)*e*((t+1)*e+t)+1},easeInOutBack:function(e){var t=1.70158;return(e/=.5)<1?e*e*((1+(t*=1.525))*e-t)*.5:.5*((e-=2)*e*((1+(t*=1.525))*e+t)+2)},easeInBounce:function(e){return 1-r.easeOutBounce(1-e)},easeOutBounce:function(e){return e<1/2.75?7.5625*e*e:e<2/2.75?7.5625*(e-=1.5/2.75)*e+.75:e<2.5/2.75?7.5625*(e-=2.25/2.75)*e+.9375:7.5625*(e-=2.625/2.75)*e+.984375},easeInOutBounce:function(e){return e<.5?.5*r.easeInBounce(2*e):.5*r.easeOutBounce(2*e-1)+.5}};e.exports={effects:r},o.easingEffects=r},function(e,t,n){"use strict";var o=n(36);t=e.exports={clear:function(e){e.ctx.clearRect(0,0,e.width,e.height)},roundedRect:function(e,t,n,o,r,i){if(i){var a=Math.min(i,o/2),s=Math.min(i,r/2);e.moveTo(t+a,n),e.lineTo(t+o-a,n),e.quadraticCurveTo(t+o,n,t+o,n+s),e.lineTo(t+o,n+r-s),e.quadraticCurveTo(t+o,n+r,t+o-a,n+r),e.lineTo(t+a,n+r),e.quadraticCurveTo(t,n+r,t,n+r-s),e.lineTo(t,n+s),e.quadraticCurveTo(t,n,t+a,n)}else e.rect(t,n,o,r)},drawPoint:function(e,t,n,o,r){var i,a,s,l,u,c;if(!t||"object"!=typeof t||"[object HTMLImageElement]"!==(i=t.toString())&&"[object HTMLCanvasElement]"!==i){if(!(isNaN(n)||n<=0)){switch(t){default:e.beginPath(),e.arc(o,r,n,0,2*Math.PI),e.closePath(),e.fill();break;case"triangle":e.beginPath(),u=(a=3*n/Math.sqrt(3))*Math.sqrt(3)/2,e.moveTo(o-a/2,r+u/3),e.lineTo(o+a/2,r+u/3),e.lineTo(o,r-2*u/3),e.closePath(),e.fill();break;case"rect":c=1/Math.SQRT2*n,e.beginPath(),e.fillRect(o-c,r-c,2*c,2*c),e.strokeRect(o-c,r-c,2*c,2*c);break;case"rectRounded":var d=n/Math.SQRT2,h=o-d,f=r-d,p=Math.SQRT2*n;e.beginPath(),this.roundedRect(e,h,f,p,p,n/2),e.closePath(),e.fill();break;case"rectRot":c=1/Math.SQRT2*n,e.beginPath(),e.moveTo(o-c,r),e.lineTo(o,r+c),e.lineTo(o+c,r),e.lineTo(o,r-c),e.closePath(),e.fill();break;case"cross":e.beginPath(),e.moveTo(o,r+n),e.lineTo(o,r-n),e.moveTo(o-n,r),e.lineTo(o+n,r),e.closePath();break;case"crossRot":e.beginPath(),s=Math.cos(Math.PI/4)*n,l=Math.sin(Math.PI/4)*n,e.moveTo(o-s,r-l),e.lineTo(o+s,r+l),e.moveTo(o-s,r+l),e.lineTo(o+s,r-l),e.closePath();break;case"star":e.beginPath(),e.moveTo(o,r+n),e.lineTo(o,r-n),e.moveTo(o-n,r),e.lineTo(o+n,r),s=Math.cos(Math.PI/4)*n,l=Math.sin(Math.PI/4)*n,e.moveTo(o-s,r-l),e.lineTo(o+s,r+l),e.moveTo(o-s,r+l),e.lineTo(o+s,r-l),e.closePath();break;case"line":e.beginPath(),e.moveTo(o-n,r),e.lineTo(o+n,r),e.closePath();break;case"dash":e.beginPath(),e.moveTo(o,r),e.lineTo(o+n,r),e.closePath()}e.stroke()}}else e.drawImage(t,o-t.width/2,r-t.height/2,t.width,t.height)},clipArea:function(e,t){e.save(),e.beginPath(),e.rect(t.left,t.top,t.right-t.left,t.bottom-t.top),e.clip()},unclipArea:function(e){e.restore()},lineTo:function(e,t,n,o){if(n.steppedLine)return"after"===n.steppedLine&&!o||"after"!==n.steppedLine&&o?e.lineTo(t.x,n.y):e.lineTo(n.x,t.y),void e.lineTo(n.x,n.y);n.tension?e.bezierCurveTo(o?t.controlPointPreviousX:t.controlPointNextX,o?t.controlPointPreviousY:t.controlPointNextY,o?n.controlPointNextX:n.controlPointPreviousX,o?n.controlPointNextY:n.controlPointPreviousY,n.x,n.y):e.lineTo(n.x,n.y)}};o.clear=t.clear,o.drawRoundedRectangle=function(e){e.beginPath(),t.roundedRect.apply(t,arguments),e.closePath()}},function(e,t,n){"use strict";var o=n(36);e.exports={toLineHeight:function(e,t){var n=(""+e).match(/^(normal|(\d+(?:\.\d+)?)(px|em|%)?)$/);if(!n||"normal"===n[1])return 1.2*t;switch(e=+n[2],n[3]){case"px":return e;case"%":e/=100}return t*e},toPadding:function(e){var t,n,r,i;return o.isObject(e)?(t=+e.top||0,n=+e.right||0,r=+e.bottom||0,i=+e.left||0):t=n=r=i=+e||0,{top:t,right:n,bottom:r,left:i,height:t+r,width:i+n}},resolve:function(e,t,n){var r,i,a;for(r=0,i=e.length;r<i;++r)if(void 0!==(a=e[r])&&(void 0!==t&&"function"==typeof a&&(a=a(t)),void 0!==n&&o.isArray(a)&&(a=a[n]),void 0!==a))return a}}},function(e,t,n){"use strict";var o=n(66),r=n(8),i=n(6);e.exports=function(e){function t(e,t,n){var o;return"string"==typeof e?(o=parseInt(e,10),-1!==e.indexOf("%")&&(o=o/100*t.parentNode[n])):o=e,o}function n(e){return null!=e&&"none"!==e}function a(e,o,r){var i=document.defaultView,a=e.parentNode,s=i.getComputedStyle(e)[o],l=i.getComputedStyle(a)[o],u=n(s),c=n(l),d=Number.POSITIVE_INFINITY;return u||c?Math.min(u?t(s,e,r):d,c?t(l,a,r):d):"none"}i.configMerge=function(){return i.merge(i.clone(arguments[0]),[].slice.call(arguments,1),{merger:function(t,n,o,r){var a=n[t]||{},s=o[t];"scales"===t?n[t]=i.scaleMerge(a,s):"scale"===t?n[t]=i.merge(a,[e.scaleService.getScaleDefaults(s.type),s]):i._merger(t,n,o,r)}})},i.scaleMerge=function(){return i.merge(i.clone(arguments[0]),[].slice.call(arguments,1),{merger:function(t,n,o,r){if("xAxes"===t||"yAxes"===t){var a,s,l,u=o[t].length;for(n[t]||(n[t]=[]),a=0;a<u;++a)l=o[t][a],s=i.valueOrDefault(l.type,"xAxes"===t?"category":"linear"),a>=n[t].length&&n[t].push({}),!n[t][a].type||l.type&&l.type!==n[t][a].type?i.merge(n[t][a],[e.scaleService.getScaleDefaults(s),l]):i.merge(n[t][a],l)}else i._merger(t,n,o,r)}})},i.where=function(e,t){if(i.isArray(e)&&Array.prototype.filter)return e.filter(t);var n=[];return i.each(e,function(e){t(e)&&n.push(e)}),n},i.findIndex=Array.prototype.findIndex?function(e,t,n){return e.findIndex(t,n)}:function(e,t,n){n=void 0===n?e:n;for(var o=0,r=e.length;o<r;++o)if(t.call(n,e[o],o,e))return o;return-1},i.findNextWhere=function(e,t,n){i.isNullOrUndef(n)&&(n=-1);for(var o=n+1;o<e.length;o++){var r=e[o];if(t(r))return r}},i.findPreviousWhere=function(e,t,n){i.isNullOrUndef(n)&&(n=e.length);for(var o=n-1;o>=0;o--){var r=e[o];if(t(r))return r}},i.isNumber=function(e){return!isNaN(parseFloat(e))&&isFinite(e)},i.almostEquals=function(e,t,n){return Math.abs(e-t)<n},i.almostWhole=function(e,t){var n=Math.round(e);return n-t<e&&n+t>e},i.max=function(e){return e.reduce(function(e,t){return isNaN(t)?e:Math.max(e,t)},Number.NEGATIVE_INFINITY)},i.min=function(e){return e.reduce(function(e,t){return isNaN(t)?e:Math.min(e,t)},Number.POSITIVE_INFINITY)},i.sign=Math.sign?function(e){return Math.sign(e)}:function(e){return 0===(e=+e)||isNaN(e)?e:e>0?1:-1},i.log10=Math.log10?function(e){return Math.log10(e)}:function(e){var t=Math.log(e)*Math.LOG10E,n=Math.round(t);return e===Math.pow(10,n)?n:t},i.toRadians=function(e){return e*(Math.PI/180)},i.toDegrees=function(e){return e*(180/Math.PI)},i.getAngleFromPoint=function(e,t){var n=t.x-e.x,o=t.y-e.y,r=Math.sqrt(n*n+o*o),i=Math.atan2(o,n);return i<-.5*Math.PI&&(i+=2*Math.PI),{angle:i,distance:r}},i.distanceBetweenPoints=function(e,t){return Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2))},i.aliasPixel=function(e){return e%2==0?0:.5},i.splineCurve=function(e,t,n,o){var r=e.skip?t:e,i=t,a=n.skip?t:n,s=Math.sqrt(Math.pow(i.x-r.x,2)+Math.pow(i.y-r.y,2)),l=Math.sqrt(Math.pow(a.x-i.x,2)+Math.pow(a.y-i.y,2)),u=s/(s+l),c=l/(s+l),d=o*(u=isNaN(u)?0:u),h=o*(c=isNaN(c)?0:c);return{previous:{x:i.x-d*(a.x-r.x),y:i.y-d*(a.y-r.y)},next:{x:i.x+h*(a.x-r.x),y:i.y+h*(a.y-r.y)}}},i.EPSILON=Number.EPSILON||1e-14,i.splineCurveMonotone=function(e){var t,n,o,r,a,s,l,u,c,d=(e||[]).map(function(e){return{model:e._model,deltaK:0,mK:0}}),h=d.length;for(t=0;t<h;++t)if(!(o=d[t]).model.skip){if(n=t>0?d[t-1]:null,(r=t<h-1?d[t+1]:null)&&!r.model.skip){var f=r.model.x-o.model.x;o.deltaK=0!==f?(r.model.y-o.model.y)/f:0}!n||n.model.skip?o.mK=o.deltaK:!r||r.model.skip?o.mK=n.deltaK:this.sign(n.deltaK)!==this.sign(o.deltaK)?o.mK=0:o.mK=(n.deltaK+o.deltaK)/2}for(t=0;t<h-1;++t)o=d[t],r=d[t+1],o.model.skip||r.model.skip||(i.almostEquals(o.deltaK,0,this.EPSILON)?o.mK=r.mK=0:(a=o.mK/o.deltaK,s=r.mK/o.deltaK,(u=Math.pow(a,2)+Math.pow(s,2))<=9||(l=3/Math.sqrt(u),o.mK=a*l*o.deltaK,r.mK=s*l*o.deltaK)));for(t=0;t<h;++t)(o=d[t]).model.skip||(n=t>0?d[t-1]:null,r=t<h-1?d[t+1]:null,n&&!n.model.skip&&(c=(o.model.x-n.model.x)/3,o.model.controlPointPreviousX=o.model.x-c,o.model.controlPointPreviousY=o.model.y-c*o.mK),r&&!r.model.skip&&(c=(r.model.x-o.model.x)/3,o.model.controlPointNextX=o.model.x+c,o.model.controlPointNextY=o.model.y+c*o.mK))},i.nextItem=function(e,t,n){return n?t>=e.length-1?e[0]:e[t+1]:t>=e.length-1?e[e.length-1]:e[t+1]},i.previousItem=function(e,t,n){return n?t<=0?e[e.length-1]:e[t-1]:t<=0?e[0]:e[t-1]},i.niceNum=function(e,t){var n=Math.floor(i.log10(e)),o=e/Math.pow(10,n);return(t?o<1.5?1:o<3?2:o<7?5:10:o<=1?1:o<=2?2:o<=5?5:10)*Math.pow(10,n)},i.requestAnimFrame="undefined"==typeof window?function(e){e()}:window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame||function(e){return window.setTimeout(e,1e3/60)},i.getRelativePosition=function(e,t){var n,o,r=e.originalEvent||e,a=e.currentTarget||e.srcElement,s=a.getBoundingClientRect(),l=r.touches;l&&l.length>0?(n=l[0].clientX,o=l[0].clientY):(n=r.clientX,o=r.clientY);var u=parseFloat(i.getStyle(a,"padding-left")),c=parseFloat(i.getStyle(a,"padding-top")),d=parseFloat(i.getStyle(a,"padding-right")),h=parseFloat(i.getStyle(a,"padding-bottom")),f=s.right-s.left-u-d,p=s.bottom-s.top-c-h;return{x:n=Math.round((n-s.left-u)/f*a.width/t.currentDevicePixelRatio),y:o=Math.round((o-s.top-c)/p*a.height/t.currentDevicePixelRatio)}},i.getConstraintWidth=function(e){return a(e,"max-width","clientWidth")},i.getConstraintHeight=function(e){return a(e,"max-height","clientHeight")},i.getMaximumWidth=function(e){var t=e.parentNode;if(!t)return e.clientWidth;var n=parseInt(i.getStyle(t,"padding-left"),10),o=parseInt(i.getStyle(t,"padding-right"),10),r=t.clientWidth-n-o,a=i.getConstraintWidth(e);return isNaN(a)?r:Math.min(r,a)},i.getMaximumHeight=function(e){var t=e.parentNode;if(!t)return e.clientHeight;var n=parseInt(i.getStyle(t,"padding-top"),10),o=parseInt(i.getStyle(t,"padding-bottom"),10),r=t.clientHeight-n-o,a=i.getConstraintHeight(e);return isNaN(a)?r:Math.min(r,a)},i.getStyle=function(e,t){return e.currentStyle?e.currentStyle[t]:document.defaultView.getComputedStyle(e,null).getPropertyValue(t)},i.retinaScale=function(e,t){var n=e.currentDevicePixelRatio=t||window.devicePixelRatio||1;if(1!==n){var o=e.canvas,r=e.height,i=e.width;o.height=r*n,o.width=i*n,e.ctx.scale(n,n),o.style.height||o.style.width||(o.style.height=r+"px",o.style.width=i+"px")}},i.fontString=function(e,t,n){return t+" "+e+"px "+n},i.longestText=function(e,t,n,o){var r=(o=o||{}).data=o.data||{},a=o.garbageCollect=o.garbageCollect||[];o.font!==t&&(r=o.data={},a=o.garbageCollect=[],o.font=t),e.font=t;var s=0;i.each(n,function(t){null!=t&&!0!==i.isArray(t)?s=i.measureText(e,r,a,s,t):i.isArray(t)&&i.each(t,function(t){null==t||i.isArray(t)||(s=i.measureText(e,r,a,s,t))})});var l=a.length/2;if(l>n.length){for(var u=0;u<l;u++)delete r[a[u]];a.splice(0,l)}return s},i.measureText=function(e,t,n,o,r){var i=t[r];return i||(i=t[r]=e.measureText(r).width,n.push(r)),i>o&&(o=i),o},i.numberOfLabelLines=function(e){var t=1;return i.each(e,function(e){i.isArray(e)&&e.length>t&&(t=e.length)}),t},i.color=o?function(e){return e instanceof CanvasGradient&&(e=r.global.defaultColor),o(e)}:function(e){return console.error("Color.js not found!"),e},i.getHoverColor=function(e){return e instanceof CanvasPattern?e:i.color(e).saturate(.5).darken(.1).rgbString()}}},,,,,function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6);o._set("global",{elements:{arc:{backgroundColor:o.global.defaultColor,borderColor:"#fff",borderWidth:2}}}),e.exports=r.extend({inLabelRange:function(e){var t=this._view;return!!t&&Math.pow(e-t.x,2)<Math.pow(t.radius+t.hoverRadius,2)},inRange:function(e,t){var n=this._view;if(n){for(var o=i.getAngleFromPoint(n,{x:e,y:t}),r=o.angle,a=o.distance,s=n.startAngle,l=n.endAngle;l<s;)l+=2*Math.PI;for(;r>l;)r-=2*Math.PI;for(;r<s;)r+=2*Math.PI;var u=r>=s&&r<=l,c=a>=n.innerRadius&&a<=n.outerRadius;return u&&c}return!1},getCenterPoint:function(){var e=this._view,t=(e.startAngle+e.endAngle)/2,n=(e.innerRadius+e.outerRadius)/2;return{x:e.x+Math.cos(t)*n,y:e.y+Math.sin(t)*n}},getArea:function(){var e=this._view;return Math.PI*((e.endAngle-e.startAngle)/(2*Math.PI))*(Math.pow(e.outerRadius,2)-Math.pow(e.innerRadius,2))},tooltipPosition:function(){var e=this._view,t=e.startAngle+(e.endAngle-e.startAngle)/2,n=(e.outerRadius-e.innerRadius)/2+e.innerRadius;return{x:e.x+Math.cos(t)*n,y:e.y+Math.sin(t)*n}},draw:function(){var e=this._chart.ctx,t=this._view,n=t.startAngle,o=t.endAngle;e.beginPath(),e.arc(t.x,t.y,t.outerRadius,n,o),e.arc(t.x,t.y,t.innerRadius,o,n,!0),e.closePath(),e.strokeStyle=t.borderColor,e.lineWidth=t.borderWidth,e.fillStyle=t.backgroundColor,e.fill(),e.lineJoin="bevel",t.borderWidth&&e.stroke()}})},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6),a=o.global;o._set("global",{elements:{line:{tension:.4,backgroundColor:a.defaultColor,borderWidth:3,borderColor:a.defaultColor,borderCapStyle:"butt",borderDash:[],borderDashOffset:0,borderJoinStyle:"miter",capBezierPoints:!0,fill:!0}}}),e.exports=r.extend({draw:function(){var e,t,n,o,r=this._view,s=this._chart.ctx,l=r.spanGaps,u=this._children.slice(),c=a.elements.line,d=-1;for(this._loop&&u.length&&u.push(u[0]),s.save(),s.lineCap=r.borderCapStyle||c.borderCapStyle,s.setLineDash&&s.setLineDash(r.borderDash||c.borderDash),s.lineDashOffset=r.borderDashOffset||c.borderDashOffset,s.lineJoin=r.borderJoinStyle||c.borderJoinStyle,s.lineWidth=r.borderWidth||c.borderWidth,s.strokeStyle=r.borderColor||a.defaultColor,s.beginPath(),d=-1,e=0;e<u.length;++e)t=u[e],n=i.previousItem(u,e),o=t._view,0===e?o.skip||(s.moveTo(o.x,o.y),d=e):(n=-1===d?n:u[d],o.skip||(d!==e-1&&!l||-1===d?s.moveTo(o.x,o.y):i.canvas.lineTo(s,n._view,t._view),d=e));s.stroke(),s.restore()}})},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6),a=o.global.defaultColor;function s(e){var t=this._view;return!!t&&Math.abs(e-t.x)<t.radius+t.hitRadius}o._set("global",{elements:{point:{radius:3,pointStyle:"circle",backgroundColor:a,borderColor:a,borderWidth:1,hitRadius:1,hoverRadius:4,hoverBorderWidth:1}}}),e.exports=r.extend({inRange:function(e,t){var n=this._view;return!!n&&Math.pow(e-n.x,2)+Math.pow(t-n.y,2)<Math.pow(n.hitRadius+n.radius,2)},inLabelRange:s,inXRange:s,inYRange:function(e){var t=this._view;return!!t&&Math.abs(e-t.y)<t.radius+t.hitRadius},getCenterPoint:function(){var e=this._view;return{x:e.x,y:e.y}},getArea:function(){return Math.PI*Math.pow(this._view.radius,2)},tooltipPosition:function(){var e=this._view;return{x:e.x,y:e.y,padding:e.radius+e.borderWidth}},draw:function(e){var t=this._view,n=this._model,r=this._chart.ctx,s=t.pointStyle,l=t.radius,u=t.x,c=t.y,d=i.color,h=0;t.skip||(r.strokeStyle=t.borderColor||a,r.lineWidth=i.valueOrDefault(t.borderWidth,o.global.elements.point.borderWidth),r.fillStyle=t.backgroundColor||a,void 0!==e&&(n.x<e.left||1.01*e.right<n.x||n.y<e.top||1.01*e.bottom<n.y)&&(n.x<e.left?h=(u-n.x)/(e.left-n.x):1.01*e.right<n.x?h=(n.x-u)/(n.x-e.right):n.y<e.top?h=(c-n.y)/(e.top-n.y):1.01*e.bottom<n.y&&(h=(n.y-c)/(n.y-e.bottom)),h=Math.round(100*h)/100,r.strokeStyle=d(r.strokeStyle).alpha(h).rgbString(),r.fillStyle=d(r.fillStyle).alpha(h).rgbString()),i.canvas.drawPoint(r,s,l,u,c))}})},function(e,t,n){"use strict";var o=n(8),r=n(17);function i(e){return void 0!==e._view.width}function a(e){var t,n,o,r,a=e._view;if(i(e)){var s=a.width/2;t=a.x-s,n=a.x+s,o=Math.min(a.y,a.base),r=Math.max(a.y,a.base)}else{var l=a.height/2;t=Math.min(a.x,a.base),n=Math.max(a.x,a.base),o=a.y-l,r=a.y+l}return{left:t,top:o,right:n,bottom:r}}o._set("global",{elements:{rectangle:{backgroundColor:o.global.defaultColor,borderColor:o.global.defaultColor,borderSkipped:"bottom",borderWidth:0}}}),e.exports=r.extend({draw:function(){var e,t,n,o,r,i,a,s=this._chart.ctx,l=this._view,u=l.borderWidth;if(l.horizontal?(e=l.base,t=l.x,n=l.y-l.height/2,o=l.y+l.height/2,r=t>e?1:-1,i=1,a=l.borderSkipped||"left"):(e=l.x-l.width/2,t=l.x+l.width/2,n=l.y,r=1,i=(o=l.base)>n?1:-1,a=l.borderSkipped||"bottom"),u){var c=Math.min(Math.abs(e-t),Math.abs(n-o)),d=(u=u>c?c:u)/2,h=e+("left"!==a?d*r:0),f=t+("right"!==a?-d*r:0),p=n+("top"!==a?d*i:0),m=o+("bottom"!==a?-d*i:0);h!==f&&(n=p,o=m),p!==m&&(e=h,t=f)}s.beginPath(),s.fillStyle=l.backgroundColor,s.strokeStyle=l.borderColor,s.lineWidth=u;var g=[[e,o],[e,n],[t,n],[t,o]],v=["bottom","left","top","right"].indexOf(a,0);function y(e){return g[(v+e)%4]}-1===v&&(v=0);var _=y(0);s.moveTo(_[0],_[1]);for(var w=1;w<4;w++)_=y(w),s.lineTo(_[0],_[1]);s.fill(),u&&s.stroke()},height:function(){var e=this._view;return e.base-e.y},inRange:function(e,t){var n=!1;if(this._view){var o=a(this);n=e>=o.left&&e<=o.right&&t>=o.top&&t<=o.bottom}return n},inLabelRange:function(e,t){if(!this._view)return!1;var n=a(this);return i(this)?e>=n.left&&e<=n.right:t>=n.top&&t<=n.bottom},inXRange:function(e){var t=a(this);return e>=t.left&&e<=t.right},inYRange:function(e){var t=a(this);return e>=t.top&&e<=t.bottom},getCenterPoint:function(){var e,t,n=this._view;return i(this)?(e=n.x,t=(n.y+n.base)/2):(e=(n.x+n.base)/2,t=n.y),{x:e,y:t}},getArea:function(){var e=this._view;return e.width*Math.abs(e.y-e.base)},tooltipPosition:function(){var e=this._view;return{x:e.x,y:e.y}}})},function(e,t){e.exports={acquireContext:function(e){return e&&e.canvas&&(e=e.canvas),e&&e.getContext("2d")||null}}},function(e,t,n){"use strict";var o=n(6),r="$chartjs",i="chartjs-",a=i+"render-monitor",s=i+"render-animation",l=["animationstart","webkitAnimationStart"],u={touchstart:"mousedown",touchmove:"mousemove",touchend:"mouseup",pointerenter:"mouseenter",pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointerleave:"mouseout",pointerout:"mouseout"};function c(e,t){var n=o.getStyle(e,t),r=n&&n.match(/^(\d+)(\.\d+)?px$/);return r?Number(r[1]):void 0}var d=!!function(){var e=!1;try{var t=Object.defineProperty({},"passive",{get:function(){e=!0}});window.addEventListener("e",null,t)}catch(e){}return e}()&&{passive:!0};function h(e,t,n){e.addEventListener(t,n,d)}function f(e,t,n){e.removeEventListener(t,n,d)}function p(e,t,n,o,r){return{type:e,chart:t,native:r||null,x:void 0!==n?n:null,y:void 0!==o?o:null}}function m(e,t,n){var u,c,d,f,m=e[r]||(e[r]={}),g=m.resizer=function(e){var t=document.createElement("div"),n=i+"size-monitor",o="position:absolute;left:0;top:0;right:0;bottom:0;overflow:hidden;pointer-events:none;visibility:hidden;z-index:-1;";t.style.cssText=o,t.className=n,t.innerHTML='<div class="'+n+'-expand" style="'+o+'"><div style="position:absolute;width:1000000px;height:1000000px;left:0;top:0"></div></div><div class="'+n+'-shrink" style="'+o+'"><div style="position:absolute;width:200%;height:200%;left:0; top:0"></div></div>';var r=t.childNodes[0],a=t.childNodes[1];t._reset=function(){r.scrollLeft=1e6,r.scrollTop=1e6,a.scrollLeft=1e6,a.scrollTop=1e6};var s=function(){t._reset(),e()};return h(r,"scroll",s.bind(r,"expand")),h(a,"scroll",s.bind(a,"shrink")),t}((u=function(){if(m.resizer)return t(p("resize",n))},d=!1,f=[],function(){f=Array.prototype.slice.call(arguments),c=c||this,d||(d=!0,o.requestAnimFrame.call(window,function(){d=!1,u.apply(c,f)}))}));!function(e,t){var n=e[r]||(e[r]={}),i=n.renderProxy=function(e){e.animationName===s&&t()};o.each(l,function(t){h(e,t,i)}),n.reflow=!!e.offsetParent,e.classList.add(a)}(e,function(){if(m.resizer){var t=e.parentNode;t&&t!==g.parentNode&&t.insertBefore(g,t.firstChild),g._reset()}})}function g(e){var t=e[r]||{},n=t.resizer;delete t.resizer,function(e){var t=e[r]||{},n=t.renderProxy;n&&(o.each(l,function(t){f(e,t,n)}),delete t.renderProxy),e.classList.remove(a)}(e),n&&n.parentNode&&n.parentNode.removeChild(n)}e.exports={_enabled:"undefined"!=typeof window&&"undefined"!=typeof document,initialize:function(){var e,t,n,o="from{opacity:0.99}to{opacity:1}";t="@-webkit-keyframes "+s+"{"+o+"}@keyframes "+s+"{"+o+"}."+a+"{-webkit-animation:"+s+" 0.001s;animation:"+s+" 0.001s;}",n=(e=this)._style||document.createElement("style"),e._style||(e._style=n,t="/* Chart.js */\n"+t,n.setAttribute("type","text/css"),document.getElementsByTagName("head")[0].appendChild(n)),n.appendChild(document.createTextNode(t))},acquireContext:function(e,t){"string"==typeof e?e=document.getElementById(e):e.length&&(e=e[0]),e&&e.canvas&&(e=e.canvas);var n=e&&e.getContext&&e.getContext("2d");return n&&n.canvas===e?(function(e,t){var n=e.style,o=e.getAttribute("height"),i=e.getAttribute("width");if(e[r]={initial:{height:o,width:i,style:{display:n.display,height:n.height,width:n.width}}},n.display=n.display||"block",null===i||""===i){var a=c(e,"width");void 0!==a&&(e.width=a)}if(null===o||""===o)if(""===e.style.height)e.height=e.width/(t.options.aspectRatio||2);else{var s=c(e,"height");void 0!==a&&(e.height=s)}}(e,t),n):null},releaseContext:function(e){var t=e.canvas;if(t[r]){var n=t[r].initial;["height","width"].forEach(function(e){var r=n[e];o.isNullOrUndef(r)?t.removeAttribute(e):t.setAttribute(e,r)}),o.each(n.style||{},function(e,n){t.style[n]=e}),t.width=t.width,delete t[r]}},addEventListener:function(e,t,n){var i=e.canvas;if("resize"!==t){var a=n[r]||(n[r]={});h(i,t,(a.proxies||(a.proxies={}))[e.id+"_"+t]=function(t){n(function(e,t){var n=u[e.type]||e.type,r=o.getRelativePosition(e,t);return p(n,t,r.x,r.y,e)}(t,e))})}else m(i,n,e)},removeEventListener:function(e,t,n){var o=e.canvas;if("resize"!==t){var i=((n[r]||{}).proxies||{})[e.id+"_"+t];i&&f(o,t,i)}else g(o)}},o.addEvent=h,o.removeEvent=f},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6);o._set("global",{animation:{duration:1e3,easing:"easeOutQuart",onProgress:i.noop,onComplete:i.noop}}),e.exports=function(e){e.Animation=r.extend({chart:null,currentStep:0,numSteps:60,easing:"",render:null,onAnimationProgress:null,onAnimationComplete:null}),e.animationService={frameDuration:17,animations:[],dropFrames:0,request:null,addAnimation:function(e,t,n,o){var r,i,a=this.animations;for(t.chart=e,o||(e.animating=!0),r=0,i=a.length;r<i;++r)if(a[r].chart===e)return void(a[r]=t);a.push(t),1===a.length&&this.requestAnimationFrame()},cancelAnimation:function(e){var t=i.findIndex(this.animations,function(t){return t.chart===e});-1!==t&&(this.animations.splice(t,1),e.animating=!1)},requestAnimationFrame:function(){var e=this;null===e.request&&(e.request=i.requestAnimFrame.call(window,function(){e.request=null,e.startDigest()}))},startDigest:function(){var e=this,t=Date.now(),n=0;e.dropFrames>1&&(n=Math.floor(e.dropFrames),e.dropFrames=e.dropFrames%1),e.advance(1+n);var o=Date.now();e.dropFrames+=(o-t)/e.frameDuration,e.animations.length>0&&e.requestAnimationFrame()},advance:function(e){for(var t,n,o=this.animations,r=0;r<o.length;)n=(t=o[r]).chart,t.currentStep=(t.currentStep||0)+e,t.currentStep=Math.min(t.currentStep,t.numSteps),i.callback(t.render,[n,t],n),i.callback(t.onAnimationProgress,[t],n),t.currentStep>=t.numSteps?(i.callback(t.onAnimationComplete,[t],n),n.animating=!1,o.splice(r,1)):++r}},Object.defineProperty(e.Animation.prototype,"animationObject",{get:function(){return this}}),Object.defineProperty(e.Animation.prototype,"chartInstance",{get:function(){return this.chart},set:function(e){this.chart=e}})}},function(e,t,n){"use strict";var o=n(8),r=n(6),i=n(67),a=n(27),s=n(68),l=n(69);e.exports=function(e){function t(t){var n=t.options;r.each(t.scales,function(e){a.removeBox(t,e)}),n=r.configMerge(e.defaults.global,e.defaults[t.config.type],n),t.options=t.config.options=n,t.ensureScalesHaveIDs(),t.buildOrUpdateScales(),t.tooltip._options=n.tooltips,t.tooltip.initialize()}function n(e){return"top"===e||"bottom"===e}e.types={},e.instances={},e.controllers={},r.extend(e.prototype,{construct:function(t,n){var i=this;n=function(e){var t=(e=e||{}).data=e.data||{};return t.datasets=t.datasets||[],t.labels=t.labels||[],e.options=r.configMerge(o.global,o[e.type],e.options||{}),e}(n);var a=s.acquireContext(t,n),l=a&&a.canvas,u=l&&l.height,c=l&&l.width;i.id=r.uid(),i.ctx=a,i.canvas=l,i.config=n,i.width=c,i.height=u,i.aspectRatio=u?c/u:null,i.options=n.options,i._bufferedRender=!1,i.chart=i,i.controller=i,e.instances[i.id]=i,Object.defineProperty(i,"data",{get:function(){return i.config.data},set:function(e){i.config.data=e}}),a&&l?(i.initialize(),i.update()):console.error("Failed to create chart: can't acquire context from the given item")},initialize:function(){var e=this;return l.notify(e,"beforeInit"),r.retinaScale(e,e.options.devicePixelRatio),e.bindEvents(),e.options.responsive&&e.resize(!0),e.ensureScalesHaveIDs(),e.buildOrUpdateScales(),e.initToolTip(),l.notify(e,"afterInit"),e},clear:function(){return r.canvas.clear(this),this},stop:function(){return e.animationService.cancelAnimation(this),this},resize:function(e){var t=this,n=t.options,o=t.canvas,i=n.maintainAspectRatio&&t.aspectRatio||null,a=Math.max(0,Math.floor(r.getMaximumWidth(o))),s=Math.max(0,Math.floor(i?a/i:r.getMaximumHeight(o)));if((t.width!==a||t.height!==s)&&(o.width=t.width=a,o.height=t.height=s,o.style.width=a+"px",o.style.height=s+"px",r.retinaScale(t,n.devicePixelRatio),!e)){var u={width:a,height:s};l.notify(t,"resize",[u]),t.options.onResize&&t.options.onResize(t,u),t.stop(),t.update(t.options.responsiveAnimationDuration)}},ensureScalesHaveIDs:function(){var e=this.options,t=e.scales||{},n=e.scale;r.each(t.xAxes,function(e,t){e.id=e.id||"x-axis-"+t}),r.each(t.yAxes,function(e,t){e.id=e.id||"y-axis-"+t}),n&&(n.id=n.id||"scale")},buildOrUpdateScales:function(){var t=this,o=t.options,i=t.scales||{},a=[],s=Object.keys(i).reduce(function(e,t){return e[t]=!1,e},{});o.scales&&(a=a.concat((o.scales.xAxes||[]).map(function(e){return{options:e,dtype:"category",dposition:"bottom"}}),(o.scales.yAxes||[]).map(function(e){return{options:e,dtype:"linear",dposition:"left"}}))),o.scale&&a.push({options:o.scale,dtype:"radialLinear",isDefault:!0,dposition:"chartArea"}),r.each(a,function(o){var a=o.options,l=a.id,u=r.valueOrDefault(a.type,o.dtype);n(a.position)!==n(o.dposition)&&(a.position=o.dposition),s[l]=!0;var c=null;if(l in i&&i[l].type===u)(c=i[l]).options=a,c.ctx=t.ctx,c.chart=t;else{var d=e.scaleService.getScaleConstructor(u);if(!d)return;c=new d({id:l,type:u,options:a,ctx:t.ctx,chart:t}),i[c.id]=c}c.mergeTicksOptions(),o.isDefault&&(t.scale=c)}),r.each(s,function(e,t){e||delete i[t]}),t.scales=i,e.scaleService.addScalesToLayout(this)},buildOrUpdateControllers:function(){var t=this,n=[],o=[];return r.each(t.data.datasets,function(r,i){var a=t.getDatasetMeta(i),s=r.type||t.config.type;if(a.type&&a.type!==s&&(t.destroyDatasetMeta(i),a=t.getDatasetMeta(i)),a.type=s,n.push(a.type),a.controller)a.controller.updateIndex(i),a.controller.linkScales();else{var l=e.controllers[a.type];if(void 0===l)throw new Error('"'+a.type+'" is not a chart type.');a.controller=new l(t,i),o.push(a.controller)}},t),o},resetElements:function(){var e=this;r.each(e.data.datasets,function(t,n){e.getDatasetMeta(n).controller.reset()},e)},reset:function(){this.resetElements(),this.tooltip.initialize()},update:function(e){var n=this;if(e&&"object"==typeof e||(e={duration:e,lazy:arguments[1]}),t(n),l._invalidate(n),!1!==l.notify(n,"beforeUpdate")){n.tooltip._data=n.data;var o=n.buildOrUpdateControllers();r.each(n.data.datasets,function(e,t){n.getDatasetMeta(t).controller.buildOrUpdateElements()},n),n.updateLayout(),n.options.animation&&n.options.animation.duration&&r.each(o,function(e){e.reset()}),n.updateDatasets(),n.tooltip.initialize(),n.lastActive=[],l.notify(n,"afterUpdate"),n._bufferedRender?n._bufferedRequest={duration:e.duration,easing:e.easing,lazy:e.lazy}:n.render(e)}},updateLayout:function(){!1!==l.notify(this,"beforeLayout")&&(a.update(this,this.width,this.height),l.notify(this,"afterScaleUpdate"),l.notify(this,"afterLayout"))},updateDatasets:function(){if(!1!==l.notify(this,"beforeDatasetsUpdate")){for(var e=0,t=this.data.datasets.length;e<t;++e)this.updateDataset(e);l.notify(this,"afterDatasetsUpdate")}},updateDataset:function(e){var t=this.getDatasetMeta(e),n={meta:t,index:e};!1!==l.notify(this,"beforeDatasetUpdate",[n])&&(t.controller.update(),l.notify(this,"afterDatasetUpdate",[n]))},render:function(t){var n=this;t&&"object"==typeof t||(t={duration:t,lazy:arguments[1]});var o=t.duration,i=t.lazy;if(!1!==l.notify(n,"beforeRender")){var a=n.options.animation,s=function(e){l.notify(n,"afterRender"),r.callback(a&&a.onComplete,[e],n)};if(a&&(void 0!==o&&0!==o||void 0===o&&0!==a.duration)){var u=new e.Animation({numSteps:(o||a.duration)/16.66,easing:t.easing||a.easing,render:function(e,t){var n=r.easing.effects[t.easing],o=t.currentStep,i=o/t.numSteps;e.draw(n(i),i,o)},onAnimationProgress:a.onProgress,onAnimationComplete:s});e.animationService.addAnimation(n,u,o,i)}else n.draw(),s(new e.Animation({numSteps:0,chart:n}));return n}},draw:function(e){var t=this;t.clear(),r.isNullOrUndef(e)&&(e=1),t.transition(e),!1!==l.notify(t,"beforeDraw",[e])&&(r.each(t.boxes,function(e){e.draw(t.chartArea)},t),t.scale&&t.scale.draw(),t.drawDatasets(e),t._drawTooltip(e),l.notify(t,"afterDraw",[e]))},transition:function(e){for(var t=0,n=(this.data.datasets||[]).length;t<n;++t)this.isDatasetVisible(t)&&this.getDatasetMeta(t).controller.transition(e);this.tooltip.transition(e)},drawDatasets:function(e){var t=this;if(!1!==l.notify(t,"beforeDatasetsDraw",[e])){for(var n=(t.data.datasets||[]).length-1;n>=0;--n)t.isDatasetVisible(n)&&t.drawDataset(n,e);l.notify(t,"afterDatasetsDraw",[e])}},drawDataset:function(e,t){var n=this.getDatasetMeta(e),o={meta:n,index:e,easingValue:t};!1!==l.notify(this,"beforeDatasetDraw",[o])&&(n.controller.draw(t),l.notify(this,"afterDatasetDraw",[o]))},_drawTooltip:function(e){var t=this.tooltip,n={tooltip:t,easingValue:e};!1!==l.notify(this,"beforeTooltipDraw",[n])&&(t.draw(),l.notify(this,"afterTooltipDraw",[n]))},getElementAtEvent:function(e){return i.modes.single(this,e)},getElementsAtEvent:function(e){return i.modes.label(this,e,{intersect:!0})},getElementsAtXAxis:function(e){return i.modes["x-axis"](this,e,{intersect:!0})},getElementsAtEventForMode:function(e,t,n){var o=i.modes[t];return"function"==typeof o?o(this,e,n):[]},getDatasetAtEvent:function(e){return i.modes.dataset(this,e,{intersect:!0})},getDatasetMeta:function(e){var t=this.data.datasets[e];t._meta||(t._meta={});var n=t._meta[this.id];return n||(n=t._meta[this.id]={type:null,data:[],dataset:null,controller:null,hidden:null,xAxisID:null,yAxisID:null}),n},getVisibleDatasetCount:function(){for(var e=0,t=0,n=this.data.datasets.length;t<n;++t)this.isDatasetVisible(t)&&e++;return e},isDatasetVisible:function(e){var t=this.getDatasetMeta(e);return"boolean"==typeof t.hidden?!t.hidden:!this.data.datasets[e].hidden},generateLegend:function(){return this.options.legendCallback(this)},destroyDatasetMeta:function(e){var t=this.id,n=this.data.datasets[e],o=n._meta&&n._meta[t];o&&(o.controller.destroy(),delete n._meta[t])},destroy:function(){var t,n,o=this,i=o.canvas;for(o.stop(),t=0,n=o.data.datasets.length;t<n;++t)o.destroyDatasetMeta(t);i&&(o.unbindEvents(),r.canvas.clear(o),s.releaseContext(o.ctx),o.canvas=null,o.ctx=null),l.notify(o,"destroy"),delete e.instances[o.id]},toBase64Image:function(){return this.canvas.toDataURL.apply(this.canvas,arguments)},initToolTip:function(){var t=this;t.tooltip=new e.Tooltip({_chart:t,_chartInstance:t,_data:t.data,_options:t.options.tooltips},t)},bindEvents:function(){var e=this,t=e._listeners={},n=function(){e.eventHandler.apply(e,arguments)};r.each(e.options.events,function(o){s.addEventListener(e,o,n),t[o]=n}),e.options.responsive&&(n=function(){e.resize()},s.addEventListener(e,"resize",n),t.resize=n)},unbindEvents:function(){var e=this,t=e._listeners;t&&(delete e._listeners,r.each(t,function(t,n){s.removeEventListener(e,n,t)}))},updateHoverStyle:function(e,t,n){var o,r,i,a=n?"setHoverStyle":"removeHoverStyle";for(r=0,i=e.length;r<i;++r)(o=e[r])&&this.getDatasetMeta(o._datasetIndex).controller[a](o)},eventHandler:function(e){var t=this,n=t.tooltip;if(!1!==l.notify(t,"beforeEvent",[e])){t._bufferedRender=!0,t._bufferedRequest=null;var o=t.handleEvent(e);n&&(o=n._start?n.handleEvent(e):o|n.handleEvent(e)),l.notify(t,"afterEvent",[e]);var r=t._bufferedRequest;return r?t.render(r):o&&!t.animating&&(t.stop(),t.render(t.options.hover.animationDuration,!0)),t._bufferedRender=!1,t._bufferedRequest=null,t}},handleEvent:function(e){var t,n=this,o=n.options||{},i=o.hover;return n.lastActive=n.lastActive||[],"mouseout"===e.type?n.active=[]:n.active=n.getElementsAtEventForMode(e,i.mode,i),r.callback(o.onHover||o.hover.onHover,[e.native,n.active],n),"mouseup"!==e.type&&"click"!==e.type||o.onClick&&o.onClick.call(n,e.native,n.active),n.lastActive.length&&n.updateHoverStyle(n.lastActive,i.mode,!1),n.active.length&&i.mode&&n.updateHoverStyle(n.active,i.mode,!0),t=!r.arrayEquals(n.active,n.lastActive),n.lastActive=n.active,t}}),e.Controller=e}},function(e,t,n){"use strict";var o=n(6);e.exports=function(e){var t=["push","pop","shift","splice","unshift"];function n(e,n){var o=e._chartjs;if(o){var r=o.listeners,i=r.indexOf(n);-1!==i&&r.splice(i,1),r.length>0||(t.forEach(function(t){delete e[t]}),delete e._chartjs)}}e.DatasetController=function(e,t){this.initialize(e,t)},o.extend(e.DatasetController.prototype,{datasetElementType:null,dataElementType:null,initialize:function(e,t){this.chart=e,this.index=t,this.linkScales(),this.addElements()},updateIndex:function(e){this.index=e},linkScales:function(){var e=this,t=e.getMeta(),n=e.getDataset();null!==t.xAxisID&&t.xAxisID in e.chart.scales||(t.xAxisID=n.xAxisID||e.chart.options.scales.xAxes[0].id),null!==t.yAxisID&&t.yAxisID in e.chart.scales||(t.yAxisID=n.yAxisID||e.chart.options.scales.yAxes[0].id)},getDataset:function(){return this.chart.data.datasets[this.index]},getMeta:function(){return this.chart.getDatasetMeta(this.index)},getScaleForId:function(e){return this.chart.scales[e]},reset:function(){this.update(!0)},destroy:function(){this._data&&n(this._data,this)},createMetaDataset:function(){var e=this.datasetElementType;return e&&new e({_chart:this.chart,_datasetIndex:this.index})},createMetaData:function(e){var t=this.dataElementType;return t&&new t({_chart:this.chart,_datasetIndex:this.index,_index:e})},addElements:function(){var e,t,n=this.getMeta(),o=this.getDataset().data||[],r=n.data;for(e=0,t=o.length;e<t;++e)r[e]=r[e]||this.createMetaData(e);n.dataset=n.dataset||this.createMetaDataset()},addElementAndReset:function(e){var t=this.createMetaData(e);this.getMeta().data.splice(e,0,t),this.updateElement(t,e,!0)},buildOrUpdateElements:function(){var e,r,i=this,a=i.getDataset(),s=a.data||(a.data=[]);i._data!==s&&(i._data&&n(i._data,i),r=i,(e=s)._chartjs?e._chartjs.listeners.push(r):(Object.defineProperty(e,"_chartjs",{configurable:!0,enumerable:!1,value:{listeners:[r]}}),t.forEach(function(t){var n="onData"+t.charAt(0).toUpperCase()+t.slice(1),r=e[t];Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:function(){var t=Array.prototype.slice.call(arguments),i=r.apply(this,t);return o.each(e._chartjs.listeners,function(e){"function"==typeof e[n]&&e[n].apply(e,t)}),i}})})),i._data=s),i.resyncElements()},update:o.noop,transition:function(e){for(var t=this.getMeta(),n=t.data||[],o=n.length,r=0;r<o;++r)n[r].transition(e);t.dataset&&t.dataset.transition(e)},draw:function(){var e=this.getMeta(),t=e.data||[],n=t.length,o=0;for(e.dataset&&e.dataset.draw();o<n;++o)t[o].draw()},removeHoverStyle:function(e,t){var n=this.chart.data.datasets[e._datasetIndex],r=e._index,i=e.custom||{},a=o.valueAtIndexOrDefault,s=e._model;s.backgroundColor=i.backgroundColor?i.backgroundColor:a(n.backgroundColor,r,t.backgroundColor),s.borderColor=i.borderColor?i.borderColor:a(n.borderColor,r,t.borderColor),s.borderWidth=i.borderWidth?i.borderWidth:a(n.borderWidth,r,t.borderWidth)},setHoverStyle:function(e){var t=this.chart.data.datasets[e._datasetIndex],n=e._index,r=e.custom||{},i=o.valueAtIndexOrDefault,a=o.getHoverColor,s=e._model;s.backgroundColor=r.hoverBackgroundColor?r.hoverBackgroundColor:i(t.hoverBackgroundColor,n,a(s.backgroundColor)),s.borderColor=r.hoverBorderColor?r.hoverBorderColor:i(t.hoverBorderColor,n,a(s.borderColor)),s.borderWidth=r.hoverBorderWidth?r.hoverBorderWidth:i(t.hoverBorderWidth,n,s.borderWidth)},resyncElements:function(){var e=this.getMeta(),t=this.getDataset().data,n=e.data.length,o=t.length;o<n?e.data.splice(o,n-o):o>n&&this.insertElements(n,o-n)},insertElements:function(e,t){for(var n=0;n<t;++n)this.addElementAndReset(e+n)},onDataPush:function(){this.insertElements(this.getDataset().data.length-1,arguments.length)},onDataPop:function(){this.getMeta().data.pop()},onDataShift:function(){this.getMeta().data.shift()},onDataSplice:function(e,t){this.getMeta().data.splice(e,t),this.insertElements(e,arguments.length-2)},onDataUnshift:function(){this.insertElements(0,arguments.length)}}),e.DatasetController.extend=o.inherits}},function(e,t,n){"use strict";var o=n(8),r=n(6),i=n(27);e.exports=function(e){e.scaleService={constructors:{},defaults:{},registerScaleType:function(e,t,n){this.constructors[e]=t,this.defaults[e]=r.clone(n)},getScaleConstructor:function(e){return this.constructors.hasOwnProperty(e)?this.constructors[e]:void 0},getScaleDefaults:function(e){return this.defaults.hasOwnProperty(e)?r.merge({},[o.scale,this.defaults[e]]):{}},updateScaleDefaults:function(e,t){this.defaults.hasOwnProperty(e)&&(this.defaults[e]=r.extend(this.defaults[e],t))},addScalesToLayout:function(e){r.each(e.scales,function(t){t.fullWidth=t.options.fullWidth,t.position=t.options.position,t.weight=t.options.weight,i.addBox(e,t)})}}}},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6),a=n(28);function s(e){var t,n,o=[];for(t=0,n=e.length;t<n;++t)o.push(e[t].label);return o}function l(e,t,n){var o=e.getPixelForTick(t);return n&&(o-=0===t?(e.getPixelForTick(1)-o)/2:(o-e.getPixelForTick(t-1))/2),o}o._set("scale",{display:!0,position:"left",offset:!1,gridLines:{display:!0,color:"rgba(0, 0, 0, 0.1)",lineWidth:1,drawBorder:!0,drawOnChartArea:!0,drawTicks:!0,tickMarkLength:10,zeroLineWidth:1,zeroLineColor:"rgba(0,0,0,0.25)",zeroLineBorderDash:[],zeroLineBorderDashOffset:0,offsetGridLines:!1,borderDash:[],borderDashOffset:0},scaleLabel:{display:!1,labelString:"",lineHeight:1.2,padding:{top:4,bottom:4}},ticks:{beginAtZero:!1,minRotation:0,maxRotation:50,mirror:!1,padding:0,reverse:!1,display:!0,autoSkip:!0,autoSkipPadding:0,labelOffset:0,callback:a.formatters.values,minor:{},major:{}}}),e.exports=function(e){function t(e,t,n){return i.isArray(t)?i.longestText(e,n,t):e.measureText(t).width}function n(e){var t=i.valueOrDefault,n=o.global,r=t(e.fontSize,n.defaultFontSize),a=t(e.fontStyle,n.defaultFontStyle),s=t(e.fontFamily,n.defaultFontFamily);return{size:r,style:a,family:s,font:i.fontString(r,a,s)}}function a(e){return i.options.toLineHeight(i.valueOrDefault(e.lineHeight,1.2),i.valueOrDefault(e.fontSize,o.global.defaultFontSize))}e.Scale=r.extend({getPadding:function(){return{left:this.paddingLeft||0,top:this.paddingTop||0,right:this.paddingRight||0,bottom:this.paddingBottom||0}},getTicks:function(){return this._ticks},mergeTicksOptions:function(){var e=this.options.ticks;for(var t in!1===e.minor&&(e.minor={display:!1}),!1===e.major&&(e.major={display:!1}),e)"major"!==t&&"minor"!==t&&(void 0===e.minor[t]&&(e.minor[t]=e[t]),void 0===e.major[t]&&(e.major[t]=e[t]))},beforeUpdate:function(){i.callback(this.options.beforeUpdate,[this])},update:function(e,t,n){var o,r,a,s,l,u,c=this;for(c.beforeUpdate(),c.maxWidth=e,c.maxHeight=t,c.margins=i.extend({left:0,right:0,top:0,bottom:0},n),c.longestTextCache=c.longestTextCache||{},c.beforeSetDimensions(),c.setDimensions(),c.afterSetDimensions(),c.beforeDataLimits(),c.determineDataLimits(),c.afterDataLimits(),c.beforeBuildTicks(),l=c.buildTicks()||[],c.afterBuildTicks(),c.beforeTickToLabelConversion(),a=c.convertTicksToLabels(l)||c.ticks,c.afterTickToLabelConversion(),c.ticks=a,o=0,r=a.length;o<r;++o)s=a[o],(u=l[o])?u.label=s:l.push(u={label:s,major:!1});return c._ticks=l,c.beforeCalculateTickRotation(),c.calculateTickRotation(),c.afterCalculateTickRotation(),c.beforeFit(),c.fit(),c.afterFit(),c.afterUpdate(),c.minSize},afterUpdate:function(){i.callback(this.options.afterUpdate,[this])},beforeSetDimensions:function(){i.callback(this.options.beforeSetDimensions,[this])},setDimensions:function(){var e=this;e.isHorizontal()?(e.width=e.maxWidth,e.left=0,e.right=e.width):(e.height=e.maxHeight,e.top=0,e.bottom=e.height),e.paddingLeft=0,e.paddingTop=0,e.paddingRight=0,e.paddingBottom=0},afterSetDimensions:function(){i.callback(this.options.afterSetDimensions,[this])},beforeDataLimits:function(){i.callback(this.options.beforeDataLimits,[this])},determineDataLimits:i.noop,afterDataLimits:function(){i.callback(this.options.afterDataLimits,[this])},beforeBuildTicks:function(){i.callback(this.options.beforeBuildTicks,[this])},buildTicks:i.noop,afterBuildTicks:function(){i.callback(this.options.afterBuildTicks,[this])},beforeTickToLabelConversion:function(){i.callback(this.options.beforeTickToLabelConversion,[this])},convertTicksToLabels:function(){var e=this.options.ticks;this.ticks=this.ticks.map(e.userCallback||e.callback,this)},afterTickToLabelConversion:function(){i.callback(this.options.afterTickToLabelConversion,[this])},beforeCalculateTickRotation:function(){i.callback(this.options.beforeCalculateTickRotation,[this])},calculateTickRotation:function(){var e=this,t=e.ctx,o=e.options.ticks,r=s(e._ticks),a=n(o);t.font=a.font;var l=o.minRotation||0;if(r.length&&e.options.display&&e.isHorizontal())for(var u,c=i.longestText(t,a.font,r,e.longestTextCache),d=c,h=e.getPixelForTick(1)-e.getPixelForTick(0)-6;d>h&&l<o.maxRotation;){var f=i.toRadians(l);if(u=Math.cos(f),Math.sin(f)*c>e.maxHeight){l--;break}l++,d=u*c}e.labelRotation=l},afterCalculateTickRotation:function(){i.callback(this.options.afterCalculateTickRotation,[this])},beforeFit:function(){i.callback(this.options.beforeFit,[this])},fit:function(){var e=this,o=e.minSize={width:0,height:0},r=s(e._ticks),l=e.options,u=l.ticks,c=l.scaleLabel,d=l.gridLines,h=l.display,f=e.isHorizontal(),p=n(u),m=l.gridLines.tickMarkLength;if(o.width=f?e.isFullWidth()?e.maxWidth-e.margins.left-e.margins.right:e.maxWidth:h&&d.drawTicks?m:0,o.height=f?h&&d.drawTicks?m:0:e.maxHeight,c.display&&h){var g=a(c)+i.options.toPadding(c.padding).height;f?o.height+=g:o.width+=g}if(u.display&&h){var v=i.longestText(e.ctx,p.font,r,e.longestTextCache),y=i.numberOfLabelLines(r),_=.5*p.size,w=e.options.ticks.padding;if(f){e.longestLabelWidth=v;var b=i.toRadians(e.labelRotation),C=Math.cos(b),M=Math.sin(b)*v+p.size*y+_*(y-1)+_;o.height=Math.min(e.maxHeight,o.height+M+w),e.ctx.font=p.font;var k=t(e.ctx,r[0],p.font),S=t(e.ctx,r[r.length-1],p.font);0!==e.labelRotation?(e.paddingLeft="bottom"===l.position?C*k+3:C*_+3,e.paddingRight="bottom"===l.position?C*_+3:C*S+3):(e.paddingLeft=k/2+3,e.paddingRight=S/2+3)}else u.mirror?v=0:v+=w+_,o.width=Math.min(e.maxWidth,o.width+v),e.paddingTop=p.size/2,e.paddingBottom=p.size/2}e.handleMargins(),e.width=o.width,e.height=o.height},handleMargins:function(){var e=this;e.margins&&(e.paddingLeft=Math.max(e.paddingLeft-e.margins.left,0),e.paddingTop=Math.max(e.paddingTop-e.margins.top,0),e.paddingRight=Math.max(e.paddingRight-e.margins.right,0),e.paddingBottom=Math.max(e.paddingBottom-e.margins.bottom,0))},afterFit:function(){i.callback(this.options.afterFit,[this])},isHorizontal:function(){return"top"===this.options.position||"bottom"===this.options.position},isFullWidth:function(){return this.options.fullWidth},getRightValue:function(e){if(i.isNullOrUndef(e))return NaN;if("number"==typeof e&&!isFinite(e))return NaN;if(e)if(this.isHorizontal()){if(void 0!==e.x)return this.getRightValue(e.x)}else if(void 0!==e.y)return this.getRightValue(e.y);return e},getLabelForIndex:i.noop,getPixelForValue:i.noop,getValueForPixel:i.noop,getPixelForTick:function(e){var t=this,n=t.options.offset;if(t.isHorizontal()){var o=(t.width-(t.paddingLeft+t.paddingRight))/Math.max(t._ticks.length-(n?0:1),1),r=o*e+t.paddingLeft;n&&(r+=o/2);var i=t.left+Math.round(r);return i+=t.isFullWidth()?t.margins.left:0}var a=t.height-(t.paddingTop+t.paddingBottom);return t.top+e*(a/(t._ticks.length-1))},getPixelForDecimal:function(e){var t=this;if(t.isHorizontal()){var n=(t.width-(t.paddingLeft+t.paddingRight))*e+t.paddingLeft,o=t.left+Math.round(n);return o+=t.isFullWidth()?t.margins.left:0}return t.top+e*t.height},getBasePixel:function(){return this.getPixelForValue(this.getBaseValue())},getBaseValue:function(){var e=this.min,t=this.max;return this.beginAtZero?0:e<0&&t<0?t:e>0&&t>0?e:0},_autoSkip:function(e){var t,n,o,r,a=this,s=a.isHorizontal(),l=a.options.ticks.minor,u=e.length,c=i.toRadians(a.labelRotation),d=Math.cos(c),h=a.longestLabelWidth*d,f=[];for(l.maxTicksLimit&&(r=l.maxTicksLimit),s&&(t=!1,(h+l.autoSkipPadding)*u>a.width-(a.paddingLeft+a.paddingRight)&&(t=1+Math.floor((h+l.autoSkipPadding)*u/(a.width-(a.paddingLeft+a.paddingRight)))),r&&u>r&&(t=Math.max(t,Math.floor(u/r)))),n=0;n<u;n++)o=e[n],(t>1&&n%t>0||n%t==0&&n+t>=u)&&n!==u-1&&delete o.label,f.push(o);return f},draw:function(e){var t=this,r=t.options;if(r.display){var s=t.ctx,u=o.global,c=r.ticks.minor,d=r.ticks.major||c,h=r.gridLines,f=r.scaleLabel,p=0!==t.labelRotation,m=t.isHorizontal(),g=c.autoSkip?t._autoSkip(t.getTicks()):t.getTicks(),v=i.valueOrDefault(c.fontColor,u.defaultFontColor),y=n(c),_=i.valueOrDefault(d.fontColor,u.defaultFontColor),w=n(d),b=h.drawTicks?h.tickMarkLength:0,C=i.valueOrDefault(f.fontColor,u.defaultFontColor),M=n(f),k=i.options.toPadding(f.padding),S=i.toRadians(t.labelRotation),T=[],L=t.options.gridLines.lineWidth,x="right"===r.position?t.right:t.right-L-b,D="right"===r.position?t.right+b:t.right,O="bottom"===r.position?t.top+L:t.bottom-b-L,E="bottom"===r.position?t.top+L+b:t.bottom+L;if(i.each(g,function(n,o){if(!i.isNullOrUndef(n.label)){var a,s,d,f,v,y,_,w,C,M,k,R,A,H,Y=n.label;o===t.zeroLineIndex&&r.offset===h.offsetGridLines?(a=h.zeroLineWidth,s=h.zeroLineColor,d=h.zeroLineBorderDash,f=h.zeroLineBorderDashOffset):(a=i.valueAtIndexOrDefault(h.lineWidth,o),s=i.valueAtIndexOrDefault(h.color,o),d=i.valueOrDefault(h.borderDash,u.borderDash),f=i.valueOrDefault(h.borderDashOffset,u.borderDashOffset));var P="middle",N="middle",I=c.padding;if(m){var W=b+I;"bottom"===r.position?(N=p?"middle":"top",P=p?"right":"center",H=t.top+W):(N=p?"middle":"bottom",P=p?"left":"center",H=t.bottom-W);var j=l(t,o,h.offsetGridLines&&g.length>1);j<t.left&&(s="rgba(0,0,0,0)"),j+=i.aliasPixel(a),A=t.getPixelForTick(o)+c.labelOffset,v=_=C=k=j,y=O,w=E,M=e.top,R=e.bottom+L}else{var F,z="left"===r.position;c.mirror?(P=z?"left":"right",F=I):(P=z?"right":"left",F=b+I),A=z?t.right-F:t.left+F;var B=l(t,o,h.offsetGridLines&&g.length>1);B<t.top&&(s="rgba(0,0,0,0)"),B+=i.aliasPixel(a),H=t.getPixelForTick(o)+c.labelOffset,v=x,_=D,C=e.left,k=e.right+L,y=w=M=R=B}T.push({tx1:v,ty1:y,tx2:_,ty2:w,x1:C,y1:M,x2:k,y2:R,labelX:A,labelY:H,glWidth:a,glColor:s,glBorderDash:d,glBorderDashOffset:f,rotation:-1*S,label:Y,major:n.major,textBaseline:N,textAlign:P})}}),i.each(T,function(e){if(h.display&&(s.save(),s.lineWidth=e.glWidth,s.strokeStyle=e.glColor,s.setLineDash&&(s.setLineDash(e.glBorderDash),s.lineDashOffset=e.glBorderDashOffset),s.beginPath(),h.drawTicks&&(s.moveTo(e.tx1,e.ty1),s.lineTo(e.tx2,e.ty2)),h.drawOnChartArea&&(s.moveTo(e.x1,e.y1),s.lineTo(e.x2,e.y2)),s.stroke(),s.restore()),c.display){s.save(),s.translate(e.labelX,e.labelY),s.rotate(e.rotation),s.font=e.major?w.font:y.font,s.fillStyle=e.major?_:v,s.textBaseline=e.textBaseline,s.textAlign=e.textAlign;var n=e.label;if(i.isArray(n))for(var o=n.length,r=1.5*y.size,a=t.isHorizontal()?0:-r*(o-1)/2,l=0;l<o;++l)s.fillText(""+n[l],0,a),a+=r;else s.fillText(n,0,0);s.restore()}}),f.display){var R,A,H=0,Y=a(f)/2;if(m)R=t.left+(t.right-t.left)/2,A="bottom"===r.position?t.bottom-Y-k.bottom:t.top+Y+k.top;else{var P="left"===r.position;R=P?t.left+Y+k.top:t.right-Y-k.top,A=t.top+(t.bottom-t.top)/2,H=P?-.5*Math.PI:.5*Math.PI}s.save(),s.translate(R,A),s.rotate(H),s.textAlign="center",s.textBaseline="middle",s.fillStyle=C,s.font=M.font,s.fillText(f.labelString,0,0),s.restore()}if(h.drawBorder){s.lineWidth=i.valueAtIndexOrDefault(h.lineWidth,0),s.strokeStyle=i.valueAtIndexOrDefault(h.color,0);var N=t.left,I=t.right+L,W=t.top,j=t.bottom+L,F=i.aliasPixel(s.lineWidth);m?(W=j="top"===r.position?t.bottom:t.top,W+=F,j+=F):(N=I="left"===r.position?t.right:t.left,N+=F,I+=F),s.beginPath(),s.moveTo(N,W),s.lineTo(I,j),s.stroke()}}}})}},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6);o._set("global",{tooltips:{enabled:!0,custom:null,mode:"nearest",position:"average",intersect:!0,backgroundColor:"rgba(0,0,0,0.8)",titleFontStyle:"bold",titleSpacing:2,titleMarginBottom:6,titleFontColor:"#fff",titleAlign:"left",bodySpacing:2,bodyFontColor:"#fff",bodyAlign:"left",footerFontStyle:"bold",footerSpacing:2,footerMarginTop:6,footerFontColor:"#fff",footerAlign:"left",yPadding:6,xPadding:6,caretPadding:2,caretSize:5,cornerRadius:6,multiKeyBackground:"#fff",displayColors:!0,borderColor:"rgba(0,0,0,0)",borderWidth:0,callbacks:{beforeTitle:i.noop,title:function(e,t){var n="",o=t.labels,r=o?o.length:0;if(e.length>0){var i=e[0];i.xLabel?n=i.xLabel:r>0&&i.index<r&&(n=o[i.index])}return n},afterTitle:i.noop,beforeBody:i.noop,beforeLabel:i.noop,label:function(e,t){var n=t.datasets[e.datasetIndex].label||"";return n&&(n+=": "),n+=e.yLabel},labelColor:function(e,t){var n=t.getDatasetMeta(e.datasetIndex).data[e.index]._view;return{borderColor:n.borderColor,backgroundColor:n.backgroundColor}},labelTextColor:function(){return this._options.bodyFontColor},afterLabel:i.noop,afterBody:i.noop,beforeFooter:i.noop,footer:i.noop,afterFooter:i.noop}}}),e.exports=function(e){function t(e,t){var n=i.color(e);return n.alpha(t*n.alpha()).rgbaString()}function n(e,t){return t&&(i.isArray(t)?Array.prototype.push.apply(e,t):e.push(t)),e}function a(e){var t=o.global,n=i.valueOrDefault;return{xPadding:e.xPadding,yPadding:e.yPadding,xAlign:e.xAlign,yAlign:e.yAlign,bodyFontColor:e.bodyFontColor,_bodyFontFamily:n(e.bodyFontFamily,t.defaultFontFamily),_bodyFontStyle:n(e.bodyFontStyle,t.defaultFontStyle),_bodyAlign:e.bodyAlign,bodyFontSize:n(e.bodyFontSize,t.defaultFontSize),bodySpacing:e.bodySpacing,titleFontColor:e.titleFontColor,_titleFontFamily:n(e.titleFontFamily,t.defaultFontFamily),_titleFontStyle:n(e.titleFontStyle,t.defaultFontStyle),titleFontSize:n(e.titleFontSize,t.defaultFontSize),_titleAlign:e.titleAlign,titleSpacing:e.titleSpacing,titleMarginBottom:e.titleMarginBottom,footerFontColor:e.footerFontColor,_footerFontFamily:n(e.footerFontFamily,t.defaultFontFamily),_footerFontStyle:n(e.footerFontStyle,t.defaultFontStyle),footerFontSize:n(e.footerFontSize,t.defaultFontSize),_footerAlign:e.footerAlign,footerSpacing:e.footerSpacing,footerMarginTop:e.footerMarginTop,caretSize:e.caretSize,cornerRadius:e.cornerRadius,backgroundColor:e.backgroundColor,opacity:0,legendColorBackground:e.multiKeyBackground,displayColors:e.displayColors,borderColor:e.borderColor,borderWidth:e.borderWidth}}e.Tooltip=r.extend({initialize:function(){this._model=a(this._options),this._lastActive=[]},getTitle:function(){var e=this,t=e._options,o=t.callbacks,r=o.beforeTitle.apply(e,arguments),i=o.title.apply(e,arguments),a=o.afterTitle.apply(e,arguments),s=[];return s=n(s,r),s=n(s,i),s=n(s,a)},getBeforeBody:function(){var e=this._options.callbacks.beforeBody.apply(this,arguments);return i.isArray(e)?e:void 0!==e?[e]:[]},getBody:function(e,t){var o=this,r=o._options.callbacks,a=[];return i.each(e,function(e){var i={before:[],lines:[],after:[]};n(i.before,r.beforeLabel.call(o,e,t)),n(i.lines,r.label.call(o,e,t)),n(i.after,r.afterLabel.call(o,e,t)),a.push(i)}),a},getAfterBody:function(){var e=this._options.callbacks.afterBody.apply(this,arguments);return i.isArray(e)?e:void 0!==e?[e]:[]},getFooter:function(){var e=this,t=e._options.callbacks,o=t.beforeFooter.apply(e,arguments),r=t.footer.apply(e,arguments),i=t.afterFooter.apply(e,arguments),a=[];return a=n(a,o),a=n(a,r),a=n(a,i)},update:function(t){var n,o,r,s,l,u,c,d=this,h=d._options,f=d._model,p=d._model=a(h),m=d._active,g=d._data,v={xAlign:f.xAlign,yAlign:f.yAlign},y={x:f.x,y:f.y},_={width:f.width,height:f.height},w={x:f.caretX,y:f.caretY};if(m.length){p.opacity=1;var b=[],C=[];w=e.Tooltip.positioners[h.position].call(d,m,d._eventPosition);var M=[];for(n=0,o=m.length;n<o;++n)M.push((r=m[n],s=void 0,l=void 0,u=void 0,c=void 0,s=r._xScale,l=r._yScale||r._scale,u=r._index,c=r._datasetIndex,{xLabel:s?s.getLabelForIndex(u,c):"",yLabel:l?l.getLabelForIndex(u,c):"",index:u,datasetIndex:c,x:r._model.x,y:r._model.y}));h.filter&&(M=M.filter(function(e){return h.filter(e,g)})),h.itemSort&&(M=M.sort(function(e,t){return h.itemSort(e,t,g)})),i.each(M,function(e){b.push(h.callbacks.labelColor.call(d,e,d._chart)),C.push(h.callbacks.labelTextColor.call(d,e,d._chart))}),p.title=d.getTitle(M,g),p.beforeBody=d.getBeforeBody(M,g),p.body=d.getBody(M,g),p.afterBody=d.getAfterBody(M,g),p.footer=d.getFooter(M,g),p.x=Math.round(w.x),p.y=Math.round(w.y),p.caretPadding=h.caretPadding,p.labelColors=b,p.labelTextColors=C,p.dataPoints=M,_=function(e,t){var n=e._chart.ctx,o=2*t.yPadding,r=0,a=t.body,s=a.reduce(function(e,t){return e+t.before.length+t.lines.length+t.after.length},0);s+=t.beforeBody.length+t.afterBody.length;var l=t.title.length,u=t.footer.length,c=t.titleFontSize,d=t.bodyFontSize,h=t.footerFontSize;o+=l*c,o+=l?(l-1)*t.titleSpacing:0,o+=l?t.titleMarginBottom:0,o+=s*d,o+=s?(s-1)*t.bodySpacing:0,o+=u?t.footerMarginTop:0,o+=u*h,o+=u?(u-1)*t.footerSpacing:0;var f=0,p=function(e){r=Math.max(r,n.measureText(e).width+f)};return n.font=i.fontString(c,t._titleFontStyle,t._titleFontFamily),i.each(t.title,p),n.font=i.fontString(d,t._bodyFontStyle,t._bodyFontFamily),i.each(t.beforeBody.concat(t.afterBody),p),f=t.displayColors?d+2:0,i.each(a,function(e){i.each(e.before,p),i.each(e.lines,p),i.each(e.after,p)}),f=0,n.font=i.fontString(h,t._footerFontStyle,t._footerFontFamily),i.each(t.footer,p),{width:r+=2*t.xPadding,height:o}}(this,p),y=function(e,t,n,o){var r=e.x,i=e.y,a=e.caretSize,s=e.caretPadding,l=e.cornerRadius,u=n.xAlign,c=n.yAlign,d=a+s,h=l+s;return"right"===u?r-=t.width:"center"===u&&((r-=t.width/2)+t.width>o.width&&(r=o.width-t.width),r<0&&(r=0)),"top"===c?i+=d:i-="bottom"===c?t.height+d:t.height/2,"center"===c?"left"===u?r+=d:"right"===u&&(r-=d):"left"===u?r-=h:"right"===u&&(r+=h),{x:r,y:i}}(p,_,v=function(e,t){var n,o,r,i,a,s=e._model,l=e._chart,u=e._chart.chartArea,c="center",d="center";s.y<t.height?d="top":s.y>l.height-t.height&&(d="bottom");var h=(u.left+u.right)/2,f=(u.top+u.bottom)/2;"center"===d?(n=function(e){return e<=h},o=function(e){return e>h}):(n=function(e){return e<=t.width/2},o=function(e){return e>=l.width-t.width/2}),r=function(e){return e+t.width+s.caretSize+s.caretPadding>l.width},i=function(e){return e-t.width-s.caretSize-s.caretPadding<0},a=function(e){return e<=f?"top":"bottom"},n(s.x)?(c="left",r(s.x)&&(c="center",d=a(s.y))):o(s.x)&&(c="right",i(s.x)&&(c="center",d=a(s.y)));var p=e._options;return{xAlign:p.xAlign?p.xAlign:c,yAlign:p.yAlign?p.yAlign:d}}(this,_),d._chart)}else p.opacity=0;return p.xAlign=v.xAlign,p.yAlign=v.yAlign,p.x=y.x,p.y=y.y,p.width=_.width,p.height=_.height,p.caretX=w.x,p.caretY=w.y,d._model=p,t&&h.custom&&h.custom.call(d,p),d},drawCaret:function(e,t){var n=this._chart.ctx,o=this._view,r=this.getCaretPosition(e,t,o);n.lineTo(r.x1,r.y1),n.lineTo(r.x2,r.y2),n.lineTo(r.x3,r.y3)},getCaretPosition:function(e,t,n){var o,r,i,a,s,l,u=n.caretSize,c=n.cornerRadius,d=n.xAlign,h=n.yAlign,f=e.x,p=e.y,m=t.width,g=t.height;if("center"===h)s=p+g/2,"left"===d?(r=(o=f)-u,i=o,a=s+u,l=s-u):(r=(o=f+m)+u,i=o,a=s-u,l=s+u);else if("left"===d?(o=(r=f+c+u)-u,i=r+u):"right"===d?(o=(r=f+m-c-u)-u,i=r+u):(o=(r=n.caretX)-u,i=r+u),"top"===h)s=(a=p)-u,l=a;else{s=(a=p+g)+u,l=a;var v=i;i=o,o=v}return{x1:o,x2:r,x3:i,y1:a,y2:s,y3:l}},drawTitle:function(e,n,o,r){var a=n.title;if(a.length){o.textAlign=n._titleAlign,o.textBaseline="top";var s,l,u=n.titleFontSize,c=n.titleSpacing;for(o.fillStyle=t(n.titleFontColor,r),o.font=i.fontString(u,n._titleFontStyle,n._titleFontFamily),s=0,l=a.length;s<l;++s)o.fillText(a[s],e.x,e.y),e.y+=u+c,s+1===a.length&&(e.y+=n.titleMarginBottom-c)}},drawBody:function(e,n,o,r){var a=n.bodyFontSize,s=n.bodySpacing,l=n.body;o.textAlign=n._bodyAlign,o.textBaseline="top",o.font=i.fontString(a,n._bodyFontStyle,n._bodyFontFamily);var u=0,c=function(t){o.fillText(t,e.x+u,e.y),e.y+=a+s};o.fillStyle=t(n.bodyFontColor,r),i.each(n.beforeBody,c);var d=n.displayColors;u=d?a+2:0,i.each(l,function(s,l){var u=t(n.labelTextColors[l],r);o.fillStyle=u,i.each(s.before,c),i.each(s.lines,function(i){d&&(o.fillStyle=t(n.legendColorBackground,r),o.fillRect(e.x,e.y,a,a),o.lineWidth=1,o.strokeStyle=t(n.labelColors[l].borderColor,r),o.strokeRect(e.x,e.y,a,a),o.fillStyle=t(n.labelColors[l].backgroundColor,r),o.fillRect(e.x+1,e.y+1,a-2,a-2),o.fillStyle=u),c(i)}),i.each(s.after,c)}),u=0,i.each(n.afterBody,c),e.y-=s},drawFooter:function(e,n,o,r){var a=n.footer;a.length&&(e.y+=n.footerMarginTop,o.textAlign=n._footerAlign,o.textBaseline="top",o.fillStyle=t(n.footerFontColor,r),o.font=i.fontString(n.footerFontSize,n._footerFontStyle,n._footerFontFamily),i.each(a,function(t){o.fillText(t,e.x,e.y),e.y+=n.footerFontSize+n.footerSpacing}))},drawBackground:function(e,n,o,r,i){o.fillStyle=t(n.backgroundColor,i),o.strokeStyle=t(n.borderColor,i),o.lineWidth=n.borderWidth;var a=n.xAlign,s=n.yAlign,l=e.x,u=e.y,c=r.width,d=r.height,h=n.cornerRadius;o.beginPath(),o.moveTo(l+h,u),"top"===s&&this.drawCaret(e,r),o.lineTo(l+c-h,u),o.quadraticCurveTo(l+c,u,l+c,u+h),"center"===s&&"right"===a&&this.drawCaret(e,r),o.lineTo(l+c,u+d-h),o.quadraticCurveTo(l+c,u+d,l+c-h,u+d),"bottom"===s&&this.drawCaret(e,r),o.lineTo(l+h,u+d),o.quadraticCurveTo(l,u+d,l,u+d-h),"center"===s&&"left"===a&&this.drawCaret(e,r),o.lineTo(l,u+h),o.quadraticCurveTo(l,u,l+h,u),o.closePath(),o.fill(),n.borderWidth>0&&o.stroke()},draw:function(){var e=this._chart.ctx,t=this._view;if(0!==t.opacity){var n={width:t.width,height:t.height},o={x:t.x,y:t.y},r=Math.abs(t.opacity<.001)?0:t.opacity,i=t.title.length||t.beforeBody.length||t.body.length||t.afterBody.length||t.footer.length;this._options.enabled&&i&&(this.drawBackground(o,t,e,n,r),o.x+=t.xPadding,o.y+=t.yPadding,this.drawTitle(o,t,e,r),this.drawBody(o,t,e,r),this.drawFooter(o,t,e,r))}},handleEvent:function(e){var t,n=this,o=n._options;return n._lastActive=n._lastActive||[],"mouseout"===e.type?n._active=[]:n._active=n._chart.getElementsAtEventForMode(e,o.mode,o),(t=!i.arrayEquals(n._active,n._lastActive))&&(n._lastActive=n._active,(o.enabled||o.custom)&&(n._eventPosition={x:e.x,y:e.y},n.update(!0),n.pivot())),t}}),e.Tooltip.positioners={average:function(e){if(!e.length)return!1;var t,n,o=0,r=0,i=0;for(t=0,n=e.length;t<n;++t){var a=e[t];if(a&&a.hasValue()){var s=a.tooltipPosition();o+=s.x,r+=s.y,++i}}return{x:Math.round(o/i),y:Math.round(r/i)}},nearest:function(e,t){var n,o,r,a=t.x,s=t.y,l=Number.POSITIVE_INFINITY;for(n=0,o=e.length;n<o;++n){var u=e[n];if(u&&u.hasValue()){var c=u.getCenterPoint(),d=i.distanceBetweenPoints(t,c);d<l&&(l=d,r=u)}}if(r){var h=r.tooltipPosition();a=h.x,s=h.y}return{x:a,y:s}}}}},function(e,t,n){"use strict";var o=n(6);e.exports=function(e){var t=o.noop;e.LinearScaleBase=e.Scale.extend({getRightValue:function(t){return"string"==typeof t?+t:e.Scale.prototype.getRightValue.call(this,t)},handleTickRangeOptions:function(){var e=this,t=e.options.ticks;if(t.beginAtZero){var n=o.sign(e.min),r=o.sign(e.max);n<0&&r<0?e.max=0:n>0&&r>0&&(e.min=0)}var i=void 0!==t.min||void 0!==t.suggestedMin,a=void 0!==t.max||void 0!==t.suggestedMax;void 0!==t.min?e.min=t.min:void 0!==t.suggestedMin&&(null===e.min?e.min=t.suggestedMin:e.min=Math.min(e.min,t.suggestedMin)),void 0!==t.max?e.max=t.max:void 0!==t.suggestedMax&&(null===e.max?e.max=t.suggestedMax:e.max=Math.max(e.max,t.suggestedMax)),i!==a&&e.min>=e.max&&(i?e.max=e.min+1:e.min=e.max-1),e.min===e.max&&(e.max++,t.beginAtZero||e.min--)},getTickLimit:t,handleDirectionalChanges:t,buildTicks:function(){var e=this,t=e.options.ticks,n=e.getTickLimit(),r={maxTicks:n=Math.max(2,n),min:t.min,max:t.max,stepSize:o.valueOrDefault(t.fixedStepSize,t.stepSize)},i=e.ticks=function(e,t){var n,r=[];if(e.stepSize&&e.stepSize>0)n=e.stepSize;else{var i=o.niceNum(t.max-t.min,!1);n=o.niceNum(i/(e.maxTicks-1),!0)}var a=Math.floor(t.min/n)*n,s=Math.ceil(t.max/n)*n;e.min&&e.max&&e.stepSize&&o.almostWhole((e.max-e.min)/e.stepSize,n/1e3)&&(a=e.min,s=e.max);var l=(s-a)/n;l=o.almostEquals(l,Math.round(l),n/1e3)?Math.round(l):Math.ceil(l);var u=1;n<1&&(u=Math.pow(10,n.toString().length-2),a=Math.round(a*u)/u,s=Math.round(s*u)/u),r.push(void 0!==e.min?e.min:a);for(var c=1;c<l;++c)r.push(Math.round((a+c*n)*u)/u);return r.push(void 0!==e.max?e.max:s),r}(r,e);e.handleDirectionalChanges(),e.max=o.max(i),e.min=o.min(i),t.reverse?(i.reverse(),e.start=e.max,e.end=e.min):(e.start=e.min,e.end=e.max)},convertTicksToLabels:function(){var t=this;t.ticksAsNumbers=t.ticks.slice(),t.zeroLineIndex=t.ticks.indexOf(0),e.Scale.prototype.convertTicksToLabels.call(t)}})}},function(e,t,n){"use strict";e.exports=function(e){var t=e.Scale.extend({getLabels:function(){var e=this.chart.data;return this.options.labels||(this.isHorizontal()?e.xLabels:e.yLabels)||e.labels},determineDataLimits:function(){var e,t=this,n=t.getLabels();t.minIndex=0,t.maxIndex=n.length-1,void 0!==t.options.ticks.min&&(e=n.indexOf(t.options.ticks.min),t.minIndex=-1!==e?e:t.minIndex),void 0!==t.options.ticks.max&&(e=n.indexOf(t.options.ticks.max),t.maxIndex=-1!==e?e:t.maxIndex),t.min=n[t.minIndex],t.max=n[t.maxIndex]},buildTicks:function(){var e=this,t=e.getLabels();e.ticks=0===e.minIndex&&e.maxIndex===t.length-1?t:t.slice(e.minIndex,e.maxIndex+1)},getLabelForIndex:function(e,t){var n=this,o=n.chart.data,r=n.isHorizontal();return o.yLabels&&!r?n.getRightValue(o.datasets[t].data[e]):n.ticks[e-n.minIndex]},getPixelForValue:function(e,t){var n,o=this,r=o.options.offset,i=Math.max(o.maxIndex+1-o.minIndex-(r?0:1),1);if(null!=e&&(n=o.isHorizontal()?e.x:e.y),void 0!==n||void 0!==e&&isNaN(t)){e=n||e;var a=o.getLabels().indexOf(e);t=-1!==a?a:t}if(o.isHorizontal()){var s=o.width/i,l=s*(t-o.minIndex);return r&&(l+=s/2),o.left+Math.round(l)}var u=o.height/i,c=u*(t-o.minIndex);return r&&(c+=u/2),o.top+Math.round(c)},getPixelForTick:function(e){return this.getPixelForValue(this.ticks[e],e+this.minIndex,null)},getValueForPixel:function(e){var t=this,n=t.options.offset,o=Math.max(t._ticks.length-(n?0:1),1),r=t.isHorizontal(),i=(r?t.width:t.height)/o;return e-=r?t.left:t.top,n&&(e-=i/2),(e<=0?0:Math.round(e/i))+t.minIndex},getBasePixel:function(){return this.bottom}});e.scaleService.registerScaleType("category",t,{position:"bottom"})}},function(e,t,n){"use strict";var o=n(8),r=n(6),i=n(28);e.exports=function(e){var t={position:"left",ticks:{callback:i.formatters.linear}},n=e.LinearScaleBase.extend({determineDataLimits:function(){var e=this,t=e.options,n=e.chart,o=n.data.datasets,i=e.isHorizontal();function a(t){return i?t.xAxisID===e.id:t.yAxisID===e.id}e.min=null,e.max=null;var s=t.stacked;if(void 0===s&&r.each(o,function(e,t){if(!s){var o=n.getDatasetMeta(t);n.isDatasetVisible(t)&&a(o)&&void 0!==o.stack&&(s=!0)}}),t.stacked||s){var l={};r.each(o,function(o,i){var s=n.getDatasetMeta(i),u=[s.type,void 0===t.stacked&&void 0===s.stack?i:"",s.stack].join(".");void 0===l[u]&&(l[u]={positiveValues:[],negativeValues:[]});var c=l[u].positiveValues,d=l[u].negativeValues;n.isDatasetVisible(i)&&a(s)&&r.each(o.data,function(n,o){var r=+e.getRightValue(n);isNaN(r)||s.data[o].hidden||(c[o]=c[o]||0,d[o]=d[o]||0,t.relativePoints?c[o]=100:r<0?d[o]+=r:c[o]+=r)})}),r.each(l,function(t){var n=t.positiveValues.concat(t.negativeValues),o=r.min(n),i=r.max(n);e.min=null===e.min?o:Math.min(e.min,o),e.max=null===e.max?i:Math.max(e.max,i)})}else r.each(o,function(t,o){var i=n.getDatasetMeta(o);n.isDatasetVisible(o)&&a(i)&&r.each(t.data,function(t,n){var o=+e.getRightValue(t);isNaN(o)||i.data[n].hidden||(null===e.min?e.min=o:o<e.min&&(e.min=o),null===e.max?e.max=o:o>e.max&&(e.max=o))})});e.min=isFinite(e.min)&&!isNaN(e.min)?e.min:0,e.max=isFinite(e.max)&&!isNaN(e.max)?e.max:1,this.handleTickRangeOptions()},getTickLimit:function(){var e,t=this.options.ticks;if(this.isHorizontal())e=Math.min(t.maxTicksLimit?t.maxTicksLimit:11,Math.ceil(this.width/50));else{var n=r.valueOrDefault(t.fontSize,o.global.defaultFontSize);e=Math.min(t.maxTicksLimit?t.maxTicksLimit:11,Math.ceil(this.height/(2*n)))}return e},handleDirectionalChanges:function(){this.isHorizontal()||this.ticks.reverse()},getLabelForIndex:function(e,t){return+this.getRightValue(this.chart.data.datasets[t].data[e])},getPixelForValue:function(e){var t=this,n=t.start,o=+t.getRightValue(e),r=t.end-n;return t.isHorizontal()?t.left+t.width/r*(o-n):t.bottom-t.height/r*(o-n)},getValueForPixel:function(e){var t=this,n=t.isHorizontal(),o=n?t.width:t.height,r=(n?e-t.left:t.bottom-e)/o;return t.start+(t.end-t.start)*r},getPixelForTick:function(e){return this.getPixelForValue(this.ticksAsNumbers[e])}});e.scaleService.registerScaleType("linear",n,t)}},function(e,t,n){"use strict";var o=n(6),r=n(28);e.exports=function(e){var t={position:"left",ticks:{callback:r.formatters.logarithmic}},n=e.Scale.extend({determineDataLimits:function(){var e=this,t=e.options,n=e.chart,r=n.data.datasets,i=e.isHorizontal();function a(t){return i?t.xAxisID===e.id:t.yAxisID===e.id}e.min=null,e.max=null,e.minNotZero=null;var s=t.stacked;if(void 0===s&&o.each(r,function(e,t){if(!s){var o=n.getDatasetMeta(t);n.isDatasetVisible(t)&&a(o)&&void 0!==o.stack&&(s=!0)}}),t.stacked||s){var l={};o.each(r,function(r,i){var s=n.getDatasetMeta(i),u=[s.type,void 0===t.stacked&&void 0===s.stack?i:"",s.stack].join(".");n.isDatasetVisible(i)&&a(s)&&(void 0===l[u]&&(l[u]=[]),o.each(r.data,function(t,n){var o=l[u],r=+e.getRightValue(t);isNaN(r)||s.data[n].hidden||r<0||(o[n]=o[n]||0,o[n]+=r)}))}),o.each(l,function(t){if(t.length>0){var n=o.min(t),r=o.max(t);e.min=null===e.min?n:Math.min(e.min,n),e.max=null===e.max?r:Math.max(e.max,r)}})}else o.each(r,function(t,r){var i=n.getDatasetMeta(r);n.isDatasetVisible(r)&&a(i)&&o.each(t.data,function(t,n){var o=+e.getRightValue(t);isNaN(o)||i.data[n].hidden||o<0||(null===e.min?e.min=o:o<e.min&&(e.min=o),null===e.max?e.max=o:o>e.max&&(e.max=o),0!==o&&(null===e.minNotZero||o<e.minNotZero)&&(e.minNotZero=o))})});this.handleTickRangeOptions()},handleTickRangeOptions:function(){var e=this,t=e.options.ticks,n=o.valueOrDefault;e.min=n(t.min,e.min),e.max=n(t.max,e.max),e.min===e.max&&(0!==e.min&&null!==e.min?(e.min=Math.pow(10,Math.floor(o.log10(e.min))-1),e.max=Math.pow(10,Math.floor(o.log10(e.max))+1)):(e.min=1,e.max=10)),null===e.min&&(e.min=Math.pow(10,Math.floor(o.log10(e.max))-1)),null===e.max&&(e.max=0!==e.min?Math.pow(10,Math.floor(o.log10(e.min))+1):10),null===e.minNotZero&&(e.min>0?e.minNotZero=e.min:e.max<1?e.minNotZero=Math.pow(10,Math.floor(o.log10(e.max))):e.minNotZero=1)},buildTicks:function(){var e=this,t=e.options.ticks,n=!e.isHorizontal(),r={min:t.min,max:t.max},i=e.ticks=function(e,t){var n,r,i=[],a=o.valueOrDefault,s=a(e.min,Math.pow(10,Math.floor(o.log10(t.min)))),l=Math.floor(o.log10(t.max)),u=Math.ceil(t.max/Math.pow(10,l));0===s?(n=Math.floor(o.log10(t.minNotZero)),r=Math.floor(t.minNotZero/Math.pow(10,n)),i.push(s),s=r*Math.pow(10,n)):(n=Math.floor(o.log10(s)),r=Math.floor(s/Math.pow(10,n)));var c=n<0?Math.pow(10,Math.abs(n)):1;do{i.push(s),10===++r&&(r=1,c=++n>=0?1:c),s=Math.round(r*Math.pow(10,n)*c)/c}while(n<l||n===l&&r<u);var d=a(e.max,s);return i.push(d),i}(r,e);e.max=o.max(i),e.min=o.min(i),t.reverse?(n=!n,e.start=e.max,e.end=e.min):(e.start=e.min,e.end=e.max),n&&i.reverse()},convertTicksToLabels:function(){this.tickValues=this.ticks.slice(),e.Scale.prototype.convertTicksToLabels.call(this)},getLabelForIndex:function(e,t){return+this.getRightValue(this.chart.data.datasets[t].data[e])},getPixelForTick:function(e){return this.getPixelForValue(this.tickValues[e])},_getFirstTickValue:function(e){var t=Math.floor(o.log10(e));return Math.floor(e/Math.pow(10,t))*Math.pow(10,t)},getPixelForValue:function(t){var n,r,i,a,s,l=this,u=l.options.ticks.reverse,c=o.log10,d=l._getFirstTickValue(l.minNotZero),h=0;return t=+l.getRightValue(t),u?(i=l.end,a=l.start,s=-1):(i=l.start,a=l.end,s=1),l.isHorizontal()?(n=l.width,r=u?l.right:l.left):(n=l.height,s*=-1,r=u?l.top:l.bottom),t!==i&&(0===i&&(n-=h=o.getValueOrDefault(l.options.ticks.fontSize,e.defaults.global.defaultFontSize),i=d),0!==t&&(h+=n/(c(a)-c(i))*(c(t)-c(i))),r+=s*h),r},getValueForPixel:function(t){var n,r,i,a,s=this,l=s.options.ticks.reverse,u=o.log10,c=s._getFirstTickValue(s.minNotZero);if(l?(r=s.end,i=s.start):(r=s.start,i=s.end),s.isHorizontal()?(n=s.width,a=l?s.right-t:t-s.left):(n=s.height,a=l?t-s.top:s.bottom-t),a!==r){if(0===r){var d=o.getValueOrDefault(s.options.ticks.fontSize,e.defaults.global.defaultFontSize);a-=d,n-=d,r=c}a*=u(i)-u(r),a/=n,a=Math.pow(10,u(r)+a)}return a}});e.scaleService.registerScaleType("logarithmic",n,t)}},function(e,t,n){"use strict";var o=n(8),r=n(6),i=n(28);e.exports=function(e){var t=o.global,n={display:!0,animate:!0,position:"chartArea",angleLines:{display:!0,color:"rgba(0, 0, 0, 0.1)",lineWidth:1},gridLines:{circular:!1},ticks:{showLabelBackdrop:!0,backdropColor:"rgba(255,255,255,0.75)",backdropPaddingY:2,backdropPaddingX:2,callback:i.formatters.linear},pointLabels:{display:!0,fontSize:10,callback:function(e){return e}}};function a(e){var t=e.options;return t.angleLines.display||t.pointLabels.display?e.chart.data.labels.length:0}function s(e){var n=e.options.pointLabels,o=r.valueOrDefault(n.fontSize,t.defaultFontSize),i=r.valueOrDefault(n.fontStyle,t.defaultFontStyle),a=r.valueOrDefault(n.fontFamily,t.defaultFontFamily);return{size:o,style:i,family:a,font:r.fontString(o,i,a)}}function l(e,t,n,o,r){return e===o||e===r?{start:t-n/2,end:t+n/2}:e<o||e>r?{start:t-n-5,end:t}:{start:t,end:t+n+5}}function u(e){return 0===e||180===e?"center":e<180?"left":"right"}function c(e,t,n,o){if(r.isArray(t))for(var i=n.y,a=1.5*o,s=0;s<t.length;++s)e.fillText(t[s],n.x,i),i+=a;else e.fillText(t,n.x,n.y)}function d(e,t,n){90===e||270===e?n.y-=t.h/2:(e>270||e<90)&&(n.y-=t.h)}function h(e){return r.isNumber(e)?e:0}var f=e.LinearScaleBase.extend({setDimensions:function(){var e=this,n=e.options,o=n.ticks;e.width=e.maxWidth,e.height=e.maxHeight,e.xCenter=Math.round(e.width/2),e.yCenter=Math.round(e.height/2);var i=r.min([e.height,e.width]),a=r.valueOrDefault(o.fontSize,t.defaultFontSize);e.drawingArea=n.display?i/2-(a/2+o.backdropPaddingY):i/2},determineDataLimits:function(){var e=this,t=e.chart,n=Number.POSITIVE_INFINITY,o=Number.NEGATIVE_INFINITY;r.each(t.data.datasets,function(i,a){if(t.isDatasetVisible(a)){var s=t.getDatasetMeta(a);r.each(i.data,function(t,r){var i=+e.getRightValue(t);isNaN(i)||s.data[r].hidden||(n=Math.min(i,n),o=Math.max(i,o))})}}),e.min=n===Number.POSITIVE_INFINITY?0:n,e.max=o===Number.NEGATIVE_INFINITY?0:o,e.handleTickRangeOptions()},getTickLimit:function(){var e=this.options.ticks,n=r.valueOrDefault(e.fontSize,t.defaultFontSize);return Math.min(e.maxTicksLimit?e.maxTicksLimit:11,Math.ceil(this.drawingArea/(1.5*n)))},convertTicksToLabels:function(){var t=this;e.LinearScaleBase.prototype.convertTicksToLabels.call(t),t.pointLabels=t.chart.data.labels.map(t.options.pointLabels.callback,t)},getLabelForIndex:function(e,t){return+this.getRightValue(this.chart.data.datasets[t].data[e])},fit:function(){var e,t;this.options.pointLabels.display?function(e){var t,n,o,i=s(e),u=Math.min(e.height/2,e.width/2),c={r:e.width,l:0,t:e.height,b:0},d={};e.ctx.font=i.font,e._pointLabelSizes=[];var h,f,p,m=a(e);for(t=0;t<m;t++){o=e.getPointPosition(t,u),h=e.ctx,f=i.size,p=e.pointLabels[t]||"",n=r.isArray(p)?{w:r.longestText(h,h.font,p),h:p.length*f+1.5*(p.length-1)*f}:{w:h.measureText(p).width,h:f},e._pointLabelSizes[t]=n;var g=e.getIndexAngle(t),v=r.toDegrees(g)%360,y=l(v,o.x,n.w,0,180),_=l(v,o.y,n.h,90,270);y.start<c.l&&(c.l=y.start,d.l=g),y.end>c.r&&(c.r=y.end,d.r=g),_.start<c.t&&(c.t=_.start,d.t=g),_.end>c.b&&(c.b=_.end,d.b=g)}e.setReductions(u,c,d)}(this):(e=this,t=Math.min(e.height/2,e.width/2),e.drawingArea=Math.round(t),e.setCenterPoint(0,0,0,0))},setReductions:function(e,t,n){var o=t.l/Math.sin(n.l),r=Math.max(t.r-this.width,0)/Math.sin(n.r),i=-t.t/Math.cos(n.t),a=-Math.max(t.b-this.height,0)/Math.cos(n.b);o=h(o),r=h(r),i=h(i),a=h(a),this.drawingArea=Math.min(Math.round(e-(o+r)/2),Math.round(e-(i+a)/2)),this.setCenterPoint(o,r,i,a)},setCenterPoint:function(e,t,n,o){var r=this,i=r.width-t-r.drawingArea,a=e+r.drawingArea,s=n+r.drawingArea,l=r.height-o-r.drawingArea;r.xCenter=Math.round((a+i)/2+r.left),r.yCenter=Math.round((s+l)/2+r.top)},getIndexAngle:function(e){return e*(2*Math.PI/a(this))+(this.chart.options&&this.chart.options.startAngle?this.chart.options.startAngle:0)*Math.PI*2/360},getDistanceFromCenterForValue:function(e){var t=this;if(null===e)return 0;var n=t.drawingArea/(t.max-t.min);return t.options.ticks.reverse?(t.max-e)*n:(e-t.min)*n},getPointPosition:function(e,t){var n=this.getIndexAngle(e)-Math.PI/2;return{x:Math.round(Math.cos(n)*t)+this.xCenter,y:Math.round(Math.sin(n)*t)+this.yCenter}},getPointPositionForValue:function(e,t){return this.getPointPosition(e,this.getDistanceFromCenterForValue(t))},getBasePosition:function(){var e=this.min,t=this.max;return this.getPointPositionForValue(0,this.beginAtZero?0:e<0&&t<0?t:e>0&&t>0?e:0)},draw:function(){var e=this,n=e.options,o=n.gridLines,i=n.ticks,l=r.valueOrDefault;if(n.display){var h=e.ctx,f=this.getIndexAngle(0),p=l(i.fontSize,t.defaultFontSize),m=l(i.fontStyle,t.defaultFontStyle),g=l(i.fontFamily,t.defaultFontFamily),v=r.fontString(p,m,g);r.each(e.ticks,function(n,s){if(s>0||i.reverse){var u=e.getDistanceFromCenterForValue(e.ticksAsNumbers[s]);if(o.display&&0!==s&&function(e,t,n,o){var i=e.ctx;if(i.strokeStyle=r.valueAtIndexOrDefault(t.color,o-1),i.lineWidth=r.valueAtIndexOrDefault(t.lineWidth,o-1),e.options.gridLines.circular)i.beginPath(),i.arc(e.xCenter,e.yCenter,n,0,2*Math.PI),i.closePath(),i.stroke();else{var s=a(e);if(0===s)return;i.beginPath();var l=e.getPointPosition(0,n);i.moveTo(l.x,l.y);for(var u=1;u<s;u++)l=e.getPointPosition(u,n),i.lineTo(l.x,l.y);i.closePath(),i.stroke()}}(e,o,u,s),i.display){var c=l(i.fontColor,t.defaultFontColor);if(h.font=v,h.save(),h.translate(e.xCenter,e.yCenter),h.rotate(f),i.showLabelBackdrop){var d=h.measureText(n).width;h.fillStyle=i.backdropColor,h.fillRect(-d/2-i.backdropPaddingX,-u-p/2-i.backdropPaddingY,d+2*i.backdropPaddingX,p+2*i.backdropPaddingY)}h.textAlign="center",h.textBaseline="middle",h.fillStyle=c,h.fillText(n,0,-u),h.restore()}}}),(n.angleLines.display||n.pointLabels.display)&&function(e){var n=e.ctx,o=e.options,i=o.angleLines,l=o.pointLabels;n.lineWidth=i.lineWidth,n.strokeStyle=i.color;var h=e.getDistanceFromCenterForValue(o.ticks.reverse?e.min:e.max),f=s(e);n.textBaseline="top";for(var p=a(e)-1;p>=0;p--){if(i.display){var m=e.getPointPosition(p,h);n.beginPath(),n.moveTo(e.xCenter,e.yCenter),n.lineTo(m.x,m.y),n.stroke(),n.closePath()}if(l.display){var g=e.getPointPosition(p,h+5),v=r.valueAtIndexOrDefault(l.fontColor,p,t.defaultFontColor);n.font=f.font,n.fillStyle=v;var y=e.getIndexAngle(p),_=r.toDegrees(y);n.textAlign=u(_),d(_,e._pointLabelSizes[p],g),c(n,e.pointLabels[p]||"",g,f.size)}}}(e)}}});e.scaleService.registerScaleType("radialLinear",f,n)}},function(e,t,n){"use strict";var o=n(2);o="function"==typeof o?o:window.moment;var r=n(8),i=n(6),a=Number.MIN_SAFE_INTEGER||-9007199254740991,s=Number.MAX_SAFE_INTEGER||9007199254740991,l={millisecond:{common:!0,size:1,steps:[1,2,5,10,20,50,100,250,500]},second:{common:!0,size:1e3,steps:[1,2,5,10,30]},minute:{common:!0,size:6e4,steps:[1,2,5,10,30]},hour:{common:!0,size:36e5,steps:[1,2,3,6,12]},day:{common:!0,size:864e5,steps:[1,2,5]},week:{common:!1,size:6048e5,steps:[1,2,3,4]},month:{common:!0,size:2628e6,steps:[1,2,3]},quarter:{common:!1,size:7884e6,steps:[1,2,3,4]},year:{common:!0,size:3154e7}},u=Object.keys(l);function c(e,t){return e-t}function d(e){var t,n,o,r={},i=[];for(t=0,n=e.length;t<n;++t)r[o=e[t]]||(r[o]=!0,i.push(o));return i}function h(e,t,n,o){var r=function(e,t,n){for(var o,r,i,a=0,s=e.length-1;a>=0&&a<=s;){if(r=e[(o=a+s>>1)-1]||null,i=e[o],!r)return{lo:null,hi:i};if(i[t]<n)a=o+1;else{if(!(r[t]>n))return{lo:r,hi:i};s=o-1}}return{lo:i,hi:null}}(e,t,n),i=r.lo?r.hi?r.lo:e[e.length-2]:e[0],a=r.lo?r.hi?r.hi:e[e.length-1]:e[1],s=a[t]-i[t],l=s?(n-i[t])/s:0,u=(a[o]-i[o])*l;return i[o]+u}function f(e,t){var n=t.parser,r=t.parser||t.format;return"function"==typeof n?n(e):"string"==typeof e&&"string"==typeof r?o(e,r):(e instanceof o||(e=o(e)),e.isValid()?e:"function"==typeof r?r(e):e)}function p(e,t){if(i.isNullOrUndef(e))return null;var n=t.options.time,o=f(t.getRightValue(e),n);return o.isValid()?(n.round&&o.startOf(n.round),o.valueOf()):null}function m(e){for(var t=u.indexOf(e)+1,n=u.length;t<n;++t)if(l[u[t]].common)return u[t]}function g(e,t,n,r){var a,c=r.time,d=c.unit||function(e,t,n,o){var r,i,a,c=u.length;for(r=u.indexOf(e);r<c-1;++r)if(a=(i=l[u[r]]).steps?i.steps[i.steps.length-1]:s,i.common&&Math.ceil((n-t)/(a*i.size))<=o)return u[r];return u[c-1]}(c.minUnit,e,t,n),h=m(d),f=i.valueOrDefault(c.stepSize,c.unitStepSize),p="week"===d&&c.isoWeekday,g=r.ticks.major.enabled,v=l[d],y=o(e),_=o(t),w=[];for(f||(f=function(e,t,n,o){var r,i,a,s=t-e,u=l[n],c=u.size,d=u.steps;if(!d)return Math.ceil(s/(o*c));for(r=0,i=d.length;r<i&&(a=d[r],!(Math.ceil(s/(c*a))<=o));++r);return a}(e,t,d,n)),p&&(y=y.isoWeekday(p),_=_.isoWeekday(p)),y=y.startOf(p?"day":d),(_=_.startOf(p?"day":d))<t&&_.add(1,d),a=o(y),g&&h&&!p&&!c.round&&(a.startOf(h),a.add(~~((y-a)/(v.size*f))*f,d));a<_;a.add(f,d))w.push(+a);return w.push(+a),w}e.exports=function(e){var t=e.Scale.extend({initialize:function(){if(!o)throw new Error("Chart.js - Moment.js could not be found! You must include it before Chart.js to use the time scale. Download at https://momentjs.com");this.mergeTicksOptions(),e.Scale.prototype.initialize.call(this)},update:function(){var t=this,n=t.options;return n.time&&n.time.format&&console.warn("options.time.format is deprecated and replaced by options.time.parser."),e.Scale.prototype.update.apply(t,arguments)},getRightValue:function(t){return t&&void 0!==t.t&&(t=t.t),e.Scale.prototype.getRightValue.call(this,t)},determineDataLimits:function(){var e,t,n,r,l,u,h=this,f=h.chart,m=h.options.time,g=m.unit||"day",v=s,y=a,_=[],w=[],b=[];for(e=0,n=f.data.labels.length;e<n;++e)b.push(p(f.data.labels[e],h));for(e=0,n=(f.data.datasets||[]).length;e<n;++e)if(f.isDatasetVisible(e))if(l=f.data.datasets[e].data,i.isObject(l[0]))for(w[e]=[],t=0,r=l.length;t<r;++t)u=p(l[t],h),_.push(u),w[e][t]=u;else _.push.apply(_,b),w[e]=b.slice(0);else w[e]=[];b.length&&(b=d(b).sort(c),v=Math.min(v,b[0]),y=Math.max(y,b[b.length-1])),_.length&&(_=d(_).sort(c),v=Math.min(v,_[0]),y=Math.max(y,_[_.length-1])),v=p(m.min,h)||v,y=p(m.max,h)||y,v=v===s?+o().startOf(g):v,y=y===a?+o().endOf(g)+1:y,h.min=Math.min(v,y),h.max=Math.max(v+1,y),h._horizontal=h.isHorizontal(),h._table=[],h._timestamps={data:_,datasets:w,labels:b}},buildTicks:function(){var e,t,n,r=this,i=r.min,a=r.max,s=r.options,c=s.time,d=[],v=[];switch(s.ticks.source){case"data":d=r._timestamps.data;break;case"labels":d=r._timestamps.labels;break;case"auto":default:d=g(i,a,r.getLabelCapacity(i),s)}for("ticks"===s.bounds&&d.length&&(i=d[0],a=d[d.length-1]),i=p(c.min,r)||i,a=p(c.max,r)||a,e=0,t=d.length;e<t;++e)(n=d[e])>=i&&n<=a&&v.push(n);return r.min=i,r.max=a,r._unit=c.unit||function(e,t,n,r){var i,a,s=o.duration(o(r).diff(o(n)));for(i=u.length-1;i>=u.indexOf(t);i--)if(a=u[i],l[a].common&&s.as(a)>=e.length)return a;return u[t?u.indexOf(t):0]}(v,c.minUnit,r.min,r.max),r._majorUnit=m(r._unit),r._table=function(e,t,n,o){if("linear"===o||!e.length)return[{time:t,pos:0},{time:n,pos:1}];var r,i,a,s,l,u=[],c=[t];for(r=0,i=e.length;r<i;++r)(s=e[r])>t&&s<n&&c.push(s);for(c.push(n),r=0,i=c.length;r<i;++r)l=c[r+1],a=c[r-1],s=c[r],void 0!==a&&void 0!==l&&Math.round((l+a)/2)===s||u.push({time:s,pos:r/(i-1)});return u}(r._timestamps.data,i,a,s.distribution),r._offsets=function(e,t,n,o,r){var i,a,s=0,l=0;return r.offset&&t.length&&(r.time.min||(i=t.length>1?t[1]:o,a=t[0],s=(h(e,"time",i,"pos")-h(e,"time",a,"pos"))/2),r.time.max||(i=t[t.length-1],a=t.length>1?t[t.length-2]:n,l=(h(e,"time",i,"pos")-h(e,"time",a,"pos"))/2)),{left:s,right:l}}(r._table,v,i,a,s),r._labelFormat=function(e,t){var n,o,r,i=e.length;for(n=0;n<i;n++){if(0!==(o=f(e[n],t)).millisecond())return"MMM D, YYYY h:mm:ss.SSS a";0===o.second()&&0===o.minute()&&0===o.hour()||(r=!0)}return r?"MMM D, YYYY h:mm:ss a":"MMM D, YYYY"}(r._timestamps.data,c),function(e,t){var n,r,i,a,s=[];for(n=0,r=e.length;n<r;++n)i=e[n],a=!!t&&i===+o(i).startOf(t),s.push({value:i,major:a});return s}(v,r._majorUnit)},getLabelForIndex:function(e,t){var n=this.chart.data,o=this.options.time,r=n.labels&&e<n.labels.length?n.labels[e]:"",a=n.datasets[t].data[e];return i.isObject(a)&&(r=this.getRightValue(a)),o.tooltipFormat?f(r,o).format(o.tooltipFormat):"string"==typeof r?r:f(r,o).format(this._labelFormat)},tickFormatFunction:function(e,t,n,o){var r=this.options,a=e.valueOf(),s=r.time.displayFormats,l=s[this._unit],u=this._majorUnit,c=s[u],d=e.clone().startOf(u).valueOf(),h=r.ticks.major,f=h.enabled&&u&&c&&a===d,p=e.format(o||(f?c:l)),m=f?h:r.ticks.minor,g=i.valueOrDefault(m.callback,m.userCallback);return g?g(p,t,n):p},convertTicksToLabels:function(e){var t,n,r=[];for(t=0,n=e.length;t<n;++t)r.push(this.tickFormatFunction(o(e[t].value),t,e));return r},getPixelForOffset:function(e){var t=this,n=t._horizontal?t.width:t.height,o=t._horizontal?t.left:t.top,r=h(t._table,"time",e,"pos");return o+n*(t._offsets.left+r)/(t._offsets.left+1+t._offsets.right)},getPixelForValue:function(e,t,n){var o=null;if(void 0!==t&&void 0!==n&&(o=this._timestamps.datasets[n][t]),null===o&&(o=p(e,this)),null!==o)return this.getPixelForOffset(o)},getPixelForTick:function(e){var t=this.getTicks();return e>=0&&e<t.length?this.getPixelForOffset(t[e].value):null},getValueForPixel:function(e){var t=this,n=t._horizontal?t.width:t.height,r=t._horizontal?t.left:t.top,i=(n?(e-r)/n:0)*(t._offsets.left+1+t._offsets.left)-t._offsets.right,a=h(t._table,"pos",i,"time");return o(a)},getLabelWidth:function(e){var t=this.options.ticks,n=this.ctx.measureText(e).width,o=i.toRadians(t.maxRotation),a=Math.cos(o),s=Math.sin(o);return n*a+i.valueOrDefault(t.fontSize,r.global.defaultFontSize)*s},getLabelCapacity:function(e){var t=this,n=t.options.time.displayFormats.millisecond,r=t.tickFormatFunction(o(e),0,[],n),i=t.getLabelWidth(r),a=t.isHorizontal()?t.width:t.height,s=Math.floor(a/i);return s>0?s:1}});e.scaleService.registerScaleType("time",t,{position:"bottom",distribution:"linear",bounds:"data",time:{parser:!1,format:!1,unit:!1,round:!1,displayFormat:!1,isoWeekday:!1,minUnit:"millisecond",displayFormats:{millisecond:"h:mm:ss.SSS a",second:"h:mm:ss a",minute:"h:mm a",hour:"hA",day:"MMM D",week:"ll",month:"MMM YYYY",quarter:"[Q]Q - YYYY",year:"YYYY"}},ticks:{autoSkip:!1,source:"auto",major:{enabled:!1}}})}},,function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("bar",{hover:{mode:"label"},scales:{xAxes:[{type:"category",categoryPercentage:.8,barPercentage:.9,offset:!0,gridLines:{offsetGridLines:!0}}],yAxes:[{type:"linear"}]}}),o._set("horizontalBar",{hover:{mode:"index",axis:"y"},scales:{xAxes:[{type:"linear",position:"bottom"}],yAxes:[{position:"left",type:"category",categoryPercentage:.8,barPercentage:.9,offset:!0,gridLines:{offsetGridLines:!0}}]},elements:{rectangle:{borderSkipped:"left"}},tooltips:{callbacks:{title:function(e,t){var n="";return e.length>0&&(e[0].yLabel?n=e[0].yLabel:t.labels.length>0&&e[0].index<t.labels.length&&(n=t.labels[e[0].index])),n},label:function(e,t){return(t.datasets[e.datasetIndex].label||"")+": "+e.xLabel}},mode:"index",axis:"y"}}),e.exports=function(e){e.controllers.bar=e.DatasetController.extend({dataElementType:r.Rectangle,initialize:function(){var t,n=this;e.DatasetController.prototype.initialize.apply(n,arguments),(t=n.getMeta()).stack=n.getDataset().stack,t.bar=!0},update:function(e){var t,n,o=this.getMeta().data;for(this._ruler=this.getRuler(),t=0,n=o.length;t<n;++t)this.updateElement(o[t],t,e)},updateElement:function(e,t,n){var o=this,r=o.chart,a=o.getMeta(),s=o.getDataset(),l=e.custom||{},u=r.options.elements.rectangle;e._xScale=o.getScaleForId(a.xAxisID),e._yScale=o.getScaleForId(a.yAxisID),e._datasetIndex=o.index,e._index=t,e._model={datasetLabel:s.label,label:r.data.labels[t],borderSkipped:l.borderSkipped?l.borderSkipped:u.borderSkipped,backgroundColor:l.backgroundColor?l.backgroundColor:i.valueAtIndexOrDefault(s.backgroundColor,t,u.backgroundColor),borderColor:l.borderColor?l.borderColor:i.valueAtIndexOrDefault(s.borderColor,t,u.borderColor),borderWidth:l.borderWidth?l.borderWidth:i.valueAtIndexOrDefault(s.borderWidth,t,u.borderWidth)},o.updateElementGeometry(e,t,n),e.pivot()},updateElementGeometry:function(e,t,n){var o=this,r=e._model,i=o.getValueScale(),a=i.getBasePixel(),s=i.isHorizontal(),l=o._ruler||o.getRuler(),u=o.calculateBarValuePixels(o.index,t),c=o.calculateBarIndexPixels(o.index,t,l);r.horizontal=s,r.base=n?a:u.base,r.x=s?n?a:u.head:c.center,r.y=s?c.center:n?a:u.head,r.height=s?c.size:void 0,r.width=s?void 0:c.size},getValueScaleId:function(){return this.getMeta().yAxisID},getIndexScaleId:function(){return this.getMeta().xAxisID},getValueScale:function(){return this.getScaleForId(this.getValueScaleId())},getIndexScale:function(){return this.getScaleForId(this.getIndexScaleId())},_getStacks:function(e){var t,n,o=this.chart,r=this.getIndexScale().options.stacked,i=void 0===e?o.data.datasets.length:e+1,a=[];for(t=0;t<i;++t)(n=o.getDatasetMeta(t)).bar&&o.isDatasetVisible(t)&&(!1===r||!0===r&&-1===a.indexOf(n.stack)||void 0===r&&(void 0===n.stack||-1===a.indexOf(n.stack)))&&a.push(n.stack);return a},getStackCount:function(){return this._getStacks().length},getStackIndex:function(e,t){var n=this._getStacks(e),o=void 0!==t?n.indexOf(t):-1;return-1===o?n.length-1:o},getRuler:function(){var e,t,n=this.getIndexScale(),o=this.getStackCount(),r=this.index,a=n.isHorizontal(),s=a?n.left:n.top,l=s+(a?n.width:n.height),u=[];for(e=0,t=this.getMeta().data.length;e<t;++e)u.push(n.getPixelForValue(null,e,r));return{min:i.isNullOrUndef(n.options.barThickness)?function(e,t){var n,o,r,i,a=e.isHorizontal()?e.width:e.height,s=e.getTicks();for(r=1,i=t.length;r<i;++r)a=Math.min(a,t[r]-t[r-1]);for(r=0,i=s.length;r<i;++r)o=e.getPixelForTick(r),a=r>0?Math.min(a,o-n):a,n=o;return a}(n,u):-1,pixels:u,start:s,end:l,stackCount:o,scale:n}},calculateBarValuePixels:function(e,t){var n,o,r,i,a,s,l=this.chart,u=this.getMeta(),c=this.getValueScale(),d=l.data.datasets,h=c.getRightValue(d[e].data[t]),f=c.options.stacked,p=u.stack,m=0;if(f||void 0===f&&void 0!==p)for(n=0;n<e;++n)(o=l.getDatasetMeta(n)).bar&&o.stack===p&&o.controller.getValueScaleId()===c.id&&l.isDatasetVisible(n)&&(r=c.getRightValue(d[n].data[t]),(h<0&&r<0||h>=0&&r>0)&&(m+=r));return i=c.getPixelForValue(m),{size:s=((a=c.getPixelForValue(m+h))-i)/2,base:i,head:a,center:a+s/2}},calculateBarIndexPixels:function(e,t,n){var o=n.scale.options,r="flex"===o.barThickness?function(e,t,n){var o,r=t.pixels,i=r[e],a=e>0?r[e-1]:null,s=e<r.length-1?r[e+1]:null,l=n.categoryPercentage;return null===a&&(a=i-(null===s?t.end-i:s-i)),null===s&&(s=i+i-a),o=i-(i-a)/2*l,{chunk:(s-a)/2*l/t.stackCount,ratio:n.barPercentage,start:o}}(t,n,o):function(e,t,n){var o,r,a=n.barThickness,s=t.stackCount,l=t.pixels[e];return i.isNullOrUndef(a)?(o=t.min*n.categoryPercentage,r=n.barPercentage):(o=a*s,r=1),{chunk:o/s,ratio:r,start:l-o/2}}(t,n,o),a=this.getStackIndex(e,this.getMeta().stack),s=r.start+r.chunk*a+r.chunk/2,l=Math.min(i.valueOrDefault(o.maxBarThickness,1/0),r.chunk*r.ratio);return{base:s-l/2,head:s+l/2,center:s,size:l}},draw:function(){var e=this.chart,t=this.getValueScale(),n=this.getMeta().data,o=this.getDataset(),r=n.length,a=0;for(i.canvas.clipArea(e.ctx,e.chartArea);a<r;++a)isNaN(t.getRightValue(o.data[a]))||n[a].draw();i.canvas.unclipArea(e.ctx)},setHoverStyle:function(e){var t=this.chart.data.datasets[e._datasetIndex],n=e._index,o=e.custom||{},r=e._model;r.backgroundColor=o.hoverBackgroundColor?o.hoverBackgroundColor:i.valueAtIndexOrDefault(t.hoverBackgroundColor,n,i.getHoverColor(r.backgroundColor)),r.borderColor=o.hoverBorderColor?o.hoverBorderColor:i.valueAtIndexOrDefault(t.hoverBorderColor,n,i.getHoverColor(r.borderColor)),r.borderWidth=o.hoverBorderWidth?o.hoverBorderWidth:i.valueAtIndexOrDefault(t.hoverBorderWidth,n,r.borderWidth)},removeHoverStyle:function(e){var t=this.chart.data.datasets[e._datasetIndex],n=e._index,o=e.custom||{},r=e._model,a=this.chart.options.elements.rectangle;r.backgroundColor=o.backgroundColor?o.backgroundColor:i.valueAtIndexOrDefault(t.backgroundColor,n,a.backgroundColor),r.borderColor=o.borderColor?o.borderColor:i.valueAtIndexOrDefault(t.borderColor,n,a.borderColor),r.borderWidth=o.borderWidth?o.borderWidth:i.valueAtIndexOrDefault(t.borderWidth,n,a.borderWidth)}}),e.controllers.horizontalBar=e.controllers.bar.extend({getValueScaleId:function(){return this.getMeta().xAxisID},getIndexScaleId:function(){return this.getMeta().yAxisID}})}},function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("bubble",{hover:{mode:"single"},scales:{xAxes:[{type:"linear",position:"bottom",id:"x-axis-0"}],yAxes:[{type:"linear",position:"left",id:"y-axis-0"}]},tooltips:{callbacks:{title:function(){return""},label:function(e,t){var n=t.datasets[e.datasetIndex].label||"",o=t.datasets[e.datasetIndex].data[e.index];return n+": ("+e.xLabel+", "+e.yLabel+", "+o.r+")"}}}}),e.exports=function(e){e.controllers.bubble=e.DatasetController.extend({dataElementType:r.Point,update:function(e){var t=this,n=t.getMeta().data;i.each(n,function(n,o){t.updateElement(n,o,e)})},updateElement:function(e,t,n){var o=this,r=o.getMeta(),i=e.custom||{},a=o.getScaleForId(r.xAxisID),s=o.getScaleForId(r.yAxisID),l=o._resolveElementOptions(e,t),u=o.getDataset().data[t],c=o.index,d=n?a.getPixelForDecimal(.5):a.getPixelForValue("object"==typeof u?u:NaN,t,c),h=n?s.getBasePixel():s.getPixelForValue(u,t,c);e._xScale=a,e._yScale=s,e._options=l,e._datasetIndex=c,e._index=t,e._model={backgroundColor:l.backgroundColor,borderColor:l.borderColor,borderWidth:l.borderWidth,hitRadius:l.hitRadius,pointStyle:l.pointStyle,radius:n?0:l.radius,skip:i.skip||isNaN(d)||isNaN(h),x:d,y:h},e.pivot()},setHoverStyle:function(e){var t=e._model,n=e._options;t.backgroundColor=i.valueOrDefault(n.hoverBackgroundColor,i.getHoverColor(n.backgroundColor)),t.borderColor=i.valueOrDefault(n.hoverBorderColor,i.getHoverColor(n.borderColor)),t.borderWidth=i.valueOrDefault(n.hoverBorderWidth,n.borderWidth),t.radius=n.radius+n.hoverRadius},removeHoverStyle:function(e){var t=e._model,n=e._options;t.backgroundColor=n.backgroundColor,t.borderColor=n.borderColor,t.borderWidth=n.borderWidth,t.radius=n.radius},_resolveElementOptions:function(e,t){var n,o,r,a=this.chart,s=a.data.datasets[this.index],l=e.custom||{},u=a.options.elements.point,c=i.options.resolve,d=s.data[t],h={},f={chart:a,dataIndex:t,dataset:s,datasetIndex:this.index},p=["backgroundColor","borderColor","borderWidth","hoverBackgroundColor","hoverBorderColor","hoverBorderWidth","hoverRadius","hitRadius","pointStyle"];for(n=0,o=p.length;n<o;++n)h[r=p[n]]=c([l[r],s[r],u[r]],f,t);return h.radius=c([l.radius,d?d.r:void 0,s.radius,u.radius],f,t),h}})}},function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("doughnut",{animation:{animateRotate:!0,animateScale:!1},hover:{mode:"single"},legendCallback:function(e){var t=[];t.push('<ul class="'+e.id+'-legend">');var n=e.data,o=n.datasets,r=n.labels;if(o.length)for(var i=0;i<o[0].data.length;++i)t.push('<li><span style="background-color:'+o[0].backgroundColor[i]+'"></span>'),r[i]&&t.push(r[i]),t.push("</li>");return t.push("</ul>"),t.join("")},legend:{labels:{generateLabels:function(e){var t=e.data;return t.labels.length&&t.datasets.length?t.labels.map(function(n,o){var r=e.getDatasetMeta(0),a=t.datasets[0],s=r.data[o],l=s&&s.custom||{},u=i.valueAtIndexOrDefault,c=e.options.elements.arc;return{text:n,fillStyle:l.backgroundColor?l.backgroundColor:u(a.backgroundColor,o,c.backgroundColor),strokeStyle:l.borderColor?l.borderColor:u(a.borderColor,o,c.borderColor),lineWidth:l.borderWidth?l.borderWidth:u(a.borderWidth,o,c.borderWidth),hidden:isNaN(a.data[o])||r.data[o].hidden,index:o}}):[]}},onClick:function(e,t){var n,o,r,i=t.index,a=this.chart;for(n=0,o=(a.data.datasets||[]).length;n<o;++n)(r=a.getDatasetMeta(n)).data[i]&&(r.data[i].hidden=!r.data[i].hidden);a.update()}},cutoutPercentage:50,rotation:-.5*Math.PI,circumference:2*Math.PI,tooltips:{callbacks:{title:function(){return""},label:function(e,t){var n=t.labels[e.index],o=": "+t.datasets[e.datasetIndex].data[e.index];return i.isArray(n)?(n=n.slice())[0]+=o:n+=o,n}}}}),o._set("pie",i.clone(o.doughnut)),o._set("pie",{cutoutPercentage:0}),e.exports=function(e){e.controllers.doughnut=e.controllers.pie=e.DatasetController.extend({dataElementType:r.Arc,linkScales:i.noop,getRingIndex:function(e){for(var t=0,n=0;n<e;++n)this.chart.isDatasetVisible(n)&&++t;return t},update:function(e){var t=this,n=t.chart,o=n.chartArea,r=n.options,a=r.elements.arc,s=o.right-o.left-a.borderWidth,l=o.bottom-o.top-a.borderWidth,u=Math.min(s,l),c={x:0,y:0},d=t.getMeta(),h=r.cutoutPercentage,f=r.circumference;if(f<2*Math.PI){var p=r.rotation%(2*Math.PI),m=(p+=2*Math.PI*(p>=Math.PI?-1:p<-Math.PI?1:0))+f,g={x:Math.cos(p),y:Math.sin(p)},v={x:Math.cos(m),y:Math.sin(m)},y=p<=0&&m>=0||p<=2*Math.PI&&2*Math.PI<=m,_=p<=.5*Math.PI&&.5*Math.PI<=m||p<=2.5*Math.PI&&2.5*Math.PI<=m,w=p<=-Math.PI&&-Math.PI<=m||p<=Math.PI&&Math.PI<=m,b=p<=.5*-Math.PI&&.5*-Math.PI<=m||p<=1.5*Math.PI&&1.5*Math.PI<=m,C=h/100,M={x:w?-1:Math.min(g.x*(g.x<0?1:C),v.x*(v.x<0?1:C)),y:b?-1:Math.min(g.y*(g.y<0?1:C),v.y*(v.y<0?1:C))},k={x:y?1:Math.max(g.x*(g.x>0?1:C),v.x*(v.x>0?1:C)),y:_?1:Math.max(g.y*(g.y>0?1:C),v.y*(v.y>0?1:C))},S={width:.5*(k.x-M.x),height:.5*(k.y-M.y)};u=Math.min(s/S.width,l/S.height),c={x:-.5*(k.x+M.x),y:-.5*(k.y+M.y)}}n.borderWidth=t.getMaxBorderWidth(d.data),n.outerRadius=Math.max((u-n.borderWidth)/2,0),n.innerRadius=Math.max(h?n.outerRadius/100*h:0,0),n.radiusLength=(n.outerRadius-n.innerRadius)/n.getVisibleDatasetCount(),n.offsetX=c.x*n.outerRadius,n.offsetY=c.y*n.outerRadius,d.total=t.calculateTotal(),t.outerRadius=n.outerRadius-n.radiusLength*t.getRingIndex(t.index),t.innerRadius=Math.max(t.outerRadius-n.radiusLength,0),i.each(d.data,function(n,o){t.updateElement(n,o,e)})},updateElement:function(e,t,n){var o=this,r=o.chart,a=r.chartArea,s=r.options,l=s.animation,u=(a.left+a.right)/2,c=(a.top+a.bottom)/2,d=s.rotation,h=s.rotation,f=o.getDataset(),p=n&&l.animateRotate?0:e.hidden?0:o.calculateCircumference(f.data[t])*(s.circumference/(2*Math.PI)),m=n&&l.animateScale?0:o.innerRadius,g=n&&l.animateScale?0:o.outerRadius,v=i.valueAtIndexOrDefault;i.extend(e,{_datasetIndex:o.index,_index:t,_model:{x:u+r.offsetX,y:c+r.offsetY,startAngle:d,endAngle:h,circumference:p,outerRadius:g,innerRadius:m,label:v(f.label,t,r.data.labels[t])}});var y=e._model;this.removeHoverStyle(e),n&&l.animateRotate||(y.startAngle=0===t?s.rotation:o.getMeta().data[t-1]._model.endAngle,y.endAngle=y.startAngle+y.circumference),e.pivot()},removeHoverStyle:function(t){e.DatasetController.prototype.removeHoverStyle.call(this,t,this.chart.options.elements.arc)},calculateTotal:function(){var e,t=this.getDataset(),n=this.getMeta(),o=0;return i.each(n.data,function(n,r){e=t.data[r],isNaN(e)||n.hidden||(o+=Math.abs(e))}),o},calculateCircumference:function(e){var t=this.getMeta().total;return t>0&&!isNaN(e)?2*Math.PI*(Math.abs(e)/t):0},getMaxBorderWidth:function(e){for(var t,n,o=0,r=this.index,i=e.length,a=0;a<i;a++)t=e[a]._model?e[a]._model.borderWidth:0,o=(n=e[a]._chart?e[a]._chart.config.data.datasets[r].hoverBorderWidth:0)>(o=t>o?t:o)?n:o;return o}})}},function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("line",{showLines:!0,spanGaps:!1,hover:{mode:"label"},scales:{xAxes:[{type:"category",id:"x-axis-0"}],yAxes:[{type:"linear",id:"y-axis-0"}]}}),e.exports=function(e){function t(e,t){return i.valueOrDefault(e.showLine,t.showLines)}e.controllers.line=e.DatasetController.extend({datasetElementType:r.Line,dataElementType:r.Point,update:function(e){var n,o,r,a=this,s=a.getMeta(),l=s.dataset,u=s.data||[],c=a.chart.options,d=c.elements.line,h=a.getScaleForId(s.yAxisID),f=a.getDataset(),p=t(f,c);for(p&&(r=l.custom||{},void 0!==f.tension&&void 0===f.lineTension&&(f.lineTension=f.tension),l._scale=h,l._datasetIndex=a.index,l._children=u,l._model={spanGaps:f.spanGaps?f.spanGaps:c.spanGaps,tension:r.tension?r.tension:i.valueOrDefault(f.lineTension,d.tension),backgroundColor:r.backgroundColor?r.backgroundColor:f.backgroundColor||d.backgroundColor,borderWidth:r.borderWidth?r.borderWidth:f.borderWidth||d.borderWidth,borderColor:r.borderColor?r.borderColor:f.borderColor||d.borderColor,borderCapStyle:r.borderCapStyle?r.borderCapStyle:f.borderCapStyle||d.borderCapStyle,borderDash:r.borderDash?r.borderDash:f.borderDash||d.borderDash,borderDashOffset:r.borderDashOffset?r.borderDashOffset:f.borderDashOffset||d.borderDashOffset,borderJoinStyle:r.borderJoinStyle?r.borderJoinStyle:f.borderJoinStyle||d.borderJoinStyle,fill:r.fill?r.fill:void 0!==f.fill?f.fill:d.fill,steppedLine:r.steppedLine?r.steppedLine:i.valueOrDefault(f.steppedLine,d.stepped),cubicInterpolationMode:r.cubicInterpolationMode?r.cubicInterpolationMode:i.valueOrDefault(f.cubicInterpolationMode,d.cubicInterpolationMode)},l.pivot()),n=0,o=u.length;n<o;++n)a.updateElement(u[n],n,e);for(p&&0!==l._model.tension&&a.updateBezierControlPoints(),n=0,o=u.length;n<o;++n)u[n].pivot()},getPointBackgroundColor:function(e,t){var n=this.chart.options.elements.point.backgroundColor,o=this.getDataset(),r=e.custom||{};return r.backgroundColor?n=r.backgroundColor:o.pointBackgroundColor?n=i.valueAtIndexOrDefault(o.pointBackgroundColor,t,n):o.backgroundColor&&(n=o.backgroundColor),n},getPointBorderColor:function(e,t){var n=this.chart.options.elements.point.borderColor,o=this.getDataset(),r=e.custom||{};return r.borderColor?n=r.borderColor:o.pointBorderColor?n=i.valueAtIndexOrDefault(o.pointBorderColor,t,n):o.borderColor&&(n=o.borderColor),n},getPointBorderWidth:function(e,t){var n=this.chart.options.elements.point.borderWidth,o=this.getDataset(),r=e.custom||{};return isNaN(r.borderWidth)?!isNaN(o.pointBorderWidth)||i.isArray(o.pointBorderWidth)?n=i.valueAtIndexOrDefault(o.pointBorderWidth,t,n):isNaN(o.borderWidth)||(n=o.borderWidth):n=r.borderWidth,n},updateElement:function(e,t,n){var o,r,a=this,s=a.getMeta(),l=e.custom||{},u=a.getDataset(),c=a.index,d=u.data[t],h=a.getScaleForId(s.yAxisID),f=a.getScaleForId(s.xAxisID),p=a.chart.options.elements.point;void 0!==u.radius&&void 0===u.pointRadius&&(u.pointRadius=u.radius),void 0!==u.hitRadius&&void 0===u.pointHitRadius&&(u.pointHitRadius=u.hitRadius),o=f.getPixelForValue("object"==typeof d?d:NaN,t,c),r=n?h.getBasePixel():a.calculatePointY(d,t,c),e._xScale=f,e._yScale=h,e._datasetIndex=c,e._index=t,e._model={x:o,y:r,skip:l.skip||isNaN(o)||isNaN(r),radius:l.radius||i.valueAtIndexOrDefault(u.pointRadius,t,p.radius),pointStyle:l.pointStyle||i.valueAtIndexOrDefault(u.pointStyle,t,p.pointStyle),backgroundColor:a.getPointBackgroundColor(e,t),borderColor:a.getPointBorderColor(e,t),borderWidth:a.getPointBorderWidth(e,t),tension:s.dataset._model?s.dataset._model.tension:0,steppedLine:!!s.dataset._model&&s.dataset._model.steppedLine,hitRadius:l.hitRadius||i.valueAtIndexOrDefault(u.pointHitRadius,t,p.hitRadius)}},calculatePointY:function(e,t,n){var o,r,i,a=this.chart,s=this.getMeta(),l=this.getScaleForId(s.yAxisID),u=0,c=0;if(l.options.stacked){for(o=0;o<n;o++)if(r=a.data.datasets[o],"line"===(i=a.getDatasetMeta(o)).type&&i.yAxisID===l.id&&a.isDatasetVisible(o)){var d=Number(l.getRightValue(r.data[t]));d<0?c+=d||0:u+=d||0}var h=Number(l.getRightValue(e));return h<0?l.getPixelForValue(c+h):l.getPixelForValue(u+h)}return l.getPixelForValue(e)},updateBezierControlPoints:function(){var e,t,n,o,r=this.getMeta(),a=this.chart.chartArea,s=r.data||[];function l(e,t,n){return Math.max(Math.min(e,n),t)}if(r.dataset._model.spanGaps&&(s=s.filter(function(e){return!e._model.skip})),"monotone"===r.dataset._model.cubicInterpolationMode)i.splineCurveMonotone(s);else for(e=0,t=s.length;e<t;++e)n=s[e]._model,o=i.splineCurve(i.previousItem(s,e)._model,n,i.nextItem(s,e)._model,r.dataset._model.tension),n.controlPointPreviousX=o.previous.x,n.controlPointPreviousY=o.previous.y,n.controlPointNextX=o.next.x,n.controlPointNextY=o.next.y;if(this.chart.options.elements.line.capBezierPoints)for(e=0,t=s.length;e<t;++e)(n=s[e]._model).controlPointPreviousX=l(n.controlPointPreviousX,a.left,a.right),n.controlPointPreviousY=l(n.controlPointPreviousY,a.top,a.bottom),n.controlPointNextX=l(n.controlPointNextX,a.left,a.right),n.controlPointNextY=l(n.controlPointNextY,a.top,a.bottom)},draw:function(){var e=this.chart,n=this.getMeta(),o=n.data||[],r=e.chartArea,a=o.length,s=0;for(i.canvas.clipArea(e.ctx,r),t(this.getDataset(),e.options)&&n.dataset.draw(),i.canvas.unclipArea(e.ctx);s<a;++s)o[s].draw(r)},setHoverStyle:function(e){var t=this.chart.data.datasets[e._datasetIndex],n=e._index,o=e.custom||{},r=e._model;r.radius=o.hoverRadius||i.valueAtIndexOrDefault(t.pointHoverRadius,n,this.chart.options.elements.point.hoverRadius),r.backgroundColor=o.hoverBackgroundColor||i.valueAtIndexOrDefault(t.pointHoverBackgroundColor,n,i.getHoverColor(r.backgroundColor)),r.borderColor=o.hoverBorderColor||i.valueAtIndexOrDefault(t.pointHoverBorderColor,n,i.getHoverColor(r.borderColor)),r.borderWidth=o.hoverBorderWidth||i.valueAtIndexOrDefault(t.pointHoverBorderWidth,n,r.borderWidth)},removeHoverStyle:function(e){var t=this,n=t.chart.data.datasets[e._datasetIndex],o=e._index,r=e.custom||{},a=e._model;void 0!==n.radius&&void 0===n.pointRadius&&(n.pointRadius=n.radius),a.radius=r.radius||i.valueAtIndexOrDefault(n.pointRadius,o,t.chart.options.elements.point.radius),a.backgroundColor=t.getPointBackgroundColor(e,o),a.borderColor=t.getPointBorderColor(e,o),a.borderWidth=t.getPointBorderWidth(e,o)}})}},function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("polarArea",{scale:{type:"radialLinear",angleLines:{display:!1},gridLines:{circular:!0},pointLabels:{display:!1},ticks:{beginAtZero:!0}},animation:{animateRotate:!0,animateScale:!0},startAngle:-.5*Math.PI,legendCallback:function(e){var t=[];t.push('<ul class="'+e.id+'-legend">');var n=e.data,o=n.datasets,r=n.labels;if(o.length)for(var i=0;i<o[0].data.length;++i)t.push('<li><span style="background-color:'+o[0].backgroundColor[i]+'"></span>'),r[i]&&t.push(r[i]),t.push("</li>");return t.push("</ul>"),t.join("")},legend:{labels:{generateLabels:function(e){var t=e.data;return t.labels.length&&t.datasets.length?t.labels.map(function(n,o){var r=e.getDatasetMeta(0),a=t.datasets[0],s=r.data[o].custom||{},l=i.valueAtIndexOrDefault,u=e.options.elements.arc;return{text:n,fillStyle:s.backgroundColor?s.backgroundColor:l(a.backgroundColor,o,u.backgroundColor),strokeStyle:s.borderColor?s.borderColor:l(a.borderColor,o,u.borderColor),lineWidth:s.borderWidth?s.borderWidth:l(a.borderWidth,o,u.borderWidth),hidden:isNaN(a.data[o])||r.data[o].hidden,index:o}}):[]}},onClick:function(e,t){var n,o,r,i=t.index,a=this.chart;for(n=0,o=(a.data.datasets||[]).length;n<o;++n)(r=a.getDatasetMeta(n)).data[i].hidden=!r.data[i].hidden;a.update()}},tooltips:{callbacks:{title:function(){return""},label:function(e,t){return t.labels[e.index]+": "+e.yLabel}}}}),e.exports=function(e){e.controllers.polarArea=e.DatasetController.extend({dataElementType:r.Arc,linkScales:i.noop,update:function(e){var t=this,n=t.chart,o=n.chartArea,r=t.getMeta(),a=n.options,s=a.elements.arc,l=Math.min(o.right-o.left,o.bottom-o.top);n.outerRadius=Math.max((l-s.borderWidth/2)/2,0),n.innerRadius=Math.max(a.cutoutPercentage?n.outerRadius/100*a.cutoutPercentage:1,0),n.radiusLength=(n.outerRadius-n.innerRadius)/n.getVisibleDatasetCount(),t.outerRadius=n.outerRadius-n.radiusLength*t.index,t.innerRadius=t.outerRadius-n.radiusLength,r.count=t.countVisibleElements(),i.each(r.data,function(n,o){t.updateElement(n,o,e)})},updateElement:function(e,t,n){for(var o=this,r=o.chart,a=o.getDataset(),s=r.options,l=s.animation,u=r.scale,c=r.data.labels,d=o.calculateCircumference(a.data[t]),h=u.xCenter,f=u.yCenter,p=0,m=o.getMeta(),g=0;g<t;++g)isNaN(a.data[g])||m.data[g].hidden||++p;var v=s.startAngle,y=e.hidden?0:u.getDistanceFromCenterForValue(a.data[t]),_=v+d*p,w=_+(e.hidden?0:d),b=l.animateScale?0:u.getDistanceFromCenterForValue(a.data[t]);i.extend(e,{_datasetIndex:o.index,_index:t,_scale:u,_model:{x:h,y:f,innerRadius:0,outerRadius:n?b:y,startAngle:n&&l.animateRotate?v:_,endAngle:n&&l.animateRotate?v:w,label:i.valueAtIndexOrDefault(c,t,c[t])}}),o.removeHoverStyle(e),e.pivot()},removeHoverStyle:function(t){e.DatasetController.prototype.removeHoverStyle.call(this,t,this.chart.options.elements.arc)},countVisibleElements:function(){var e=this.getDataset(),t=this.getMeta(),n=0;return i.each(t.data,function(t,o){isNaN(e.data[o])||t.hidden||n++}),n},calculateCircumference:function(e){var t=this.getMeta().count;return t>0&&!isNaN(e)?2*Math.PI/t:0}})}},function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("radar",{scale:{type:"radialLinear"},elements:{line:{tension:0}}}),e.exports=function(e){e.controllers.radar=e.DatasetController.extend({datasetElementType:r.Line,dataElementType:r.Point,linkScales:i.noop,update:function(e){var t=this,n=t.getMeta(),o=n.dataset,r=n.data,a=o.custom||{},s=t.getDataset(),l=t.chart.options.elements.line,u=t.chart.scale;void 0!==s.tension&&void 0===s.lineTension&&(s.lineTension=s.tension),i.extend(n.dataset,{_datasetIndex:t.index,_scale:u,_children:r,_loop:!0,_model:{tension:a.tension?a.tension:i.valueOrDefault(s.lineTension,l.tension),backgroundColor:a.backgroundColor?a.backgroundColor:s.backgroundColor||l.backgroundColor,borderWidth:a.borderWidth?a.borderWidth:s.borderWidth||l.borderWidth,borderColor:a.borderColor?a.borderColor:s.borderColor||l.borderColor,fill:a.fill?a.fill:void 0!==s.fill?s.fill:l.fill,borderCapStyle:a.borderCapStyle?a.borderCapStyle:s.borderCapStyle||l.borderCapStyle,borderDash:a.borderDash?a.borderDash:s.borderDash||l.borderDash,borderDashOffset:a.borderDashOffset?a.borderDashOffset:s.borderDashOffset||l.borderDashOffset,borderJoinStyle:a.borderJoinStyle?a.borderJoinStyle:s.borderJoinStyle||l.borderJoinStyle}}),n.dataset.pivot(),i.each(r,function(n,o){t.updateElement(n,o,e)},t),t.updateBezierControlPoints()},updateElement:function(e,t,n){var o=this,r=e.custom||{},a=o.getDataset(),s=o.chart.scale,l=o.chart.options.elements.point,u=s.getPointPositionForValue(t,a.data[t]);void 0!==a.radius&&void 0===a.pointRadius&&(a.pointRadius=a.radius),void 0!==a.hitRadius&&void 0===a.pointHitRadius&&(a.pointHitRadius=a.hitRadius),i.extend(e,{_datasetIndex:o.index,_index:t,_scale:s,_model:{x:n?s.xCenter:u.x,y:n?s.yCenter:u.y,tension:r.tension?r.tension:i.valueOrDefault(a.lineTension,o.chart.options.elements.line.tension),radius:r.radius?r.radius:i.valueAtIndexOrDefault(a.pointRadius,t,l.radius),backgroundColor:r.backgroundColor?r.backgroundColor:i.valueAtIndexOrDefault(a.pointBackgroundColor,t,l.backgroundColor),borderColor:r.borderColor?r.borderColor:i.valueAtIndexOrDefault(a.pointBorderColor,t,l.borderColor),borderWidth:r.borderWidth?r.borderWidth:i.valueAtIndexOrDefault(a.pointBorderWidth,t,l.borderWidth),pointStyle:r.pointStyle?r.pointStyle:i.valueAtIndexOrDefault(a.pointStyle,t,l.pointStyle),hitRadius:r.hitRadius?r.hitRadius:i.valueAtIndexOrDefault(a.pointHitRadius,t,l.hitRadius)}}),e._model.skip=r.skip?r.skip:isNaN(e._model.x)||isNaN(e._model.y)},updateBezierControlPoints:function(){var e=this.chart.chartArea,t=this.getMeta();i.each(t.data,function(n,o){var r=n._model,a=i.splineCurve(i.previousItem(t.data,o,!0)._model,r,i.nextItem(t.data,o,!0)._model,r.tension);r.controlPointPreviousX=Math.max(Math.min(a.previous.x,e.right),e.left),r.controlPointPreviousY=Math.max(Math.min(a.previous.y,e.bottom),e.top),r.controlPointNextX=Math.max(Math.min(a.next.x,e.right),e.left),r.controlPointNextY=Math.max(Math.min(a.next.y,e.bottom),e.top),n.pivot()})},setHoverStyle:function(e){var t=this.chart.data.datasets[e._datasetIndex],n=e.custom||{},o=e._index,r=e._model;r.radius=n.hoverRadius?n.hoverRadius:i.valueAtIndexOrDefault(t.pointHoverRadius,o,this.chart.options.elements.point.hoverRadius),r.backgroundColor=n.hoverBackgroundColor?n.hoverBackgroundColor:i.valueAtIndexOrDefault(t.pointHoverBackgroundColor,o,i.getHoverColor(r.backgroundColor)),r.borderColor=n.hoverBorderColor?n.hoverBorderColor:i.valueAtIndexOrDefault(t.pointHoverBorderColor,o,i.getHoverColor(r.borderColor)),r.borderWidth=n.hoverBorderWidth?n.hoverBorderWidth:i.valueAtIndexOrDefault(t.pointHoverBorderWidth,o,r.borderWidth)},removeHoverStyle:function(e){var t=this.chart.data.datasets[e._datasetIndex],n=e.custom||{},o=e._index,r=e._model,a=this.chart.options.elements.point;r.radius=n.radius?n.radius:i.valueAtIndexOrDefault(t.pointRadius,o,a.radius),r.backgroundColor=n.backgroundColor?n.backgroundColor:i.valueAtIndexOrDefault(t.pointBackgroundColor,o,a.backgroundColor),r.borderColor=n.borderColor?n.borderColor:i.valueAtIndexOrDefault(t.pointBorderColor,o,a.borderColor),r.borderWidth=n.borderWidth?n.borderWidth:i.valueAtIndexOrDefault(t.pointBorderWidth,o,a.borderWidth)}})}},function(e,t,n){"use strict";n(8)._set("scatter",{hover:{mode:"single"},scales:{xAxes:[{id:"x-axis-1",type:"linear",position:"bottom"}],yAxes:[{id:"y-axis-1",type:"linear",position:"left"}]},showLines:!1,tooltips:{callbacks:{title:function(){return""},label:function(e){return"("+e.xLabel+", "+e.yLabel+")"}}}}),e.exports=function(e){e.controllers.scatter=e.controllers.line}},function(e,t,n){"use strict";e.exports=function(e){e.Bar=function(t,n){return n.type="bar",new e(t,n)}}},function(e,t,n){"use strict";e.exports=function(e){e.Bubble=function(t,n){return n.type="bubble",new e(t,n)}}},function(e,t,n){"use strict";e.exports=function(e){e.Doughnut=function(t,n){return n.type="doughnut",new e(t,n)}}},function(e,t,n){"use strict";e.exports=function(e){e.Line=function(t,n){return n.type="line",new e(t,n)}}},function(e,t,n){"use strict";e.exports=function(e){e.PolarArea=function(t,n){return n.type="polarArea",new e(t,n)}}},function(e,t,n){"use strict";e.exports=function(e){e.Radar=function(t,n){return n.type="radar",new e(t,n)}}},function(e,t,n){"use strict";e.exports=function(e){e.Scatter=function(t,n){return n.type="scatter",new e(t,n)}}},function(e,t,n){"use strict";e.exports={},e.exports.filler=n(404),e.exports.legend=n(405),e.exports.title=n(406)},function(e,t,n){"use strict";var o=n(8),r=n(21),i=n(6);o._set("global",{plugins:{filler:{propagate:!0}}});var a={dataset:function(e){var t=e.fill,n=e.chart,o=n.getDatasetMeta(t),r=o&&n.isDatasetVisible(t)&&o.dataset._children||[],i=r.length||0;return i?function(e,t){return t<i&&r[t]._view||null}:null},boundary:function(e){var t=e.boundary,n=t?t.x:null,o=t?t.y:null;return function(e){return{x:null===n?e.x:n,y:null===o?e.y:o}}}};function s(e,t,n){var o,r=e._model||{},i=r.fill;if(void 0===i&&(i=!!r.backgroundColor),!1===i||null===i)return!1;if(!0===i)return"origin";if(o=parseFloat(i,10),isFinite(o)&&Math.floor(o)===o)return"-"!==i[0]&&"+"!==i[0]||(o=t+o),!(o===t||o<0||o>=n)&&o;switch(i){case"bottom":return"start";case"top":return"end";case"zero":return"origin";case"origin":case"start":case"end":return i;default:return!1}}function l(e){var t,n=e.el._model||{},o=e.el._scale||{},r=e.fill,i=null;if(isFinite(r))return null;if("start"===r?i=void 0===n.scaleBottom?o.bottom:n.scaleBottom:"end"===r?i=void 0===n.scaleTop?o.top:n.scaleTop:void 0!==n.scaleZero?i=n.scaleZero:o.getBasePosition?i=o.getBasePosition():o.getBasePixel&&(i=o.getBasePixel()),null!=i){if(void 0!==i.x&&void 0!==i.y)return i;if("number"==typeof i&&isFinite(i))return{x:(t=o.isHorizontal())?i:null,y:t?null:i}}return null}function u(e,t,n){var o,r=e[t].fill,i=[t];if(!n)return r;for(;!1!==r&&-1===i.indexOf(r);){if(!isFinite(r))return r;if(!(o=e[r]))return!1;if(o.visible)return r;i.push(r),r=o.fill}return!1}function c(e){var t=e.fill,n="dataset";return!1===t?null:(isFinite(t)||(n="boundary"),a[n](e))}function d(e){return e&&!e.skip}function h(e,t,n,o,r){var a;if(o&&r){for(e.moveTo(t[0].x,t[0].y),a=1;a<o;++a)i.canvas.lineTo(e,t[a-1],t[a]);for(e.lineTo(n[r-1].x,n[r-1].y),a=r-1;a>0;--a)i.canvas.lineTo(e,n[a],n[a-1],!0)}}e.exports={id:"filler",afterDatasetsUpdate:function(e,t){var n,o,i,a,d=(e.data.datasets||[]).length,h=t.propagate,f=[];for(o=0;o<d;++o)a=null,(i=(n=e.getDatasetMeta(o)).dataset)&&i._model&&i instanceof r.Line&&(a={visible:e.isDatasetVisible(o),fill:s(i,o,d),chart:e,el:i}),n.$filler=a,f.push(a);for(o=0;o<d;++o)(a=f[o])&&(a.fill=u(f,o,h),a.boundary=l(a),a.mapper=c(a))},beforeDatasetDraw:function(e,t){var n=t.meta.$filler;if(n){var r=e.ctx,a=n.el,s=a._view,l=a._children||[],u=n.mapper,c=s.backgroundColor||o.global.defaultColor;u&&c&&l.length&&(i.canvas.clipArea(r,e.chartArea),function(e,t,n,o,r,i){var a,s,l,u,c,f,p,m=t.length,g=o.spanGaps,v=[],y=[],_=0,w=0;for(e.beginPath(),a=0,s=m+!!i;a<s;++a)c=n(u=t[l=a%m]._view,l,o),f=d(u),p=d(c),f&&p?(_=v.push(u),w=y.push(c)):_&&w&&(g?(f&&v.push(u),p&&y.push(c)):(h(e,v,y,_,w),_=w=0,v=[],y=[]));h(e,v,y,_,w),e.closePath(),e.fillStyle=r,e.fill()}(r,l,u,s,c,a._loop),i.canvas.unclipArea(r))}}}},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6),a=n(27),s=i.noop;function l(e,t){return e.usePointStyle?t*Math.SQRT2:e.boxWidth}o._set("global",{legend:{display:!0,position:"top",fullWidth:!0,reverse:!1,weight:1e3,onClick:function(e,t){var n=t.datasetIndex,o=this.chart,r=o.getDatasetMeta(n);r.hidden=null===r.hidden?!o.data.datasets[n].hidden:null,o.update()},onHover:null,labels:{boxWidth:40,padding:10,generateLabels:function(e){var t=e.data;return i.isArray(t.datasets)?t.datasets.map(function(t,n){return{text:t.label,fillStyle:i.isArray(t.backgroundColor)?t.backgroundColor[0]:t.backgroundColor,hidden:!e.isDatasetVisible(n),lineCap:t.borderCapStyle,lineDash:t.borderDash,lineDashOffset:t.borderDashOffset,lineJoin:t.borderJoinStyle,lineWidth:t.borderWidth,strokeStyle:t.borderColor,pointStyle:t.pointStyle,datasetIndex:n}},this):[]}}},legendCallback:function(e){var t=[];t.push('<ul class="'+e.id+'-legend">');for(var n=0;n<e.data.datasets.length;n++)t.push('<li><span style="background-color:'+e.data.datasets[n].backgroundColor+'"></span>'),e.data.datasets[n].label&&t.push(e.data.datasets[n].label),t.push("</li>");return t.push("</ul>"),t.join("")}});var u=r.extend({initialize:function(e){i.extend(this,e),this.legendHitBoxes=[],this.doughnutMode=!1},beforeUpdate:s,update:function(e,t,n){var o=this;return o.beforeUpdate(),o.maxWidth=e,o.maxHeight=t,o.margins=n,o.beforeSetDimensions(),o.setDimensions(),o.afterSetDimensions(),o.beforeBuildLabels(),o.buildLabels(),o.afterBuildLabels(),o.beforeFit(),o.fit(),o.afterFit(),o.afterUpdate(),o.minSize},afterUpdate:s,beforeSetDimensions:s,setDimensions:function(){var e=this;e.isHorizontal()?(e.width=e.maxWidth,e.left=0,e.right=e.width):(e.height=e.maxHeight,e.top=0,e.bottom=e.height),e.paddingLeft=0,e.paddingTop=0,e.paddingRight=0,e.paddingBottom=0,e.minSize={width:0,height:0}},afterSetDimensions:s,beforeBuildLabels:s,buildLabels:function(){var e=this,t=e.options.labels||{},n=i.callback(t.generateLabels,[e.chart],e)||[];t.filter&&(n=n.filter(function(n){return t.filter(n,e.chart.data)})),e.options.reverse&&n.reverse(),e.legendItems=n},afterBuildLabels:s,beforeFit:s,fit:function(){var e=this,t=e.options,n=t.labels,r=t.display,a=e.ctx,s=o.global,u=i.valueOrDefault,c=u(n.fontSize,s.defaultFontSize),d=u(n.fontStyle,s.defaultFontStyle),h=u(n.fontFamily,s.defaultFontFamily),f=i.fontString(c,d,h),p=e.legendHitBoxes=[],m=e.minSize,g=e.isHorizontal();if(g?(m.width=e.maxWidth,m.height=r?10:0):(m.width=r?10:0,m.height=e.maxHeight),r)if(a.font=f,g){var v=e.lineWidths=[0],y=e.legendItems.length?c+n.padding:0;a.textAlign="left",a.textBaseline="top",i.each(e.legendItems,function(t,o){var r=l(n,c)+c/2+a.measureText(t.text).width;v[v.length-1]+r+n.padding>=e.width&&(y+=c+n.padding,v[v.length]=e.left),p[o]={left:0,top:0,width:r,height:c},v[v.length-1]+=r+n.padding}),m.height+=y}else{var _=n.padding,w=e.columnWidths=[],b=n.padding,C=0,M=0,k=c+_;i.each(e.legendItems,function(e,t){var o=l(n,c)+c/2+a.measureText(e.text).width;M+k>m.height&&(b+=C+n.padding,w.push(C),C=0,M=0),C=Math.max(C,o),M+=k,p[t]={left:0,top:0,width:o,height:c}}),b+=C,w.push(C),m.width+=b}e.width=m.width,e.height=m.height},afterFit:s,isHorizontal:function(){return"top"===this.options.position||"bottom"===this.options.position},draw:function(){var e=this,t=e.options,n=t.labels,r=o.global,a=r.elements.line,s=e.width,u=e.lineWidths;if(t.display){var c,d=e.ctx,h=i.valueOrDefault,f=h(n.fontColor,r.defaultFontColor),p=h(n.fontSize,r.defaultFontSize),m=h(n.fontStyle,r.defaultFontStyle),g=h(n.fontFamily,r.defaultFontFamily),v=i.fontString(p,m,g);d.textAlign="left",d.textBaseline="middle",d.lineWidth=.5,d.strokeStyle=f,d.fillStyle=f,d.font=v;var y=l(n,p),_=e.legendHitBoxes,w=e.isHorizontal();c=w?{x:e.left+(s-u[0])/2,y:e.top+n.padding,line:0}:{x:e.left+n.padding,y:e.top+n.padding,line:0};var b=p+n.padding;i.each(e.legendItems,function(o,l){var f=d.measureText(o.text).width,m=y+p/2+f,g=c.x,v=c.y;w?g+m>=s&&(v=c.y+=b,c.line++,g=c.x=e.left+(s-u[c.line])/2):v+b>e.bottom&&(g=c.x=g+e.columnWidths[c.line]+n.padding,v=c.y=e.top+n.padding,c.line++),function(e,n,o){if(!(isNaN(y)||y<=0)){d.save(),d.fillStyle=h(o.fillStyle,r.defaultColor),d.lineCap=h(o.lineCap,a.borderCapStyle),d.lineDashOffset=h(o.lineDashOffset,a.borderDashOffset),d.lineJoin=h(o.lineJoin,a.borderJoinStyle),d.lineWidth=h(o.lineWidth,a.borderWidth),d.strokeStyle=h(o.strokeStyle,r.defaultColor);var s=0===h(o.lineWidth,a.borderWidth);if(d.setLineDash&&d.setLineDash(h(o.lineDash,a.borderDash)),t.labels&&t.labels.usePointStyle){var l=p*Math.SQRT2/2,u=l/Math.SQRT2,c=e+u,f=n+u;i.canvas.drawPoint(d,o.pointStyle,l,c,f)}else s||d.strokeRect(e,n,y,p),d.fillRect(e,n,y,p);d.restore()}}(g,v,o),_[l].left=g,_[l].top=v,function(e,t,n,o){var r=p/2,i=y+r+e,a=t+r;d.fillText(n.text,i,a),n.hidden&&(d.beginPath(),d.lineWidth=2,d.moveTo(i,a),d.lineTo(i+o,a),d.stroke())}(g,v,o,f),w?c.x+=m+n.padding:c.y+=b})}},handleEvent:function(e){var t=this,n=t.options,o="mouseup"===e.type?"click":e.type,r=!1;if("mousemove"===o){if(!n.onHover)return}else{if("click"!==o)return;if(!n.onClick)return}var i=e.x,a=e.y;if(i>=t.left&&i<=t.right&&a>=t.top&&a<=t.bottom)for(var s=t.legendHitBoxes,l=0;l<s.length;++l){var u=s[l];if(i>=u.left&&i<=u.left+u.width&&a>=u.top&&a<=u.top+u.height){if("click"===o){n.onClick.call(t,e.native,t.legendItems[l]),r=!0;break}if("mousemove"===o){n.onHover.call(t,e.native,t.legendItems[l]),r=!0;break}}}return r}});function c(e,t){var n=new u({ctx:e.ctx,options:t,chart:e});a.configure(e,n,t),a.addBox(e,n),e.legend=n}e.exports={id:"legend",_element:u,beforeInit:function(e){var t=e.options.legend;t&&c(e,t)},beforeUpdate:function(e){var t=e.options.legend,n=e.legend;t?(i.mergeIf(t,o.global.legend),n?(a.configure(e,n,t),n.options=t):c(e,t)):n&&(a.removeBox(e,n),delete e.legend)},afterEvent:function(e,t){var n=e.legend;n&&n.handleEvent(t)}}},function(e,t,n){"use strict";var o=n(8),r=n(17),i=n(6),a=n(27),s=i.noop;o._set("global",{title:{display:!1,fontStyle:"bold",fullWidth:!0,lineHeight:1.2,padding:10,position:"top",text:"",weight:2e3}});var l=r.extend({initialize:function(e){i.extend(this,e),this.legendHitBoxes=[]},beforeUpdate:s,update:function(e,t,n){var o=this;return o.beforeUpdate(),o.maxWidth=e,o.maxHeight=t,o.margins=n,o.beforeSetDimensions(),o.setDimensions(),o.afterSetDimensions(),o.beforeBuildLabels(),o.buildLabels(),o.afterBuildLabels(),o.beforeFit(),o.fit(),o.afterFit(),o.afterUpdate(),o.minSize},afterUpdate:s,beforeSetDimensions:s,setDimensions:function(){var e=this;e.isHorizontal()?(e.width=e.maxWidth,e.left=0,e.right=e.width):(e.height=e.maxHeight,e.top=0,e.bottom=e.height),e.paddingLeft=0,e.paddingTop=0,e.paddingRight=0,e.paddingBottom=0,e.minSize={width:0,height:0}},afterSetDimensions:s,beforeBuildLabels:s,buildLabels:s,afterBuildLabels:s,beforeFit:s,fit:function(){var e=this,t=i.valueOrDefault,n=e.options,r=n.display,a=t(n.fontSize,o.global.defaultFontSize),s=e.minSize,l=i.isArray(n.text)?n.text.length:1,u=i.options.toLineHeight(n.lineHeight,a),c=r?l*u+2*n.padding:0;e.isHorizontal()?(s.width=e.maxWidth,s.height=c):(s.width=c,s.height=e.maxHeight),e.width=s.width,e.height=s.height},afterFit:s,isHorizontal:function(){var e=this.options.position;return"top"===e||"bottom"===e},draw:function(){var e=this,t=e.ctx,n=i.valueOrDefault,r=e.options,a=o.global;if(r.display){var s,l,u,c=n(r.fontSize,a.defaultFontSize),d=n(r.fontStyle,a.defaultFontStyle),h=n(r.fontFamily,a.defaultFontFamily),f=i.fontString(c,d,h),p=i.options.toLineHeight(r.lineHeight,c),m=p/2+r.padding,g=0,v=e.top,y=e.left,_=e.bottom,w=e.right;t.fillStyle=n(r.fontColor,a.defaultFontColor),t.font=f,e.isHorizontal()?(l=y+(w-y)/2,u=v+m,s=w-y):(l="left"===r.position?y+m:w-m,u=v+(_-v)/2,s=_-v,g=Math.PI*("left"===r.position?-.5:.5)),t.save(),t.translate(l,u),t.rotate(g),t.textAlign="center",t.textBaseline="middle";var b=r.text;if(i.isArray(b))for(var C=0,M=0;M<b.length;++M)t.fillText(b[M],0,C,s),C+=p;else t.fillText(b,0,0,s);t.restore()}}});function u(e,t){var n=new l({ctx:e.ctx,options:t,chart:e});a.configure(e,n,t),a.addBox(e,n),e.titleBlock=n}e.exports={id:"title",_element:l,beforeInit:function(e){var t=e.options.title;t&&u(e,t)},beforeUpdate:function(e){var t=e.options.title,n=e.titleBlock;t?(i.mergeIf(t,o.global.title),n?(a.configure(e,n,t),n.options=t):u(e,t)):n&&(a.removeBox(e,n),delete e.titleBlock)}}}]]);